PDA

View Full Version : Bits/(pixel*Frame) incorrectly calculated with "Calculate Avi Size"


ahgencer
24th May 2002, 17:14
Here is a minor bug that I was hoping that would go away with 0.26, but it didn't:
GKnot calculates bits/(pixel*frame) incorrectly for DivX4 and 5:

For example, bitrate=2000 kBits/s = 2,000,000 bits/s, FPS=25, resolution=640x480 (307,200pix) would give bits/(pixel*frame)=0.2604, which is 2,000,000/25/307,200.

If you select "Calculate Average Bitrate" in GKnot, and adjust your file size such that the bitrate is 2000kbit/s then the bits/(pixel*Frame) value is calculated correctly. Now, if you switch to "Calculate Avi Filesize" and our 2000kbits/s, the bits/(pixel*frame) goes up to 0.267, or by a factor of 1.024! For the same bitrate, this value shouldn't change, no matter how I do the calculation.

Interestingly, for DivX3, (which uses 1kbit=1024bit) it works fine, thus I assume that something was forgotten when coding DivX4, and the bug is carried to DivX5.

---Alp