Overclock.net › Forums › Software, Programming and Coding › Other Software › Art / Graphics › anyone know how to limit file size in handbrake?
New Posts  All Forums:Forum Nav:

anyone know how to limit file size in handbrake? - Page 2

post #11 of 12
I thought I'd write this up for anyone that stumbles across this thread still.

Handbrake no longer offers a target filesize option, but don't fear, this is simple math.

There are a minimum of two different streams that you are creating in handbrake - an audio stream and a video stream. Both are presented in handbrake as kbps (kiloBITs per second).

Audio + Video = total kbps of your video = total filesize of your video.

Say you have a 30 minute video and you want it to be 500 megabytes in size.

Take 500, divide by 30 (number of minutes), divide by 60 (seconds in a minute), and multiple by 1,000 (1 megabyte = 1,000 kilobytes). Sure you could go from megabytes to kiloBITs directly, but I thought this would be more helpful.

There are 8 kilobits in a byte, so (finally) multiply this number by 8.

The result is 2222. You would need a bit rate of 2,222 kbps (or 2.222 mbps) to end up with a filesize of 500 megabytes.

Again - 2.222 is the total audio + video. I'll let you decide if you want 320kbps or 128kbps for your audio bitrate - or whatever works for you. Just know that you'll subtract whatever you pick as your audio bitrate from 2,222 kbps to get your video bit rate. If you have 3 audio tracks, make that subtraction 3 times.

In the quality section of the Video tab in handbrake, select "Average Bitrate", and of course 2-pass encoding for better quality, and enter your calculated video kbps. If you went with 320kbps for audio for example, you'd enter 1902 into this box.

As a quick reminder:
Take your target size / the number of minutes in the video / 60 * 1,000 * 8
To get your required video + audio bitrate.
post #12 of 12
I can confirm HandBrake 0.9.5 (released January 4, 2011) was the last version to support the "target size" feature.
Elliot's PC
(13 items)
 
  
CPUMotherboardGraphicsRAM
Intel Core i7-6700K MSI Z170A Gaming Pro Carbon Zotac GeForce GTX 1080 Amp Extreme Corsair Vengeance 16GB DDR4-4000 
Hard DriveOSMonitorMonitor
SanDisk Ultra Plus 128 GB Windows 10 x64 AOC Q2577PWQ AOC Q2577PWQ 
KeyboardCase
Logitech Wireless Keyboard K360 Thermaltake Suppressor F51 
  hide details  
Reply
Elliot's PC
(13 items)
 
  
CPUMotherboardGraphicsRAM
Intel Core i7-6700K MSI Z170A Gaming Pro Carbon Zotac GeForce GTX 1080 Amp Extreme Corsair Vengeance 16GB DDR4-4000 
Hard DriveOSMonitorMonitor
SanDisk Ultra Plus 128 GB Windows 10 x64 AOC Q2577PWQ AOC Q2577PWQ 
KeyboardCase
Logitech Wireless Keyboard K360 Thermaltake Suppressor F51 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Art / Graphics
Overclock.net › Forums › Software, Programming and Coding › Other Software › Art / Graphics › anyone know how to limit file size in handbrake?