Orthogonal transform coding apparatus and decoding apparatus

Abstract: Image signals are orthogonal-transformed (DCTed) in mutually different dimensions (DMs) to obtain transform coefficients (TC) for each DM, which are then compared mutually to select TC of one DM based on the comparison. Or else, such TC of one DM are selected based on the image signals in a specific DM and the selected TC are quantized and variable-length coded to output coded signals. In another way, prediction error (PE) signals obtained by predictive coding (PC) are DCTed in mutually different DMs to obtain TC for each DM; the TC of one DM are selected based on the PE signals in a specific DM, and then quantized and coded. Or else, the TC obtained for each DM are quantized and then compared mutually. The quantized signals of one DM are selected based on the comparison and then coded. Or else, the TC obtained for each DM are quantized and coded, and coded signals of one DM are selected based on the comparison. The coded signals are transmitted together with mode information (MI) indicating which DM the selected TC are transformed in. The coded signals are decoded, and then inversely quantized (IQed). The IQed signals are inversely DCTed in the DM indicated by the MI.

Description: BACKGROUND OF THE INVENTION Field of the Invention The present invention relates to a coding apparatus and a decoding apparatus for executing orthogonal transform (DCT (Discrete Cosine Transform), in particular), which can code signals and decode the coded signals by a high efficient coding and decoding method on the basis of a small coding quantity, in a digital signal processing (e.g., recording, transmitting, displaying, etc.) system. Description of the Prior Art In the high efficient coding technique using the orthogonal transform such as DCT, the quantity of data can be reduced on the basis of effective utilization of interframe correlation. Therefore, this coding technique is widely adopted as the standard technique. In this coding technique, the orthogonal transform is executed, in general, in two dimensions of vertical and horizontal directions of a block of image signals, for instance. This is because in the case of the one dimensional orthogonal transform, only one of the vertical and horizontal interframe correlations can be used; on the other hand, in the case of the two dimensional orthogonal transform, both the vertical and horizontal interframe correlations can be used. Further, it is effective to increase the size of transform block from the correlation standpoint, because the interframe correlation can be utilized more efficiently with increasing size of the transform block. In practice, however, there exists no substantial difference when the number of pixels is 8 x 8 or more. On the other hand, since the quantization error extends over the block, it is preferable to decrease the size of the block from the visual standpoint. In addition, the processing quantity decreases with decreasing size of the block. In summary, it is most general to transform image signals of the block of 8 x 8 pixels (8 degrees in both vertical and horizontal directions). In addition, in the case of the moving image coding, it is general to execute interframe predictive coding in the time direction and to adopt the spatial orthogonal transform for the prediction error. Fig. 1 shows a prior art coding apparatus and as is disclosed in JP-A-03 159 489 and EP-A-0 542 261. In the drawing, the apparatus comprises an image input 1, a horizontal DCT (discrete cosine transformer) 2, a vertical DCT 3, a quantizer 5, a variable length coder 6, and a coded signal output 7. The horizontal DCT 2 transforms inputted image signals in accordance with 8-degree discrete cosine transform in the horizontal direction for each two-dimensional block of 8 x 8 pixels. Further, the vertical DCT 3 further transforms the horizontally DCTed (discrete cosine transformed) signals in accordance with 8-degree discrete cosine transform in the vertical direction. The quantizer 5 quantizes the DCTed signals to such a quantization step width that the quantization error is not distinguishable visually. Here, the coefficients of almost all quantized signals are zero. The variable length coder 6 transforms the sequence of signals arranged in the two-dimensional block status into the sequence of signals arranged in the one-dimensional status (referred to as "zigzag scanning sequence") as listed in Fig. 2A. The run lengths of the zero coefficients and the values of the non-zero coefficients are coded in accordance with a VLC (variable length coding) such as Huffman code. The output of the variable length coder 6 is outputted as compressed data to a decoding apparatus (described below) through the code output 7. Fig. 3 shows a prior art decoding apparatus corresponding to the coding apparatus shown in Fig. 1. The decoding apparatus comprises a coded signal input 21, a variable length decoder 22, an inverse quantizer 23, a vertical inverse DCT 24, a horizontal inverse DCT 25, and an image output 26. The variable length decoder 22 decodes the compressed data of the variable length code to the fixed length codes. The inverse quantizer 23 inversely quantizes the fixed length codes to values representative of the quantization of the coded signals. The vertical inverse DCT 24 inversely transforms the inputted representative values in the vertical direction. The horizontal inverse DCT 25 further inversely transforms the inputted representative values in the horizontal direction. The obtained reproduced image signals are outputted through an image signal output 26. In the above-mentioned two-dimensional orthogonal transform coding apparatus, the transform efficiency is relatively high in the image portion in which the interframe correlation is relatively high. However, the prior art apparatus is not necessarily suitable for the image portion in which the interframe correlation is relatively low, for instance at the image edge portions. The above-mentioned tendency is prominent in the interframe prediction error signals, in particular. In other words, since the interframe correlation of the error signals is low, the two-dimensional orthogonal transform is not an appropriate coding method. Therefore, there exist some portions at which the one-dimensional transform such as only the horizontal or vertical transform is higher in efficiency than the two-dimensional transform. Further, in the two-dimensional transform, the quantization error extends over the two-dimensional block, so that the noise components are prominent in the vicinity of the image edges. In other words, the one-dimensional transform using a small transform block is preferable from the visual standpoint, as far as the equivalent coding error is allowed. Further, although the other coding technique such as DPCM (Differential Pulse Code Modulation) is preferable because the noise components are not prominent from the visual standpoint, the interframe correlation cannot be utilized effectively in the other coding technique, so that the basic efficiency is insufficient. SUMMARY OF THE INVENTION The object of the present invention is to provide an orthogonal transform coding apparatus high in coding efficiency and low in the noise components, and an orthogonal transform decoding apparatus corresponding to the coding apparatus. The present invention provides an apparatus for orthogonal transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first activity detecting means for detecting a first activity of the one-dimensional orthogonal transform coefficients; second activity detecting means for detecting a second activity of the two-dimensional orthogonal transform coefficients; output means for comparing the first and second activities with each other to output transform mode information; and selecting means, responsive to the transform mode information, for selecting either the one or the two-dimensional orthogonal transform coefficients. Further, the present invention provides an apparatus for orthogonal transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first coding means for quantizing and variable-length coding the one-dimensional orthogonal transform coefficients to obtain a one-dimensional orthogonal transform coded signal; second coding means for quantizing and variable-length coding the two-dimensional orthogonal transform coefficients to obtain a two-dimensional orthogonal transform coded signal; comparing means for comparing code quantities of the one- and two-dimensional orthogonal transform coded signals with each other to output transform mode information; and selecting means, responsive to the transform mode information, for selecting either the one- or the two-dimensional orthogonal transform coefficients. Further, the present invention provides an apparatus for orthogonal-transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first detecting means for detecting change rate of the signals to be coded in a vertical direction; second detecting means for detecting activity of the signals to be coded; comparing means for comparing the detected change rate and activity with each other to output transform mode information; and selecting means, responsive to the transform mode information, for selecting either the one- or the two-dimensional orthogonal transform coefficients. Further, the present invention provides an apparatus for orthogonal transform decoding coded signals of the type generated in the coding apparatus of claim 1, 4 or 5, the apparatus comprising: orthogonal inverse transforming means for inversely orthogonal transforming the coded signals by selecting one- or two-dimensional inverse transforming: and controlling means for controlling the orthogonal inverse transforming means to select the one- or the two-dimensional inverse transforming in response to transform mode information, the transform mode information being comprised in the coded signals to be decoded. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 is a block diagram showing a prior art orthogonal transform coding apparatus; Fig. 2A is a table showing the transform (scanning) sequence of two-dimensional arranged signals; Fig. 2B is a table showing the transform (scanning) sequence of one-dimensional arranged signals; Fig. 3 is a block diagram showing a prior art orthogonal transform decoding apparatus; Fig. 4 is a block diagram showing a first embodiment of the orthogonal transform coding apparatus according to the present invention; Fig. 5A is a table showing the construction of a two-dimensional DCTed (discrete cosine transformed) block; Fig. 5B is a table showing the construction of a one-dimensional DCTed (discrete cosine transformed) block; Fig. 6 is a block diagram showing a second embodiment of the orthogonal transform coding apparatus according to the present invention; Fig. 7 is a block diagram showing a third embodiment of the orthogonal transform coding apparatus according to the present invention; Fig. 8 is a block diagram showing a first embodiment of the orthogonal transform decoding apparatus according to the present invention; Fig. 9 is a block diagram showing a fourth embodiment of the orthogonal transform coding apparatus according to the present invention; Fig. 10 is a block diagram showing a fifth embodiment of the orthogonal transform coding apparatus according to the present invention; Fig. 11 is a block diagram showing a sixth embodiment of the orthogonal transform coding apparatus according to the present invention; and Fig. 12 is a block diagram showing a second embodiment of the orthogonal transform decoding apparatus according to the present invention. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS The embodiments of the coding apparatus and decoding apparatus according to the present invention will be described hereinbelow with reference to the attached drawings. Fig. 4 shows a first embodiment of the orthogonal coding apparatus. The apparatus comprises an image signal input 1, a horizontal DCT (discrete cosine transformer) 2, a vertical DCT 3, a selector 4, a quantizer 5, a variable length coder 6, a coded signal output 7, and in addition a first activity detector 8, a second activity detector 9, a mode discriminator 10, and a mode output 11. Image signals inputted through the image input 1 are DCTed (discrete cosine transformed) in the horizontal direction for each block of 8 x 8 pixels by the horizontal DCT 2, and then the horizontal DCTed signals are given to the vertical DCT 3, the selector 4, and the first activity detector 8, respectively. The horizontal DCTed signals are further DCTed in the vertical direction by the vertical DCT 3, and then the two-dimensional DCTed signals are given to the selector 4, and the second activity detector 9. Here, when the image signals are DCTed only in the horizontal direction by the horizontal DCT 2, the DCT block is of one-dimension (horizontal direction) of 8 pixels. However, it is convenient to bundle 8 DCT blocks in the vertical direction into a block of 8 x 8 pixels under consideration of switching from one-dimensional processing to the two-dimensional processing or vice versa. Fig. 5A shows a two-dimensional DCT block; and Fig. 5B shows a horizontal DCT block. In Figs. 5A and 5B, DCs represent average components of the DCT coefficients of the DCTed signals, and blanks represent alternating components (AC), respectively. The first activity detector 8 detects the activity of the signals DCTed only in the horizontal direction. The activity Ald of the signals can be obtained by an addition of absolute values of the respective DCT coefficients, for instance as expressed by formula (1) below: where C1d xy denotes a coefficient value of the x-th DCT position in the horizontal direction and the y-th DCT position in the vertical direction; and Cld 0y denotes a DC component. Further, although there exist 8 DC components within a block of 8 x 8 pixels, the simple sum of these DC absolute values is not suitable for the activity. Therefore, differences between adjacent two DC components in the vertical direction are calculated as the formula (1) above. Further, in the formula (1), the first one DC value (at which no difference can be obtained) is excluded from the above-mentioned addition. The second activity detector 9 detects the activity of the signals two-dimensional DCTed both in the horizontal and vertical directions. The activity A2d of the signals can be obtained by an addition of absolute values of the respective coefficients, for instance as expressed by formula (2) below: where C2d xy denotes a coefficient value of the x-th two-dimensional DCT position in the horizontal direction and the y-th two-dimensional DCT position in the vertical direction; and C2d 00 denotes a DC component. Further, in the formula (2), the one DC component is excluded. Further, in the case where the coded signals are not the image signals but the error signals of the interframe prediction, since the DC component is substantially regarded as the AC component, the absolute values of all the coefficients are simply added. In practice, the following formula (3) is used in place of the formula (1) in the first activity detector 8, and the fallowing formula (4) is used in place of the formula (2) in the second activity detector 9. Here, the unit of pixels switched for processing is not necessarily the same as the number of pixels of the DCT block (8 x 8 pixels); that is, it is possible to bundle a plurality of the DCT blocks In the case where the color difference signals of color images are sub-sampled, in particular, since a plurality of luminance signal blocks and the color difference signal block are paired, the bundled blocks are sometimes convenient. The horizontal DCT activity obtained by the first activity detector 8 and the two-dimensional DCT activity obtained by the second activity detector 9 are given block by block to the mode discriminator 10. The mode discriminator 10 compares the two activities to determine which one of the activities is smaller than the other; that is, to obtain mode information. In this comparison, it is possible to add a value (about 1 for each coefficient) to one of the activities (as far as the inputted image signals are of 8 bits and represented by values from 0 to 255 and further the transform magnification of the horizontal DCT 2 and the vertical DCT 3 is 8 1/2 , respectively) or to multiply one of the activities by about 1. 25, so that a certain offset can be given for adjustment of the selection. The mode information thus obtained is outputted to a decoding apparatus described later through the mode output 11 and further to the selector 4, the quantizer 5 and the variable length coder 6. On the basis of the mode information, the selector 4 selects transform (DCT) coefficients and the selected transform coefficients are given to the quantizer 5. When the respective DCT coefficients are quantized uniformly, the quantizer 5 executes the same processing. When the DCT coefficients are weighted in accordance with the visual characteristics, the quantizer 5 executes different processing according to the transform method. The weighted quantization of the DCT coefficients is executed on the basis of the mode information so as to obtain the two-dimensional characteristics in the case of the two-dimensional (in both horizontal and vertical directions) DCT and so as to obtain the one-dimensional characteristics in the case of the one-dimensional (in only the horizontal direction) DCT. The output of the quantizer 5 is coded by the variable length coder 6. The sequence of arrangement transform (scanning) executed by the variable length coding is different between the two-dimensional DCT and the one-dimensional DCT. The scanning sequence of the two-dimensional DCT is the same as with the case of the prior art as shown in Fig. 2A. However, the scanning sequence of the one-dimensional DCT becomes as shown in Fig. 2B. By processing 8 one-dimensional DCTed signals bundled as shown in Fig. 2B, it is possible to improve the efficiency of the O-run length coding with the use of the same VLC (variable length coding) table. The codes compressed by the variable length coder 6 are outputted to a decoding apparatus (described later) through the code output 7. In the first embodiment of the coding apparatus according to the present invention as describe above, the activity of the signals DCTed only in the horizontal direction is obtained by the first activity detector 8, and further the activity of the signal two-dimensional DCTed in both horizontal and vertical directions is obtained by the second activity detector 9. In other words; the activities of the DCTed signals are calculated on the basis of transform coefficients obtained by a plurality of orthogonal transforming means (the horizontal DCT 2 and the vertical DCT 3), and the appropriate orthogonal transforming method of the signals to be coded can be discriminated or selected. Accordingly, the coding apparatus is simple in configuration and high in processing speed. Further, the apparatus is high in precision, as compared with the case where the activity is obtained by the use of the final data coded. This is because in the case of the present embodiment, the transform coefficients obtained by the horizontal DCT 2 and the vertical DCT 3 directly indicate the activity required to select the orthogonal transform method. Fig. 6 shows a second embodiment of the orthogonal transform coding apparatus according to the present invention, in which the same reference numerals have been retained for the similar parts or elements which have the same functions as with the case of the first embodiment shown in Fig. 4. In Fig. 6, the image signals inputted through the image input 1 are DCTed in the horizontal direction by the horizontal DCT 2, and then given to the vertical DCT 3 and the quantizer 5. The image signals DCTed in the horizontal direction by the horizontal DCT 2 are further DCTed in the vertical direction by the vertical DCT 3 as the two-dimensional DCTed signals, and then given to another quantizer 31. The horizontally DCTed image signals are quantized by the quantizer 5. In this case, the weighting according to the one-dimensional (horizontal) visual characteristics is made to the respective DCT signals or coefficients by the quantizer 5. The quantized coefficients are given to the activity detector 8 and the selector 4, respectively. In the same way, the horizontally and vertically DCTed image signals are quantized by the quantizer 31. In this case, the weighting according to the two-dimensional (horizontal and vertical) visual characteristics is made to the respective DCT signals or coefficients by the quantizer 31. The quantized coefficients are given to the activity detector 9 and the selector 4, respectively. In Fig. 6, the functions of the activity detector 8 and the activity detector 9 are the same as with the case of the first embodiment as shown in Fig. 4. However, the DCTed image signals are weighted and then quantized in such a way that the weighting decreases as the image signal components increase in frequency. Since the weighting of the quantization is effected as described above, it is possible to allow the coding to be more suitable for the practical coding method. The activity of the horizontal DCTed signals obtained by the activity detector 8 and the activity of the two-dimensional DCTed signals obtained by the activity detector 9 are both given to the mode discriminator 10 for each block. The mode discriminator 10 compares the two activities to select the smaller one, and outputs the orthogonal transform mode information. The outputted mode information is given to the variable length coder 6 and further to a decoding apparatus (described later) through the mode output 11. The selector 4 selects one of the outputs of the quantizer 5 and the quantizer 31 on the basis of the mode information, and the selected quantized coefficients are given to the variable length coder 6. The variable length coder 6 codes the quantized coefficients by changing the scanning sequence (as shown in Figs. 2A and 2B) on the basis of the mode information. The coded data compressed by the variable length coder 6 are outputted to the decoding apparatus through the code output 7. Fig. 7 shows a third embodiment of the orthogonal transform coding apparatus according to the present invention, in which the same reference numerals have been retained for the similar parts or elements which have the same functions as with the case of the first embodiment shown in Fig. 4. The basic operation of this third embodiment is the same as the case of the first embodiment shown, except the method of weighting the coefficients when the activities are obtained. In Fig. 7, the horizontal DCT 2 and the vertical DCT 3 operate in the same way as those shown in Fig. 4. The output of the horizontal DCT 2 is given to the vertical DCT 3 and a coefficient weighting section 42, and the output of the vertical DCT 3 is given to a coefficient weighing section 41. The coefficient weighting section 41 divides each coefficient by a value corresponding to the weight determined when the two-dimensional DCTed signals are quantized. In the same way, the coefficient weighting section 42 divides each coefficient by a value corresponding to the weight determined when the horizontally DCTed signals are quantized. That is, the processing is equivalent to that by which the DCTed signals are quantized on the basis of sufficiently small quantization step. The divided coefficient output of the coefficient weighting section 41 is given to the activity detector 9, and the divided coefficient output of the coefficient weighting section 42 is given to the activity detector 8, respectively. In comparison with the second embodiment shown in Fig. 6, in this third embodiment, it is possible to apply a weight even a small coefficient value so as to be used for the mode discrimination, otherwise it will be neglected. The functions of the activity detectors 8 and 9, the mode discriminator 10, the selector 4, the quantizer 5, and the variable length coder 6 are all the same as with the case of the first embodiment shown in Fig. 4. The compressed coded data are outputted to the decoding apparatus through the code output 7. Fig. 8 shows a first embodiment of the orthogonal transform decoding apparatus according to the present invention, in which the same reference numerals have been retained for the similar parts or selections which have the same functions as with the case of the prior art decoding apparatus as shown in Fig. 3. In Fig. 8, the decoding apparatus comprises a mode input 28 and a selector 27 in addition to the elements shown in Fig. 3. The compressed data applied through the code input 21 are introduced into the variable length decoder 22. On the other hand, the mode information obtained by the coding apparatus according to the present invention is inputted through the mode input 28, and then given to the variable length decoder 22, the inverse quantizer 23, and the selector 27, respectively. The functions of the variable length decoder 22 and the inverse quantizer 23 are basically the same as those of the prior art decoding apparatus shown in Fig. 3. However, in the variable length decoder 22, the scanning order is switched on the basis of the mode information. Further, in the inverse quantizer 23, the weighting of the coefficient is switched on the basis of the mode information. The output of the inverse quantizer 23 is given to the vertical inverse DCT 24 and the selector 25. The vertical inverse DCT 24 inversely transforms the DCTed signals in the vertical direction. The selector 25 controlled on the basis of the mode information selects the output of the vertical inverse DCT 24 in the case of the two-dimensional DCTed block and output of the inverse quantizer 24 in the case of the horizontal DCTed block. The selected DCTed block is introduced to the horizontal inverse DCT 25 to inversely transform the DCTed signals in the horizontal direction. As described above, the two-dimensional block is inversely DCTed in both vertical and horizontal directions, and the one-dimensional (horizontal) block is inversely DCTed in only the horizontal direction. The reproduced image signals thus obtained are outputted through the image output 26. In the orthogonal coding apparatus according to the present invention as shown in Figs. 4, 6 and 7, since the dimension of the orthogonal transform is controllably changed for each block to select an optimum transform method, it is possible to execute the optimum coding processing for each block (for each image position) and thereby to improve the coding efficiency all over the image, as compared with the apparatus which adopts only a single transform method. Further, since the one-dimensional transform is executed at image edges, for instance, it is possible to reduce the quantization noise and error, thus improving the image quality. In addition, the transform method is determined or selected on the basis of the activities derived from the orthogonal transformed coefficients or the transformed and quantized coefficients, the activities can be detected easily at high precision. Fig. 9 shows a fourth embodiment of the orthogonal transform coding apparatus according to the present invention, in which the same reference numerals have been retained in the same way as in the previous embodiments. In Fig. 9, the image signals given through the image input 1 are DCTed for each block of 8 x 8 pixels in the horizontal direction by the horizontal DCT 2, and then given to the vertical DCT 3 and the quantizer 80. The horizontally DCTed signals are further DCTed in the vertical direction by the vertical DCT 3, and then given to the quantizer 5 as the two dimensional DCTed signals. In other words, the quantizer 80 quantizes the signals DCTed only in the horizontal direction, and the quantizer 5 quantizes the signals DCTed both in the horizontal and vertical directions. Here, in the case of the horizontal transform, the DCT block is of 8 pixels of one dimension. However, as well as in the case of the horizontal and vertical (two-dimensional) transform, the DCT block is of 8 x pixels of two dimension (8 horizontal blocks are bundled in the vertical direction as shown in Fig. 5B) for convenience of switching between one dimensional processing and two dimensional processing. When the two quantizers 5 and 80 quantize the respective coefficients of the DCTed signals uniformly, the quantization processing becomes the same for both. However, when the weighting is made to the respective DCT coefficients according to the visual characteristics (e.g., rough at higher frequencies), the quantization processing is different form each other. The quantizer 5 effects the quantization weighting in accordance with the two-dimensional characteristics; however, the quantizer 80 effects the quantization weighting repeatedly in accordance with the one-dimensional characteristics. The output of the quantizer 5 is coded by the variable length coder 6, and the output of the quantizer 80 is coded by the variable length coder 90, respectively. Both the coded signals are given to the selector 4 and a minimum value discriminator 100. The way of arrangement transform (scanning sequence) of the variable length coding is different between the quantizers 6 and 90. In more detail, the arrangement transform in the variable length coder 6 is of oblique zigzag scanning as shown in Fig. 2A in the same way as in the conventional way, and the arrangement transform in the variable length coder 90 is of vertical scanning as shown in Fig. 2B. This arrangement transform method is the same as disclosed in the prior application of a co-inventor and the same Applicant (Japanese Patent Application No. 1-213939 laid open as JP-A-3-77477). As described above, since the one-dimensional DCTed signals are processed for each block of 8 x 8 pixels by bundling the 8 pixels of one dimension so as to be processed in the same way as with the case of the two-dimensional DCTed signals, it is possible to improve the efficiency of the 0-run length coding. Further, in this case, the same VLC (variable length coding) table can be used for both the quantizers 6 and 10. However, when two different VLC tables are used for the two quantizers appropriately, it is possible to further improve the coding efficiency. The minimum value discriminator 100 compares the outputs of (i.e., the code quantities (the numbers of bits) of the respective blocks) of the two variable length coders 6 and 90, and outputs a control signal as the mode information so that the output of the smaller number of bits can be selected. Here, the unit of pixels compared with respect to the numbers of bits to switch the processing is not necessarily the same as the number of pixels of the DCT block (8 x 8 pixels); that is, it is possible to bundle any number of the DCT blocks. In the case where the color difference signals of color images are sub-sampled in particular, since a plurality of luminance signal blocks and one color difference signal block are paired according to the proportion of the sub-sampling, it is convenient to compare the numbers of bits for each pair to switch the processing. The mode information is outputted to the selector 4 and further to the decoding apparatus (described later) through the mode output 11. The selector 4 selects one (smaller in data quantity) of the outputs of the variable length coders 6 and 90 and outputs the selected data through the data (code) output 7. Therefore, in the case where the correlation is small in the vertical direction, since the one-dimensional (horizontal) DCTed signals are selected without DCTing the image signals in the two-dimensional, it is possible to execute orthogonal transform coding high at efficiency and low in noise. In the above-mentioned processing, when the quantization weighting is determined in such a way that the distortion caused by the quantization becomes the same in the respective transform processing and further one (smaller in data quantity) of the outputs of the variable length coders 6 and 90 can be selected under these conditions, it is possible to equalize the distortion degree and further to reduce the overall data quantity. In this case, when the quantization of the quantizer 80 is determined to be slightly rough, although the one-dimensional transformed signals are apt to be selected and thereby the coding error increases slightly, it is possible to obtain a coding desirable from the visual standpoint. Fig. 10 shows a fifth embodiment of the orthogonal transform coding apparatus according to the present invention, in which the transform mode is determined by means different from the main coding system of the fourth embodiment shown in Fig. 9. In Fig. 10, the image signals given through the image input 1 are DCTed in the horizontal direction as block signals of 8 x 8 pixels by the horizontal DCT 2, and then introduced to the vertical DCT 3 and the selector 4. The horizontally DCTed signals are further DCTed in the vertical direction, and then the two-dimensional DCTed signals are given to the selector 4. On the other hand, a mode discriminating section 340 includes a vertical change detector 310, an activity detector 320 and a mode discriminator 330. The image signals inputted through the image input 1 are given to the vertical change detector 310 for detecting the change rate v in the vertical direction, and the activity detector 320 for detecting the dispersion value d in the image block. The change rate v in the vertical direction and the dispersion value d of the block are expressed by the formulae as follows: where dc denotes an average value, and P xy denotes a horizontal x-th and vertical y-th pixel value in the 8 x 8 block. The mode discriminator 330 compares the two information values. When the change rate v in the vertical direction is relatively large with respect to the dispersion value d, the mode discriminator 330 outputs a control signal to select only the horizontal DCTed signals. This is because when the signals (whose change rate v in the vertical direction is large) is DCTed in the vertical direction, the components of higher frequencies increase and therefore the transform efficiency is deteriorated as compared with when not DCTed. In other words, when the mode discriminating section 340 discriminates that the change rate v of the two dimensional DCTed signals are relatively large, the orthogonal transform is not executed in the two-dimension to prevent the transform efficiency from being reduced. The functions of the quantizer 5 and the variable length coder 6 are the same as with the case of the first embodiment shown in Fig. 4. In this fifth embodiment, since only one main coding system is used, it is possible to reduce the processing quantity as compared with the fourth embodiment shown in Fig. 9. Fig. 11 shows a sixth embodiment of the orthogonal transform coding apparatus according to the present invention, in which the same reference numerals have been retained in the same way as in the other embodiments. In this embodiment, interframe prediction is effected, and the orthogonal transform is effected for the prediction error signals. The image signals inputted through the image input 1 are given to a prediction subtracter 410. The prediction signals given by a frame memory 420 are subtracted from the image signals to obtain the prediction error signals. The prediction error signals are given to the horizontal DCT 2 and the mode discrimination section 340. The functions of the mode discrimination section 340, the horizontal DCT 2, the vertical DCT 3, the selector 4, the quantizer 5, and the variable length coder 6 are the same as with the case of the fifth embodiment shown in Fig. 10. Further, the functions of a local decoding section composed of the inverse quantizer 23, the horizontal inverse DCT 25, the vertical inverse DCT 24 and the selector 27 are the same as with the case of the first embodiment of the decoding apparatus shown in Fig. 8. The prediction signals given by the frame memory 420 are added to the prediction error signals (locally decoded by the horizontal inverse DCT 25) by an adder 430 to obtain the reproduced image signals. The obtained image signals are given to the frame memory 420. The reproduced image signals delayed by one frame are applied as the prediction signals from the frame memory 420 to the prediction subtracter 410 and the adder 430. The prediction error signals are lower in correlation than the ordinary image signals. Therefore, the proportion at which the one-dimensional DCTed signals are used is more increased than the ordinary image signals. In other words, when the image moves slightly, since the prediction error is small and the intraframe correlation is small, the image signals are orthogonal-transformed by the one-dimensional DCT without use of the two-dimensional DCT, thus increasing the transform efficiency and decreasing the transform noise. Further, in the practical apparatus, motion compensation is usually applied to the interframe prediction signals. However, the embodiment of the present invention including no motion compensation function is substantially the same as the practical apparatus including the motion compensation function. Fig. 12 shows a second embodiment of the orthogonal transform decoding apparatus according to the present invention, in which the same reference numerals have been retained for the similar parts or sections which have the same functions as with the case of the first embodiment shown in Fig. 8. This decoding apparatus corresponds with the coding apparatus shown in Fig. 11. The functions of the variable length decoder 22, the inverse quantizer 23, the vertical inverse DCT 24, the horizontal inverse DCT 25, and the selector 27 are the same as with the case of the decoding apparatus shown in Fig. 8, and the functions of the frame memory 420 and the adder 430 are the same as with the case of the coding apparatus shown in Fig. 11. In the above-mentioned crthogonal transform coding apparatuses, since the dimension of the orthogonal transform is changed block by block to select the optimum transform method, it is possible to code the image signals for each block locally under the optimum conditions and thus to improve the coding efficiency all over the image, as compared with the coding method using only a fixed transform method. When the concept of the present invention is applied to the interframe prediction error signals in particular, since the interframe correlation of the prediction error is small, it is possible to execute the orthogonal transform coding at an extremely high efficiency. Further, since the one-dimensional orthogonal transform coding is adopted at the image edge portions, the noise caused by the quantization can be reduced, so that the image quality can be further improved by reducing the coding error.

Claims: An apparatus for orthogonal transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means (2) for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means (2,3) for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first activity detecting means (8) for detecting a first activity of the one-dimensional orthogonal transform coefficients; second activity detecting means (9) for detecting a second activity of the two-dimensional orthogonal transform coefficients; output means (10) for comparing the first and second activities with each other to output transform mode information; and selecting means (4), responsive to the transform mode information, for selecting either the one- or the two-dimensional orthogonal transform coefficients. The apparatus according to claim 1, further comprising quantizing means (5,31) for quantizing the one- and two-dimensional orthogonal transform coefficients, wherein the first and second activity detecting means detect the activities of the one- and two-dimensional orthogonal transform coefficients thus quantized, respectively. The apparatus according to claim 1, further comprising weighting means (41,42) for weighting the one- and two-dimensional orthogonal transform coefficients, wherein the first and second activity detecting means detect the activities of the one- and two- dimensional orthogonal transform coefficients thus weighted, respectively. An apparatus for orthogonal transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means (2) for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means (2,3) for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first coding means (80,90) for quantizing and variable-length coding the one-dimensional orthogonal transform coefficients to obtain a one-dimensional orthogonal transform coded signal; second coding means (5,6) for quantizing and variable-length coding the two-dimensional orthogonal transform coefficients to obtain a two-dimensional orthogonal transform coded signal; comparing means (100) for comparing code quantities of the one- and two-dimensional orthogonal transform coded signals with each other to output transform mode information; and selecting means (4), responsive to the transform mode information, for selecting either the one- or the two-dimensional orthogonal transform coefficients. An apparatus for orthogonal-transform coding image signals by switching one- and two-dimensional transforming, the apparatus comprising: first orthogonal transforming means (2) for one-dimensional orthogonal transforming image signals to be coded to obtain one-dimensional orthogonal transform coefficients; second orthogonal transforming means (2,3) for two-dimensional orthogonal transforming the image signals to be coded to obtain two-dimensional orthogonal transform coefficients; first detecting means (310) for detecting change rate of the signals to be coded in a vertical direction; second detecting means (320) for detecting activity of the signals to be coded; comparing means (330) for comparing the detected change rate and activity with each other to output transform mode information; and selecting means (4), responsive to the transform mode information, for selecting either the one- or the two-dimensional orthogonal transform coefficients. The apparatus according to claim 5, wherein the signals to be coded are interframe prediction error signals. An apparatus for orthogonal transform decoding coded signals of the type generated in the coding apparatus of claim 1, 4 or 5, the apparatus comprising: orthogonal inverse transforming means (24, 25) for inversely orthogonal transforming the coded signals by selecting one- or two-dimensional inverse transforming; and controlling means (27) for controlling the orthogonal inverse transforming means to select the one- or the two-dimensional inverse transforming in response to transform mode information, the transform mode information being comprised in the coded signals to be decoded. The apparatus according to claim 7, wherein the coded signals are interframe prediction error coded signals, the apparatus further comprising reproducing means (420, 430) for adding output signals of the orthogonal inverse transforming means and signals already decoded by the apparatus to produce output signals.

Inventors: NAKAMURA HIROYA, SUGIYAMA KENJI, NAKAMURA, HIROYA, SUGIYAMA, KENJI
Applicants: VICTOR COMPANY OF JAPAN, VICTOR COMPANY OF JAPAN, LTD.
Application year: 1993
Main classification: H04N7
IPC codes: H04N7, G06T9