Since CRF settings aren’t that useful for hitting a specified filesize, you can use the following equation to calculate the bitrate needed to encode a video of a given runtime at a given file size
- s = length of video file in seconds
- t = target size in gigabytes
- b = target bitrate in kilobit/s
b = (t*8*10^6)/s
ie, my copy of Serenity is 01:58:55 long, which is 7135 seconds (see https://www.calculateme.com/time/hours-minutes-seconds/to-seconds), I want it to be 2.5gb, my equation is
b = (2.5*8*10^6)/7135 = 2803 kbit/s
You can use any tool, handbrake, ffmpeg, whatever, any codec, and this equation will tell you the average bitrate needed to hit that file size. You would use “vbr” encoding mode instead of crf. I’d recommend enabling 2-pass for x264, not sure if this would be needed/is available for x265 as I’m a bit of a stick in the mud re: video codecs.
Couple notes, I’m using SI units (powers of 10 instead of powers of 2) for the conversion, and am converting from bytes to bits as this is a more common unit to represent bitrates. If your software uses different units for the bitrate for some reason, or you prefer representing file sizes using gibibytes/etc then you’ll need to rewrite the equation accordingly
Open source is just another commons, and companies have a way of uncontrollably exploiting common resources until they collapse.
In the case of open source, it’s healthy in the sense that money is flowing, we have companies sponsoring projects, tons of code is available for inspection and reuse, etc. Very nice. But if you go back to the original concepts of free software, in many cases we struggle with actually exercising the four freedoms. Red Hat has engineered an EULA that basically lets them ban practices that had been thought protected by the GPL for at least a generation, and so on and so forth. So is the open source community healthy or dying? Doesn’t the answer to that depend on your priorities?
I think it would make a lot of sense to try to create an economic model that can fund open source software development without relying on corporate injections of cash. It’s not that they don’t pay for it ever, they just pay for it to the bare minimum extent. IE, the heartbleed fiasco – tons of companies were freeloading off one guy and like half the Internet’s security got fucked for it. Imagine if OpenSSL had had some kind of economic support structure in place to allow for, uh, more than one guy to manage the encryption library for like half the Internet before something insanely stupid and predictable like that happened. Well, we can never have that with corporate-controlled open source.