A novel two-pass VBR coding algorithm for fixed-size storage application
We propose a novel variable bit rate (VBR) algorithm that adopts two-pass encoding to implement high-performance coding for fixed-size storage applications. In the first-pass encoding, we use the original frame as the reference for motion estimation. This way, we are able to obtain the exact relationship between the amount of bits generated for each frame (rate) and each possible quantization factor (Q) so that an R-Q function can be built. The corresponding computational expense is virtually the same as a typical VBR encoder. With this R-Q function, we can optimize the quantization factor for each frame throughout the entire sequence based on the constraints in total storage size and decoder buffer size before the second-pass encoding is executed. This procedure not only guarantees full use of the fixed storage size for the compressed bitstream, but also prevents the decoder buffer from underflowing. Unlike a typical constant bit rate (CBR) decoder, this VBR decoder is capable of preventing the buffer from overflowing by introducing the pausing operation at some designated time. Because the quantization factor optimization is a simple table lookup, the computational requirement is minimized. In the second-pass encoding, the estimated quantization factors for all the frames through the above procedures is used to encode the entire video sequence as a free VBR encoder. Experimental results on real video sequences show that the proposed VBR encoding can provide more consistent visual quality and an improved coding efficiency. The application of the proposed VBR coding scheme includes video streaming over the Internet, digital versatile disk, digital library, and video on demand.