Embodiment
(first embodiment)
Hereinafter with reference to each width of cloth accompanying drawing, the first embodiment of the present invention is described.
Fig. 4 is the integrally-built block diagram of expression picture coding device 1 of the present invention.Picture coding device 1 is the device that is used to carry out infra-frame prediction of the present invention, and picture coding device 1 comprises intraprediction unit 11, difference computational unit 12, switch 13, orthogonal transform unit 14, quantifying unit 15, entropy coding unit 16, is used to carry out the inter prediction unit 17 of inter prediction and the control unit 18 of encoding.Inter prediction unit 17 has switch 170, inverse quantization unit 171, inverse transformation block 172, adder 173, loop filter 174, frame memory 175, motion prediction unit 176 and motion compensation units 177.
When carrying out inter prediction, will be input to difference computational unit 12 about the information of the present frame that will be encoded.In difference computational unit 12, can obtain predictive residual signal (prediction residual signal) by calculating about the difference between the information of the present frame that will be encoded and the prediction image signal of exporting as motion compensation units 177.Predictive residual signal is exported to orthogonal transform unit 14 and quantifying unit 15.Orthogonal transform unit 14 is carried out the frequency translation of predictive residual signal.Quantifying unit 15 is carried out such as the image encoding that quantizes and is handled and the output transform coefficient.Conversion coefficient is input in inverse quantization unit 171 and the inverse transformation block 172, and is performed the picture decoding processing such as re-quantization and inverse transformation, thereby obtains decoded residual signal.Adder 173 is added to decoded residual signal on the prediction image signal, and generates the picture signal of rebuilding.Loop filter 174 is carried out filtering on the reconstructed image signal that is generated, then picture signal is stored in the frame memory 175.
The received image signal of each macro block of reading from frame memory 175 also is input to the motion prediction unit 176.At this, from as detecting being stored in the middle of one or more coded frame the frame memory 175 of target frame, detect image-region signal value near received image signal, thus the reference frame index of selected frame when determining that the motion vector of presentation video regional location and expression detect.Motion compensation units 177 is used the detected motion vector sum reference frame index that obtains by above-mentioned processing, extracts the optimized image zone in the coded frame from be stored in frame memory 175, the generation forecast image.
Variable length code is carried out for information encoded in entropy coding unit 16, this information encoded for example be motion vector, reference frame index that obtains by above-mentioned a series of processing and the residual signal of having encoded, thereby obtain bit stream.
But above-mentioned processing is the sequence of operation of inter prediction encoding, and inter prediction encoding and intraframe predictive coding can use switch 3 and switch 170 to switch.Under the situation of intraframe predictive coding, predicted picture is not to produce by motion compensation, but as mentioned above, and by based on the coding region in the same frame, the predicted picture of the current region that generation will be encoded is carried out subtraction and the generation forecast residual signal then.As the situation of inter prediction encoding, predictive residual signal is transformed to the residual signal of having encoded in orthogonal transform unit 14 and quantifying unit 15, and encodes in the variable-length mode in entropy coding unit 16, obtains the bit stream that will export then.The operation of each processing unit in the aforementioned picture coding device 1 of coding control unit 18 controls.
Fig. 5 is the block diagram of the intraprediction unit structure of expression first embodiment of the invention.Intraprediction unit 11 is such processing units, and it only calculates some 4 * 4 the predicated error that is comprised in 16 * 16 macro blocks, and does not calculate all prediction on intra-frame prediction mode errors, just determines intra prediction mode.Intraprediction unit 11 comprises comparing unit 43, prediction mode estimation unit 44 and memory cell 47 between piece selected cell 41, mode error value computing unit 42, pattern.In memory cell 47, the adjacent block prediction mode information 48 of the intra prediction mode that uses in the adjacent block that storage representation has been encoded, and the pixel value of the adjacent block of having encoded, comprise 1) with the adjacent coded macroblocks in the current macro top pixel value and 2 of below delegation) with the pixel value of the adjacent macro block rightmost side of having encoded the row of current macro left, and 16 * 16 pixel values of storage current macro.
Here, the predicated error computing unit is corresponding to prediction mode estimation unit 44, pattern determining unit is corresponding to comparing unit 43 between piece selected cell 41, mode error value computing unit 42 and pattern, and mode selecting unit is corresponding to piece selected cell 41 and prediction mode estimation unit 44.
The image information of the present frame that is encoded is input to the piece selected cell 41 from external device (ED).
In piece selected cell 41, the current block that is encoded is divided into predicated error computing block and nonanticipating Error Calculation piece, the predicated error computing block is used for determining intra prediction mode by calculating predicated error, determines intra prediction mode but not the predicated error computing block is used for not calculating predicated error.In fact in piece selected cell 41, store one or more patterns of cutting apart in advance, these cut apart the arrangement that pattern is represented predicated error computing block and nonanticipating Error Calculation piece." cut apart " by determining that cutting apart one of pattern carries out.Fig. 6 A to 6F is the exemplary plot that is divided into predicated error computing block and nonanticipating Error Calculation piece with 4 * 4.Numeral coded sequence in each 4 * 4.Or rather, Fig. 6 A shows only to calculate and is positioned at upper left prediction errors, and does not calculate the situation of other three prediction errors.Fig. 6 B shows only to calculate and is positioned at two prediction errors of upper left side and lower left, and does not calculate the situation of two other prediction errors.Fig. 6 C shows and only calculates two prediction errors that are positioned at the top, and does not calculate the situation of two other prediction errors of below.The situation of three prediction errors during Fig. 6 D shows and calculates 4 * 4 except being positioned at a bottom-right pixel.During showing and calculate 16 * 16, Fig. 6 E is positioned at the situation of seven prediction errors of the top and the leftmost side.Fig. 6 F shows as carreau, calculates 4 * 4 the upper left side and the situation of bottom-right two prediction errors of being positioned at.Shown in Fig. 6 A to 6F, with regard to predicated error computing block and nonanticipating Error Calculation piece, depend on and cut apart figure that the number that calculates the piece of its predicated error is inequality.In piece selected cell 41, store the composite diagram of predicated error computing block and nonanticipating Error Calculation piece in the macro block in advance, and predicated error computing block and nonanticipating Error Calculation piece are that the processing load by considering coding method selected cell 50 and the processing operational ton of each width of cloth composite diagram are determined.For example under the processing of coding method selected cell 50 load condition with higher, select to have height ratio nonanticipating Error Calculation piece cut apart figure.On the other hand, under the relatively low situation of the processing of coding method selected cell 50 load, select to have height ratio the predicated error computing block cut apart figure.These only are some examples of option, and option is not limited to these examples.In addition, the macro block of same frame both can use the identical figure of cutting apart for whole, also can use the different figure of cutting apart for whole.
Mode error value computing unit 42 uses the present frame information of the current block that will be encoded that is confirmed as the predicated error computing block, and the present frame that calculating will be encoded is each prediction on intra-frame prediction mode error optionally.Absolute difference sum (SAD) is generally used for predicated error with difference of two squares sum (SSD).
Next, comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Intra prediction mode corresponding to this predicated error is confirmed as, and has been defined as the intra prediction mode of the current block that will be encoded of predicated error computing block.
Be confirmed as at the current block that will be encoded under the situation of nonanticipating Error Calculation piece, prediction mode estimation unit 44 is used the prediction mode information of the adjacent block of the current block that will be encoded, the intra prediction mode of definite current block that will be encoded., do not carry out all optional prediction on intra-frame prediction mode Error Calculation respectively here, therefore can reduce the processing operational ton.
Fig. 7 is expression and the figure of the maximum number of the adjacent predicated error computing block of nonanticipating Error Calculation piece.Or rather, prediction mode estimation unit 44 is used the intra prediction mode of encoding block when selecting the intra prediction mode of nonanticipating Error Calculation piece.For the selection of the intra prediction mode of nonanticipating Error Calculation piece, a kind of like this method is arranged, need not anyly change, use the intra prediction mode of the piece of having determined intra prediction mode.
Now Fig. 7 shows the peaked situation that the number of the piece of having determined its intra prediction mode is the adjacent block of the current block that will be encoded.For example under current 4 * 4 upper left sides or top-right situation that are positioned at macro block that will be encoded, the intra prediction mode of five piece A, B, C, D and F is determined.On the other hand, in Fig. 7 in the nonanticipating Error Calculation piece of site grid representation, select to determine a kind of in the coding mode of piece of its intra prediction mode, and this predictive mode is used for the current block that will be encoded.
As shown in Figure 7, under the situation among a plurality of predicated error computing blocks are present in adjacent block, following method is available:
(1) selection is positioned at the method (in other words, selecting to be positioned at respect to nonanticipating Error Calculation piece the intra prediction mode of the predicated error computing block on the fixed position) of the intra prediction mode of the piece on the fixed position with respect to the current block that will be encoded;
(2) in the middle of the intra prediction mode of determining for the predicated error computing block, select the method for intra prediction mode with minimal mode numbering;
(3) SAD estimated value of selecting its predicated error computing block etc. is the method for the intra prediction mode of minimum value;
(4) in the middle of the intra prediction mode of determining for the predicated error computing block, select the method for the most normal intra prediction mode of selecting for use of adjacent block; And
(5) in the middle of the estimated value sum of each intra prediction mode of calculating for the predicated error computing block, select the method for intra prediction mode with minimum value.
Fig. 8 is the figure of the example of the expression intra prediction mode of selecting nonanticipating Error Calculation piece in the middle of the adjacent encoding block.Here will be described about following situation, in the middle of the adjacent block 2,8 and 10 intra prediction modes of determining of the predicated error that has been as calculated, select the 9th current 4 * 49 intra prediction mode that will be encoded in coded sequence.Before should be noted in the discussion above that supposition the 9th will be encoded in coded sequence 4 * 4, the 10th 4 * 4 of will be encoded in the coded sequence are encoded, so that be chosen in the coded sequence the 9th 4 * 4 intra prediction mode.
For example, select to be positioned at the method that Fig. 7 describes the intra prediction mode of the piece on the fixed position according to (1), when regulation " selection is positioned in the intra prediction mode with the adjacent piece in the current block that will be encoded left side ", the 9th 4 * 4 are chosen as the 8th 4 * 4 definite intra prediction modes " 0 ", and the 8th 4 * 4 are positioned in the left side in abutting connection with the 9th piece.Similarly, when regulation " selection is positioned at the intra prediction mode of upper left of the current block that will be encoded ", select the 2nd 4 * 4 intra prediction mode " 3 ".
In addition, according to (2) in the middle of adjacent a plurality of predicated error computing blocks, select the method for intra prediction mode with minimal mode numbering, for instance, determined intra prediction mode " 3 " being second 4 * 4, be the 8th 4 * 4 and determined intra prediction mode " 0 ", and be under the 10th 4 * 4 situations of determining intra prediction mode " 8 ", be the 9th 4 * 4 and be chosen as the 8th 4 * 4 definite intra prediction modes " 0 ".According to standard H.264, under the situation of coded frame inner estimation mode, when and the current block that will be encoded above and when selecting less pattern numbering between the adjacent macro block in left side, can carry out coding by enough bits still less.In fact, when the adjacent macro block in the top and left side of the current block that is positioned in and will be encoded was selected as the predicated error computing block, this method was effective.
In addition, according to (3) in the middle of adjacent a plurality of predicated error computing blocks, SAD estimated value of selecting its predicated error computing block etc. is the method for the intra prediction mode of minimum value, for instance, second 4 * 4 predicated errors are " 93 " and determined intra prediction mode " 3 " for it, the 8th 4 * 4 predicated error is " 54 " and determined intra prediction mode " 0 " for it, the 10th 4 * 4 predicated error is " 21 " and when having determined intra prediction mode " 8 " for it, and what select to have minimum predicated error from three pieces is the 10th 4 * 4 definite intra prediction modes " 8 ".
Fig. 9 is the figure of another example of the expression intra prediction mode of selecting nonanticipating Error Calculation piece in the middle of the adjacent block.Here will be described about following situation, in the middle of the adjacent block 0,1 and 2 intra prediction modes of determining of the predicated error that has been as calculated, select the 3rd current 4 * 4 intra prediction mode that will be encoded in coded sequence.For as calculated the adjacent block 0,1 and 2 of predicated error, create the form 110,111 and 112 of each prediction on intra-frame prediction mode error of expression, and they be stored in the memory cell 47 as adjacent block prediction mode information 48.
According to (4) in the middle of the intra prediction mode of determining for the predicated error computing block, select the method for the most normal intra prediction mode of selecting for use of adjacent block, be that two pieces are selected intra prediction mode " 4 " (selected predictive mode is irised out) in Fig. 9, and therefore be that the 3rd piece selected intra prediction mode " 4 " among Fig. 9.
Next, according to (5) in the middle of the estimated value sum of each intra prediction mode of calculating for the predicated error computing block, select the method for intra prediction mode with minimum value, in Fig. 9, be each intra prediction mode 0 to 9, calculate the summation of the estimated value of the 0th piece, first piece and second piece, addition value is the intra prediction mode that the intra prediction mode of minimum value is selected as the 3rd piece then.
For example, the prediction error value of supposing each intra prediction mode M of k piece be E (k, M).Notice that M represents intra prediction mode 0 to 9.The equation of the addition value S (M) of each intra prediction mode is as follows:
S (M)=∑
K=0 to 3E (k, M)
Therefore, the intra prediction mode M that S (M) value has minimum value is selected as the intra prediction mode of the 3rd piece.
Figure 10 is the flow chart that method (1) is selected the order of intra prediction mode in the expression use macro block shown in Figure 8.Method (1) is in the middle of adjacent a plurality of predicated error computing blocks, selects to be positioned at respect to the current block that will be encoded the method for the intra prediction mode of the piece on the fixed position.Piece selected cell 41 determines whether 4 * 4 in the macro block will be predicated error computing block (S501).At 4 * 4 is not under the situation of predicated error computing block, in other words, under the situation that these 4 * 4 are confirmed as nonanticipating Error Calculation piece, prediction mode estimation unit 44 is checked the intra prediction mode (S302) that is positioned at the locational coded prediction of adjacent fixed Error Calculation piece with respect to nonanticipating Error Calculation piece.Determine that at piece selected cell 41 in the macro blocks 4 * 4 will be under the situation of predicated error computing block (S501), the information that mode error value computing unit 42 uses about the present frame that will be encoded is calculated each prediction on intra-frame prediction mode error (S504) that can be selected for this piece in the middle of nine kinds of intra prediction modes.Comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Be confirmed as the intra prediction mode of the current block that will be encoded corresponding to the intra prediction mode of this predicated error, this current block that will be encoded has been confirmed as predicated error computing block (S505).
Figure 11 is the flow chart that the order of method (2) selection intra prediction mode in the macro block shown in Figure 8 is used in expression.Method (2) is in the middle of adjacent a plurality of predicated error computing blocks, selects the method for the intra prediction mode with minimal mode numbering.Piece selected cell 41 determines whether 4 * 4 in the macro block will be predicated error computing block (S501).At 4 * 4 is not under the situation of predicated error computing block, in other words, under the situation that these 4 * 4 are confirmed as nonanticipating Error Calculation piece, prediction mode estimation unit 44 is checked and is positioned in and nonanticipating Error Calculation piece left side adjacent at least two intra prediction mode of coded prediction Error Calculation piece (S502).Prediction mode estimation unit 44 is selected the adjacent block (S503) with intra prediction mode lowest number in the middle of the adjacent block of being checked.Determine that at piece selected cell 41 in the macro blocks 4 * 4 are under the situation of predicated error computing block (S501), the information that mode error value computing unit 42 uses about the present frame that will be encoded is calculated each prediction on intra-frame prediction mode error (S504) that can be selected for this piece in the middle of nine kinds of intra prediction modes.Comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Be confirmed as the intra prediction mode of the current block that will be encoded corresponding to the intra prediction mode of this predicated error, this current block that will be encoded has been confirmed as predicated error computing block (S505).
Figure 12 is the flow chart that the order of method (3) the selection intra prediction mode in the macro block shown in Figure 8 is used in expression.Method (3) is in the middle of adjacent a plurality of predicated error computing blocks, and selection has the method for the intra prediction mode of the minimum estimated value that calculates by prediction error value.Piece selected cell 41 determines whether 4 * 4 in the macro block will be predicated error computing block (S501).At 4 * 4 is not under the situation of predicated error computing block, in other words, under the situation that these 4 * 4 are confirmed as nonanticipating Error Calculation piece, prediction mode estimation unit 44 is checked and is positioned in and nonanticipating Error Calculation piece left side adjacent at least two intra prediction mode of coded prediction Error Calculation piece (S502).Prediction mode estimation unit 44 is selected minimum predicted value (S603) in the middle of the adjacent block of being checked.Determine that at piece selected cell 41 in the macro blocks 4 * 4 are under the situation of predicated error computing block (S501), the information that mode error value computing unit 42 uses about the present frame that will be encoded is calculated each prediction on intra-frame prediction mode error (S504) that can be selected for this piece in the middle of nine kinds of intra prediction modes.Comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Be confirmed as the intra prediction mode of the current block that will be encoded corresponding to the intra prediction mode of this predicated error, this current block that will be encoded has been confirmed as predicated error computing block (S505).
Figure 13 is the flow chart that the order of method (4) the selection intra prediction mode in the macro block shown in Figure 9 is used in expression.Method (4) is in the middle of adjacent a plurality of predicated error computing blocks, selects the method for the most normal intra prediction mode of selecting for use.Piece selected cell 41 determines whether 4 * 4 in the macro block will be predicated error computing block (S501).At 4 * 4 is not under the situation of predicated error computing block, in other words, under the situation that these 4 * 4 are confirmed as nonanticipating Error Calculation piece, prediction mode estimation unit 44 is checked and is positioned in and nonanticipating Error Calculation piece left side adjacent at least two intra prediction mode of coded prediction Error Calculation piece (S502).Prediction mode estimation unit 44 is selected the most normal pattern of selecting for use (S703) in the middle of the adjacent block of being checked.Determine that at piece selected cell 41 in the macro blocks 4 * 4 are under the situation of predicated error computing block (S501), the information that mode error value computing unit 42 uses about the present frame that will be encoded is calculated each prediction on intra-frame prediction mode error (S504) that can be selected for this piece in the middle of nine kinds of intra prediction modes.Comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Be confirmed as the intra prediction mode of the current block that will be encoded corresponding to the intra prediction mode of this predicated error, this current block that will be encoded has been confirmed as predicated error computing block (S505).
Figure 14 is the flow chart that the order of method (5) the selection intra prediction mode in the macro block shown in Figure 9 is used in expression.Method (5) is in the middle of the estimated value sum of each intra prediction mode that calculates for the predicated error computing block, selects the method for the intra prediction mode with minimum value.Piece selected cell 41 determines whether 4 * 4 in the macro block will be predicated error computing block (S501).At 4 * 4 is not under the situation of predicated error computing block, in other words, under the situation that these 4 * 4 are confirmed as nonanticipating Error Calculation piece, prediction mode estimation unit 44 is checked and is positioned in and nonanticipating Error Calculation piece left side adjacent at least two intra prediction mode of coded prediction Error Calculation piece (S502).Prediction mode estimation unit 44 adds prediction error value for each intra prediction mode, and selects to have the intra prediction mode (S903) of minimum addition value.Determine that at piece selected cell 41 in the macro blocks 4 * 4 are under the situation of predicated error computing block (S501), the information that mode error value computing unit 42 uses about the present frame that will be encoded is calculated each prediction on intra-frame prediction mode error (S504) that can be selected for this piece in the middle of nine kinds of intra prediction modes.Comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.Be confirmed as the intra prediction mode of the current block that will be encoded corresponding to the intra prediction mode of this predicated error, this current block that will be encoded has been confirmed as predicated error computing block (S505).
Figure 15 A to 15C is the exemplary plot of system of selection of intra prediction mode that the nonanticipating Error Calculation piece of method (1) is shown, and after being divided into predicated error computing block and nonanticipating Error Calculation piece, is defined as nonanticipating Error Calculation piece.Figure 15 A is the figure of expression as example, only calculates predicated error upper left 4 * 4 in 8 * 8, is selected as the intra prediction mode of other three 4 * 4 nonanticipating computing blocks then for 4 * 4 definite intra prediction modes in upper left side.According to this method, under the situation that is upper left 8 * 84 * 4 definite intra prediction modes in middle upper left side of macro block " 0 ", also be to select intra prediction mode " 0 " (other three 4 * 4 modules) for example at upper left whole 8 * 8.On the other hand, in top-right 8 * 8, be upper left 4 * 4 definite intra prediction modes " 4 ", therefore be upper left other three 4 * 4 and select intra prediction mode " 4 ".In the same way, in 8 * 8 of lower left, select intra prediction mode " 8 ", and in bottom-right 8 * 8,, select intra prediction mode " 3 " based on the pattern on 4 * 4 on upper left side.
Figure 15 B is the figure of expression as example, regards a unit as, 4 * 4 predicated error of calculating upper left side and lower left with 8 * 8.Based on these predicated errors, selection and upper right side and lower right nonanticipating Error Calculation piece 4 * 4 piece the intra prediction mode adjacent respectively in the left side.Shown in Figure 15 B, in 4 * 4 predicated error computing blocks of upper left side, determine under the situation of intra prediction mode " 0 ", be 4 * 4 nonanticipating Error Calculation pieces selection intra prediction mode " 0 " adjacent on the right side with this predicated error computing block.And in 4 * 4 predicated error computing blocks of lower left, determine under the situation of intra prediction mode " 2 ", be 4 * 4 nonanticipating Error Calculation pieces selection intra prediction mode " 2 " adjacent on the right side with this predicated error computing block.In the same way, be chosen as the identical intra prediction mode that this predicated error computing block is determined for being positioned in adjacent 4 * 4 nonanticipating Error Calculation pieces in this predicated error computing block right side.
Figure 15 C is the figure that represents as an example, regards a unit as, calculating upper left side and top-right 4 * 4 predicated error with 8 * 8.Based on these predicated errors, selection and lower right and 4 * 4 adjacent up intra prediction mode of lower left nonanticipating Error Calculation piece respectively.Shown in Figure 15 C, in 4 * 4 predicated error computing blocks of upper left side, determine under the situation of intra prediction mode " 0 ", for this predicated error computing block below adjacent 4 * 4 nonanticipating Error Calculation pieces select intra prediction mode " 0 ".In the same way, be chosen as the identical intra prediction mode that this predicated error computing block is determined for being positioned in adjacent 4 * 4 nonanticipating Error Calculation pieces of this predicated error computing block downside.
This system of selection is not limited to previous example, but can use system of selection arbitrarily.It is not essential selecting intra prediction mode in the middle of the adjacent block, but can use specific intra prediction mode.For example, intra prediction mode " 0 " can be used for specific nonanticipating Error Calculation piece always.
Although should be noted in the discussion above that the situation of only having described 4 * 4 intra prediction modes in the aforementioned embodiment, the present invention is not limited to this kind situation.For example present embodiment can be applied to the situation of 8 * 8 intra prediction modes and 16 * 16 intra prediction modes.
Use preceding method, determine the intra prediction mode of the current block that will be encoded in an orderly manner, and from coding method selected cell 50 the determined pattern of output, as selecting coding method information.
(second embodiment)
Hereinafter with reference to each width of cloth accompanying drawing, the second embodiment of the present invention is described.
The unitary construction of the picture coding device 1 of second embodiment is identical with first embodiment shown in Figure 4, therefore no longer comprises its description here.
Figure 16 is the block diagram of the intraprediction unit structure of expression second embodiment of the invention.Intraprediction unit 11 is by skipping some pixel, calculates in 16 * 16 macro blocks 8 * 8 predicated error, and 4 * 4 intra prediction mode in determining 8 * 8.Intraprediction unit 11 comprises comparing unit 43 and piece predictor calculation unit 62 between pixel selection unit 61, mode error value computing unit 42, pattern.
Here the predicated error computing unit is corresponding to piece predictor calculation unit 62, and the macro block mode determining unit is corresponding to comparing unit 43 between pixel selection unit 61, mode error value computing unit 42 and pattern.
The image information of the present frame that is encoded is input to the pixel selection unit 61 from external equipment.
In pixel selection unit 61, in 64 pixels from comprise 8 * 8 of the current block that will be encoded, select the pixel that is used to calculate each prediction on intra-frame prediction mode error.
Figure 17 is an exemplary plot of selecting 16 pixels that are used to calculate all optional prediction on intra-frame prediction mode errors from 8 * 8.In Figure 17, selected pixel is represented with hacures.Unselected pixel is represented with white circle.In the present embodiment, pixel selection unit 61 is selected to be positioned evenly over being used in 8 * 8 and is calculated the pixel of predicated error.Or rather, be each 4 * 4 pixels of selecting similar numbers, and also select being positioned at the pixel of delegation and being positioned at the pixel of same row of similar number respectively.In other words, consider that the side that selected pixel is not positioned at this piece selects pixel, and more pixel adjacent can be as the reference of all optional intra prediction modes.
Figure 18 (a) is the figure of 4 * 4 middle number of pixels of expression.Figure 18 (b) is that the pixel figure of 8 * 8 middle number of pixels is afterwards skipped in expression.Shown in Figure 18 (a) and Figure 18 (b), 4 * 4 with 8 * 8 in number of pixels be identical, therefore do not skip the situation (a) of pixel for calculating 4 * 4 predicated error and calculate 8 * 8 predicated error and select for the situation (b) with the pixel of 4 * 4 similar numbers by skipping pixel, mode error value computing unit 42 performed operational tons are identical.According to this method, the pixel that is used for calculating predicated error is positioned evenly over 8 * 8, and the pixel value that is used for each intra prediction mode thus in 8 * 8 is reflected in the result of predicated error equably.Therefore, be better than based on the situation (a) of only selecting intra prediction mode by the predicated error of 4 * 4 middle calculated for pixel values in upper left side, under based on the situation (b) of selecting intra prediction mode by the predicated error that is positioned evenly over the calculated for pixel values in 8 * 8, can expect more accurate infra-frame prediction.
Figure 19 A is illustrated in by intra prediction mode " 0 " to select equably under the situation of the pixel in 8 * 8, the figure of related neighbor, and Figure 19 B is the intra prediction mode " 0 " that is illustrated in by in 8 * 8, under the situation on all pixels are positioned at from the upper left side to bottom-right diagonal, the figure of related neighbor.In Figure 19 A, the neighbor that relate to comes mark with grid.Shown in Fig. 2 B,, on the vertical direction of piece, calculate predicated error by intra prediction mode " 0 ".On the other hand, in the piece of Figure 19 A, the selected pixel that is used for calculating predicated error is positioned evenly over 8 * 8.Therefore because these pixels are present in each row in the piece, therefore relate to come from the adjacent up encoding block of current block in 8 pixels in the middle of the one-row pixels bottom.In the piece shown in Figure 19 B, use this pattern " 0 ", selected pixel is positioned at from the upper left side to bottom-right diagonal, and image pattern 19A is the same, because these pixels are present in each row in the piece, therefore relate to come from the adjacent up encoding block of current block in the pixel of similar number, i.e. 8 pixels in the middle of the one-row pixels bottom.
Figure 20 A is illustrated in by intra prediction mode " 4 ", and selected pixel is positioned evenly under the situation in 8 * 8, the figure of related neighbor.Figure 20 B is that intra prediction mode " 4 " is passed through in expression, under the situation on selected pixel is positioned at from the upper left side to bottom-right diagonal, and the figure of related neighbor.Intra prediction mode 4 is shown in Fig. 2 B, calculates the pattern of predicated error on the direction from the upper left side to the lower left.On the other hand, in the piece shown in Figure 20 A, the selected pixel that is used for calculating predicated error is positioned evenly over 8 * 8, so these pixels almost are present in each row.Among Figure 20 A, in the upper right corner and the lower left corner, on bottom-right direction, all do not have pixel, therefore with the delegation bottom of the adjacent up encoding block of current block in, relate to 7 pixels.In addition, with current block in rightmost one row of the adjacent encoding block in left side, relate to 7 pixels.Compare with the situation of Figure 20 A, in the piece of Figure 20 B, selected pixel is positioned at from the upper left side to bottom-right diagonal, and all pixels all are positioned at from the upper left side to a bottom-right line, and lists at other and not have pixel.Therefore, use intra prediction mode 4, with current block in rightmost one row of the adjacent encoding block in left side, only relate to 2 pixels.
Pixel selection unit 61 according to second embodiment, as Figure 19 A, Figure 19 B, seen among Figure 20 A and Figure 20 B, the selected pixel that is used for calculating predicated error is positioned evenly over this piece and independent of direction, thereby the information of relevant 8 * 8 blocks of middle images can be reflected as the predicated error that all intra prediction modes will calculate equably, and the more accurate infra-frame prediction to nonanticipating Error Calculation piece is to be worth expectation thus.
Next, the information that mode error value computing unit 42 uses about the present frame that will be encoded, be defined as being used to calculating 8 * 8 of pixel of predicated error for use, calculating for the current block that will be encoded is optional each prediction on intra-frame prediction mode error.Absolute difference sum (SAD) is generally used for predicated error with difference of two squares sum (SSD).Have only selected pixel to be used to calculate predicated error here, rather than use 64 pixels, therefore can reduce operational ton.
Next, comparing unit 43 compares each prediction on intra-frame prediction mode error between pattern, and determines to have the predicated error of minimum value.All intra prediction modes of 4 * 4 that are confirmed as comprising in 8 * 8 corresponding to the intra prediction mode of this predicated error.
Next, all pixels that piece predictor calculation unit 62 uses in determined intra prediction mode and the piece are calculated predicated error.In standard H.264, the profile (profile) that can be used for 8 * 8 intra prediction modes is limited, and this predictive mode can not be used for master profile (main profile).According to preceding method,, can reduce operational ton effectively by all intra prediction modes of 4 * 4 in determining 8 * 8.
About the advanced profile (high profile) that can be used for 8 * 8 intra prediction modes, use determined 8 * 8 intra prediction modes, 8 * 8 infra-frame predictions can be carried out, and 4 * 4 infra-frame predictions need not be carried out.
Figure 21 be expression by skipping the pixel in shown in Figure 17 8 * 8, and determine the flow chart of the order of intra prediction mode.In other words, in the method, calculate this predicated error, and select to have the intra prediction mode of minimum prediction error value by the pixel of skipping in 8 * 8.The pixel (S801) that predicated error is calculated is selected to be used in pixel selection unit 61 in 8 * 8.Piece predictor calculation unit 62 uses selected pixel, calculates selectable each prediction on intra-frame prediction mode error (S802) that is used for this piece in the middle of 9 kinds of intra prediction modes.Judge these 8 * 8 then by 4 * 4 intraframe predictive codings or by 8 * 8 intraframe predictive codings (S803).Next, under the situation of encoding by 4 * 4 infra-frame predictions, to determine to have the predictive mode of predicated error minimum value be to be used for 8 * 8 all intra prediction modes of 4 * 4 (S804) to comparing unit 43 between pattern, and under the situation of being encoded by 8 * 8 infra-frame predictions, the predictive mode with predicated error minimum value is to be used for 8 * 8 intra prediction mode (S805).
In addition, in the aforementioned embodiment, functional block shown in Figure 5 also can be implemented as the LSI as integrated circuit typically.LSI can be a monolithic, perhaps can be multi-disc.May also be referred to as IC, system LSI, ultra-large LSI, great scale LSI or the like at this LSI as an example.
In addition, the form of integrated circuit not only can be implemented as LSI, also can be implemented as special circuit and general processor.After having made LSI, the connection of circuit element and be provided with and can use reconfigurable processor among field programmable gate array (FPGA), the LSI.
And, when the semiconductor technology that in the future can obtain to further develop or derive substitutes LSI, obviously can use this technology to carry out the integrated of described functional block.Can expect bionic application or the like.
Although below only some one exemplary embodiment of the present invention is described in detail, those skilled in the art can easily understand, and can carry out many modifications to one exemplary embodiment, and can not depart from the instruction and the advantage of novelty of the present invention in itself.Therefore, all such modifications all are intended within the scope of the present invention involved.