1. Field of the Invention
This invention relates to the field of digital audio signal reproduction, and in particular to an audio decoder which implements an efficient method for decompressing a compressed audio gain value.
2. Description of the Related Art
Digital audio and video programs in initial sampled form and final playback form comprise an enormous amount of data, indeed so much that it would be prohibitively expensive to store or to secure the necessary bandwidth and power to transmit programs of moderate quality and length. To address this problem, compression techniques are commonly employed to reduce the amount of data by which the program is represented during storage and transmission, after which the program is reconstructed by some matched decompression method. To ensure compliance between transmitters and receivers of various manufacturers, several compression standards have been established. For audio compression, MUSICAM and Dolby AC-3 are popular. For multimedia (audio/video) compression, MPEG and DVD are popular.
These standards are not completely distinct and independent, e.g. DVD employs MPEG video compression techniques and allows for use of MUSICAM and AC-3 audio compression techniques. Although attention herein is directed primarily to the DVD standard, much of what is said is also applicable to systems operating according to other compression standards, and exclusion of such systems is not intended.
A compressed bitstream created in accordance with the DVD standard consists of interleaved substreams. Examples of substreams which may be included in a DVD bitstream include audio substreams, a video substream, sub-picture unit (SPU) substreams, and navigation substreams. Each substream consists of data packets having a packet header and a packet payload. The packet header includes identifying information specifying which substream the packet belongs to and where it belongs in that substream. The packet header also includes information specifying the payload type and size, and any compression parameters which may be required for decompression.
To reconstruct the original data from the DVD bitstream, a DVD decoder locates the beginning of a packet, then reads the packet header to determine the substream membership. The decoder then routes the packet payload and portions of the packet header to the appropriate elementary bitstream buffer. Various modules of the decoder then operate on the contents of each buffer to reconstruct the associated program component (i.e. audio, video, SPU, navigation), and the reconstructed program component is finally presented to an appropriate output channel for delivery to the user.
As used herein, "substream" refers to the stream of data packets associated with a program component, and elementary bitstream refers to the data which is written to the elementary bitstream buffers, i.e. the contents of the data packet minus the identifying header fields, but including header fields which specify decompression parameters that may be needed by the ensuing decoder modules.
One of the audio substream formats which is defined in the DVD standard is the linear pulse code modulation (linear PCM) format. The linear PCM audio samples are sampled at 48 kHz or 96 kHz and byte-packed into audio substream packets. These packets include a linear PCM block header carrying parameters for use by an audio decoder (e.g. gain, number of channels, bit width of audio samples), and a block of audio data, as shown by packet 10 in FIG. 1A. The format of the audio data in the block is dependent on the bit-width of the samples. FIG. 1B shows how the audio samples in the audio data payload may be stored for 16-bit samples. In this example, the 16-bit samples made in a given time instant are stored as left (LW) and right (RW), followed by samples for any other channels (XW). Allowances are made for up to 8 channels. FIG. 1C shows how the audio samples in the audio data payload are stored for 20-bit samples. In this example, byte-alignment is preserved by grouping sample times into pairs. The most significant 16 bits for samples in the paired time instants are stored in the same manner as before. The remaining nibbles are grouped together following the 16-bit words. The nibbles are packed in the same order as the previous portions of the samples, i.e. LN1,RN1,XN1,LN2,RN2,XN2. FIG. 1D shows how the audio samples in the audio data payload are stored for 24-bit samples. In this example, the portions of the audio samples are ordered in the same manner as FIG. 1C. The primary difference is that the remaining portions (4-bit nibbles in the previous example) are now 8-bit bytes.
The DVD standard provides a gain control mechanism for linear PCM and AC-3 encoded audio substreams. The packet headers include a eight-bit range-control field for specifying a gain value. When each of the audio samples in the packet is multiplied by the gain value, an output audio sequence with a compressed audio range results. The range control field value is chosen by the audio program creator to provide the end user with configurability of the audio range. The use of the gain value can optionally be disabled or scaled by the user.
The range control field for specifying the gain value G consists of a 3-bit value X and a 5-bit value Y. The gain value G can then be found from the following formula: EQU G=2.sup.4-X-(Y/30)
Straightforward evaluation of this formula requires a dedicated arithmetic processor that requires a prohibitively large amount of hardware resources to implement. Existing methods include use of floating point processors, use of microcode/software controllers, or iterative methods which may require a variable amount of time to complete the calculation. Consequently, it is desirable to provide an efficient method for evaluating the above formula using resources already available to an audio decoder.
USPTO Backgrounds
USPTO Backgrounds