Encoding and decoding system

Abstract: An encoding apparatus which utilizes masking characteristics of channels for bit allocation in order to encode digitally sampled audio signals of at least two channels in units of an audio frame. The apparatus allocates the bits to the divided bands of the first and second channels, detects a channel in which the respective divided bands all have a masking to noise ration which exceeds a masking threshold the other channel. The encoding apparatus has a bit allocation portion (13A, 13B) for producing bit allocation information corresponding to each channel and bit ratio information between the channels, a first quantizer (14A) for receiving audio signals of the first channel divided bands and quantizing the received audio signal in response to the bit allocation information of the bit allocation portion (13A, 13B) to output the result, a second quantizer (14B) for receiving audio signals of the second channel divided bands and quantizing the received audio signal in response to the bit allocation information of the bit allocation portion (13A, 13B) to output the result, and a multiplexer (15) for multiplexing signals output from the first and second quantizers (14A, 14B), and the bit allocation information and the bit ratio information of the bit allocation portion (13A, 13B), to output the result, thereby providing an effect of improving sound quality even though an audio signal including many high frequency components may be reproduced.

Description: The present invention relates to an encoding and decoding system and in particular to a system which utilizes masking characteristics of channels for bit allocation. Generally, in digital audio products such digital video cassette recorders (VCR), high-definition televisions (HD-TV), digital compact cassettes (DCC), multimedia systems, and digital broadcasting systems (DBS), an analog audio signal is sampled and the sampled audio signal is converted into a digital audio signal so as to be recorded on a medium or to be transmitted. However, to record and reproduce or to transmit and receive the sampled digital audio signal, data rates of more than 700 Kbps for a channel are required. Accordingly, it has been difficult in applying conventional encoding technology to particular products because of the excessive amount of data required. To solve such a conventional difficulty, various encoding methods for compressing data more than four times while maintaining audio signal quality have been proposed. Among them, one is an encoding method using variable bit allocation. In the variable bit allocation method of the moving picture expert group (MPEG), the sampled audio signal band is divided into divided bands using a subband filter group, and a masking threshold value which is varied according to a specific weight of an audio quality and an audio source is calculated using a human auditory system, thereby adaptively allocating the number of bits to each divided band. Such a variable bit allocation method of the MPEG will be described below with reference to Figures 1A through 1C. Figures 1A through 1C are graphical views for explaining a method for allocating bits to each divided band by a conventional variable bit allocation encoding method. Figures 1A through 1C schematically show thirty-two divided bands, in which a digital audio signal band is divided into thirty-two frequency divided bands each of which has a predetermined width A. Figure 1A shows a masking to noise ratio (MNR) with respect to each frequency divided band in an initial state prior to bit allocation. Figure 1B shows an MNR with respect to each divided band during bit allocation. Figure 1C shows an MNR with respect to each divided band after completion of bit allocation. Referring to Figures 1A through 1C, a conventional variable bit allocation method will be described below. If calculation of initial values (illustrated as a solid line) of the MNR with respect to the divided bands has been completed, bit allocation for quantization starts from a divided band having the lowest value of the MNR. The divided band B of Figure 1A having the lowest MNR value among the 32 divided bands increases a value of the MNR through the bit allocation as depicted as a dotted line C. After completion of the bit allocation with respect to divided band B, a divided band having the lowest MNR value becomes a divided band D shown in Figure 1B. The divided band D increases the MNR value through the bit allocation as shown as a dotted line E. Such a process is repeated until the number of bits which are allocated to the divided bands does not become larger than that permissible for one form of an audio signal. The MNR values after completion of the bit allocation with respect to the entire frequency bands of the audio signal becomes values more than zero with respect to the most of the divided bands as shown in Figure 1C. When the MNR values all of the divided bands become more than zero, the human auditory system cannot recognize noise even though the noise is included in the audio signal. Thus, listeners cannot perceive the noise (the quantization noise) for the frame. However, the MNR value after completion of the bit allocation is generally varied according to a class of the audio signal and a specific weight of the audio quality. For instance, since a human voice or a piano sound does not include a significant high frequency component, the MNR values after completion of the bit allocation become more than zero with respect to all the divided bands. On the other hand, since a sound of a beat instrument includes a considerable high frequency component, the MNR values after completion of the bit allocation becomes less than zero with respect to some of divided bands. Therefore, the conventional variable bit allocation method of the MPEG has the consequence of degrading the audio quality due to the signal degeneration when reproducing an audio signal having many high frequency components, and users perceive the noise. European Patent application EP-A-0559383 (AT&T) discloses a method and apparatus for coding audio signals based on a perceptual model in which stereophonic audio signals are coded by a perceptual filter-bank coder which exploits interchannel redundancies. Using perceptual principles, switching between a normal and a short window of input samples is said to improve output signal quality for certain input signals, particularly those having a rapid attack. Switching is accomplished between coding of left and right channels and so-called sum and difference channels in response to particular signal conditions. Therefore, with a view to solving or reducing the above problems, it is an aim of preferred embodiments of the present invention to provide an encoding method which utilizes masking characteristics of channels for bit allocation so as to improve sound quality when reproducing an audio signal, in which when audio signals equal to or more than two channels are encoded, the number of bits required are reduced for a channel where an MNR value of each divided band is more than a predetermined value and the residue bits corresponding to the number of remaining bits are additionally allocated to each divided band of another channel having an MNR value less than the predetermined value. It is another aim of preferred embodiments of the present invention to provide an apparatus embodying the above encoding method. It is still another aim of preferred embodiments of the present invention to provide an apparatus for decoding an audio signal encoded by such an encoding apparatus. According to a first aspect of the present invention, there is provided an encoding apparatus which utilizes masking characteristics of channels for bit allocation in order to encode digitally sampled audio frame signals of at least two channels, said encoding apparatus comprising first and second filter groups, first and second threshold calculation means, bit allocation means and first and second quantization means, the apparatus being characterised by the following features: the first filter group comprises a first divided band filter group for receiving an input first channel audio signal, dividing the input first channel audio signal into predetermined frequency divided bands and outputting a first channel frequency divided signal; the first threshold calculation means comprises a first threshold value calculation means for receiving both the input first channel audio signal and the first channel frequency divided signal of said first divided band filter group, and calculating a first masking threshold value; the second filter group comprises a second divided band filter group for receiving an input second channel audio signal, dividing the input second channel audio signal into predetermined frequency divided bands and outputting a second channel frequency divided signal; the second threshold calculation means comprises a second threshold value calculation means for receiving both the input second channel audio signal and the second channel frequency divided signal of said second divided band filter group, and calculating a second masking threshold value; the bit allocation means is arranged for: (i) performing bit allocation for the respective first and second channel frequency divided signals; (ii) receiving the respective first and second masking threshold values; (iii) detecting a masking to noise ratio of the respective first and second channels so as to monitor sub-bands of the first and second frequency divided signals; (iv) performing bit allocation to respective sub-bands of the first and second frequency divided signals, until the masking to noise ratio of all sub-bands of one of said respective first and second frequency divided signals exceeds its respective first or second masking threshold value; (v) using remaining bits which have not been used in exceeding the masking threshold value of the said one of said first or second frequency divided signals for bit allocation to the other of said first or second frequency divided signals; and (vi) producing bit allocation information corresponding to each channel and bit ratio information between the channels; the first quantization means is arranged for receiving the first channel frequency divided signal output from said first divided band filter group and for quantizing the received first channel frequency divided signal in response to the bit allocation information of said bit allocation means to output a quantized first channel signal; the second quantization means is arranged for receiving the second channel frequency divided signal output from said second divided band filter group and quantizing the received second channel frequency divided signal in response to the bit allocation information of said bit allocation means to output a quantized second channel signal; and multiplexing means are provided for multiplexing the signals output from said first and second quantization means, and the bit allocation information and the bit ratio information from said bit allocation means, and outputting the resulting multiplexed signal. Preferably, said bit allocation means allocates bits to the respective divided bands of the first and second channels by using a predetermined total combined number of bits for the first and second channel frequency divided signals of an audio frame. Preferably, said bit allocation means comprises: a first bit allocator which allocates bits in a prioritised manner so as to first allocate bits to those particular divided frequency bands having the lowest masking to noise ratio among the divided frequency bands of the first channel, calculates revised masking to noise ratios with respect to the bit allocated divided frequency bands and compares the calculated revised masking to noise ratios with the first masking threshold value; and a second bit allocator which allocates bits in a prioritised manner so as to first allocate bits to those particular divided frequency bands having the lowest masking to noise ratio among the divided frequency bands of the second channel, calculates revised masking to noise ratios with respect to the bit-allocated divided band and compares the calculated masking to noise ratio with the second masking threshold value, wherein when said first bit allocator allocates bits with respect to all the divided frequency bands of the first channel so as to attain masking to noise ratios for each divided frequency band which exceed the first masking threshold value earlier than said second bit allocator, said first bit allocator thereafter outputs bit allocation completion information to said second bit allocator, and said second bit allocator generates bit ratio information based on the bit allocation completion information. Preferably, when said second bit allocator allocates bits with respect to all the divided frequency bands of the second channel so as to attain masking to noise ratios which exceed the second masking threshold value earlier than said first bit allocator, said second bit allocator thereafter outputs bit allocation completion information to said first bit allocator, and said first bit allocator generates bit ratio information based on the bit allocation completion information. Preferably, said bit ratio information is determined based on the number of bits which are used for bit allocation by the particular channel where the bit allocation has been accomplished earliest. According to a second aspect of the invention, there is provided a decoding apparatus using masking characteristics of channels for bit allocation in order to distribute an encoded and multiplexed input audio bit stream of two channels into their respective channels and to decode the resultant distributed audio bit stream, said decoding apparatus being characterised by: a first-in first-out memory for storing a bit stream in which externally supplied two-channel audio data is combined and stored data is output, according to a write enable signal and a read enable signal; a first digital signal processor for generating a control signal for controlling a read operation by detecting an interrupt signal supplied from said first-in first-out memory, and receiving the two-channel audio bit stream read from said first-in first-out memory to decode only audio data of a first channel; control logic means for supplying the read enable signal to said first-in first-out memory according to the control signal supplied from said first digital signal processor; and a second digital signal processor for receiving second channel audio data which has been separated from the first channel audio data by said first digital signal processor and for decoding the received second channel audio data. Preferably, said first-in first-out memory outputs said interrupt signal as soon as the input audio data is fully recorded therein. Preferably, said first digital signal processor detects the bit ratio information between the channels from the audio bit stream from said first-in first-out memory and separates the respective channel audio data therefrom based on the detected bit ratio information. According to a third aspect of the invention, there is provided an encoding method which utilizes masking characteristics of channels for bit allocation in order to encode digitally sampled audio frame signals of at least two channels, said encoding method including the general steps of band filtering the two channel signals, allocating bits, and quantizing based on the allocated number bits and, in more detail, the method being characterised by the following specific steps of: receiving an input first channel audio signal, dividing the input first channel audio signal into predetermined frequency divided bands to output a first channel frequency divided signal, and calculating a first masking threshold value; receiving an input second channel audio signal, dividing the input second channel audio signal into predetermined frequency divided bands to output a second channel frequency divided signal, and calculating a second masking threshold value; calculating masking to noise ratios and recalculating revised masking to noise ratios resulting from progressive bit allocation for each of the first channel frequency divided bands and each of the second channel frequency divided bands, and comparing the calculated masking to noise ratios with the first masking threshold value and the second masking threshold value for each frequency divided band of the respective first and second channel; detecting when each frequency divided band of a given channel has achieved a condition in which the masking to noise ratio in which each bit allocated frequency divided band exceeds a masking threshold value based on the result of the above comparing step; for the channel in which it has been detected earliest that the above mentioned condition has been achieved, allocating those remaining bits which have not already been allocated to the other channel in which said above mentioned condition has not yet been achieved, and producing bit allocation information corresponding to each channel and bit ratio information between the channels; receiving the bit allocation information corresponding to each channel and quantizing the frequency divided signals of each channel to output quantized channel signals; and multiplexing: (i) the bit ratio information; (ii) bit allocation completion information from the channel which has achieved the abovementioned condition earliest; and (iii) the quantized channel signals. Preferably, said calculation and comparison step comprises repeatedly performing the steps of: performing bit allocation with respect to the particular frequency divided band having the lowest masking to noise ratio; and comparing the masking to noise ratio corresponding to the frequency divided band for which bit allocation has been accomplished with the masking threshold value of the corresponding channel. Preferably, said information producing step produces said bit allocation information at the time at which bit allocation has been accomplished for the two channels. Preferably, said bit ratio information represents a ratio between the number of allocated bits of the first channel and the number of allocated bits of the second channel at the time at which the bit allocation has been accomplished with respect to the two channels of the audio frame. For a better understanding of the invention, and to show how embodiments of the same may be carried into effect, reference will now be made, by way of example, to the accompanying diagrammatic drawings, in which: Figures 1A and 1C are graphical views for explaining a method for allocating bits to each divided band through the conventional variable bit allocation encoding method; Figure 2 is a block diagram of an encoding apparatus using masking characteristics for bit allocation according to one preferred embodiment of the present invention; Figures 3A through 3D are graphical views for explaining an improved bit allocation method in the Figure 2 apparatus; Figure 4 shows a structure of a bit stream forming one audio frame according to one embodiment of the present invention; and Figure 5 is a block diagram of an apparatus for decoding an audio signal generated by the Figure 2 apparatus. A preferred embodiment of the present invention will be described below in more detail with reference to the accompanying Figures 2 through 5. Figure 2 is a block diagram of an encoding apparatus using masking characteristics for bit allocation according to one preferred embodiment of the present invention. In Figure 2, divided band filter group 11A divides a digitally sampled A-channel audio signal into N divided-band signals. The output of divided band filter group 11A divides a digitally sampled A-channel audio signal into N divided-band signals. The output of divided band filter group 11A is connected to a fast Fourier transform and threshold value calculator 12A and a quantizer 14A. Fast Fourier transform and threshold value calculator 12A receives an audio signal input to divided band filter group 11A and the divided-band signals output from divided band filter group 11A and calculates a first masking threshold value in which noise cannot be detected in view of a characteristic of a human auditory system. A bit allocator 13A receives the first masking threshold value from fast Fourier transform and threshold value calculator 12A and generates bit allocation completion information with respect to all the A-channel divided bands. The bit allocation completion information is supplied to quantizer 14A. Quantizer 14A quantizes the output signal of divided band filter group 11A according to the bit allocation completion information supplied from bit allocator 13A, and outputs the quantized signal for multiplexer 15. Bit allocator 13A is connected to a second bit allocator 13B for generating bit allocation completion information with respect to all the B-channel divided bands. The digitally sampled B-channel audio signal is supplied to a second divided band filter group 11B and a second fast Fourier transform and threshold value calculator 12B. Fast Fourier transform and threshold value calculator 12B generates a second masking threshold value and outputs the second masking threshold value to second bit allocator 13B. A second quantizer 14B quantizes the output signal of divided band filter group 11B according to the bit allocation completion information supplied from bit allocator 13B, and outputs the quantized signal for multiplexer 15. Bit allocators 13A and 13B are connected to each other so as to give and take the information to and from each other. Bit allocator 13A or 13B generates bit allocation completion information corresponding to each channel or bit ratio information between channels. For example, if the B-channel bit allocator 13B generates the bit allocation completion information, A-channel bit allocator 13A which receives the bit allocation completion information generates the bit ratio information between the channels. Multiplexer 15 multiplexes the signals supplied from quantizers 14A and 14B and bit allocators 13A and 13B and outputs the result. The operation of the Figure 2 apparatus having the above construction will be described below. The digitally sampled A-channel audio signal is applied to divided band filter group 11A and fast Fourier transform and threshold value calculator 12A, and the digitally sampled B-channel audio signal is applied to divided band filter group 11B and fast Fourier transform and threshold value calculator 12B. The blocks 11A, 12A, 13A and 14A for processing the A-channel audio signal and the blocks 11B, 12B, 13B and 14B for processing the B-channel audio signal perform the same operation until the bit allocation with respect to one channel completes. Such bit allocation will be described with respect to only the A-channel. Divided band filter group 11A divides the applied digitally sampled audio signal into a predetermined number of divided bands (thirty-two in case of the MPEG). Fast Fourier transform and threshold value calculator 12A receives an audio signal applied to divided band filter group 11A and an audio signal output from divided band filter group 11A, Fourier-transforms the received audio signals, analyzes the spectrum of the audio signals and calculates a first masking threshold value in which noise cannot be detected in view of a characteristic of a human auditory system. The calculated first masking threshold value is applied to bit allocator 13A. Bit allocator 13A performs bit allocation with respect to each divided band using a predetermined number of bits for an audio frame. Here, the bit allocation is performed with respect to the band having the lowest MNR until each divided band has an MNR which exceeds the first masking threshold value. In this manner, during the bit allocation with respect to the A-channel and B-channel divided bands, bit allocator 13A or 13B of the channel of which the bit allocation is accomplished generates bit allocation completion information and supplies the same to bit allocator 13B or 13A of which the bit allocation is being performed. Here, the channel of which the bit allocation is accomplished represents a channel having an MNR in which each divided band for one audio frame exceeds a masking threshold value. For example, when the A-channel bit allocator 13A completes earlier than the B-channel bit allocator 13B, bit allocator 13A generates bit allocation completion information and outputs the same to bit allocator 13B. The bit allocation completion information includes the number of the allocated bits with respect to the A-channel divided bands. If the bit allocation completion information is applied to bit allocator 13B, the number of the bits used for the bit allocation of the A-channel is subtracted from the predetermined number of the bits with respect to one audio frame. The number of the difference bits between the number of the bits obtained by the subtraction and the number of the allocated bits of the B-channel at the time of the completion of the bit allocation with respect to the A-channel, is used for bit allocation of the B-channel. For example, when one hundred and sixty bits are given to one audio frame, A-channel bit allocator 13A uses seventy bits and completes the bit allocation with respect to all the divided bands of the A-channel. Then, bit allocator 13B can use remaining ninety bits for bit allocation of the B-channel. Bit allocator 13B additionally uses the number of the remaining bits after the completion of the bit allocation of the A-channel and continuously performs bit allocation with respect to the divided bands of the B-channel. Bit allocator 13B generates bit ratio information which represents a ratio of the number of the bits which are used for the bit allocation of the A-channel to the number of the bits which are used for the bit allocation of the B-channel. The bit ratio information represents a ratio of the number of the bits which are used for the bit allocation of the A-channel to the number of the bits which are used for the bit allocation of the B-channel, that is, M:N (M and N are integers). Here, M is the A-channel bit allocation and N is the B-channel bit allocation. Such bit ratio information is used for easily decoding the audio bit stream multiplexed with even video data. If the bit allocation is accomplished with respect to the two channels, bit allocator 13A outputs the bit allocation information to quantizer 14A and multiplexer 15, and bit allocator 13B generates the bit ratio information and the bit allocation information and outputs the bit ratio information and the bit allocation information to multiplexer 15 and outputs the bit ratio information to quantizer 14B. Quantizer 14A quantizes the divided band signals input from divided band filter group 11A according to the applied bit allocation information, so as to output the result. Likewise, quantizer 14B quantizes the divided band signals input from divided band filter group 11B according to the applied bit allocation information, so as to output the result. As described above, a case where the A-channel bit allocation is earlier accomplished has been described. However, when the B-channel bit allocation is earlier accomplished, the Figure 2 apparatus operates so that bit allocator 13B generates the bit allocation completion information and bit allocator 13A generates the bit ratio information. Figures 3A through 3D are graphical views for explaining an improved bit allocation method in the Figure 2 apparatus. In Figures 3A and 3B, solid lines represent values of the MNR of the respective divided bands or the frequency bands at the initial states prior to the bit allocation, and illustrate the respective MNR values of the divided bands with respect to the sampled audio signals of one channel where high frequency components do not exist as in a human voice or a piano sound. In Figures 3C and 3D, solid lines represent the respective MNR values of the divided bands at the initial states prior to the bit allocation, and show the respective MNR values of the divided bands with respect to the sampled audio signals of the other channel where high frequency components exist as in a sound of a beat instrument. When comparing the initial MNR values of the two channels to each other, the MNR value of the beat instrument such as a drum in case of the MNR value of the high frequency domain has a lower value than the MNR value of the human voice or the piano sound. This is due to a fact that the sound of the beat instrument generally has a larger high frequency component than that of the human voice, and the sound of the beat instrument has a relatively wide amplitude from a low frequency to a high frequency on a spectrum. If bit allocation were performed by the conventional method, the MNR values represented as the solid lines as shown in Figures 3A and 3C are changed into the MNR values represented as the dotted lines. However, in this case, the final MNR values with respect to the human voice have much larger values than zero being a masking threshold value over the entire divided bands as shown in Figure 3A, while the final MNR values with respect to the sound of the beat instrument have values equal to or less than zero being the masking threshold value with respect to a plurality of the divided bands as shown in Figure 3C. On the contrary, if the bit allocation with respect to the two channels using the bit allocation method according to embodiments of the present invention is accomplished, the final MNR values have the MNR values represented as the dotted lines in Figures 3B and 3D. That is, after the bit allocation with respect to the two channels is accomplished, the MNR values (Figure 3B) with respect to the human voice and the MNR values (Figure 3D) with respect to the sound of the beat instrument exceed zero being the masking threshold value. Therefore, the user cannot perceive noise from the reproduced sound, thereby improving sound quality. Returning to Figure 2 again, multiplexer 15 multiplexes the signals quantized by quantizers 14A and 14B, the bit allocation information and/or the bit ratio information output from bit allocators 13A and 13B, and outputs the multiplexed result. The bit stream output from multiplexer 15 will be described below with reference to Figure 4. Figure 4 shows a structure of a bit stream forming one audio frame. The audio frame produced by multiplexer 15 is composed of 36-bit header data, bit allocation information, a scale factor and audio data, in sequence. The header data includes four-bit ratio information which represents a bit ratio of one channel with respect to the predetermined number of the bits in one audio frame in addition to thirty-two bits recommended by the MPEG. The bit allocation information is information for allocating the bits to each divided band. Then, the scale factor is a parameter which is used for quantization as is well known. The audio data following the scale factor is composed of the A-channel audio data and the B-channel audio data both of which are alternated. When the bit ratio information is composed of four bits, the bit ratio information which is actually produced by multiplexer 15 has a value of M-1. Thus, the bit ratio with respect to the B-channel becomes 16-(M-1). For example, if the bit ratio information which is produced by multiplexer 15 is five, M becomes six and N becomes ten. Thus, the audio data forming the bit stream has a format in which six bits of the A-channel and ten bits of the B-channel are alternated. Figure 5 is a block diagram of an apparatus for decoding an audio signal generated by the Figure 2 apparatus. In Figure 5, FIFO memory 21 stores an audio bit stream which is applied thereto according to a write enable signal of a controller (not shown) and outputs the stored data according to read enable signal of control logic unit 23. A first digital signal processor 22 outputs a signal for controlling a read operation to control logic unit 23 in response to an interrupt signal IRQ applied from FIFO memory 21. First digital signal processor 22 also receives the audio bit stream read from FIFO memory 21 and decodes only the A-channel audio signal, while the B-channel audio signal is supplied to a second digital signal processor 24. Control logic unit 23 outputs read enable signal to FIFO memory 21 according to a control signal applied from first digital signal processor 22. Second digital signal processor 24 receives the B-channel audio signal and decodes the received audio signal. The operation of the Figure 5 apparatus as constructed above will be described below. A bit stream having a video signal and multiplexed audio signal is input to an input end IN of FIFO memory 21. A controller (not shown) generates a write enable signal for separating an audio signal from the bit stream. FIFO memory 21 stores the applied bit stream by one byte when write enable signal having a sequential two one-byte interval is a low level state. FIFO memory 21 outputs interrupt signal IRQ to first digital signal processor 22 through full flag end FF as soon as a state of storing the data therein becomes full. First digital signal processor 22 outputs a control signal to control logic unit 23 as soon as the interrupt signal is applied thereto. Control logic unit 23 outputs read enable signal to FIFO memory 21 in response to the control signal. FIFO memory 21 outputs the bit stream having the A-channel audio data mixed with the B-channel audio data to first digital signal processor 22 in response to a low level state of read enable signal. First digital signal processor 22 separates the input audio bit stream into the A-channel audio data and the B-channel audio data using the bit ratio information which is inserted in a header portion, and decodes the only A-channel audio data. The B-channel audio data output from first digital signal processor 22 is applied to second digital signal processor 24 which decodes the input B-channel audio data. As described above, when the audio data of at least two channels is encoded, the number of the bits are saved at the channel of which the respective MNR values of the divided bands are all equal to or more than a predetermined value, and then the residue bits corresponding to the number of the remaining bits are additionally allocated to the other channel of which the respective MNR values are equal to or less than the predetermined value. Accordingly, the present invention has an effect of improving a quality of the sound so that the user cannot feel noise when an audio signal including many high frequency components is reproduced.

Claims: An encoding apparatus which utilizes masking characteristics of channels for bit allocation in order to encode digitally sampled audio frame signals of at least two channels, said encoding apparatus comprising first and second filter groups, first and second threshold calculation means, bit allocation means and first and second quantization means, the apparatus being characterised by the following features: the first filter group comprises a first divided band filter group (11A) for receiving an input first channel audio signal, dividing the input first channel audio signal into predetermined frequency divided bands and outputting a first channel frequency divided signal; the first threshold calculation means comprises a first threshold value calculation means (12A) for receiving both the input first channel audio signal and the first channel frequency divided signal of said first divided band filter group (11A), and calculating a first masking threshold value; the second filter group comprises a second divided band filter group (11B) for receiving an input second channel audio signal, dividing the input second channel audio signal into predetermined frequency divided bands and outputting a second channel frequency divided signal; the second threshold calculation means comprises a second threshold value calculation means (12B) for receiving both the input second channel audio signal and the second channel frequency divided signal of said second divided band filter group (11B), and calculating a second masking threshold value; the bit allocation means (13A, 13B) is arranged for: (i) performing bit allocation for the respective first and second channel frequency divided signals; (ii) receiving the respective first and second masking threshold values; (iii) detecting a masking to noise ratio of the respective first and second channels so as to monitor sub-bands of the first and second frequency divided signals; (iv) performing bit allocation to respective sub-bands of the first and second frequency divided signals, until the masking to noise ratio of all sub-bands of one of said respective first and second frequency divided signals exceeds its respective first or second masking threshold value; (v) using remaining bits which have not been used in exceeding the masking threshold value of the said one of said first or second frequency divided signals for bit allocation to the other of said first or second frequency divided signals; and (vi) producing bit allocation information corresponding to each channel and bit ratio information between the channels; the first quantization means (14A) is arranged for receiving the first channel frequency divided signal output from said first divided band filter group (11A) and for quantizing the received first channel frequency divided signal in response to the bit allocation information of said bit allocation means (13A, 13B) to output a quantized first channel signal; the second quantization means (14B) is arranged for receiving the second channel frequency divided signal output from said second divided band filter group (11B) and quantizing the received second channel frequency divided signal in response to the bit allocation information of said bit allocation means (13A, 13B) to output a quantized second channel signal; and multiplexing means (15) are provided for multiplexing the signals output from said first and second quantization means (14A, 14B), and the bit allocation information and the bit ratio information from said bit allocation means (13A, 13B), and outputting the resulting multiplexed signal. An encoding apparatus using masking characteristics of channels for bit allocation according to claim 1, wherein said bit allocation means (13A, 13B) allocates bits to the respective divided bands of the first and second channels by using a predetermined total combined number of bits for the first and second channel frequency divided signals of an audio frame. An encoding apparatus using masking characteristics of channels for bit allocation according to claim 1 of 2, wherein said bit allocation means (13A, 13B) comprises: a first bit allocator (13A) which allocates bits in a prioritised manner so as to first allocate bits to those particular divided frequency bands having the lowest masking to noise ratio among the divided frequency bands of the first channel, calculates revised masking to noise ratios with respect to the bit allocated divided frequency bands and compares the calculated revised masking to noise ratios with the first masking threshold value; and a second bit allocator (13B) which allocates bits in a prioritised manner so as to first allocate bits to those particular divided frequency bands having the lowest masking to noise ratio among the divided frequency bands of the second channel, calculates revised masking to noise ratios with respect to the bit-allocated divided band and compares the calculated masking to noise ratio with the second masking threshold value, wherein when said first bit allocator (13A) allocates bits with respect to all the divided frequency bands of the first channel so as to attain masking to noise ratios for each divided frequency band which exceed the first masking threshold value earlier than said second bit allocator (13B), said first bit allocator (13A) thereafter outputs bit allocation completion information to said second bit allocator (13B), and said second bit allocator (13B) generates bit ratio information based on the bit allocation completion information. An encoding apparatus using masking characteristics of channels for bit allocation according to claim 3, wherein when said second bit allocator (13B) allocates bits with respect to all the divided frequency bands of the second channel so as to attain masking to noise ratios which exceed the second masking threshold value earlier than said first bit allocator (13A), said second bit allocator (13B) thereafter outputs bit allocation completion information to said first bit allocator (13A), and said first bit allocator (13B) generates bit ratio information based on the bit allocation completion information. An encoding apparatus using masking characteristics of channels for bit allocation according to any of the preceding claims, wherein said bit ratio information is determined based on the number of bits which are used for bit allocation by the particular channel where the bit allocation has been accomplished earliest. A decoding apparatus using masking characteristics of channels for bit allocation in order to distribute an encoded and multiplexed input audio bit stream of two channels into their respective channels and to decode the resultant distributed audio bit stream, said decoding apparatus being characterised by : a first-in first-out memory (21) for storing a bit stream in which externally supplied two-channel audio data is combined and stored data is output, according to a write enable signal and a read enable signal; a first digital signal processor (22) for generating a control signal for controlling a read operation by detecting an interrupt signal supplied from said first-in first-out memory (21), and receiving the two-channel audio bit stream read from said first-in first-out memory (21) to decode only audio data of a first channel; control logic means (23) for supplying the read enable signal to said first-in first-out memory (21) according to the control signal supplied from said first digital signal processor (22); and a second digital signal processor (24) for receiving second channel audio data which has been separated from the first channel audio data by said first digital signal processor (22) and for decoding the received second channel audio data. A decoding apparatus using masking characteristics of channels for bit allocation according to claim 6, wherein said first-in first-out memory (21) outputs said interrupt signal as soon as the input audio data is fully recorded therein. A decoding apparatus using masking characteristics of channels for bit allocation according to claim 6 or 7, wherein said first digital signal processor (22) detects bit ratio information between the channels from the audio bit stream from said first-in first-out memory (21) and separates the respective channel audio data therefrom based on the detected bit ratio information. An encoding method which utilizes masking characteristics of channels for bit allocation in order to encode digitally sampled audio frame signals of at least two channels, said encoding method including the general steps of band filtering the two channel signals, allocating bits, and quantizing based on the allocated number bits and, in more detail, the method being characterised by the following specific steps of: receiving an input first channel audio signal, dividing the input first channel audio signal into predetermined frequency divided bands to output a first channel frequency divided signal, and calculating a first masking threshold value; receiving an input second channel audio signal, dividing the input second channel audio signal into predetermined frequency divided bands to output a second channel frequency divided signal, and calculating a second masking threshold value; calculating masking to noise ratios and recalculating revised masking to noise ratios resulting from progressive bit allocation for each of the first channel frequency divided bands and each of the second channel frequency divided bands, and comparing the calculated masking to noise ratios with the first masking threshold value and the second masking threshold value for each frequency divided band of the respective first and second channel; detecting when each frequency divided band of a given channel has achieved a condition in which the masking to noise ratio in which each bit allocated frequency divided band exceeds a masking threshold value based on the result of the above comparing step; for the channel in which it has been detected earliest that the above mentioned condition has been achieved, allocating those remaining bits which have not already been allocated to the other channel in which said above mentioned condition has not yet been achieved, and producing bit allocation information corresponding to each channel and bit ratio information between the channels; receiving the bit allocation information corresponding to each channel and quantizing the frequency divided signals of each channel to output quantized channel signals; and multiplexing: (i) the bit ratio information; (ii) bit allocation completion information from the channel which has achieved the abovementioned condition earliest; and (iii) the quantized channel signals. An encoding method using masking characteristics of channels for bit allocation according to claim 9, wherein said calculation and comparison step comprises repeatedly performing the steps of: performing bit allocation with respect to the particular frequency divided band having the lowest masking to noise ratio; and comparing the masking to noise ratio corresponding to the frequency divided band for which bit allocation has been accomplished with the masking threshold value of the corresponding channel. An encoding method using masking characteristics of channels for bit allocation according to claim 9 or 10, wherein said information producing step produces said bit allocation information at the time at which bit allocation has been accomplished for the two channels. An encoding method using masking characteristics of channels for bit allocation according to claim 9, wherein said bit ratio information represents a ratio between the number of allocated bits of the first channel and the number of allocated bits of the second channel at the time at which the bit allocation has been accomplished with respect to the two channels of the audio frame.

Inventors: KIM SEOUNG-BONG, KIM, SEOUNG-BONG, KIM, SEOUNG-BONG, SAMSUNG ELECTRONICS CO., LTD.
Applicants: SAMSUNG ELECTRONICS CO LTD, SAMSUNG ELECTRONICS CO., LTD.
Application year: 1995
Main classification: G11B20
IPC codes: H04B1, G10L19, G11B20, H03M7