_ _ _ _ | | | |___| |___ ___ _____ ___ | | | | -_| | _| . | | -_| |_____|___|_|___|___|_|_|_|___|

My Links: Home - Me - About

Neocities Contact: ajroach42

Mastodon Contact: ajroach42

Low Bitrate Videos

I've been experimenting with very low bitrate encoding for a few years, including winning a couple of low-bitrate film festivals. After lots of experimentation with lots of esoteric codec combinations and weird containers, we've reached a point where AV1 is Good Enough and fast enough.. I can encode h265 videos that are slightly smaller for more or less the same visual quality, but they won't play back in a browser and they're only marginally smaller. I can also encode h265 videos that are much smaller, for significantly worse visual quality. H265 videos do encode about 5x as fast, as AV1 videos, but that doesn't have a huge impact on things for me right now, esepecially since they don't play back in browser. AV1 makes small enough files that look good enough and can be played back in enough common places that it makes sense to use it in production.

Why?

Because not everyone has multi-gigabit fiber running to their homes, and not everyone is watching videos on 80" TVs, and even if we all were, data transfer and data storage still comes at a cost, financially and environmentally. On an individual file basis, that cost might currently be negligble, but the carbon footprint of streaming services is likely only to grow with time.

Other reasons, too, probably. Smaller files are easier to transfer and store. Right now, I'm averaging just under 100 Kilobits per second, or about 45 MB per hour. At that rate, video can fit in a lot of places, and through a lot of distribution mechanisms, that were previously inaccessible.

But what does it look like?

Here are some example videos, taken from the internet archive, and compressed with ffmpeg ( c:v libaom-av1 -strict -2 -threads 16 -cpu-used 8 -filter:v scale=-1:480 -crf 60 -c:a libopus -b:a 16k -ac 1 ). These are not the smallest videos it is possible to make, but I think they're the smallest videos that are genuinely watchable.

3 Dev Adam - 3 Giant Men - Turkish Spiderman meets El Santo and Captain America

Content Warnings: Lots of implied Gore (no explicit gore), some implied sexual content, some near nudity, rodents chewing on people's faces. Came from a Very Bad DVD release, which appears to have been sourced from some manner of tape. This was the hardest of the videos to make look good. Total size 55.7 MB.


Bad Hair Day - Donkey Kong Country - S01E01

Content Warnings: It's a cartoon from the 90s. It's Samson and Delilah transposed to the Donkey Kong Country universe. There's some violence. The 3D animation is Very Odd. Total size 17.2 MB


Koko The Clown - A Trip To Mars

Content Warnings: Gas masks, explosions, animation from the 20s, very jittery video. Super jittery. I really should have stabalized this one before I re-encoded it (I have stablized it before, I thought I was working from the stablized copy, I wasn't. So it goes.) total size: 5.57MB


VHS Resolution

Here are a couple more videos done at VHS resolution (and with limited chroma subsampling), this lets me give a higher percentage of the bitrate to video details and a lower percentage to resolution and color accuracy.

Captain Isotope Episode One

VP9

AV1 is very computationally expensive both to encode and to decode and isn't supported on Mac. h265 isn't supported in firefox. What does VP9 look like? Total Size 37.2MB

The answer is that it looks acceptable! But in order to make it look acceptable, we have to basically double the size compared to AV1.

H264

and here's the same video in h264 at a file size of 35.9MB

On the hardware I'm using, the AV1 video encodes at roughly 40 frames per second, the VP9 video encodes at roughly 60 frames per second, The h265 video at roughly 300, and the h264 at over 900. h264 and vp9 are widely supported, and produce roughly equivalent quality. h264 encodes much more quickly, but is legally problematic.

Now what?

I may add more videos in time, or do something more advanced with this project like set up a super low bandwidth streaming platform, designed to be self hosted from SBCs in closets on domestic internet connections and accessed via some manner of overlay network, or something equally absurd.) Or, I might just leave this up for a while as an example of what can be done and not touch it anymore. Either way, my copy of 3 Dev Adam looks about as good as the one on youtube, while taking up just over a quarter of the space, and that's got to count for something.

© CC-BY - Andrew Roach