About

About this calculator

The calculator below was originally designed for DVD, but has been updated (a few times) and can now be used to determine the bitrate values for several different formats (including HD-DVD and Blu-ray). All the calculations are done in your browser, by a script, therefore you need a browser with JavaScript support (and script execution must be enabled). If you see the message ENABLE SCRIPTS, that means that your browser doesn't support JavaScript, or that for some reason it's not working correctly. After scripting is enabled, you may need to reload the page for it to function properly.

If you want to store a direct link to the calculator, select the appropriate anchor from the menu on the left (or click here) before setting a browser boomark (or "favourite"). That way you won't need to scroll down each time you visit the page. Alternatively, you may want to create one or more presets with the values you use more frequently (see below).

Instructions

Instructions

The calculator is divided into two sections. The user settings are displayed on the left and the results are displayed on the right (or below, if your browser window is too narrow to display them side by side). To update the results after editing a value manually, just click on any empty area of the page or press return on your keyboard.

Note that when describing the size of media (ex., the size of a DVD), a gigabyte is usually considered to be equivalent to 1000 megabytes, whereas operating sytems normally consider that one gigabyte is equivalent to 1024 megabytes (the same is valid for kilobytes, megabytes, etc.). Bits are nearly always calculated using a factor of 1000 (not 1024). For this reason, a "4.7 GB" disc will typically appear as having only 4.37 "gigabytes" (technically it has 4.37 gibibytes, or GiB), but a bitrate of 9.8 Mb (megabits) is equivalent to 9800 kb (kilobits). In this calculator, all values that are displayed in bytes (indicated by an uppercase "B") use a factor of 1024, and all numbers displayed in bits (indicated by a lowercase "b") use a factor of 1000.

Here's a brief description of the different areas:

Source length:

Total length of source footage

If your disc will have more than one clip, enter the sum of the lengths of all clips. If you want to encode each clip with different settings, you'll have to calculate the bitrate for one at a time, using the Media size or Other assets fields (described below) to decide how much space each clip is allowed to use.


Video format:

Determines resolution, frames per second and GOP limit

Select the video standard that your disc will use. This will set the appropriate GOP limit and frame rate.


Audio format:

Pick a preset or specify the bitrate

The DVD PCM preset sets the audio bitrate to that of 48-kHz, 16-bit, stereo uncompressed sound. The VCD MPA preset sets the bitrate to 224 kb/s (as used by VCD MPEG-1 audio). Most other formats (ex., Dolby Digital, MPEG audio for DVD or SVCD, etc.) can use different levels of compression. A few common presets are included in the drop-down list. If you'll be using a different audio bitrate, enter it manually.


Audio streams:

Number of independent audio tracks

This refers to the number of audio tracks, not to the number of channels. A 6-channel surround track counts only as one audio stream. Two stereo sound tracks count as two streams. This value is multiplied by the source length and the audio bitrate to determine how much space will be taken up by the audio (this is then subtracted from the available space to determine how much is left for the video).


Scene motion:

Describe the amount of motion in the footage

In most cases, you'll want to leave this set to Heavy or mixed, but for footage with very simple, very regular motion, or with no motion at all (ex., a slide show), setting it to Light or none will result in a more optimised GOP structure suggestion.


Scene detection:

Information about the encoder

If your encoder supports scene change detection (sometimes described as "automatic GOP placement" or "automatic I-Picture insertion"), and if you're planning to use it, leave this option set to Active. You should only disable scene change detection in your encoder if you need consistent GOPs (ex., for multi-angle DVDs). If you're unsure whether your encoder supports scene change detection or not, leave this option active. If you notice that the first few frames after scene changes (in the encoded video) have significantly lower quality than the frames in the middle of each scene, that probably means your encoder does not support this feature. In that case, set this option to Inactive in the calculator, and it will suggest a different GOP structure to minimise the problem (but this comes at the expensve of a slight overall decrease in quality, so don't use it unless you have to).


Rate control:

Video bitrate control mode

Normally, the calculator will automatically decide, based on the computed bitrate values, whether you should use CBR or VBR. If for some reason you want to use constant bitrate regardless of the values, select Force CBR, otherwise leave it set to Automatic.


Bitrate limit:

Select the video stream type or enter value manually

This is the maximum bitrate allowed by the destination format (including audio, subtitles and other elements). Note that some disc formats may have specific limits for each element (ex., in SVCD discs, the video bitrate must be less than 2520 kb/s, even if you don't use audio).


Media size:

Select the media type or enter value manually

If you're using the whole disc for this movie, simply select the type of disc (if it's listed). If the type of disc you'll use isn't listed, use the custom field and enter the amount of free space manually (contact me using the menu on the left if you notice that a frequently-used format is missing, and would like it added to the list). If not all the space on the disc is available, you can either enter only the available space in this field, or enter the full size and use the field below (Other assets) to subtract from it.


Other assets:

Subtitles, data files, menus, etc.

The value you enter here is subtracted from the Media size to determine the available space. Use this field to take into account other files that you know will be included in the disc, such as subtitles, menus or data files.


Create preset:

Store the current calculator settings

Clicking this button will encode the curent input settings into your browser's address bar. You can then bookmark the resulting page (or copy the address to the clipboard, etc.), and use it to load the calculator with the settings applied. You may also edit the encoded values manually (the parameters are self-explanatory); any settings that aren't present in the encoded address will simply use the default values when the calculator loads.



Calculator

Calculator

Calculator : Settings

Source length:

minutes

Video format:

Audio format:


Custom ( kb/s)

Audio streams:

Rate control:

Scene motion:

Scene detection:

Bitrate limit:


Custom ( kb/s)

Media size: 


Custom ( MiB)

Other assets:

MiB

Create preset
Calculator : Results

Status:


Rate control:


Bitrate:

Maximum kb/s
Average kb/s
Minimum kb/s

GOP structure:

I-pictures
P-pictures
B-pictures

GOP limit:

frames

Size (approx.):

Video MiB
Audio MiB
Other MiB
Remaining  MiB


Results

What the results mean

Some of the calculator's results may not be completely straightforward, so here's a short description of how they're calculated:

Rate control:

CBR or 2-pass VBR

Normally, the calculator will suggest 2-pass VBR (if your encoder doesn't support 2-pass VBR, use a supported VBR mode that allows you to define the minimum, average and maximum bitrates). It will suggest CBR in two circumstances. First, when you select Force CBR in the first section of the calculator. Second, when there's enough space on the disc to make the average bitrate equal to or greater than the maximum bitrate. In this case, a VBR file would effectively be CBR, therefore it makes no sense to use the VBR mode (which takes longer to encode). If the calculator suggests VBR with an average bitrate value that is very close (i.e., within 10%) of the maximum bitrate value, you can greatly reduce the encoding time (with a very small loss in quality) by selecting CBR mode.


Bitrate:

Maximum, average and minimum

The maximum video bitrate is calculated by subtracting the total audio bitrate from the maximum bitrate allowed by the disc format. Using a higher value might make the disc incompatible with some players. Using a lower value should not cause any problems. To make a DVD compatible with as many players as possible, use a value of 8000 kb/s or less (some older DVD players may have problems when the video bitrate goes beyond that value). Likewise, for Blu-ray discs avoid using a maximum bitrate over 40 Mb/s (Blu-ray's official "video", "audio" and "video + audio" bitrates don't really add up).

The average bitrate is calculated by dividing the free disc space (taking the audio into account) by the project length, leaving a small safety margin (typically between 2% and 5%) in case the encoder doesn't stick to the value, and to allow for normal file overhead. Using a higher value might cause the resulting file to be too big to fit in one disc. Using a lower value shouldn't cause any problems.

The minimum bitrate is calculated simply as a percentage of the average bitrate. Using a different value shouldn't cause any problems. Some authoring programs prefer files where the bitrate never drops below a certain value (ex., 2000 kb/s). If this is the case with your authoring software, and the value suggested by the calculator is lower, increase it to that value. Note that (obviously), the minimum bitrate should always be less than the average bitrate, and the average bitrate should always be less than the maximum bitrate.


GOP structure:

I-pictures, P-pictures and B-pictures

Based on your video format, bitrate, encoder abilities (scene change detection) and information about the source footage (amount of motion), the calculator suggests a value for the number of pictures of each type (I per GOP, P per I and B per P). It assumes you will be using open GOPs (in other words, it assumes the GOP can end with a B-picture). If you use closed GOPs you might need to increase the number of P-pictures (and possibly reduce the number of I- or B-pictures) to make the best use of the allowed GOP length. Most of the times, though, the suggestion given by the calculator will also be suitable for closed GOPs. For a longer description of picture types and GOP structure, see the DVD compression guide and the FAQ (use the menu on the left). Note that this suggestion assumes you're encoding a DVD; for SVCD, Blu-ray, etc., ignore these values.

Some encoders use a different notation for the GOP structure where, instead of letting you set the number of I-, P- and B-pictures, you can only set the values for "N" and "M", where "N" is the total number of pictures in the GOP and "M" is the spacing of the P-pictures (i.e., B plus one). So, for example, if a GOP consists of IBBPBBPBBPBB\, it can be described as [ I=1 / P=3 / B=2 ] or as [ N=12 / M=3 ]. Since some GOP structures can't be represented at all using the [ N / M ] notation (ex., IBPBIBPBIBPB\), the calculator shows its results using the standard MPEG format [ I / P / B ].

Note...


Under some extreme circumstances, the calculator might suggest a GOP with I- and B-pictures only (zero P-pictures). While this is correct (for those situations), and allowed by the MPEG-2 standard, some encoders won't let you define the number of B-pictures when there are no P-pictures. If this is the case with the encoder you're using, set the number of P-pictures to 1 and reduce the number of I-pictures until the total GOP length (I + IxP + IxB + IxPxB) is under the limit. The same thing is true if you use closed GOPs, which cannot end with a B-picture (but in this case the total GOP length is given by I + IxP + IxB + IxPxB - B, since the last sequence of B-pictures is discarded). This will only be an issue at extremely low bitrates, though, so it's unlikely that you'll ever have to worry about it.



GOP limit:

15 (PAL) or 18 (NTSC)

The maximum number of frames in a GOP (the GOP size limit) is determined by the DVD video format. If you're encoding video for a different format (ex., VCD, Blu-ray, etc.), ignore this suggestion and calculate the GOP size and structure manually (or use your encoder's defaults).


Size:

Video, audio, other and remaining

This area of the calculator tells you the approximate size of the files that will be created if you use the suggested settings. Normally the calculator will try to use all the available space, leaving only a small margin for safety and extras (ex., file headers, project data, etc.). The exception to this is when the average bitrate matches the limit for the format (in this situation, since the bitrate cannot be increased, some space will be left unused).


Note...


How much is this tool worth to you? More than your gold-plated private jet? Less than a cup of coffee? You decide. Click the link below and enter the amount you consider fair. You will need a valid credit card or a PayPal account.

PAY WHAT YOU LIKE!

If you notice any errors or if you have any questions or comments about this calculator, post a message in the forum. If you quote text from this page in any forum posts, e-mails, academic papers, etc., or if you use any of its code, please include a link to this page.


Copyright

Copyright