WebP hack thread

Since WebP will never get adopted on Sup Forums because herosheema is busy watching chinese cartoons then I propose we bring back the WebP hack back from the dead. It will also cuck apple users into converting the files into images on their fagbook to use them as a bonus.

Hack:
for %f IN (*.png) DO ffmpeg -loop 1 -i "%~nf.png" -an -c:v libvpx -qmin 20 -quality best -threads 4 -t 4 -r 4 "%~nf.webm"

The hack basically uses the WebM container to store a VP8 video stream with a duration of 4 seconds of a still image. Why a 4 second image? Well it turns out if you just store a single frame it will loop infinitely and cause your CPU to burst into flames.

Other urls found in this thread:

xooyoozoo.github.io/yolo-octo-bugfixes/#fruits&webp=s&bpg=s
twitter.com/NSFWRedditVideo

>Well it turns out if you just store a single frame it will loop infinitely and cause your CPU to burst into flames.
u wot m8?

You can change the output quality of the WebM by modifying the -qmin parameter. 4 means near-lossless and 63 means super shitty quality.

...

See for yourself. WebM related is just a png converted to a webm without all the special parameters.

>680x641
>2.83MB
lmao what did you do?

iCucks and tumblrinas on suicide watch

-qmin 63 test

Cool

>lmao what did you do?

Perhaps you should play the video.

FYI: qmin sets the lower bound of quality, qmax sets the upper bound of quality (quantization factor). You're also wasting data running above 1 fps.

All I get is a still image playing 500 frames in one second. How did you manage to get the file size to 2.83MB? Is every frame different or are they the same?

Because if they are all the same than VP8 is pretty fucking dumb, why would it encode 500 frames separately when the first one is the one used in all the other frames?

>FYI: qmin sets the lower bound of quality, qmax sets the upper bound of quality (quantization factor).
I know, I just want VP8 to use specific QF to control output quality and file size.

>You're also wasting data running above 1 fps.
I'm afraid running below 4 fps will cause CPU usage spikes though. No point in this WebP hack if it fucking obliterates your CPU.

Anybody know what the max 4chin WebM resolution is?

I think I dun goofed. Is there anyway to control the quality precisely beside providing the -qmin and -qmax parameters? Seems like a fucking drag to have to type out both of them. -crf doesn't seem to affect over all final quality/file size.

Testing 1200x1600 res WebM

When the fuck is VP9 support getting added?

try the same maximum as normal images and merge sort from there.

-b:v 100M
the number being the bitrate in K/M/G etc

Thanks!

I'm kinda curious -t 1 -r 1 doesn't work?

I'm too lazy to sit down and do A/B testing so someone just lay it out for me straight; are the VP9 streams on youtube actually better quality than the H.264 streams? The VP9 streams use a much lower bitrate so I would think they're equal or maybe even worse.

just leave out the -r

...

>I'm too lazy to sit down and do A/B testing so someone just lay it out for me straight; are the VP9 streams on youtube actually better quality than the H.264 streams?
Yes, modern VP9 btfo H264 at the same bitrate. It is however more CPU intensive than HEVC though. Wish more HW support would exist for it.

Okay

I think large short static webms are probably a bad deal.
post your whole line.

That somehow made it worse, lmao

ffmpeg -c:v libvpx -qmin 0 -qmax 0 -quality best -t 1 "%~n1.webm"

replace qmin qmax and quality with -b:v 100K

2048x2048 WebM test

2048x2048 confirmed as max WebM res, nothing bigger than that will upload.

The main thing is I'm trying to get something that is as close to the original file as possible. That single frame webm is 1/5th the size of the original but its very close to visually identical from what I can tell.

Actually I'm pretty sure that's said in the /wsg/ sticky.
It also has a lot of ffmpeg tips, everyone go there.

OP here something bad happen gtg, sorry

Doesn't seem to do anything to my CPU, just kinda ramps up the usage but it just goes up and down like normal

Now what's it have to do with apple users?

iOS doesn't support vpx

>Doesn't seem to do anything to my CPU, just kinda ramps up the usage but it just goes up and down like normal
This causes unnecessary stress on the CPU.

>Now what's it have to do with apple users?
aplel users can't save webms.

You can still open them in vlc or safari but it's an annoying chore to have to do for every webm you encounter. This is partly why I sold my iphone 6 and got and android phone instead.

>tfw I can view this in clover with 0 problems
I like this hack. Maybe it will help keep more redditors out of Sup Forums.

The video is 6144fps

xooyoozoo.github.io/yolo-octo-bugfixes/#fruits&webp=s&bpg=s
BPG is superior, but I agree. WebP is better than JPEG.

1min load avg on a dual core got to 0.99
nice work

this is a fucking terrible hack and you should feel disgusted for seriously suggesting this

Hiroshima won't allow webp, what else are we supposed to do?

BPG isn't free

Neither is JPEG or h.264

>2048x2048
>loads instantly

why can't we have webp?

Use PNG or JPEG

>click on webm to expand it
>it starts loading and quickly fades out to black
>it then fades back in with a darkened overlay
>right click -> hit play
>it now fades in but with the wrong colors and while consuming shittons of CPU
webm for still images is truly the future

There's no support on it for iOS at all. I think this is the main reason why Sup Forums is holding back. If everyone switched to webp overnight all iOS users would be left in the dark. Who knows, maybe tim cuck is paying Sup Forums from supporting webp too.

Thats actually your browser doing that.
Get a better browser.

No one uses iOS here except for like 10 faggots that don't matter.

>If everyone switched to webp overnight all iOS users would be left in the dark.
And Firefox

but both would be patched instantly since now the whole internet is using webp

Firefox supports webp.

You're using an iPhone user aren't cha? :^)

...

... the cuck assumed loudly, as he flaunted his botnet status

It supports vpx, it cannot open webp images directly because it doesn't understand the container format. If you convert them to webm then it can read them

>browsing Sup Forums on a phone
summer sure is here

can't wait for you fuckers to have some classes to attend to again

forgot to add it

>open “image” in new tab for closer inspection
>can't just zoom in or out as normal, always scales down to browser size
just no

wew lad. Glad I started using Chrome a year ago, Firefox is a fat feminist train wreck.

>proud user of the botnet that doesn't even hide the fact that it openly spies on its users
stay bluepilled cuck

Yeah my bad didn't know he meant an image.

You know Firefox is truely fucked when webkit-gtk starts to have better support.

>enjoys using a web browser taken over by feminists
>calls me a cuck

What does it look like for iphone users?

who gives a shit?

>caring about apple, ever

I'm actually a college dropout working as a plumber but k

>implying enjoyment
I don't enjoy using firefox, it's just the least shit option in a cesspool of ridiculously shitty browsers

out of the box, firefox is a piece of garbage, but unlike chrome you can actually install enough addons and make enough about:config tweaks to turn it into something that can remotely be considered a browser

can't say that for anything else

ex-iphone user here: you have to open each of these webms individually in safari or vlc.

Why do you call this a webp hack, when it has almost nothing to do with webp?

Webp would be fucking glorious for animations.

moot was a retard for implementing webm, and then going out of his way to remove sound in them, when webp only supports video.

A huge problem I have with webm is that if I try to seek in the video while it's still loading, even if I'm seeking into a period that's been loaded, the video freezes completely until the whole thing is loaded.

o-oh

It's not more intensive for decoding, VP9 is less complex than h265
libvpx is still slower than x265 though, encoding still takes ages

bump

chrome works fine on my laptop

It's not a problem when you open it in a separate tab but when you open it inside the thread it causes the cpu to panic.

I opened it, but nothing serious happend (a little more cpu load than ususal (at maximum it was 25% on a quad core system)).

Does this only affect a specific browser engine?

Maybe, cpu usage goes to like 80% when I open the webm inside the thread on firefox. Never used any other browser so I don't know how other browsers behave.

Still we should stick to OPs parameters just to be safe.

I tried epiphany on linux (uses webkit) and there was no lag. I even opened multiple of the previous webms and still no lag (but then the CPU usage was like 50% but not more than that)

Fuck off with this shit you stupid niggers. It's lossy and it acts like a fucking video player.

Holy shit, look at that file size.

>and cause your CPU to burst into flames

I don't get it (hurr I'm dum) why would this be a problem? It's just a video. Are people to stupid to see that it's a video? Don't they see the pause/play button or look at the extension (but that could be changed (It's still a vide if you calll it .png.penis.lel.kek.hack.lol))?

>why would this be a problem?
Because when you open it in a browser it will auto-loop that same frame over and over again infinitely. This will cause pointless stress on the CPU and overall slow the users computer with no benefit whatsoever. Yes you can stop this by hitting pause but it's a fucking pain to do and using OPs parameters ensure that no significant CPU resources are used even when the video auto-loops every 4 seconds.

...

Follow OPs parameter settings you nigger. All that looping is gonna set my laptop on fire.

Did this on Firefox.
It wasn't unresponsive or anything, but it did use a fair bit of power.

Testing webm with -qmin and -qmax of 63 with -filter:v unsharp=luma_msize_x=7:luma_msize_y=7:luma_amount=2.5 added in.

Holy shit that actually looks okay. Gonna try this with a higher res image.

Or, in webm if I must.

I have also openend the "poop.webm" in a webkit based browser (also epiphany, like ) but it didn't stress my cpu much. No lag and my laptop is "old" (ca. 2011)

As for the rate/time thing.
This is 2s at 1fps and it doesn't add significant load when open.
I think so long as your video has more than one frame, firefox is happy.
The thing here being that the file is smaller (half IIRC) that way.

It's funny to see so many germans using this imageboard lately (I noticed it in other threads as well (screenshots or file names))

Testing another webm with same parameters as This is pretty cool. Maybe I should join YIFY.

Not all browsers will behave the same so for the sake of compatibility we should stick to OPs parameters.

Testing Webm with -t 2 -r 1

Tell me if this stresses out your CPU guys.

OPs parameters result in a nearly doubled filesize.
That's all well and good, but if the parameters I provided work in Chrome as well, that's pretty much every browser happy with it.

This is essentially a kludge until webp is properly supported on channel 4 anyway.

almost no difference (only a little bit more)

For reference this is with OPs parameters.

No but this does

Now gonna post equivalent jpegs.
This one is the same size as the 2s/1fps webm I posed.

This one is the same size as OPs spec (4s/4fps)

>OPs parameters result in a nearly doubled filesize.
False. going from -t 4 -r 4 to -t 2 -r 1 only reduces file size by ~20%

see and Still if -t 2 -r 1 doesn't cause much unnecessary cpu usage then it should be used instead.