[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

How the fuck do I compress a 4 minute video into a 4MB webm for

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 58
Thread images: 9

How the fuck do I compress a 4 minute video into a 4MB webm for 4chan and make it look good?
Help.
>>
>>60777987
nigger you do realize its impossible right

unless you reduce resolution to ant-tier or hirohito allows vp9 webms
>>
>>60778010
Well, let's go smaller. Can I compress a 2 minute video into a 4MB webm for 4chan and make it look good?
>>
Just use the pied piper app
>>
>>60777987
Isn't that Caska? I don't remember seeing a scene like that.
>>
>>60778052
>pied piper app
what now?
>>
>>60778030
Reduce the time,
reduce the quality,
reduce the dimensions,
mute the audio

Then it might fit.

Honestly it'd be better to upload it to mixtape.moe and just send the link
>>
Dunno man, I don't know if some people have real web skills or I just imagine that their webms look better.

Tried this today for KC there is a 10mb limit. rate

https://webmshare.com/WWyeD
>>
its possible anon, use webm converter (webm for retards)
>>
>>60777987
You have your target length and target size. From that, calculate the target bitrate. Decide on the fps you want, and tweak all other settings (resolution will be important) until you get the most viewable product.
>>
>>60778112
It's from here btw, maybe someone is bored and makes a proper webm. This guy can sing desu.

https://www.youtube.com/watch?v=t9ilBHkH9Io
>>
>>60778112
At 320kbps the audio bitrate is too high. 128kbps would be enough, maybe even as low as 96kbps. That leaves around 300-330kbps for video. Really low but still manageable is you performa a 2 pass encode and use bigger GOP lengths, say 10 seconds. Your video has a GOP length of 5.

Rated.
>>
>>60778162
>>60778112
Here you go, this was me btw >>60778195
https://webmshare.com/R31B6

Here's my command line
ffmpeg -i "Chandelier - Postmodern Jukebox ft. Singing Sad Clown Puddles - As Performed On America's Got Talent-t9ilBHkH9Io.mp4" -pass 1 -vcodec libvpx -vf fps=20,scale=512x288 -g 200 -acodec libvorbis -b:a 96k -b:v 310k "Chandelier - Postmodern Jukebox ft. Singing Sad Clown Puddles - As Performed On America's Got Talent-t9ilBHkH9Io.webm"

ffmpeg -i "Chandelier - Postmodern Jukebox ft. Singing Sad Clown Puddles - As Performed On America's Got Talent-t9ilBHkH9Io.mp4" -pass 1 -vcodec libvpx -vf fps=20,scale=512x288 -g 200 -acodec libvorbis -b:a 96k -b:v 310k "Chandelier - Postmodern Jukebox ft. Singing Sad Clown Puddles - As Performed On America's Got Talent-t9ilBHkH9Io.webm"
>>
>>60778387
wew meant -pass 2 for the second command.
>>
>>60777987
>posting that shitty version where Kyasuka looks like she was dropped on her head repeatedly
>>
you just had to activate my dick, did you...?

fuck
>>
>>60778387
>9.5MB
How is this a successful conversion?
>>
>>60778195
>>60778387
That looks great, thank you. Gave it 320kbps because I wanted to focus on audio. Probably unnecessary.
Will try this now
https://www.youtube.com/watch?v=aVevvbFNKiY


>>60778466
It's for KC there is a 10mb limit.
>>
>>60778466
I wasn't sure what percentage overhead there would be so I picked lower video bitrate, could've probably used 330kbps instead of 310kbps. Wouldn't make a lot of difference though.

>>60778493
You can push it slightly further by using "-deadline best" or "-quality best" but the encoding speed will drop considerably.
>>
>>60777987
The more motion it has, the higher the bit rate will be. VP8 is really terrible at hitting target bit rates too. You can set max bit rate with min/max quantifier and do 2-pass VBR. If your video has audio, mono channel at 32kbps is the lowest bit rate allowable by vorbis. It will sound like ass for music, but for speech it will be fine. If all else fails, lower the resolution size.
>>
>>60777987
4 minutes = 60 secs * 4 = 240 seconds

4 MB is 4000 KB is 4 KB * 1000 is (8 kilobits* 4 * 1000) is 32000 kilobits is 32 megabit.

32 000 kilobit / 240 seconds = 133 kilobit per second

So you'll have to make a video with bit rate average nomore than 133 kilobit.
>>
>>60778580
What's the argument for changing audio bitrate?
>>
>>60778637
To give more bitrate to the video stream. I think high enough resolution is pretty important when the embedded player can't be scaled, like on 4chan. So with higher bitrate higher resolutions can be kept to present the content the content better.
>>
>>60778626
This is VP8 we're talking about. It's going to do what it's going to do. He could try doing two pass with this. If it thinks the bitrate is too low, it wont matter how low a value you use.
-b:v 128k -qmin 0 -qmax 50 -maxrate 256k
>>
File: 1489845182411.jpg (135KB, 519x537px) Image search: [Google]
1489845182411.jpg
135KB, 519x537px
ffmpeg says
Output file is empty, nothing was encoded 
>>
File: anime press presser.jpg (128KB, 1443x641px) Image search: [Google]
anime press presser.jpg
128KB, 1443x641px
>>
>>60778699
2nd pass
>>
>>60778733
Yeah right, you wrote it. Looks good so far and converting is faster than webm for retards but the webm has no sound:

ffmpeg -i a.mp4 -pass 2 -vcodec libvpx -vf fps=20,scale=512x288 -g 200 -acodec libvorbis -b:a 96k -b:v 310k b.webm
>>
I use this
find ./ -regex '.*mp4\|.*mkv\|.*wmv\|.*gif\|.*avi' -exec bash -c 'ffmpeg -loglevel panic -i "$0" -n -an -sn -c:v libvpx -f webm -b:v 500K -bufsize 1000k -vf scale=-1:360 -preset ultrafast -qcomp 1 -crf 28 -quality good -auto-alt-ref 0 -qmin 10 -qmax 42 -movflags +faststart -fs 1.9M "${0%%.mp4}.webm"' {} \;

>>
>>60778900
I'm not the guy who wrote that, but I always use
-an in the first pass. This tells ffmpeg not to do anything with audio. Use this in the second pass. -ac 1 tells it to encode mono.
-codec:a libvorbis -ac 1 -b:a 32k
>>
>>60778010
No? Not him, but that's pretty doable with a 480p video while still looking better than a 70% compressed JPG.
>>
>>60778052
>not using hooli app
>>
The best way to do this without destroying quality too much is to play with the CRF value in ffmpeg. I recommend starting with a value of 16 and then increase it after each test encode. The higher the value, the smaller the overall file size will be at the cost of reduced quality.

Here's a .BAT, hopefully it works.

code]for %%f IN (*.mkv) do (
ffmpeg -i "%%~nf.mkv" -an -c:v libvpx -crf 16 -b:v 0 -quality good "%%~nf.webm"
)[/code]
>>
>>60779266
28 is a good trade of between size and quality
>>
>>60779266
It's the easiest way. Not the best way.
>>
>>60779276
OP might have to go a little higher though. VP9?8 has to make due with an average bitrate of like 128kbps.

>>60779314
2-pass VBR on VP8 is hard to do and the commands to do it recently changed so I stopped trying. If you know how to do it then enlighten us.
>>
File: Brett_vorm_kopf.jpg (6KB, 200x151px) Image search: [Google]
Brett_vorm_kopf.jpg
6KB, 200x151px
>>60779009
I'm confused right now. Could you provide a complete command? Never worked with ffmpeg before so it seems a bit cryptic.
Tried this and it still doesn't have audio:

ffmpeg -i a.mp4 -pass 2 -vcodec libvpx -vf fps=20,scale=512x288 -codec:a libvorbis -ac 1 -b:a 32k -b:v 310k 10.webm
>>
>>60779367
Ahhh stop the presses. Youtube-dlg downloaded without any audio. Sorry brb
>>
>>60779358
That's why I said CRF was the easiest. 2-pass will always get better results.
>>60778387
Genius put 1 pass twice instead of 2 pass.
>>
>>60779367
>ffmpeg -i "IN.mp4" -vcodec libvpx -b:v xxxk -an -pass 1
>ffmpeg -i "IN.mp4" -vcodec libvpx -b:v xxxk -acodec libvorbis -b:a xxk -pass 2
Like this.
>>
File: 1492925162001.jpg (208KB, 700x700px) Image search: [Google]
1492925162001.jpg
208KB, 700x700px
Thanks all works good now. Ffmpeg is easier to use than I thought and the results are better than these from webm for retards or xmedia recode. Btw I recommend youtube-dlg to everyone but chose the right audio setting. Seems downloading from YT isn't easy with browser anymore.


https://webmshare.com/6rZa1
https://webmshare.com/WWyDD
>>
>>60779885
It helps when you group settings together.
>ffmpeg (time options) (input) (video filters) (video codec and options) (audio codec and options) (output)
Once you begin mixing and matching, not only does it become a clusterfuck, options might not even be passed at all.
>>
>>60777987
For a 4 minutes video a small calculation suggests a bitrate of 140kbps, downscale to a 480p resolution and turn down the bitrate to around 100kbps for the video and 40kbps for audio, it will be shit but you'll have a recognizable signal, I've done worse for improvised professional Facebook streams
>>
>>60779948
Okay

Btw OP this webm https://webmshare.com/5xowL is nearly 9 minutes long, has sound and the quality is acceptable. It will work in some way.
>>
>>60777987
once gook moot add vp9
>>
File: ero1.webm (202KB, 288x592px) Image search: [Google]
ero1.webm
202KB, 288x592px
>>60777987
>>
>>60780352
c - cute
>>
File: ero2.webm (1MB, 1280x720px) Image search: [Google]
ero2.webm
1MB, 1280x720px
>>60780352
>>
>>60778086
Yes
She also gets violently raped
#triggerwarning
:^)
>>
File: youjo.webm (335KB, 1280x720px) Image search: [Google]
youjo.webm
335KB, 1280x720px
>>60780368
>>
>>60778086
It's from the newer Berserk movies.

I think one is on netflix
>>
File: giphy.gif (793KB, 320x240px) Image search: [Google]
giphy.gif
793KB, 320x240px
>>60780352
>>60780368
STOP.

I have a clingy little sister who still hangs out with me even though she's in middle school. This is making me very uncomfortable.
>>
>>60780508
Embrace the loli. E M B R A C E I T
>>
>>60780603
Fuck man, I don't even know why I even started watching the show. I stopped watching it because how uncomfortable it made me feel.

I feel like I want to go into a permanent comma if I even attempt to think lewd thoughts about my lil sis.
>>
>>60780144
300 seconds is supposed to be the limit. I usually have to do 298 seconds for 4chan to accept it though.
>>
>>60779266
crf unless coupled with rate limiting is useless for filesize limited situations, like 4chan, I'm not sure if that works with VP8. 2 pass is more reliable.
>>
>>60779885
As you can see removing chroma information helps to encode at higher quality. If I were doing an encoder wrapper I would add a black & white filter for extreme situations.
>>
>>60780658
watch the show with her.
Thread posts: 58
Thread images: 9


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.