WO2012160879A1 - 画像符号化装置と画像復号装置およびその方法 - Google Patents

画像符号化装置と画像復号装置およびその方法 Download PDF

Info

Publication number
WO2012160879A1
WO2012160879A1 PCT/JP2012/059025 JP2012059025W WO2012160879A1 WO 2012160879 A1 WO2012160879 A1 WO 2012160879A1 JP 2012059025 W JP2012059025 W JP 2012059025W WO 2012160879 A1 WO2012160879 A1 WO 2012160879A1
Authority
WO
WIPO (PCT)
Prior art keywords
unit
context
parallel
image
parallel processing
Prior art date
Application number
PCT/JP2012/059025
Other languages
English (en)
French (fr)
Inventor
敦 大和
Original Assignee
ソニー株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ソニー株式会社 filed Critical ソニー株式会社
Publication of WO2012160879A1 publication Critical patent/WO2012160879A1/ja

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/1887Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a variable length codeword
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/13Adaptive entropy coding, e.g. adaptive variable length coding [AVLC] or context adaptive binary arithmetic coding [CABAC]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/167Position within a video image, e.g. region of interest [ROI]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • H04N19/436Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation using parallelised computational arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/60Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding
    • H04N19/61Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding in combination with predictive coding

Definitions

  • This technology relates to an image encoding device, an image decoding device, and a method thereof. Specifically, the image encoding process and decoding process can be performed at high speed.
  • CABAC Context-based Adaptive Binary Arithmetic Coding
  • CAVLC Context-based Adaptive Variable Length Coding
  • a code string is obtained by repeating the process of dividing a numerical interval according to the occurrence probability for each symbol. That is, all symbols need to be processed sequentially. Also, it is necessary to perform encoding while sequentially updating a symbol occurrence probability table called a context (hereinafter simply referred to as “probability table”) for each encoding process.
  • probability table a symbol occurrence probability table
  • processing reverse to arithmetic coding is performed. As described above, since the process is performed while sequentially updating the probability table, when the probability tables are used in an overlapping manner, the next encoding process cannot be performed unless the update of the probability table is completed. Therefore, it is difficult to perform arithmetic coding and arithmetic decoding at high speed by parallelizing the processes.
  • the context index (ctxIdx) setting unit 201 shown in FIG. 1 sets a context index according to the syntax to be encoded or decoded, and outputs it to the variable selection units 202-0 and 202-1.
  • the variable selection unit 202-0 selects a context variable based on the context index supplied from the context index setting unit 201 and outputs the selected context variable to the arithmetic decoding unit 203-0.
  • a dominant symbol (most probable symbol) having a high occurrence probability and a symbol occurrence probability table number (pStateIdx) of the dominant symbol are shown.
  • the arithmetic decoding unit 203-0 performs arithmetic decoding using the selected context variable and outputs a decoding result bin0.
  • variable selection unit 202-1 selects a context variable based on the context index supplied from the context index setting unit 201, and outputs it to the arithmetic decoding unit 203-1.
  • the arithmetic decoding unit 203-1 performs arithmetic decoding using the selected context variable and outputs a decoding result bin1.
  • the arithmetic decoding unit 203-0 and the arithmetic decoding unit 203 are selected. -1 can perform arithmetic decoding in parallel.
  • the arithmetic decoding unit 203-1 must perform the next arithmetic decoding unless the probability table is updated based on the decoding result bin0 obtained by the arithmetic decoding unit 203-0. I can't. Therefore, it becomes difficult to perform arithmetic decoding at high speed by parallelizing the processes.
  • high throughput can be realized using a technique called multi slice.
  • the multi-slice method as shown in FIG. 2A, an image is divided into a plurality of regions, and CABAC encoding processing and decoding processing are performed independently on each of the regions. For example, as indicated by a dotted arrow in FIG. 2A, arithmetic coding is performed for each macroblock in order from the upper macroblock line in the image toward the lower macroblock line in the image. In this way, CABAC encoding / decoding of each region can be performed in parallel, and the processing speed is increased. This divided area is referred to as a slice.
  • the current macroblock (curr) is encoded / decoded with reference to other adjacent macroblocks (mbA to mbD) as shown in FIGS. 2B and 2C.
  • the probability table used in CABAC converges to the actual occurrence probability as the encoding progresses, and the encoding efficiency increases.
  • the probability table used for each region (slice) The probability table is initialized. Therefore, the encoding efficiency at the start of the slice may be reduced.
  • An entropy slice method has been proposed as a method for improving coding efficiency while parallelizing CABAC (see Non-Patent Document 1, for example). According to this method, only the CABAC processing part is divided into areas called entropy slices and executed in parallel, so that intra prediction can be used even at the entropy slice boundary. It was. However, surrounding macroblock references in CABAC processing cannot be used at entropy slice boundaries.
  • Patent Document 2 An ordered entropy slice method has been proposed as a further improvement technique (see, for example, Patent Document 2). This method makes it possible to refer to adjacent macroblocks at the boundary even in CABAC processing.
  • the present technology has been made in view of such a situation, and an object thereof is to provide an image encoding device, an image decoding device, and a method thereof that can perform image encoding processing and decoding processing at high speed. To do.
  • a binarization unit that converts a syntax element into binary data and a context index for specifying a context variable for the syntax element do not overlap in a parallel processing unit.
  • a context index setting unit to be set, a context variable selection processing unit that selects a context variable according to the context index set by the context index setting unit, and the context variable selection processing unit selected for each parallel processing unit
  • an arithmetic coding processing unit that performs arithmetic coding of the binary data in parallel using the context variable.
  • the context index for specifying the context variable used for arithmetic coding of the binary data of the syntax element is set so as not to overlap in the parallel processing unit, and the set context index Depending on the context variable is selected.
  • the number of parallel processes is set in units of slices according to the image resolution or frame rate.
  • the number of parallel processes is set in units of blocks according to the number of zero coefficients in the orthogonal transform coefficients obtained by performing orthogonal transform in units of blocks. When the number of parallel processes is not set for each block, the number of parallel processes set for each slice is used.
  • arithmetic coding of binarized data is performed in parallel using context variables corresponding to different context indexes.
  • the syntax element includes an element indicating the number of parallel processes.
  • the context index is set using an allocation table indicating the relationship between the index for each orthogonal transform coefficient and the context index. Further, in the allocation table, the index for each coefficient and the context index are related so that the same context index is used more frequently for the coefficients whose frequencies are close to each other.
  • a second aspect of this technique is that a binarization step for converting syntax elements into binarized data and a context index for specifying a context variable for the syntax elements do not overlap in a parallel processing unit.
  • a context index setting unit that sets a context index for specifying a context variable corresponding to a syntax element to be decoded so as not to overlap in a parallel processing unit; and the context index setting unit
  • a context variable selection processing unit that selects a context variable according to the context index set by the step, and for each parallel processing unit, arithmetic decoding of encoded data is performed using the context variable selected by the context variable selection processing unit.
  • An image decoding apparatus includes an arithmetic decoding processing unit that performs in parallel and a multi-value conversion unit that converts binary data obtained by performing the arithmetic decoding into a value of a syntax element.
  • the context index corresponding to the syntax element to be decoded is set so as not to overlap within the parallel processing unit.
  • Context variables are selected according to the set context index, and binary data is arithmetically decoded in parallel processing units using context variables according to different context indexes.
  • binarized data obtained by performing arithmetic decoding is converted into a value of a syntax element that is multilevel data.
  • the number of parallel processes is set for each slice or block based on a syntax element indicating the number of parallel processes encoded and included in the encoded data.
  • the context index is set using an allocation table indicating the relationship between the index for each orthogonal transform coefficient and the context index.
  • a context index corresponding to a syntax element to be decoded is set so as not to overlap in a parallel processing unit, and the context index set in the context index setting step A context variable selection processing step for selecting a context variable in response, and an arithmetic decoding step for performing arithmetic decoding of encoded data in parallel using the context variable selected in the context variable selection step in the parallel processing unit, And a multi-value conversion step of converting binary data obtained by performing the arithmetic decoding into syntax elements.
  • the context index is set so as not to cause duplication within the parallel processing unit, and the context variable corresponding to the set context index is used. Therefore, arithmetic coding and arithmetic decoding are performed. Therefore, it is possible to perform image encoding processing and decoding processing at high speed.
  • FIG. 3 illustrates the configuration of the image encoding device.
  • the image encoding device 10 includes an analog / digital conversion unit (A / D conversion unit) 11, a screen rearrangement buffer 12, a calculation unit 13, an orthogonal transformation unit 14, a quantization unit 15, a lossless encoding unit 16, and a storage buffer 17.
  • the rate control unit 18 is provided.
  • the image encoding device 10 includes an inverse quantization unit 21, an inverse orthogonal transform unit 22, a calculation unit 23, a deblocking filter 24, a frame memory 25, an intra prediction unit 31, a motion prediction / compensation unit 32, a predicted image / optimum A mode selection unit 33 is provided.
  • the A / D converter 11 converts an analog image signal into digital image data and outputs the digital image data to the screen rearrangement buffer 12.
  • the screen rearrangement buffer 12 rearranges the frames of the image data output from the A / D conversion unit 11.
  • the screen rearrangement buffer 12 rearranges the frames according to the GOP (Group of Pictures) structure related to the encoding process, and outputs the rearranged image data to the arithmetic unit 13, the rate control unit 18, and the intra prediction unit 31. The result is output to the motion prediction / compensation unit 32.
  • GOP Group of Pictures
  • the calculation unit 13 is supplied with the image data output from the screen rearrangement buffer 12 and the predicted image data selected by the predicted image / optimum mode selection unit 33 described later.
  • the calculation unit 13 is a difference image image data (prediction error) that is a difference between the image data of the input image output from the screen rearrangement buffer 12 and the image data of the prediction image supplied from the prediction image / optimum mode selection unit 33. Data) is output to the orthogonal transform unit 14.
  • the orthogonal transform unit 14 performs orthogonal transform processing such as discrete cosine transform (DCT) and Karoonen-Loeve transform on the prediction error data output from the computation unit 13.
  • the orthogonal transform unit 14 outputs transform coefficient data obtained by performing the orthogonal transform process to the quantization unit 15.
  • the quantization unit 15 is supplied with transform coefficient data output from the orthogonal transform unit 14 and a quantization parameter (quantization scale) from a rate control unit 18 described later.
  • the quantization unit 15 quantizes the transform coefficient data and outputs the quantized data to the lossless encoding unit 16 and the inverse quantization unit 21. Further, the quantization unit 15 changes the bit rate of the quantized data according to the quantization parameter set by the rate control unit 18.
  • the lossless encoding unit 16 is supplied with quantized data from the quantization unit 15, prediction mode information from the intra prediction unit 31, prediction mode information and motion vector information from the motion prediction / compensation unit 32, and the like. Also, information indicating whether the optimal mode is intra prediction or inter prediction is supplied from the predicted image / optimum mode selection unit 33.
  • the prediction mode information includes a prediction mode, block size information, and the like according to intra prediction or inter prediction.
  • the lossless encoding unit 16 performs lossless encoding processing on the quantized data by, for example, variable length encoding or arithmetic encoding, generates an encoded stream, and outputs the encoded stream to the accumulation buffer 17. Moreover, the lossless encoding part 16 performs the lossless encoding of the prediction mode information supplied from the intra prediction part 31, when the optimal mode is intra prediction. Further, when the optimum mode is inter prediction, the lossless encoding unit 16 performs lossless encoding of prediction mode information, motion vector information, and the like supplied from the motion prediction / compensation unit 32. Furthermore, the lossless encoding part 16 performs the lossless encoding of the information regarding a quantization parameter.
  • the accumulation buffer 17 accumulates the encoded stream from the lossless encoding unit 16.
  • the accumulation buffer 17 outputs the accumulated encoded stream at a transmission rate corresponding to the transmission path.
  • the rate control unit 18 monitors the free capacity of the storage buffer 17, and when the free capacity is low, the bit rate of the quantized data decreases, and when the free capacity is sufficiently large, the bit of the quantized data
  • the quantization parameter is set so as to increase the rate and output to the quantization unit 15. Further, the rate control unit 18 adjusts and limits the quantization parameter according to the coding distortion information based on a control signal from a coding distortion control unit (not shown).
  • the rate control unit 18 may supply information relating to the limitation of the quantization parameter to the lossless encoding unit 16 in order to increase the encoding efficiency of the quantization parameter information.
  • the inverse quantization unit 21 performs an inverse quantization process on the quantized data supplied from the quantization unit 15.
  • the inverse quantization unit 21 outputs transform coefficient data obtained by performing the inverse quantization process to the inverse orthogonal transform unit 22.
  • the inverse orthogonal transform unit 22 performs an inverse orthogonal transform process on the transform coefficient data supplied from the inverse quantization unit 21, and outputs the obtained data to the calculation unit 23.
  • the computing unit 23 adds the data supplied from the inverse orthogonal transform unit 22 and the predicted image data supplied from the predicted image / optimum mode selection unit 33 to generate image data of the local decoded image, and the deblocking filter 24. And output to the intra prediction unit 31.
  • generated by the calculating part 23 is used as a reference image in intra prediction or inter prediction.
  • the deblocking filter 24 performs a filter process for reducing block distortion that occurs during image coding.
  • the deblocking filter 24 performs a filter process for removing block distortion from the image data supplied from the calculation unit 23, and stores the image data after the filter process in the frame memory 25.
  • the intra prediction unit 31 uses the input image data of the encoding target image supplied from the screen rearrangement buffer 12 and the image data (reference image data) supplied from the calculation unit 23 to make all the intra prediction modes that are candidates. To make a prediction and determine the optimal intra prediction mode. For example, the intra prediction unit 31 calculates the cost function value in each intra prediction mode, and sets the intra prediction mode in which the coding efficiency is the best based on the calculated cost function value as the optimal intra prediction mode. The intra prediction unit 31 outputs the predicted image data generated in the optimal intra prediction mode and the cost function value in the optimal intra prediction mode to the predicted image / optimum mode selection unit 33. Further, the intra prediction unit 31 outputs prediction mode information indicating the optimal intra prediction mode to the lossless encoding unit 16.
  • the motion prediction / compensation unit 32 uses the input image data of the encoding target image supplied from the screen rearrangement buffer 12 and the reference image data read from the frame memory 25 to perform prediction in all candidate inter prediction modes. To determine the optimal inter prediction mode. For example, the motion prediction / compensation unit 32 calculates the cost function value in each inter prediction mode, and sets the inter prediction mode in which the coding efficiency is the best based on the calculated cost function value as the optimal inter prediction mode. The motion prediction / compensation unit 32 outputs the predicted image data generated in the optimal inter prediction mode and the cost function value in the optimal inter prediction mode to the predicted image / optimum mode selection unit 33. Further, the motion prediction / compensation unit 32 outputs prediction mode information and motion vector information regarding the optimal inter prediction mode to the lossless encoding unit 16.
  • the predicted image / optimum mode selection unit 33 compares the cost function value supplied from the intra prediction unit 31 with the cost function value supplied from the motion prediction / compensation unit 32, and encodes the one having the smaller cost function value. Select the optimal mode with the best efficiency. Further, the predicted image / optimum mode selection unit 33 outputs the predicted image data generated in the optimal mode to the calculation unit 13 and the calculation unit 23. Further, the predicted image / optimum mode selection unit 33 outputs information indicating whether the optimal mode is the intra prediction mode or the inter prediction mode to the lossless encoding unit 16. Note that the predicted image / optimum mode selection unit 33 switches between intra prediction and inter prediction in units of slices. Further, the predicted image / optimum mode selection unit 33 performs processing for designating the optimum mode based on the coding distortion information based on the control signal from the coding distortion control unit.
  • FIG. 4 illustrates the configuration of a CABAC encoder that performs CABAC encoding processing in the lossless encoding unit 16.
  • the CABAC encoder 160 includes a binarization unit 161, a context index (ctxIdx) setting unit 162, a context variable selection processing unit 163, an arithmetic encoding processing unit 164, and an encoding result selection unit 165. Further, the CABAC encoder 160 is provided with a parallel processing number setting unit 167.
  • the binarization unit 161 receives a differential motion vector, syntax such as an orthogonal transform coefficient, a prediction mode, etc., performs binarization processing defined by the standard, generates binarized data, and performs arithmetic coding Output to the units 164-0 to 164-N.
  • a differential motion vector syntax such as an orthogonal transform coefficient, a prediction mode, etc.
  • the context index setting unit 162 sets a context index (ctxIdx) based on the syntax and outputs it to the context variable selection processing unit 163.
  • the context index (ctxIdx) is information for selecting a context variable.
  • a dominant symbol most probable symbol having a high probability of occurrence and a probability table number (pStateIdx) indicating the probability of occurrence of the dominant symbol. Is shown.
  • variable selection processing unit 163 variable selection units 163-0 to 163-N are provided.
  • the variable selection unit 163-0 selects a context variable corresponding to the context index (ctxIdx-0) from the context variable table and outputs the selected context variable to the arithmetic coding processing unit 164.
  • the variable selection units 163-1 to 163-N select context variables corresponding to the context indexes (ctxIdx-1 to ctxIdx-N) and output them to the arithmetic coding processing unit 164.
  • the context variable table for each context index, the number of the context variable, that is, the probability symbol of the dominant symbol and the dominant symbol is shown.
  • arithmetic encoding units 164-0 to 164-N are provided in the arithmetic encoding processing unit 164.
  • the arithmetic coding units 164-0 to 164-N perform arithmetic coding processing based on the binarized data and the context variable.
  • the arithmetic encoding unit 164-0 performs arithmetic encoding using the binarized data indicating the first coefficient of the parallel processing unit and the context variable selected by the variable selecting unit 163-0, and the arithmetic encoding result is obtained.
  • the result is output to the encoding result selection unit 165.
  • the arithmetic encoding unit 164-0 outputs the arithmetic encoding result to the variable selection unit 163-0, and updates the probability table number in the context variable selected by the variable selection unit 163-0.
  • the arithmetic encoding units 164-1 to 164-N use the binarized data of each coefficient in the parallel processing unit and the context variables selected by the variable selection units 163-1 to 163-N. Encoding is performed, and the arithmetic encoding result is output to the encoding result selection unit 165.
  • arithmetic coding units 164-1 to 164-N output the arithmetic coding results to variable selection units 163-1 to 163-N, and update the probability table numbers in the selected context variables.
  • the encoding result selection unit 165 selects the arithmetic encoding results supplied from the arithmetic encoding units 164-0 to 164-N in order from the arithmetic encoding unit 164-0 to generate and output an encoded stream.
  • the parallel processing number setting unit 167 sets parallel processing when arithmetic coding is performed in parallel in units of slices according to, for example, the resolution or frame rate of the image.
  • the parallel processing number setting unit 167 may set parallel processing in units of blocks according to the number of zero coefficients in the orthogonal transformation performed in units of blocks.
  • the parallel processing number setting unit 167 sets the parallel processing number in at least one of a slice unit and a block unit, and is set in slice units when the parallel processing number is not set in block units.
  • the number of parallel processes may be used.
  • the parallel processing number setting unit 167 operates the CABAC encoder 160 so that arithmetic coding is performed with the set number of parallel processings.
  • the parallel processing number setting unit 167 may not be provided.
  • step ST11 the A / D converter 11 performs A / D conversion on the input image signal.
  • step ST12 the screen rearrangement buffer 12 performs image rearrangement.
  • the screen rearrangement buffer 12 stores the image data supplied from the A / D conversion unit 11, and rearranges from the display order of each picture to the encoding order.
  • step ST13 the calculation unit 13 generates prediction error data.
  • the calculation unit 13 calculates a difference between the image data of the input image rearranged in step ST12 and the image data of the predicted image selected by the predicted image / optimum mode selection unit 33, and the image data of the difference image, that is, the prediction Generate error data.
  • the prediction error data has a smaller data amount than the original image data. Therefore, the data amount can be encoded as compared with the case where the image is encoded as it is.
  • the orthogonal transform unit 14 performs an orthogonal transform process.
  • the orthogonal transform unit 14 performs orthogonal transform on the prediction error data supplied from the calculation unit 13. Specifically, orthogonal transformation such as discrete cosine transformation and Karhunen-Loeve transformation is performed on the prediction error data, and transformation coefficient data is output.
  • step ST15 the quantization unit 15 performs a quantization process.
  • the quantization unit 15 quantizes the transform coefficient data.
  • rate control is performed as described in the process of step ST25 described later.
  • step ST16 the inverse quantization unit 21 performs an inverse quantization process.
  • the inverse quantization unit 21 inversely quantizes the transform coefficient data quantized by the quantization unit 15 with characteristics corresponding to the characteristics of the quantization unit 15.
  • the inverse orthogonal transform unit 22 performs an inverse orthogonal transform process.
  • the inverse orthogonal transform unit 22 performs inverse orthogonal transform on the transform coefficient data inversely quantized by the inverse quantization unit 21 with characteristics corresponding to the characteristics of the orthogonal transform unit 14.
  • step ST18 the calculation unit 23 generates reference image data.
  • the calculation unit 23 adds the predicted image data supplied from the predicted image / optimum mode selection unit 33 and the data after inverse orthogonal transformation of the position corresponding to the predicted image to generate image data (reference image) of the local decoded image. Data).
  • step ST19 the deblocking filter 24 performs a deblocking filter process.
  • the deblocking filter 24 filters the decoded image data output from the calculation unit 23 to remove block distortion.
  • the frame memory 25 stores the decoded image data.
  • the frame memory 25 stores decoded image data that has been filtered by the deblocking filter.
  • the intra prediction unit 31 and the motion prediction / compensation unit 32 each perform a prediction process. That is, the intra prediction unit 31 performs intra prediction processing in the intra prediction mode, and the motion prediction / compensation unit 32 performs motion prediction / compensation processing in the inter prediction mode.
  • the prediction process prediction processes in all candidate prediction modes are performed, and cost function values in all candidate prediction modes are calculated.
  • the optimal intra prediction mode and the optimal inter prediction mode are selected, and the prediction image generated in the selected prediction mode and its cost function and prediction mode information are predicted image / optimum mode. It is supplied to the selector 33.
  • the predicted image / optimum mode selection unit 33 selects predicted image data.
  • the predicted image / optimum mode selection unit 33 determines the optimal mode with the best coding efficiency based on the cost function values output from the intra prediction unit 31 and the motion prediction / compensation unit 32.
  • the predicted image / optimum mode selection unit 33 selects the optimal intra prediction mode as the optimal mode when image quality degradation caused by the encoding / decoding process is large based on the control signal from the encoding distortion control unit. Further, the predicted image / optimum mode selection unit 33 outputs the predicted image data of the determined optimal mode to the calculation unit 13 and the calculation unit 23. As described above, the predicted image data is used for the calculations in steps ST13 and ST18.
  • the lossless encoding unit 16 performs a lossless encoding process.
  • the lossless encoding unit 16 performs lossless encoding on the quantized data output from the quantization unit 15. That is, lossless encoding such as variable-length encoding or arithmetic encoding is performed on the quantized data to encode the data.
  • the lossless encoding unit 16 performs lossless encoding of prediction mode information or the like corresponding to the prediction image data selected in step ST25, and adds the prediction mode to the encoded stream generated by lossless encoding of the quantized data. Lossless encoded data such as information is included.
  • step ST24 the accumulation buffer 17 performs accumulation processing.
  • the accumulation buffer 17 accumulates the encoded stream output from the lossless encoding unit 16.
  • the encoded stream stored in the storage buffer 17 is appropriately read and transmitted to the decoding side via the transmission path.
  • step ST25 the rate control unit 18 performs rate control.
  • the rate control unit 18 sets the quantization parameter QP so that overflow or underflow does not occur in the accumulation buffer 17 and outputs the quantization parameter QP to the quantization unit 15. Control the rate of activation. Further, the rate control unit 18 adjusts or limits the quantization parameter QP in accordance with the coding distortion information based on the control signal from the coding distortion control unit.
  • the CABAC encoder sets the number of parallel processes in units of slices. For example, in the case of a moving image with a high resolution and frame rate, the number that can be processed in parallel is increased to give priority to high-speed processing. Further, as the resolution and frame rate increase, the number of parallel processing may be increased to give higher priority to high-speed processing.
  • the number of parallel processes may be switched in units of macro blocks.
  • the lossless encoding unit counts the number of coefficients (zero coefficients) whose coefficient value is “0” in the macroblock, and if there are many zero coefficients, the speed-up process is not necessary, so the encoding efficiency Is prioritized, and when the zero coefficient is small, the speed-up process is prioritized over the coding efficiency.
  • FIG. 6 is a flowchart showing the operation of the CABAC encoder.
  • the CABAC encoder 160 determines whether the resolution and the frame rate are high.
  • the CABAC encoder 160 proceeds to step ST32 when the resolution or frame rate of the moving image indicated by the system control unit or the like of the image encoding device 10 is higher than a predetermined value, and proceeds to step ST33 when not higher. Proceed to
  • the CABAC encoder 160 sets the parallel processing number to a large value.
  • the CABAC encoder 160 gives priority to high-speed processing because the resolution and frame rate are higher than predetermined values. Specifically, a syntax element “slice_parallel_processing_id” indicating the number of parallel processes is provided in the slice header syntax, and the numerical value of the syntax element “slice_parallel_processing_id” is set to a large value. That is, CABAC encoder 160 prioritizes high-speed processing with the numerical value of syntax element “slice_parallel_processing_id” being a larger value than when encoding efficiency is prioritized, and proceeds to step ST34.
  • step ST33 the CABAC encoder 160 sets the number of parallel processes to a small value.
  • the CABAC encoder 160 gives priority to encoding efficiency because the resolution and frame rate are not higher than a predetermined value.
  • the syntax element “slice_parallel_processing_id” is provided in the slice header syntax, and the numerical value of the syntax element “slice_parallel_processing_id” is set to a small value. That is, CABAC encoder 160 prioritizes encoding efficiency by setting the numerical value of syntax element “slice_parallel_processing_id” to a smaller value than when high-speed processing is prioritized, and proceeds to step ST34.
  • FIG. 7 illustrates a part of the slice header syntax provided with the syntax element “slice_parallel_processing_id”.
  • the syntax element “slice_parallel_processing_id” is provided after the syntax element “pic_parameter_set_id”.
  • step ST34 the CABAC encoder 160 determines whether the number of zero coefficients in the macroblock is equal to or greater than a predetermined number.
  • the CABAC encoder 160 proceeds to step ST35 when the number of zero coefficients indicated by the system control unit of the image encoding device 10 is a predetermined number or more, and proceeds to step ST36 when the number is less than the predetermined number.
  • step ST35 the CABAC encoder 160 sets the parallel processing number to a small value.
  • the CABAC encoder 160 gives priority to the encoding efficiency because there are more zero coefficients than the predetermined number.
  • a syntax element “mb_parallel_processing_id” indicating the number of parallel processes is provided in the macroblock header syntax, and the numerical value of the syntax element “mb_parallel_processing_id” is set to a small value. That is, CABAC encoder 160 prioritizes encoding efficiency by setting the numerical value of syntax element “mb_parallel_processing_id” to a smaller value than when high-speed processing is prioritized, and proceeds to step ST37.
  • step ST36 the CABAC encoder 160 sets the parallel processing number to a large value.
  • the CABAC encoder 160 gives priority to high-speed processing because the zero coefficient is not larger than the predetermined number.
  • the syntax element “mb_parallel_processing_id” is provided in the macroblock header syntax, and the numerical value of the syntax element “mb_parallel_processing_id” is set to a large value. That is, the CABAC encoder 160 sets the numerical value of the syntax element “mb_parallel_processing_id” to a larger value than when encoding efficiency is prioritized and prioritizes high-speed processing, and proceeds to step ST37.
  • FIG. 8 illustrates a macroblock header syntax provided with a syntax element “mb_parallel_processing_id”.
  • the syntax element “mb_parallel_processing_id” is provided after the syntax element “mb_type”. Further, when the syntax element “slice_parallel_processing_id” and the syntax element “mb_parallel_processing_id” are provided, processing is performed with the number of parallel processes indicated by any one of the syntax elements.
  • step ST37 the CABAC encoder 160 selects a context index (ctxIdx) allocation table according to the number of parallel processes.
  • context indexes are preliminarily tabulated so as not to cause duplication within a parallel processing unit.
  • a specific example of the context index allocation table will be described later.
  • step ST38-0 the CABAC encoder 160 sets a level list index (LevelListIdx) and proceeds to step ST39-0.
  • the CABAC encoder 160 sets the level list index (LevelListIdx) to “0”. Thereafter, each time the parallel processing is repeated, the level list index (LevelListIdx) is updated according to the number of parallel processing. For example, when the number of parallel processes is “2”, the level list index (LevelListIdx) is updated in the order of “0, 2, 4,... 62” every time the parallel process is repeated. When the number of parallel processing is “4”, the level list index (LevelListIdx) is updated in the order of “0, 4, 8,... 60” each time the parallel processing is repeated. When the parallel processing number is “15”, the level list index (LevelListIdx) is updated in the order of “0, 15, 30,... 60” every time the parallel processing is repeated.
  • the CABAC encoder 160 determines a context index (ctxIdx) corresponding to the level list index (LevelListIdx).
  • the CABAC encoder 160 adds the context index offset (ctxIdxOffset) to the context index increment (ctxIdxInc) assigned to the level list index (LevelListIdx), and the context index (ctxIdx) corresponding to the level list index (LevelListIdx) And
  • step ST40-0 the CABAC encoder 160 calls a context variable corresponding to the context index (ctxIdx).
  • the CABAC encoder 160 calls a context variable corresponding to the context index (ctxIdx) determined in step ST39-0 from the context variable table selected in step ST37.
  • step ST41-0 the CABAC encoder 160 performs arithmetic encoding.
  • the CABAC encoder 160 performs arithmetic encoding using the context variable called in step ST40-0.
  • step ST42 the CABAC encoder 160 updates the context variable.
  • the CABAC encoder 160 updates the number of the probability table in the context variable selected based on the arithmetic encoding results of steps ST41-0 to 41-N, and proceeds to step ST43.
  • step ST43 the CABAC encoder 160 determines whether the coefficient processing is completed.
  • the CABAC encoder 160 returns to step ST37 when the arithmetic coding for the coefficients for one macroblock is not completed, and proceeds to step ST44 when the arithmetic coding is completed for the coefficients for one macroblock. .
  • step ST44 the CABAC encoder 160 determines whether or not the macroblock processing is completed.
  • the CABAC encoder 160 returns to step ST34 when arithmetic coding is not completed for each macroblock in the slice, performs processing for the next macroblock, and proceeds to step ST45 when it is completed.
  • step ST45 the CABAC encoder 160 determines whether the slice processing is completed. If the arithmetic coding has not been completed for each slice in the frame, the CABAC encoder 160 returns to step ST31 and performs processing for the next slice.
  • the number of parallel processes is increased and priority is given to the high-speed processing, so that an encoded stream can be generated at high speed. Further, not only switching for each slice but also switching for each macroblock is supported. In other words, if there are many zero coefficients in the macroblock, high-speed processing is unnecessary, so the number of parallel processes is reduced to give priority to coding efficiency, and when the number of zero coefficients is small, the number of parallel processes is increased Prioritize processing. As described above, by enabling switching of the number of parallel processes for each macroblock, more detailed control can be performed as compared with switching of the number of parallel processes for each slice.
  • the image decoding apparatus described later performs arithmetic with the same number of parallel processes as the image encoding apparatus based on the information of the syntax element indicating the number of parallel processes. Decoding processing can be performed.
  • the image decoding apparatus can perform the arithmetic decoding process with the same number of parallel processes as the image encoding apparatus, so that the data amount of the encoded stream can be reduced.
  • An encoded stream generated by encoding an input image is supplied to an image decoding device via a predetermined transmission path, a recording medium, and the like and decoded.
  • FIG. 9 exemplifies a configuration of an image decoding apparatus that performs decoding processing of an encoded stream.
  • the image decoding device 50 includes a storage buffer 51, a lossless decoding unit 52, an inverse quantization unit 53, an inverse orthogonal transform unit 54, a calculation unit 55, a deblocking filter 56, a screen rearrangement buffer 57, a digital / analog conversion unit (D / A conversion unit) 58. Further, the image decoding device 50 includes a frame memory 61, an intra prediction unit 71, a motion compensation unit 72, and a selector 73.
  • the accumulation buffer 51 accumulates the transmitted encoded stream.
  • the lossless decoding unit 52 decodes the encoded stream supplied from the accumulation buffer 51 by a method corresponding to the encoding method of the CABAC encoder 160 shown in FIG.
  • the lossless decoding unit 52 operates as an information acquisition unit and acquires various information from the encoded stream. For example, the lossless decoding unit 52 outputs prediction mode information and the like obtained by decoding the encoded stream to the intra prediction unit 71 and the motion compensation unit 72. Further, the lossless decoding unit 52 outputs the quantization parameter information and the quantized data obtained by decoding the encoded stream to the inverse quantization unit 53. In addition, when the quantization parameter range is limited and the quantization parameter information is encoded, the lossless decoding unit 52 uses a control signal supplied from an encoding distortion control unit (not shown). Then, the quantization parameter information is decoded.
  • the inverse quantization unit 53 performs inverse quantization of the quantized data supplied from the lossless decoding unit 52 using a quantization parameter in a method corresponding to the quantization method of the quantization unit 15 shown in FIG.
  • the inverse orthogonal transform unit 54 performs inverse orthogonal transform on the output of the inverse quantization unit 53 by a method corresponding to the orthogonal transform method of the orthogonal transform unit 14 illustrated in FIG.
  • the calculation unit 55 adds the data after inverse orthogonal transformation and the predicted image data supplied from the selector 73 to generate image data of the decoded image, and outputs it to the deblocking filter 56 and the intra prediction unit 71.
  • the deblocking filter 56 performs a filter process for reducing block distortion that occurs during image encoding.
  • the deblocking filter 56 performs a filter process for removing block distortion from the image data supplied from the calculation unit 55, and outputs the image data after the filter process to the screen rearrangement buffer 57 and the frame memory 61.
  • the screen rearrangement buffer 57 rearranges images. That is, the order of frames rearranged for the encoding order by the screen rearrangement buffer 12 shown in FIG. 3 is rearranged in the original display order and output to the D / A converter 58.
  • the D / A converter 58 performs D / A conversion on the image data supplied from the screen rearrangement buffer 57, and outputs the decoded image to a display (not shown).
  • the intra prediction unit 71 generates predicted image data based on the prediction mode information supplied from the lossless decoding unit 52 and the decoded image data supplied from the calculation unit 55, and outputs the generated predicted image data to the selector 73. .
  • the motion compensation unit 72 performs motion compensation using the image data read from the frame memory 61 based on the prediction mode information and the motion vector information supplied from the lossless decoding unit 52, and generates predicted image data.
  • the motion compensation unit 72 outputs the generated predicted image data to the selector 73.
  • the selector 73 selects the intra prediction unit 71 for intra prediction and the motion compensation unit 72 for inter prediction based on the prediction mode information supplied from the lossless decoding unit 52.
  • the selector 73 outputs the predicted image data generated by the selected intra prediction unit 71 or motion compensation unit 72 to the calculation unit 55.
  • FIG. 10 illustrates the configuration of a CABAC decoder that performs CABAC decoding processing in the lossless decoding unit 52.
  • the CABAC decoder 520 receives encoded data from the accumulation buffer 51, decodes it into binary data, and converts it into a value of a syntax element that is multilevel data.
  • the CABAC decoder 520 includes a context index setting unit 521, a context variable selection processing unit 522, an arithmetic decoding processing unit 523, a decoding result selection unit 524, a multi-value conversion unit 525, a register 526, and a parallel processing number setting unit 527. .
  • the context index setting unit 521 sets the context index (ctxIdx) of the syntax element to be decoded next, based on the information regarding the syntax element stored in the register 526, and outputs it to the context variable selection processing unit 522.
  • variable selection units 522-0 to 522-N are provided.
  • the parallel processing number setting unit is provided in the image encoding device and the parallel processing number is set, the parallel processing number setting unit 527 sets the parallel processing number.
  • the variable selection unit 522-0 selects a context variable corresponding to the context index (ctxIdx-0) from the context variable table and outputs the selected context variable to the arithmetic decoding processing unit 523.
  • the variable selection units 522-1 to 522-N select context variables corresponding to the context indexes (ctxIdx-1 to ctxIdx-N) and output them to the arithmetic decoding processing unit 523.
  • arithmetic decoding units 523-0 to 523-N are provided. Arithmetic decoding units 523-0 to 523-N decode the encoded data input from the accumulation buffer 51 into binary data. For example, when decoding the encoded data of one coefficient, the arithmetic decoding unit 523-0 performs decoding based on the context variable supplied from the variable selection unit 522-0, and binarized data that is an arithmetic decoding result Is output to the decoding result selection unit 524. In addition, the arithmetic decoding unit 523-0 outputs the arithmetic decoding result to the variable selection unit 522-0, and updates the number of the probability table in the context variable selected by the variable selection unit 522-0.
  • the arithmetic decoding units 523-1 to 523-N perform decoding based on the context variables supplied from the variable selection units 522-1 to 522-N when decoding the encoded data of one coefficient,
  • the binarized data that is the result of arithmetic decoding is output to the decoding result selection unit 524.
  • the arithmetic decoding units 523-1 to 523-N output the arithmetic decoding results to the variable selection units 522-1 to 522-N, and the context variables selected by the variable selection units 522-1 to 522-N. Update the probability table number at.
  • the decoding result selection unit 524 sequentially selects the arithmetic decoding results supplied from the arithmetic decoding units 523-0 to 523-N, and outputs them to the multi-level unit 525.
  • the multi-value quantization unit 525 performs processing corresponding to the binarization unit 161 of the CABAC encoder 160, and multi-values the binary data supplied from the decoding result selection unit 524, so that the data before encoding is encoded. Multi-value data, that is, the value of the syntax element is output.
  • the multilevel conversion unit 525 outputs information used to set a context index (ctxIdx) in the next decoding in the syntax element generated by performing multilevel conversion to the register 526. Further, the multi-value quantization unit 525 outputs the value of the syntax element to the parallel processing number setting unit 527.
  • the register 526 holds the information supplied from the multi-level unit 525 and outputs the held information to the context index setting unit 521.
  • the parallel processing number setting unit 527 sets the parallel processing number for arithmetic decoding.
  • the parallel processing count setting unit 527 determines the parallel processing count based on a syntax element indicating the parallel processing count included in the encoded data, for example.
  • the parallel processing number setting unit 527 sets the number of slices according to the resolution or frame rate of the image to be decoded.
  • the parallel processing number setting unit 527 operates the CABAC decoder 520 so that arithmetic decoding is performed with the set number of parallel processings.
  • step ST51 the accumulation buffer 51 accumulates the supplied encoded stream.
  • step ST52 the lossless decoding unit 52 performs lossless decoding processing.
  • the lossless decoding unit 52 decodes the encoded stream supplied from the accumulation buffer 51. That is, quantized data of each picture encoded by the CABAC encoder 160 shown in FIG. 4 is obtained.
  • the lossless decoding unit 52 performs lossless decoding such as prediction mode information included in the encoded stream and the obtained prediction mode information is information related to the intra prediction mode
  • the prediction mode information is transferred to the intra prediction unit 71.
  • the lossless decoding part 52 outputs prediction mode information and motion vector information to the motion compensation part 72, when prediction mode information is the information regarding inter prediction mode.
  • step ST53 the inverse quantization unit 53 performs an inverse quantization process.
  • the inverse quantization unit 53 inversely quantizes the quantized data decoded by the lossless decoding unit 52 with characteristics corresponding to the characteristics of the quantization unit 15 illustrated in FIG.
  • step ST54 the inverse orthogonal transform unit 54 performs an inverse orthogonal transform process.
  • the inverse orthogonal transform unit 54 performs inverse orthogonal transform on the transform coefficient data inversely quantized by the inverse quantization unit 53 with characteristics corresponding to the characteristics of the orthogonal transform unit 14 illustrated in FIG.
  • step ST55 the calculation unit 55 generates decoded image data.
  • the computing unit 55 adds the data obtained by performing the inverse orthogonal transform process and the predicted image data selected in step ST59 described later to generate decoded image data. As a result, the original image is decoded.
  • step ST56 the deblocking filter 56 performs filter processing.
  • the deblocking filter 56 filters the decoded image data output from the calculation unit 55 to remove block distortion.
  • step ST57 the frame memory 61 stores data.
  • the frame memory 61 stores decoded image data that has been filtered by the deblocking filter.
  • step ST58 the intra prediction unit 71 and the motion compensation unit 72 generate predicted image data.
  • the intra prediction unit 71 and the motion compensation unit 72 generate prediction image data corresponding to the prediction mode information supplied from the lossless decoding unit 52, respectively.
  • the intra prediction unit 71 when prediction mode information for intra prediction is supplied from the lossless decoding unit 52, the intra prediction unit 71 generates predicted image data based on the prediction mode information.
  • the motion compensation unit 72 performs motion compensation based on the prediction mode information and motion vector information to generate predicted image data.
  • step ST59 the selector 73 selects predicted image data.
  • the selector 73 selects the prediction image data supplied from the intra prediction unit 71 and the prediction image data supplied from the motion compensation unit 72, supplies the selected prediction image data to the calculation unit 55, and reverses in step ST55. It is added to the output of the orthogonal transformation unit 54.
  • the selector 73 selects the predicted image data supplied from the intra prediction unit 71 when image quality degradation caused by the encoding / decoding process is large based on the control signal from the encoding distortion control unit.
  • step ST60 the screen rearrangement buffer 57 performs image rearrangement. That is, the screen rearrangement buffer 57 rearranges the order of frames rearranged for encoding by the screen rearrangement buffer 12 of the image encoding device 10 shown in FIG. 3 to the original display order.
  • step ST61 the D / A converter 58 D / A converts the image data from the screen rearrangement buffer 57. This image is output to a display (not shown), and the image is displayed.
  • FIG. 12 is a flowchart showing the operation of the CABAC decoder in the lossless decoding unit.
  • the CABAC decoder 520 acquires the number of parallel processes from the slice header.
  • the CABAC decoder 520 acquires the parallel processing number N (parallel_processing_id) from the syntax of the slice header (slice_Header).
  • step ST72 the CABAC decoder 520 acquires the number of parallel processes from the macroblock header.
  • the CABAC decoder 520 acquires the parallel processing number N (mb_parallel_processing_id) from the syntax of the macroblock header (mb_Header).
  • the CABAC decoder 520 determines the number of parallel processes and sets the next context index (ctxIdx) and level list index (LevelListIdx).
  • the lossless decoding unit 52 determines the number of parallel processes based on the information on the number of parallel processes acquired from the slice header. Further, when information indicating the number of parallel processes is acquired from the macro block header in a macro block in the slice, the number of parallel processes is determined based on this information. Further, the CABAC decoder 520 sets a context index and a level list index to be decoded next.
  • step ST74 the CABAC decoder 520 selects a context index (ctxIdx) allocation table according to the number of parallel processes. Similar to the CABAC encoder 160, the CABAC decoder 520 selects a context index allocation table according to the number of parallel processes.
  • the CABAC decoder 520 performs the processing from step ST75 to step ST78 in parallel according to the number of parallel processes.
  • step ST75-0 the CABAC decoder 520 sets a level list index (LevelListIdx) and proceeds to step ST76-0.
  • the CABAC encoder 160 sets the level list index (LevelListIdx) to “0”. Thereafter, each time the parallel processing is repeated, the level list index (LevelListIdx) is updated according to the number of parallel processing. For example, when the number of parallel processes is “2”, the level list index (LevelListIdx) is updated in the order of “0, 2, 4,... 62” every time the parallel process is repeated. When the parallel processing number is “2”, the level list index (LevelListIdx) is updated in the order of “0, 2, 4,... 60” each time the parallel processing is repeated. When the number of parallel processes is “15”, for example, the level list index (LevelListIdx) is updated in the order of “0, 15, 30,... 60” each time the parallel process is repeated.
  • step ST76-0 the CABAC decoder 520 determines a context index (ctxIdx).
  • the CABAC decoder 520 adds the context index offset (ctxIdxOffset) to the context index increment (ctxIdxInc) assigned to the level list index (LevelListIdx), and the context index (ctxIdx) corresponding to the level list index (LevelListIdx) To do.
  • step ST77-0 the CABAC decoder 520 calls a context variable corresponding to the context index (ctxIdx).
  • the CABAC decoder 520 calls a context variable corresponding to the context index (ctxIdx) determined in step ST76-0 from the table.
  • step ST78-0 the CABAC decoder 520 performs arithmetic decoding.
  • the CABAC decoder 520 performs arithmetic decoding using the context variable called in step ST77-0.
  • LevelListIdx level list index
  • step ST79 the CABAC decoder 520 updates the context variable.
  • CABAC decoder 520 updates the number of the probability table in the selected context variable based on the results of arithmetic decoding in steps ST78-0 to 78-N, and proceeds to step ST80.
  • step ST80 the CABAC decoder 520 determines whether the coefficient processing is completed.
  • the CABAC decoder 520 returns to step ST73 when the arithmetic decoding has not been completed for the coefficients for one macroblock, and proceeds to step ST81 when the arithmetic decoding has been completed for the coefficients for one macroblock.
  • step ST81 the CABAC decoder 520 determines whether or not the macroblock processing is completed. CABAC decoder 520 returns to step ST72 to perform processing for the next macroblock if arithmetic decoding has not been completed for each macroblock in the slice, and proceeds to step ST82 if completion.
  • step ST82 the CABAC decoder 520 determines whether or not the slice processing is completed. If the arithmetic decoding has not been completed for each slice in the frame, the CABAC decoder 520 returns to step ST71 and performs the process for the next slice.
  • FIG. 13 shows a level list index (LevelListIdx) for an 8 ⁇ 8 orthogonal transform component for one macroblock.
  • the order of the level list index (LevelListIdx) is a zigzag scan order like the numerical order of FIG.
  • FIG. 14 illustrates a context index allocation table corresponding to the number of parallel processes.
  • the context index allocation table with the table Id “TableId 1”, that is, the context index of FIG. Select an allocation table.
  • the context index allocation table whose table Id is “TableId 3” shown in FIG.
  • FIG. 15 shows the context index increment (ctxIdxInc) for the 8 ⁇ 8 orthogonal transform component when the number of parallel processes is “2”.
  • the relationship between the level list index (LevelListIdx) shown in FIG. 13 and the context index increment (ctxIdxInc) shown in FIG. 15 is shown in the context index allocation table shown in FIG.
  • the context index increment (ctxIdxInc) changes as shown in FIG.
  • the context index increment is assigned so that the context index increment (ctxIdxInc) is different. Therefore, since the same context index increment (ctxIdxInc) is not used in the parallel processing unit, the processing can be performed at high speed.
  • FIG. 17 shows the context index increment (ctxIdxInc) for the 8 ⁇ 8 orthogonal transform component when the number of parallel processes is “4”.
  • the relationship between the level list index (LevelListIdx) shown in FIG. 13 and the context index increment (ctxIdxInc) shown in FIG. 17 is shown in the context index allocation table shown in FIG.
  • the context index increment (ctxIdxInc) changes as shown in FIG.
  • the context index increment is assigned so that the context index increment (ctxIdxInc) is different. Therefore, since the same context index increment (ctxIdxInc) is not used in the parallel processing unit, the processing can be performed at high speed.
  • FIG. 19 shows the context index increment (ctxIdxInc) for the 8 ⁇ 8 orthogonal transform component when the number of parallel processes is “8”.
  • the relationship between the level list index (LevelListIdx) shown in FIG. 13 and the context index increment (ctxIdxInc) shown in FIG. 19 is shown in the context index allocation table shown in FIG.
  • the context index increment (ctxIdxInc) changes as shown in FIG.
  • the context index increment is assigned so that the context index increment (ctxIdxInc) is different. Therefore, since the same context index increment (ctxIdxInc) is not used in the parallel processing unit, the processing can be performed at high speed.
  • FIG. 21 shows the context index increment (ctxIdxInc) for the 8 ⁇ 8 orthogonal transform component when the number of parallel processes is “15”. Note that the relationship between the level list index (LevelListIdx) shown in FIG. 13 and the context index increment (ctxIdxInc) shown in FIG. 21 is shown in the context index assignment table shown in FIG.
  • the context index increment (ctxIdxInc) changes as shown in FIG.
  • the context index increment is assigned so that the context index increment (ctxIdxInc) is different. Therefore, since the same context index increment (ctxIdxInc) is not used in the parallel processing unit, the processing can be performed at high speed.
  • FIG. 23 shows context index increment (ctxIdxInc) for an 8 ⁇ 8 orthogonal transform component when parallel processing is not performed.
  • the relationship between the level list index (LevelListIdx) shown in FIG. 13 and the context index increment (ctxIdxInc) shown in FIG. 23 is shown in the context index assignment table shown in (E) of FIG.
  • the processing can be performed at high speed.
  • the same context index increment (ctxIdxInc) occurs randomly, but allocation is performed so that equal context index increments (ctxIdxInc) are used more frequently in orthogonal transform coefficients whose frequencies are close to each other.
  • the encoding efficiency may be increased by allocating the orthogonal transform coefficients whose frequencies are close so that the same context index increment (ctxIdxInc) is used more frequently.
  • context index increment (ctxIdxInc) “4” is often used for orthogonal transform coefficients in the vicinity of the frequency.
  • the program can be recorded in advance on a hard disk or ROM (Read Only Memory) as a recording medium.
  • the program can be temporarily or permanently stored on a removable recording medium such as a flexible disk, CD-ROM (Compact Disc Read Only Memory), MO (Magneto optical disc), DVD (Digital Versatile Disc), magnetic disk, or semiconductor memory. It can be stored (recorded).
  • a removable recording medium can be provided as so-called package software.
  • the program is installed on the computer from the removable recording medium as described above, or is wirelessly transferred from the download site to the computer, or is wired to the computer via a network such as a LAN (Local Area Network) or the Internet. .
  • the computer can receive the program transferred in this way and install it on a recording medium such as a built-in hard disk.
  • the step of describing the program includes not only the processing that is performed in time series in the described order but also the processing that is not necessarily performed in time series but is executed in parallel or individually.
  • H.264 is used as the encoding method / decoding method.
  • the present technology can also be applied to an image encoding device / image decoding device using other encoding methods / decoding methods.
  • the present technology is, for example, MPEG, H.264, etc.
  • the present invention can be applied to an image encoding device and an image decoding device that are used when receiving via the storage medium or processing on a storage medium such as an optical, magnetic disk, and flash memory.
  • the image encoding device 10 and the image decoding device 50 described above can be applied to any electronic device. Examples thereof will be described below.
  • FIG. 25 illustrates a schematic configuration of a television apparatus to which the present technology is applied.
  • the television apparatus 90 includes an antenna 901, a tuner 902, a demultiplexer 903, a decoder 904, a video signal processing unit 905, a display unit 906, an audio signal processing unit 907, a speaker 908, and an external interface unit 909. Furthermore, the television apparatus 90 includes a control unit 910, a user interface unit 911, and the like.
  • the tuner 902 selects a desired channel from the broadcast wave signal received by the antenna 901, demodulates it, and outputs the obtained encoded bit stream to the demultiplexer 903.
  • the demultiplexer 903 extracts video and audio packets of the program to be viewed from the encoded bit stream, and outputs the extracted packet data to the decoder 904.
  • the demultiplexer 903 supplies a packet of data such as EPG (Electronic Program Guide) to the control unit 910. If scrambling is being performed, descrambling is performed by a demultiplexer or the like.
  • the decoder 904 performs a packet decoding process, and outputs the video data generated by the decoding process to the video signal processing unit 905 and the audio data to the audio signal processing unit 907.
  • the video signal processing unit 905 performs noise removal, video processing according to user settings, and the like on the video data.
  • the video signal processing unit 905 generates video data of a program to be displayed on the display unit 906, image data by processing based on an application supplied via a network, and the like.
  • the video signal processing unit 905 generates video data for displaying a menu screen for selecting an item and the like, and superimposes the video data on the video data of the program.
  • the video signal processing unit 905 generates a drive signal based on the video data generated in this way, and drives the display unit 906.
  • the display unit 906 drives a display device (for example, a liquid crystal display element or the like) based on a drive signal from the video signal processing unit 905 to display a program video or the like.
  • a display device for example, a liquid crystal display element or the like
  • the audio signal processing unit 907 performs predetermined processing such as noise removal on the audio data, performs D / A conversion processing and amplification processing on the processed audio data, and outputs the audio data to the speaker 908.
  • the external interface unit 909 is an interface for connecting to an external device or a network, and transmits and receives data such as video data and audio data.
  • a user interface unit 911 is connected to the control unit 910.
  • the user interface unit 911 includes an operation switch, a remote control signal receiving unit, and the like, and supplies an operation signal corresponding to a user operation to the control unit 910.
  • the control unit 910 is configured using a CPU (Central Processing Unit), a memory, and the like.
  • the memory stores a program executed by the CPU, various data necessary for the CPU to perform processing, EPG data, data acquired via a network, and the like.
  • the program stored in the memory is read and executed by the CPU at a predetermined timing such as when the television device 90 is activated.
  • the CPU controls each unit so that the television device 90 operates according to the user operation by executing the program.
  • the television device 90 is provided with a bus 912 for connecting the tuner 902, the demultiplexer 903, the video signal processing unit 905, the audio signal processing unit 907, the external interface unit 909, and the control unit 910.
  • the decoder 904 is provided with the function of the image decoding apparatus (image decoding method) of the present technology. For this reason, by using the function of the image encoding device of the present technology on the broadcast station side, even if arithmetic encoding is performed in parallel and an encoded bit stream is generated at a high speed, the encoded bit is generated by the television device. Stream decoding can be performed correctly and at high speed.
  • FIG. 26 exemplifies a schematic configuration of a mobile phone to which the present technology is applied.
  • the cellular phone 92 includes a communication unit 922, an audio codec 923, a camera unit 926, an image processing unit 927, a demultiplexing unit 928, a recording / reproducing unit 929, a display unit 930, and a control unit 931. These are connected to each other via a bus 933.
  • An antenna 921 is connected to the communication unit 922, and a speaker 924 and a microphone 925 are connected to the audio codec 923. Further, an operation unit 932 is connected to the control unit 931.
  • the mobile phone 92 performs various operations such as transmission / reception of voice signals, transmission / reception of e-mail and image data, image shooting, and data recording in various modes such as a voice call mode and a data communication mode.
  • the voice signal generated by the microphone 925 is converted into voice data and compressed by the voice codec 923 and supplied to the communication unit 922.
  • the communication unit 922 performs transmission processing of audio data, frequency conversion processing, and the like to generate a transmission signal.
  • the communication unit 922 supplies a transmission signal to the antenna 921 and transmits it to a base station (not shown).
  • the communication unit 922 performs amplification, frequency conversion processing, demodulation processing, and the like of the reception signal received by the antenna 921, and supplies the obtained audio data to the audio codec 923.
  • the audio codec 923 performs data expansion of the audio data and conversion to an analog audio signal and outputs the result to the speaker 924.
  • the control unit 931 receives character data input by operating the operation unit 932 and displays the input characters on the display unit 930.
  • the control unit 931 generates mail data based on a user instruction or the like in the operation unit 932 and supplies the mail data to the communication unit 922.
  • the communication unit 922 performs mail data modulation processing, frequency conversion processing, and the like, and transmits the obtained transmission signal from the antenna 921.
  • the communication unit 922 performs amplification, frequency conversion processing, demodulation processing, and the like of the reception signal received by the antenna 921, and restores mail data. This mail data is supplied to the display unit 930 to display the mail contents.
  • the mobile phone 92 can also store the received mail data in a storage medium by the recording / playback unit 929.
  • the storage medium is any rewritable storage medium.
  • the storage medium is a removable medium such as a semiconductor memory such as a RAM or a built-in flash memory, a hard disk, a magnetic disk, a magneto-optical disk, an optical disk, a USB memory, or a memory card.
  • the image data generated by the camera unit 926 is supplied to the image processing unit 927.
  • the image processing unit 927 performs encoding processing of image data and generates encoded data.
  • the demultiplexing unit 928 multiplexes the encoded data generated by the image processing unit 927 and the audio data supplied from the audio codec 923 by a predetermined method, and supplies the multiplexed data to the communication unit 922.
  • the communication unit 922 performs modulation processing and frequency conversion processing of multiplexed data, and transmits the obtained transmission signal from the antenna 921.
  • the communication unit 922 performs amplification, frequency conversion processing, demodulation processing, and the like of the reception signal received by the antenna 921, and restores multiplexed data. This multiplexed data is supplied to the demultiplexing unit 928.
  • the demultiplexing unit 928 performs demultiplexing of the multiplexed data, and supplies the encoded data to the image processing unit 927 and the audio data to the audio codec 923.
  • the image processing unit 927 performs a decoding process on the encoded data to generate image data.
  • the image data is supplied to the display unit 930 and the received image is displayed.
  • the audio codec 923 converts the audio data into an analog audio signal, supplies the analog audio signal to the speaker 924, and outputs the received audio.
  • the image processing unit 927 is provided with the functions of an image encoding device (image encoding method) and an image decoding device (image decoding method) of the present technology. Therefore, when image data is communicated, image encoding and decoding can be performed at high speed.
  • FIG. 27 illustrates a schematic configuration of a recording / reproducing apparatus to which the present technology is applied.
  • the recording / reproducing apparatus 94 records, for example, audio data and video data of a received broadcast program on a recording medium, and provides the recorded data to the user at a timing according to a user instruction.
  • the recording / reproducing device 94 can also acquire audio data and video data from another device, for example, and record them on a recording medium.
  • the recording / reproducing device 94 decodes and outputs the audio data and video data recorded on the recording medium, thereby enabling image display and audio output on the monitor device or the like.
  • the recording / reproducing apparatus 94 includes a tuner 941, an external interface unit 942, an encoder 943, an HDD (Hard Disk Drive) unit 944, a disk drive 945, a selector 946, a decoder 947, an OSD (On-Screen Display) unit 948, a control unit 949, A user interface unit 950 is included.
  • Tuner 941 selects a desired channel from a broadcast signal received by an antenna (not shown).
  • the tuner 941 outputs an encoded bit stream obtained by demodulating the received signal of a desired channel to the selector 946.
  • the external interface unit 942 includes at least one of an IEEE 1394 interface, a network interface unit, a USB interface, a flash memory interface, and the like.
  • the external interface unit 942 is an interface for connecting to an external device, a network, a memory card, and the like, and receives data such as video data and audio data to be recorded.
  • the encoder 943 performs encoding by a predetermined method when the video data and audio data supplied from the external interface unit 942 are not encoded, and outputs an encoded bit stream to the selector 946.
  • the HDD unit 944 records content data such as video and audio, various programs, and other data on a built-in hard disk, and reads them from the hard disk during playback.
  • the disk drive 945 records and reproduces signals with respect to the mounted optical disk.
  • An optical disk such as a DVD disk (DVD-Video, DVD-RAM, DVD-R, DVD-RW, DVD + R, DVD + RW, etc.), a Blu-ray (registered trademark) disk, or the like.
  • the selector 946 selects one of the encoded bit streams from the tuner 941 or the encoder 943 when recording video or audio, and supplies the selected bit stream to either the HDD unit 944 or the disk drive 945. Further, the selector 946 supplies the encoded bit stream output from the HDD unit 944 or the disk drive 945 to the decoder 947 at the time of reproduction of video and audio.
  • the decoder 947 performs a decoding process on the encoded bit stream.
  • the decoder 947 supplies the video data generated by performing the decoding process to the OSD unit 948.
  • the decoder 947 outputs audio data generated by performing the decoding process.
  • the OSD unit 948 generates video data for displaying a menu screen for selecting an item and the like, and superimposes the video data on the video data output from the decoder 947 and outputs the video data.
  • a user interface unit 950 is connected to the control unit 949.
  • the user interface unit 950 includes an operation switch, a remote control signal receiving unit, and the like, and supplies an operation signal corresponding to a user operation to the control unit 949.
  • the control unit 949 is configured using a CPU, a memory, and the like.
  • the memory stores programs executed by the CPU and various data necessary for the CPU to perform processing.
  • the program stored in the memory is read and executed by the CPU at a predetermined timing such as when the recording / reproducing apparatus 94 is activated.
  • the CPU executes the program to control each unit so that the recording / reproducing device 94 operates in accordance with the user operation.
  • the encoder 943 is provided with the function of the image encoding device (image encoding method) of the present technology
  • the decoder 947 is provided with the function of the image decoding device (image decoding method). Video recording and playback can be performed at high speed.
  • FIG. 28 illustrates a schematic configuration of an imaging apparatus to which the present technology is applied.
  • the imaging device 96 images a subject and displays an image of the subject on a display unit, or records it on a recording medium as image data.
  • the imaging device 96 includes an optical block 961, an imaging unit 962, a camera signal processing unit 963, an image data processing unit 964, a display unit 965, an external interface unit 966, a memory unit 967, a media drive 968, an OSD unit 969, and a control unit 970. Have. In addition, a user interface unit 971 is connected to the control unit 970. Furthermore, the image data processing unit 964, the external interface unit 966, the memory unit 967, the media drive 968, the OSD unit 969, the control unit 970, and the like are connected via a bus 972.
  • the optical block 961 is configured using a focus lens, a diaphragm mechanism, and the like.
  • the optical block 961 forms an optical image of the subject on the imaging surface of the imaging unit 962.
  • the imaging unit 962 is configured using a CCD or CMOS image sensor, generates an electrical signal corresponding to the optical image by photoelectric conversion, and supplies the electrical signal to the camera signal processing unit 963.
  • the camera signal processing unit 963 performs various camera signal processing such as knee correction, gamma correction, and color correction on the electrical signal supplied from the imaging unit 962.
  • the camera signal processing unit 963 supplies the image data after the camera signal processing to the image data processing unit 964.
  • the image data processing unit 964 performs an encoding process on the image data supplied from the camera signal processing unit 963.
  • the image data processing unit 964 supplies the encoded data generated by performing the encoding process to the external interface unit 966 and the media drive 968. Further, the image data processing unit 964 performs a decoding process on the encoded data supplied from the external interface unit 966 and the media drive 968.
  • the image data processing unit 964 supplies the image data generated by performing the decoding process to the display unit 965. Further, the image data processing unit 964 superimposes the processing for supplying the image data supplied from the camera signal processing unit 963 to the display unit 965 and the display data acquired from the OSD unit 969 on the image data. To supply.
  • the OSD unit 969 generates display data such as a menu screen or an icon made up of symbols, characters, or graphics and outputs it to the image data processing unit 964.
  • the external interface unit 966 includes, for example, a USB input / output terminal, and is connected to a printer when printing an image.
  • a drive is connected to the external interface unit 966 as necessary, and a removable medium such as a magnetic disk or an optical disk is appropriately mounted, and a program read from them is installed as necessary.
  • the external interface unit 966 has a network interface connected to a predetermined network such as a LAN or the Internet.
  • the control unit 970 reads the encoded data from the memory unit 967 in accordance with an instruction from the user interface unit 971, and supplies the encoded data to the other device connected via the network from the external interface unit 966. it can.
  • the control unit 970 may acquire encoded data and image data supplied from another device via the network via the external interface unit 966 and supply the acquired data to the image data processing unit 964. it can.
  • any readable / writable removable medium such as a magnetic disk, a magneto-optical disk, an optical disk, or a semiconductor memory is used.
  • the recording medium may be any type of removable medium, and may be a tape device, a disk, or a memory card. Of course, a non-contact IC card or the like may be used.
  • media drive 968 and the recording medium may be integrated and configured by a non-portable storage medium such as a built-in hard disk drive or an SSD (Solid State Drive).
  • a non-portable storage medium such as a built-in hard disk drive or an SSD (Solid State Drive).
  • the control unit 970 is configured using a CPU, a memory, and the like.
  • the memory stores programs executed by the CPU, various data necessary for the CPU to perform processing, and the like.
  • the program stored in the memory is read and executed by the CPU at a predetermined timing such as when the imaging device 96 is activated.
  • the CPU executes the program to control each unit so that the imaging device 96 operates according to the user operation.
  • the image data processing unit 964 is provided with the functions of an image encoding device (image encoding method) and an image decoding device (image decoding method) of the present technology. Therefore, when a captured image is recorded in the memory unit 967, a recording medium, or the like or when a recorded captured image is reproduced, recording / reproduction can be performed at high speed.
  • the present technology should not be construed as being limited to the embodiments of the technology described above.
  • the embodiments of this technology disclose the present technology in the form of examples, and it is obvious that those skilled in the art can make modifications and substitutions of the embodiments without departing from the gist of the present technology. In other words, the scope of the claims should be considered in order to determine the gist of the present technology.
  • this technique can also take the following structures.
  • a binarization unit that converts syntax elements into binarized data;
  • a context index setting unit for setting a context index for specifying a context variable for the syntax element so as not to overlap in a parallel processing unit;
  • a context variable selection processing unit that selects a context variable according to the context index set by the context index setting unit;
  • An image coding apparatus comprising: an arithmetic coding processing unit that performs arithmetic coding of the binary data in parallel using the context variable selected by the context variable selection processing unit for each parallel processing unit.
  • the image encoding device according to (1) or (2), further including a parallel processing number setting unit configured to set the parallel processing number.
  • the image coding apparatus according to (6), wherein the parallel processing number setting unit sets the parallel processing number according to the number of zero coefficients in orthogonal transform performed in units of blocks.
  • the parallel processing number setting unit sets the parallel processing number in at least one of a slice unit and a block unit, and when the parallel processing number is not set in a block unit, in a slice unit
  • the context index setting unit sets the context index using an allocation table indicating a relationship between an index for each syntax element indicating an orthogonal transform coefficient and the context index. Any one of (1) to (8) An image encoding apparatus according to claim 1.
  • a context index setting unit that sets a context index for specifying a context variable corresponding to a syntax element to be decoded so as not to overlap in a parallel processing unit;
  • a context variable selection processing unit that selects a context variable according to the context index set by the context index setting unit;
  • An arithmetic decoding processing unit that performs arithmetic decoding of encoded data in parallel using the context variable selected by the context variable selection processing unit for each parallel processing unit;
  • An image decoding apparatus comprising: a multilevel conversion unit that converts binary data obtained by performing the arithmetic decoding into a value of a syntax element.
  • the image decoding device according to (11), further including a parallel processing number setting unit that sets the parallel processing number.
  • the image decoding device (13) The image decoding device according to (12), wherein the parallel processing count setting unit determines the parallel processing count based on a syntax element indicating the parallel processing count included in the encoded data. (14) The image decoding device according to (12), wherein the parallel processing number setting unit sets the parallel processing number in units of slices according to a resolution or a frame rate of an image to be decoded. (15) The context index setting unit sets the context index using an allocation table indicating a relationship between an index for each syntax element indicating an orthogonal transform coefficient and the context index.
  • a context index is set and set so as not to cause duplication within a parallel processing unit. Arithmetic coding and arithmetic decoding are performed using a context variable corresponding to the context index. For this reason, within the parallel processing unit, the context variable is updated, and arithmetic coding and arithmetic decoding are not performed using the updated context variable, and image encoding processing and decoding processing are performed at high speed. Will be able to.
  • the present technology allows an encoded stream obtained by performing encoding in units of blocks, such as MPEG and H.26x, to be transmitted via network media such as satellite broadcasting, cable TV, the Internet, and mobile phones. It is suitable for electronic devices that transmit and receive, and electronic devices that record and reproduce images using storage media such as optical disks, magnetic disks, and flash memories.
  • Dequantization part 58 ... D / A conversion part, 71 ... Intra prediction 72, motion compensation unit 73, 946 selector, 90 television 92 ... Mobile phone, 94 ... Recording / playback device, 96 ... Imaging device, 160 ... CABAC encoder, 161 ... Binarization unit, 162, 201, 521,.
  • Context index (ctxIdx) setting unit 163, 522...
  • Context variable selection processing unit 163-0 to 163-N, 202-0, 202-1, 522-0 to 522-N.
  • User interface unit 912, 933, 972 ... Bus, 922 ... Communication unit, 923 ... Audio codec, 925 ... Microphone, 926 ... Camera unit, 927 ... Image processing unit, 928 ... Demultiplexing unit, 929 ..Recording / reproducing unit, 932... Operation unit, 941... Tuner, 943... Encoder, 944. 948, 969 ... OSD unit, 961 ... optical block, 962 ... imaging unit, 963 ... camera signal processing unit, 964 ... image data processing unit, 967 ... memory unit, 968 ... Media drive

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

 二値化部161はシンタックス要素を二値化データに変換する。コンテキストインデックス(ctxIdx)設定部162は、シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定する。コンテキスト変数処理部163は、設定されたコンテキストインデックスに応じてコンテキスト変数を選択する。算術符号化処理部164は、並列処理単位毎に、選択されたコンテキスト変数を用いて二値化データの算術符号化を並列して行う。符号化処理を高速に行えるようになる。同様に、算術復号を並列して行うことで復号処理を高速に行えるようになる。

Description

画像符号化装置と画像復号装置およびその方法
 この技術は、画像符号化装置と画像復号装置およびその方法に関する。詳しくは、画像の符号化処理や復号処理を高速に行えるようにする。
 従来、AVC(Advanced Video Coding)画像符号化方式では、エントロピー符号化としてCABAC(Context-based Adaptive Binary Arithmetic Coding)や、CAVLC(Context-based Adaptive Variable Length Coding)が定義されている。このうち、CABACは、周囲の状況(コンテキスト(Context))に応じて適応的に符号化を行う2値の算術符号方式である。
 算術符号化では、1シンボル毎に発生確率に応じて数値区間を分割する処理を繰り返すことで符号列を得る。すなわち、全シンボルを順次処理する必要がある。また、コンテキストと呼ばれるシンボル発生確率テーブル(以下単に「確率テーブル」という)を符号化処理毎に順次更新しながら符号化を行う必要がある。また、算術復号では、算術符号化と逆の処理が行われる。このように、確率テーブルを順次更新しながら処理を行うため、確率テーブルが重複して用いられる場合、確率テーブルの更新が完了しないと次の符号化処理を行うことができない。したがって、処理の並列化によって算術符号化や算術復号を高速に行うことが困難である。
 例えば図1に示すコンテキストインデックス(ctxIdx)設定部201は、符号化または復号するシンタックスに応じてコンテキストインデックスを設定して変数選択部202-0,202-1に出力する。変数選択部202-0は、コンテキストインデックス設定部201から供給されたコンテキストインデックスに基づきコンテキスト変数を選択して算術復号部203-0に出力する。なお、コンテキスト変数では、発生確率が高い優勢シンボル(most probable symbol)と、その優勢シンボルのシンボル発生確率テーブルの番号(pStateIdx)が示されている。算術復号部203-0は、選択されたコンテキスト変数を用いて算術復号を行い復号結果bin0を出力する。同様に、変数選択部202-1は、コンテキストインデックス設定部201から供給されたコンテキストインデックスに基づきコンテキスト変数を選択して、算術復号部203-1に出力する。算術復号部203-1は、選択されたコンテキスト変数を用いて算術復号を行い復号結果bin1を出力する。ここで、算術復号部203-0,203-1を用いて復号処理を並列して行う場合、コンテキストインデックスが異なると確率テーブルを個々に選択できることから、算術復号部203-0と算術復号部203-1で並列に算術復号を行うことができる。しかし2つのシンボルでコンテキストインデックスが等しいと、算術復号部203-0で得られた復号結果bin0に基づき確率テーブルを更新してからでないと、算術復号部203-1は次の算術復号を行うことができない。したがって、処理の並列化によって算術復号を高速に行うことが困難となる。
 また、AVCではマルチスライス(multi slice)という手法を用いて高スループットを実現することができるようになされている。マルチスライス手法では、図2の(A)に示されるように、画像が複数の領域に分割され、それぞれに対して独立してCABAC符号化処理や復号処理が行われる。例えば、図2の(A)の点線矢印に示されるように、画像内上側のマクロブロックラインから画像内下側のマクロブロックラインに向かう順に、マクロブロック毎に算術符号化が行われる。このようにすることにより各領域のCABAC符号化/復号を並列に行うことができるようになり、処理の高速化が実現された。この分割された領域をスライス(slice)と称する。
 カレントマクロブロック(curr)は、図2の(B)(C)に示されるように、隣接する他のマクロブロック(mbA~mbD)を参照しながら符号化/復号が行われる。
 しかしながら、領域を分割することは符号化効率を落とす要因になる。第1に、各スライスが独立に符号化されるので、図2の(B)(C)に示されるように、各領域(スライス)の符号化/復号において相互参照をすることができない。したがって、境界部分で画面内予測(intra-prediction)が使用できなくなり、符号化効率が低減する恐れがあった。
 第2に、CABACでは確率テーブルを選択するために、図2の(C)に示されるように周辺マクロブロックの状態が参照されるが、境界部分では隣接マクロブロックの参照が不可能になるため、適切な確率テーブルの選択が困難になる恐れがあった。
 第3に、CABACで用いられる確率テーブルは、符号化が進むにつれて実際の発生確率に収束して符号化効率が高まっていくが、マルチスライス(multi slice)の場合、領域(スライス)毎にその確率テーブルが初期化される。したがって、スライス(slice)開始時点での符号化効率が低減する恐れがある。
 CABACを並列化しつつ符号化効率を改善する手法としてエントロピースライス(entropy slice)方式が提案された(例えば、非特許文献1参照)。この方式によればCABAC処理部分のみが、エントロピースライス(entropy slice)と称される領域に分割されて並列に実行されるので、画面内予測についてはエントロピースライス(entropy slice)境界でも使用可能であった。しかしながら、CABAC処理における周辺マクロブロック参照は、エントロピースライス(entropy slice)境界において使用できない。
 さらなる改善手法としてオーダードエントロピースライス(ordered entropy slices)方式が提案された(例えば、特許文献2参照)。この方式により、CABAC処理でも境界部分で隣接マクロブロックの参照が可能となった。
A. Segall, J.Zhao, "Entropy slices for parallel entropy decoding", VCEG input document COM16-C405, Geneva, CH, April 2008 Xun Guo,Yu-Wen Huang,Shawmin Lei"Ordered Entropy Slices for Parallel CABAC", VCEG input document VCEG-AK25, Yokohama, Japan, April 2009
 ところで、第2のエントロピースライス(entropy slice)の符号化や復号を行う場合、上側に隣接する第1のエントロピースライス(entropy slice)のマクロブロックの処理を終えていなければならない。このため、スライス(slice)間の依存が生じてしまい並列化のメリットが失われてしまう。すなわち、本来の目的であるCABAC処理の高速化の達成が困難である。
 本技術は、このような状況に鑑みてなされたものであり、画像の符号化処理や復号処理を高速に行うことができる画像符号化装置と画像復号装置およびその方法を提供することを目的とする。
 この技術の第1の側面は、シンタックス要素を二値化データに変換する二値化部と、前記シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて前記二値化データの算術符号化を並列して行う算術符号化処理部とを備える画像符号化装置にある。
 この技術においては、シンタックス要素(SyntaxElement)の二値化データの算術符号化に用いるコンテキスト変数を特定するためのコンテキストインデックスが並列処理単位内で重複しないように設定されて、設定されたコンテキストインデックスに応じてコンテキスト変数が選択される。並列処理数は、画像の解像度またはフレームレートに応じてスライス単位で設定される。また、並列処理数は、ブロック単位で直交変換を行うことにより得られた直交変換係数におけるゼロ係数の数に応じて、ブロック単位で設定される。なお、ブロック単位で並列処理数が設定されていない場合、スライス単位で設定された並列処理数が用いられる。この並列処理単位で、互いに異なるコンテキストインデックスに応じたコンテキスト変数を用いて二値化データの算術符号化が並列して行われる。また、シンタックス要素には、並列処理数を示す要素が含められる。コンテキストインデックスの設定は、直交変換の係数毎のインデックスとコンテキストインデックスの関係を示す割り当てテーブルを用いて行われる。また、割り当てテーブルでは、周波数が近傍する係数では、等しいコンテキストインデックスがより多く用いられるように、係数毎のインデックスとコンテキストインデックスが関係付けられている。
 この技術の第2の側面は、シンタックス要素を二値化データに変換する二値化工程と、前記シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定するコンテキストインデックス設定工程と、前記コンテキストインデックス設定工程で設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理工程と、前記並列処理単位毎に、前記選択されたコンテキスト変数を用いて前記二値化データの算術符号化を並列して行う算術符号化処理工程とを含む画像符号化方法にある。
 この技術の第3の側面は、復号するシンタックス要素に対応するコンテキスト変数を特定するためのコンテキストインデックスを、並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて符号化データの算術復号を並列して行う算術復号処理部と、前記算術復号を行うことによって得られた二値化データをシンタックス要素の値に変換する多値化部とを備える画像復号装置にある。
 この技術においては、復号するシンタックス要素に対応するコンテキストインデックスが、並列処理単位内で重複しないように設定される。この設定されたコンテキストインデックスに応じてコンテキスト変数を選択して、並列処理単位で、互いに異なるコンテキストインデックスに応じたコンテキスト変数を用いて二値化データの算術復号が並列して行われる。また、算術復号を行うことによって得られた二値化データは多値化データであるシンタックス要素の値に変換される。並列処理数は、符号化データに符号化されて含まれている並列処理数を示すシンタックス要素に基づいて、スライス単位やブロック単位で設定する。コンテキストインデックスの設定は、直交変換の係数毎のインデックスとコンテキストインデックスの関係を示す割り当てテーブルを用いて行われる。
 この技術の第4の側面は、復号するシンタックス要素に対応するコンテキストインデックスを、並列処理単位内で重複しないように設定するコンテキストインデックス設定工程と、前記コンテキストインデックス設定工程で設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理工程と、前記並列処理単位で、前記コンテキスト変数選択工程で選択されたコンテキスト変数を用いて符号化データの算術復号を並列して行う算術復号工程と、前記算術復号を行うことによって得られた二値化データをシンタックス要素に変換する多値化工程とを含む画像復号方法にある。
 この技術によれば、算術符号化や算術復号を並列して行う場合に、並列処理単位内で重複を生じないようにコンテキストインデックスを設定して、設定されたコンテキストインデックスに対応するコンテキスト変数を用いて算術符号化や算術復号が行われる。したがって、画像の符号化処理や復号処理を高速に行うことができるようになる。
処理の並列化を行う場合の従来の構成を説明するための図である。 マルチスライス手法を説明するための図である。 画像符号化装置の構成を例示した図である。 CABAC符号化器の構成を例示した図である。 画像符号化装置の動作を示すフローチャートである。 CABAC符号化器の動作を示すフローチャートである。 シンタックス要素「slice_parallel_processing_id」を設けたスライスヘッダシンタックスを例示した図である。 シンタックス要素「mb_parallel_processing_id」を設けたマクロブロックヘッダシンタックスを例示した図である。 画像復号装置の構成を例示した図である。 CABAC復号器の構成を例示した図である。 画像復号装置の動作を示すフローチャートである。 CABAC復号器の動作を示すフローチャートである。 レベルリストインデックス(LevelListIdx)を示した図である。 コンテキストインデックス割り当てテーブルを例示した図である。 並列処理数を「2」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示した図である。 並列処理数を「2」とした場合のコンテキストインデックスインクリメント(ctxIdxInc)の変化を示した図である。 並列処理数を「4」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示した図である。 並列処理数を「4」とした場合のコンテキストインデックスインクリメント(ctxIdxInc)の変化を示した図である。 並列処理数を「8」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示した図である。 並列処理数を「8」とした場合のコンテキストインデックスインクリメント(ctxIdxInc)の変化を示した図である。 並列処理数を「15」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示した図である。 並列処理数を「15」とした場合のコンテキストインデックスインクリメント(ctxIdxInc)の変化を示した図である。 並列処理を行わない場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示した図である。 並列処理を行わない場合のコンテキストインデックスインクリメント(ctxIdxInc)の変化を示した図である。 テレビジョン装置の概略構成を例示した図である。 携帯電話機の概略構成を例示した図である。 記録再生装置の概略構成を例示した図である。 撮像装置の概略構成を例示した図である。
 以下、本技術を実施するための形態について説明する。なお、説明は以下の順序で行う。
 1.画像符号化装置の構成
 2.可逆符号化部の構成
 3.画像符号化装置の動作
 4.可逆符号化部の動作
 5.画像復号装置の構成
 6.可逆復号部の構成
 7.画像復号装置の動作
 8.可逆復号部の動作
 9.並列処理の具体例
 10.ソフトウェア処理の場合
 11.電子機器に適用した場合
 <1.画像符号化装置の構成>
 図3は、画像符号化装置の構成を例示している。画像符号化装置10は、アナログ/ディジタル変換部(A/D変換部)11、画面並べ替えバッファ12、演算部13、直交変換部14、量子化部15、可逆符号化部16、蓄積バッファ17、レート制御部18を備えている。さらに、画像符号化装置10は、逆量子化部21、逆直交変換部22、演算部23、デブロッキングフィルタ24、フレームメモリ25、イントラ予測部31、動き予測・補償部32、予測画像・最適モード選択部33を備えている。
 A/D変換部11は、アナログの画像信号をディジタルの画像データに変換して画面並べ替えバッファ12に出力する。画面並べ替えバッファ12は、A/D変換部11から出力された画像データに対してフレームの並べ替えを行う。画面並べ替えバッファ12は、符号化処理に係るGOP(Group of Pictures)構造に応じてフレームの並べ替えを行い、並べ替え後の画像データを演算部13とレート制御部18およびイントラ予測部31と動き予測・補償部32に出力する。
 演算部13には、画面並べ替えバッファ12から出力された画像データと、後述する予測画像・最適モード選択部33で選択された予測画像データが供給される。演算部13は、画面並べ替えバッファ12から出力された入力画像の画像データと予測画像・最適モード選択部33から供給された予測画像の画像データとの差分である差分画像の画像データ(予測誤差データ)を算出して、直交変換部14に出力する。
 直交変換部14は、演算部13から出力された予測誤差データに対して、離散コサイン変換(DCT;Discrete Cosine Transform)、カルーネン・レーベ変換等の直交変換処理を行う。直交変換部14は、直交変換処理を行うことにより得られた変換係数データを量子化部15に出力する。
 量子化部15には、直交変換部14から出力された変換係数データと、後述するレート制御部18から量子化パラメータ(量子化スケール)が供給されている。量子化部15は変換係数データの量子化を行い、量子化データを可逆符号化部16と逆量子化部21に出力する。また、量子化部15は、レート制御部18で設定された量子化パラメータに応じて量子化データのビットレートを変化させる。
 可逆符号化部16には、量子化部15から量子化データ、イントラ予測部31から予測モード情報や動き予測・補償部32から予測モード情報と動きベクトル情報等が供給される。また、予測画像・最適モード選択部33から最適モードがイントラ予測であるかインター予測であるかを示す情報が供給される。なお、予測モード情報には、イントラ予測またはインター予測に応じて、予測モードやブロックサイズ情報等が含まれる。
 可逆符号化部16は、量子化データに対して例えば可変長符号化または算術符号化等により可逆符号化処理を行い、符号化ストリームを生成して蓄積バッファ17に出力する。また、可逆符号化部16は、最適モードがイントラ予測である場合、イントラ予測部31から供給された予測モード情報の可逆符号化を行う。また、可逆符号化部16は、最適モードがインター予測である場合、動き予測・補償部32から供給された予測モード情報や動きベクトル情報等の可逆符号化を行う。さらに、可逆符号化部16は、量子化パラメータに関する情報の可逆符号化を行う。
 蓄積バッファ17は、可逆符号化部16からの符号化ストリームを蓄積する。また、蓄積バッファ17は、蓄積した符号化ストリームを伝送路に応じた伝送速度で出力する。
 レート制御部18は、蓄積バッファ17の空き容量の監視を行い、空き容量が少なくなっている場合には量子化データのビットレートが低下し、空き容量が十分大きい場合には量子化データのビットレートが高くなるように量子化パラメータを設定して量子化部15に出力する。また、レート制御部18は、符号化歪み制御部(図示せず)からの制御信号に基づき、符号化歪み情報に応じて量子化パラメータの調整や制限を行う。レート制御部18は、量子化パラメータ情報の符号化効率を高めるために、量子化パラメータの制限に関する情報を可逆符号化部16に供給してもよい。
 逆量子化部21は、量子化部15から供給された量子化データの逆量子化処理を行う。逆量子化部21は、逆量子化処理を行うことで得られた変換係数データを逆直交変換部22に出力する。
 逆直交変換部22は、逆量子化部21から供給された変換係数データの逆直交変換処理を行い、得られたデータを演算部23に出力する。
 演算部23は、逆直交変換部22から供給されたデータと予測画像・最適モード選択部33から供給された予測画像データを加算してローカルデコード画像の画像データを生成して、デブロッキングフィルタ24とイントラ予測部31に出力する。なお、演算部23で生成されたローカルデコード画像は、イントラ予測またはインター予測において参照画像として用いられる。
 デブロッキングフィルタ24は、画像の符号化時に生じるブロック歪みを減少させるためのフィルタ処理を行う。デブロッキングフィルタ24は、演算部23から供給された画像データからブロック歪みを除去するフィルタ処理を行い、フィルタ処理後の画像データをフレームメモリ25に記憶させる。
 イントラ予測部31は、画面並べ替えバッファ12から供給された符号化対象画像の入力画像データと演算部23から供給された画像データ(参照画像データ)を用いて、候補となる全てのイントラ予測モードで予測を行い、最適イントラ予測モードを決定する。イントラ予測部31は、例えば各イントラ予測モードでコスト関数値を算出して、算出したコスト関数値に基づき符号化効率が最良となるイントラ予測モードを最適イントラ予測モードとする。イントラ予測部31は、最適イントラ予測モードで生成された予測画像データと最適イントラ予測モードでのコスト関数値を予測画像・最適モード選択部33に出力する。さらに、イントラ予測部31は、最適イントラ予測モードを示す予測モード情報を可逆符号化部16に出力する。
 動き予測・補償部32は、画面並べ替えバッファ12から供給された符号化対象画像の入力画像データとフレームメモリ25から読み出した参照画像データを用いて、候補となる全てのインター予測モードで予測を行い、最適インター予測モードを決定する。動き予測・補償部32は、例えば各インター予測モードでコスト関数値を算出して、算出したコスト関数値に基づき符号化効率が最良となるインター予測モードを最適インター予測モードとする。動き予測・補償部32は、最適インター予測モードで生成された予測画像データと最適インター予測モードでのコスト関数値を予測画像・最適モード選択部33に出力する。さらに、動き予測・補償部32は、最適インター予測モードに関する予測モード情報と動きベクトル情報を可逆符号化部16に出力する。
 予測画像・最適モード選択部33は、イントラ予測部31から供給されたコスト関数値と動き予測・補償部32から供給されたコスト関数値を比較して、コスト関数値が少ない方を、符号化効率が最良となる最適モードとして選択する。また、予測画像・最適モード選択部33は、最適モードで生成した予測画像データを演算部13と演算部23に出力する。さらに、予測画像・最適モード選択部33は、最適モードがイントラ予測モードであるかインター予測モードであるかを示す情報を可逆符号化部16に出力する。なお、予測画像・最適モード選択部33は、スライス単位でイントラ予測またはインター予測の切り替えを行う。また、予測画像・最適モード選択部33は、符号化歪み制御部からの制御信号に基づき、符号化歪み情報に基づいて最適モードを指定する処理を行う。
 <2.可逆符号化部の構成>
 図4は、可逆符号化部16においてCABAC符号化処理を行うCABAC符号化器の構成を例示している。CABAC符号化器160は、二値化部161、コンテキストインデックス(ctxIdx)設定部162、コンテキスト変数選択処理部163、算術符号化処理部164、符号化結果選択部165を備えている。さらに、CABAC符号化器160には、並列処理数設定部167が設けられている。
 二値化部161は、差分動きベクトルや、直交変換係数、予測モード等のシンタックスを入力し、規格によって定められた二値化処理を行い、二値化データを生成して、算術符号化部164-0~164-Nに出力する。
 コンテキストインデックス設定部162は、シンタックスに基づきコンテキストインデックス(ctxIdx)を設定してコンテキスト変数選択処理部163に出力する。コンテキストインデックス(ctxIdx)とは、コンテキスト変数を選択するための情報であり、コンテキスト変数では、発生確率が高い優勢シンボル(most probable symbol)とその優勢シンボルの発生確率を示す確率テーブルの番号(pStateIdx)が示される。
 コンテキスト変数選択処理部163では、変数選択部163-0~163-Nが設けられている。ここで、並列処理数を「M」とする場合、「N=M-1」とする。なお、並列処理数は、固定の並列処理数または並列処理数設定部167によって例えばスライス単位やブロック単位で設定させる。
 変数選択部163-0は、コンテキスト変数テーブルからコンテキストインデックス(ctxIdx-0)に対応したコンテキスト変数を選択して算術符号化処理部164に出力する。同様に、変数選択部163-1~163-Nは、コンテキストインデックス(ctxIdx-1~ctxIdx-N)に対応したコンテキスト変数を選択して算術符号化処理部164に出力する。コンテキスト変数テーブルでは、コンテキストインデックス毎に、コンテキスト変数すなわち優勢シンボルと優勢シンボルの確率テーブルの番号が示されている。
 算術符号化処理部164では、算術符号化部164-0~164-Nが設けられている。算術符号化部164-0~164-Nは、二値化データとコンテキスト変数に基づいて算術符号化処理を行う。例えば算術符号化部164-0は、並列処理単位の最初の係数を示す二値化データと変数選択部163-0で選択されたコンテキスト変数を用いて算術符号化を行い、算術符号化結果を符号化結果選択部165に出力する。また、算術符号化部164-0は、算術符号化結果を変数選択部163-0に出力して、変数選択部163-0で選択されているコンテキスト変数における確率テーブルの番号を更新する。同様に、算術符号化部164-1~164-Nは、並列処理単位内の各係数の二値化データと、変数選択部163-1~163-Nで選択されたコンテキスト変数を用いて算術符号化を行い、算術符号化結果を符号化結果選択部165に出力する。また、算術符号化部164-1~164-Nは、算術符号化結果を変数選択部163-1~163-Nに出力して、選択されているコンテキスト変数における確率テーブルの番号を更新する。符号化結果選択部165は、算術符号化部164-0~164-Nから供給された算術符号化結果を算術符号化部164-0から順に選択して符号化ストリームを生成して出力する。
 並列処理数設定部167は、算術符号化を並列して行う場合の並列処理を例えば画像の解像度またはフレームレートに応じてスライス単位で設定する。また、並列処理数設定部167は、ブロック単位で行われた直交変換におけるゼロ係数の数に応じて並列処理をブロック単位で設定してもよい。さらに、並列処理数設定部167は、並列処理数を、スライス単位とブロック単位の少なくとも何れかの単位で設定して、ブロック単位で並列処理数が設定されていない場合に、スライス単位で設定された並列処理数を用いるようにしてもよい。並列処理数設定部167は、設定した並列処理数で算術符号化が行われるようにCABAC符号化器160を動作させる。なお、固定の並列処理数で算術符号化を行う場合には、並列処理数設定部167を設けていなくともよい。
 <3.画像符号化装置の動作>
 次に、画像符号化装置の動作について、図5に示すフローチャートを用いて説明する。ステップST11において、A/D変換部11は入力された画像信号をA/D変換する。
 ステップST12において画面並べ替えバッファ12は、画像並べ替えを行う。画面並べ替えバッファ12は、A/D変換部11より供給された画像データを記憶し、各ピクチャの表示する順番から符号化する順番への並べ替えを行う。
 ステップST13において演算部13は、予測誤差データの生成を行う。演算部13は、ステップST12で並べ替えられた入力画像の画像データと予測画像・最適モード選択部33で選択された予測画像の画像データとの差分を算出して、差分画像の画像データすなわち予測誤差データを生成する。予測誤差データは、元の画像データに比べてデータ量が小さい。したがって、画像をそのまま符号化する場合に比べて、データ量を符号化することができる。
 ステップST14において直交変換部14は、直交変換処理を行う。直交変換部14は、演算部13から供給された予測誤差データを直交変換する。具体的には、予測誤差データに対して離散コサイン変換、カルーネン・レーベ変換等の直交変換が行われ、変換係数データを出力する。
 ステップST15において量子化部15は、量子化処理を行う。量子化部15は、変換係数データを量子化する。量子化に際しては、後述するステップST25の処理で説明されるように、レート制御が行われる。
 ステップST16において逆量子化部21は、逆量子化処理を行う。逆量子化部21は、量子化部15により量子化された変換係数データを量子化部15の特性に対応する特性で逆量子化する。
 ステップST17において逆直交変換部22は、逆直交変換処理を行う。逆直交変換部22は、逆量子化部21により逆量子化された変換係数データを直交変換部14の特性に対応する特性で逆直交変換する。
 ステップST18において演算部23は、参照画像データの生成を行う。演算部23は、予測画像・最適モード選択部33から供給された予測画像データと、この予測画像と対応する位置の逆直交変換後のデータを加算して、ローカルデコード画像の画像データ(参照画像データ)を生成する。
 ステップST19においてデブロッキングフィルタ24は、デブロッキングフィルタ処理を行う。デブロッキングフィルタ24は、演算部23より出力された復号画像データをフィルタリングしてブロック歪みを除去する。
 ステップST20においてフレームメモリ25は、復号画像データを記憶する。フレームメモリ25は、デブロッキングフィルタでフィルタリングが行われた復号画像データを記憶する。
 ステップST21においてイントラ予測部31と動き予測・補償部32は、それぞれ予測処理を行う。すなわち、イントラ予測部31は、イントラ予測モードのイントラ予測処理を行い、動き予測・補償部32は、インター予測モードの動き予測・補償処理を行う。予測処理により、候補となる全ての予測モードでの予測処理がそれぞれ行われ、候補となる全ての予測モードでのコスト関数値がそれぞれ算出される。そして、算出されたコスト関数値に基づいて、最適イントラ予測モードと最適インター予測モードが選択され、選択された予測モードで生成された予測画像とそのコスト関数および予測モード情報が予測画像・最適モード選択部33に供給される。
 ステップST22において予測画像・最適モード選択部33は、予測画像データの選択を行う。予測画像・最適モード選択部33は、イントラ予測部31および動き予測・補償部32より出力された各コスト関数値に基づいて、符号化効率が最良となる最適モードを決定する。また、予測画像・最適モード選択部33は、符号化歪み制御部からの制御信号に基づき、符号化/復号処理によって生じる画質劣化が大きい場合は、最適イントラ予測モードを最適モードとして選択する。さらに、予測画像・最適モード選択部33は、決定した最適モードの予測画像データを、演算部13と演算部23に出力する。この予測画像データが、上述したように、ステップST13,ST18の演算に利用される。
 ステップST23において可逆符号化部16は、可逆符号化処理を行う。可逆符号化部16は、量子化部15より出力された量子化データを可逆符号化する。すなわち、量子化データに対して可変長符号化や算術符号化等の可逆符号化が行われて、データ符号化される。また、可逆符号化部16は、ステップST25で選択された予測画像データに対応する予測モード情報等の可逆符号化を行い、量子化データを可逆符号化して生成された符号化ストリームに、予測モード情報等の可逆符号化データが含められる。
 ステップST24において蓄積バッファ17は、蓄積処理を行う。蓄積バッファ17は、可逆符号化部16から出力される符号化ストリームを蓄積する。この蓄積バッファ17に蓄積された符号化ストリームは、適宜読み出されて伝送路を介して復号側に伝送される。
 ステップST25においてレート制御部18は、レート制御を行う。レート制御部18は、蓄積バッファ17で符号化ストリームを蓄積する場合、オーバーフローまたはアンダーフローが蓄積バッファ17で発生しないように、量子化パラメータQPを設定して量子化部15に出力することで量子化動作のレートを制御する。また、レート制御部18は、符号化歪み制御部からの制御信号に基づき、符号化歪み情報に応じて量子化パラメータQPの調整や制限等を行う。
 <4.可逆符号化部の動作>
 次に、可逆符号化部におけるCABAC符号化器の動作について、並列処理数設定部が設けられている場合を説明する。可逆符号化部は、解像度やフレームレートが高いほど、符号化ストリームの生成処理を高速化する必要がある。したがって、CABAC符号化器は、スライス単位で並列処理数を設定して例えば解像度やフレームレートが高い動画像の場合、並列処理可能な数を大きくして、高速処理を優先させる。また、解像度やフレームレートが高くなるに伴い、並列処理可能な数を増やして高速処理をさらに優先させるようにしてもよい。
 また、並列処理数は、マクロブロック単位で切り替え可能としてもよい。例えば、可逆符号化部は、マクロブロック内で係数値が「0」である係数(ゼロ係数)の数をカウントして、ゼロ係数が多い場合は高速化の処理は不要であるので符号化効率を優先し、ゼロ係数が少ない場合は、符号化効率より高速化処理を優先にする。
 図6は、CABAC符号化器の動作を示すフローチャートである。ステップST31でCABAC符号化器160は、解像度やフレームレートが高いか判別する。CABAC符号化器160は、画像符号化装置10のシステム制御部等によって示された動画像の解像度やフレームレートが、所定値よりも高い場合にはステップST32に進み、高くない場合にはステップST33に進む。
 ステップST32でCABAC符号化器160は、並列処理数を大きな値に設定する。CABAC符号化器160は、解像度やフレームレートが所定値よりも高いことから、高速処理を優先させる。具体的には、スライスヘッダシンタックスに並列処理数を示すシンタックス要素「slice_parallel_processing_id」を設けて、このシンタックス要素「slice_parallel_processing_id」の数値を大きな値とする。すなわち、CABAC符号化器160は、符号化効率を優先させる場合よりもシンタックス要素「slice_parallel_processing_id」の数値を大きな値として高速処理を優先させてステップST34に進む。
 ステップST33でCABAC符号化器160は、並列処理数を小さな値に設定する。CABAC符号化器160は、解像度やフレームレートが所定値よりも高くないことから、符号化効率を優先させる。具体的には、スライスヘッダシンタックスにシンタックス要素「slice_parallel_processing_id」を設けて、このシンタックス要素「slice_parallel_processing_id」の数値を小さな値に設定する。すなわち、CABAC符号化器160は、高速処理を優先させる場合よりもシンタックス要素「slice_parallel_processing_id」の数値を小さな値として符号化効率を優先させてステップST34に進む。
 図7は、シンタックス要素「slice_parallel_processing_id」を設けたスライスヘッダシンタックスの一部を例示している。例えば、スライスヘッダシンタックスでは、シンタックス要素「pic_parameter_set_id」の次に、シンタックス要素「slice_parallel_processing_id」を設けている。
 ステップST34でCABAC符号化器160は、マクロブロック内のゼロ係数の数が所定数以上であるか判別する。CABAC符号化器160は、画像符号化装置10のシステム制御部によって示されたゼロ係数の数が所定数以上の場合にはステップST35に進み、所定数未満である場合にはステップST36に進む。
 ステップST35でCABAC符号化器160は、並列処理数を小さな値に設定する。CABAC符号化器160は、ゼロ係数が所定数よりも多いことから、符号化効率を優先させる。具体的には、マクロブロックヘッダシンタックスに並列処理数を示すシンタックス要素「mb_parallel_processing_id」を設けて、このシンタックス要素「mb_parallel_processing_id」の数値を小さな値に設定する。すなわち、CABAC符号化器160は、高速処理を優先させる場合よりもシンタックス要素「mb_parallel_processing_id」の数値を小さな値として符号化効率を優先させてステップST37に進む。
 ステップST36でCABAC符号化器160は、並列処理数を大きな値に設定する。CABAC符号化器160は、ゼロ係数が所定数よりも多くないことから、高速処理を優先させる。具体的には、マクロブロックヘッダシンタックスにシンタックス要素「mb_parallel_processing_id」を設けて、このシンタックス要素「mb_parallel_processing_id」の数値を大きな値に設定する。すなわち、CABAC符号化器160は、符号化効率を優先させる場合よりもシンタックス要素「mb_parallel_processing_id」の数値を大きな値に設定して高速処理を優先させてステップST37に進む。
 図8は、シンタックス要素「mb_parallel_processing_id」を設けたマクロブロックヘッダシンタックスを例示している。例えば、マクロブロックヘッダシンタックスでは、シンタックス要素「mb_type」の次にシンタックス要素「mb_parallel_processing_id」を設けている。また、シンタックス要素「slice_parallel_processing_id」とシンタックス要素「mb_parallel_processing_id」を設ける場合、何れかのシンタックス要素で示された並列処理数で処理を行うようにする。例えば、シンタックス要素の選択を行うための要素「mb_parallel_setting」を設けて、要素「mb_parallel_setting」が「1」である場合、シンタックス要素「mb_parallel_processing_id」で示された並列処理数で処理を行う。また、要素「mb_parallel_setting」が「0」である場合は、シンタックス要素「slice_parallel_processing_id」の並列処理数で処理を行うようにする。
 ステップST37でCABAC符号化器160は、並列処理数に応じてコンテキストインデックス(ctxIdx)割り当てテーブルを選択する。コンテキストインデックス割り当てテーブルは、並列処理単位内で重複を生じないようにコンテキストインデックスが予めテーブル化されている。なお、コンテキストインデックス割り当てテーブルの具体例については後述する。
 CABAC符号化器160は、並列処理数に応じて選択されたコンテキストインデックス割り当てテーブルを用いて、ステップST38~ステップST41の処理を並列して行う。なお、上述のように並列処理数を「M」として、「N=M-1」とする。
 ステップST38-0でCABAC符号化器160は、レベルリストインデックス(LevelListIdx)を設定してステップST39-0に進む。CABAC符号化器160は、1回目の並列処理を行う場合、レベルリストインデックス(LevelListIdx)を「0」に設定する。その後、並列処理が繰り返される毎に、並列処理数に応じてレベルリストインデックス(LevelListIdx)を更新する。例えば並列処理数が「2」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,2,4,・・・62」の順に更新する。並列処理数が「4」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,4,8,・・・60」の順に更新する。並列処理数が「15」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,15,30,・・・60」の順に更新する。
 ステップST39-0でCABAC符号化器160は、レベルリストインデックス(LevelListIdx)に対応するコンテキストインデックス(ctxIdx)を決定する。CABAC符号化器160は、レベルリストインデックス(LevelListIdx)に割り当てられているコンテキストインデックスインクリメント(ctxIdxInc)にコンテキストインデックスオフセット(ctxIdxOffset)を加算して、レベルリストインデックス(LevelListIdx)に対応するコンテキストインデックス(ctxIdx)とする。
 ステップST40-0でCABAC符号化器160は、コンテキストインデックス(ctxIdx)に対応するコンテキスト変数の呼び出しを行う。CABAC符号化器160は、ステップST39-0で決定したコンテキストインデックス(ctxIdx)に対応するコンテキスト変数をステップST37で選択したコンテキスト変数テーブルから呼び出す。
 ステップST41-0でCABAC符号化器160は、算術符号化を行う。CABAC符号化器160は、ステップST40-0で呼び出したコンテキスト変数を用いて算術符号化を行う。
 CABAC符号化器160は、ステップST38-1において、ステップST38-0で設定したレベルリストインデックス(LevelListIdx)に「1」を加算して、レベルリストインデックス(LevelListIdx)とする。同様に、CABAC符号化器160は、ステップST38-Nまでのレベルリストインデックス(LevelListIdx)の設定を行う。例えばステップST38-Nでは、ステップST38-1で設定したレベルリストインデックス(LevelListIdx)に「N=(M-1)」を加算して、レベルリストインデックス(LevelListIdx)を設定する。このように、ステップST38-1~38-Nでレベルリストインデックス(LevelListIdx)を設定して、ステップST39-1~39-NからステップST41-1~41-Nの処理を行うと、並列処理数分の算術符号化を並列して行うことができる。
 ステップST42でCABAC符号化器160は、コンテキスト変数の更新を行う。CABAC符号化器160は、ステップST41-0~41-Nの算術符号化結果に基づき選択されているコンテキスト変数における確率テーブルの番号を更新してステップST43に進む。
 ステップST43でCABAC符号化器160は、係数処理が終了したか判別する。CABAC符号化器160は、1マクロブロック分の係数について算術符号化が完了していない場合にはステップST37に戻り、1マクロブロック分の係数について算術符号化が完了した場合にはステップST44に進む。
 ステップST44でCABAC符号化器160は、マクロブロック処理が終了したか判別する。CABAC符号化器160は、スライス内の各マクロブロックについて算術符号化が完了していない場合にはステップST34に戻って次のマクロブロックについての処理を行い、完了した場合にはステップST45に進む。
 ステップST45でCABAC符号化器160は、スライス処理が終了したか判別する。CABAC符号化器160は、フレーム内の各スライスについて算術符号化が完了していない場合にはステップST31に戻って次のスライスついての処理を行う。
 このように、解像度やフレームレートが高い場合には、並列処理数を増やし、高速化処理を優先させることで、符号化ストリームの生成を高速に行うことができる。また、スライス毎の切り替えだけでなく、マクロブロック毎の切り替えにも対応する。すなわち、マクロブロック内のゼロ係数が多い場合、高速化の処理は不要であるので、並列処理数を少なくして符号化効率優先させて、ゼロ係数が少ない場合に並列処理数を増やして高速化処理を優先させる。このように、マクロブロック毎に並列処理数を切り替え可能とすることで、スライス毎の並列処理数の切り替えに比べて、より詳細な制御が可能となる。
 また、並列処理数を示すシンタックス要素を符号化ストリームに含めることで、後述する画像復号装置では、並列処理数を示すシンタックス要素の情報に基づき、画像符号化装置と等しい並列処理数で算術復号処理を行うことができる。
 さらに、画像の解像度やフレームレートに基づき並列処理数を設定する場合、画像符号化装置と画像復号装置で等しいルールを用いて並列処理数を設定すれば、並列処理数を示すシンタックス要素を符号化ストリームに含めることなく、画像復号装置は、画像符号化装置と等しい並列処理数で算術復号処理を行うことができるので、符号化ストリームのデータ量を削減することが可能となる。
 <5.画像復号装置の構成>
 次に、画像符号化装置から出力される符号化ストリームの復号処理を行う画像復号装置について説明する。入力画像を符号化して生成された符号化ストリームは、所定の伝送路や記録媒体等を介して画像復号装置に供給されて復号される。
 図9は、符号化ストリームの復号処理を行う画像復号装置の構成を例示している。画像復号装置50は、蓄積バッファ51、可逆復号部52、逆量子化部53、逆直交変換部54、演算部55、デブロッキングフィルタ56、画面並べ替えバッファ57、ディジタル/アナログ変換部(D/A変換部)58を備えている。また、画像復号装置50は、フレームメモリ61、イントラ予測部71、動き補償部72、セレクタ73を備えている。
 蓄積バッファ51は、伝送されてきた符号化ストリームを蓄積する。可逆復号部52は、蓄積バッファ51より供給された符号化ストリームを、図4に示すCABAC符号化器160の符号化方式に対応する方式で復号する。
 可逆復号部52は、情報取得部として動作を行い符号化ストリームから種々の情報を取得する。例えば、可逆復号部52は、符号化ストリームを復号して得られた予測モード情報等をイントラ予測部71や動き補償部72に出力する。また、可逆復号部52は、符号化ストリームを復号して得られた量子化パラメータ情報と量子化データを逆量子化部53に出力する。また、可逆復号部52は、量子化パラメータの範囲が制限されて量子化パラメータ情報の符号化が行われている場合、符号化歪み制御部(図示せず)から供給された制御信号を利用して、量子化パラメータ情報の復号を行う。
 逆量子化部53は、量子化パラメータを用いて、図3に示す量子化部15の量子化方式に対応する方式で、可逆復号部52から供給された量子化データの逆量子化を行う。逆直交変換部54は、図3に示す直交変換部14の直交変換方式に対応する方式で逆量子化部53の出力を逆直交変換して演算部55に出力する。
 演算部55は、逆直交変換後のデータとセレクタ73から供給される予測画像データを加算してデコード画像の画像データを生成してデブロッキングフィルタ56とイントラ予測部71に出力する。
 デブロッキングフィルタ56は、画像の符号化時に生じるブロック歪みを減少させるためのフィルタ処理を行う。デブロッキングフィルタ56は、演算部55から供給された画像データからブロック歪みを除去するフィルタ処理を行い、フィルタ処理後の画像データを画面並べ替えバッファ57とフレームメモリ61に出力する。
 画面並べ替えバッファ57は、画像の並べ替えを行う。すなわち、図3に示す画面並べ替えバッファ12により符号化の順番のために並べ替えられたフレームの順番が、元の表示の順番に並べ替えられて、D/A変換部58に出力される。
 D/A変換部58は、画面並べ替えバッファ57から供給された画像データをD/A変換し、図示せぬディスプレイに出力することでデコード画像を表示させる。
 イントラ予測部71は、可逆復号部52から供給された予測モード情報と演算部55から供給された復号画像データに基づいて予測画像データの生成を行い、生成した予測画像データをセレクタ73に出力する。
 動き補償部72は、可逆復号部52から供給された予測モード情報と動きベクトル情報に基づきフレームメモリ61から読み出した画像データを用いて動き補償を行い、予測画像データを生成する。動き補償部72は、生成した予測画像データをセレクタ73に出力する。
 セレクタ73は、可逆復号部52から供給された予測モード情報に基づき、イントラ予測である場合はイントラ予測部71、インター予測である場合は動き補償部72を選択する。セレクタ73は、選択されたイントラ予測部71または動き補償部72で生成された予測画像データを演算部55に出力する。
 <6.可逆復号部の構成>
図10は、可逆復号部52においてCABAC復号処理を行うCABAC復号器の構成を例示している。CABAC復号器520は、蓄積バッファ51から符号化データを受け取り、二値化データに復号した後に多値化データであるシンタックス要素の値に変換する。CABAC復号器520は、コンテキストインデックス設定部521、コンテキスト変数選択処理部522、算術復号処理部523、復号結果選択部524、多値化部525、レジスタ526、並列処理数設定部527を備えている。
 コンテキストインデックス設定部521は、レジスタ526に記憶されているシンタックス要素に関する情報に基づき、次に復号するシンタックス要素のコンテキストインデックス(ctxIdx)を設定してコンテキスト変数選択処理部522に出力する。
 コンテキスト変数選択処理部522では、変数選択部522-0~522-Nが設けられている。ここで、符号化ストリームで示されている並列処理数を「M」とする場合、「N=M-1」とする。なお、並列処理数は、画像符号化装置で固定されていることが明らかな場合には画像符号化装置と等しい固定の並列処理数とする。また、画像符号化装置に並列処理数設定部を設けて並列処理数を設定する場合、並列処理数設定部527において並列処理数の設定を行う。
 変数選択部522-0は、コンテキスト変数テーブルからコンテキストインデックス(ctxIdx-0)に対応したコンテキスト変数を選択して算術復号処理部523に出力する。同様に、変数選択部522-1~522-Nは、コンテキストインデックス(ctxIdx-1~ctxIdx-N)に対応したコンテキスト変数を選択して算術復号処理部523に出力する。
 算術復号処理部523では、算術復号部523-0~523-Nが設けられている。算術復号部523-0~523-Nは、蓄積バッファ51から入力された符号化データを二値化データに復号する。例えば、算術復号部523-0は、1つ係数の符号化データを復号する際、変数選択部522-0から供給されたコンテキスト変数に基づいて復号を行い、算術復号結果である二値化データを復号結果選択部524に出力する。また、算術復号部523-0は、算術復号結果を変数選択部522-0に出力して、変数選択部522-0で選択されているコンテキスト変数における確率テーブルの番号を更新する。同様に、算術復号部523-1~523-Nは、1つの係数の符号化データを復号する際、変数選択部522-1~522-Nから供給されたコンテキスト変数に基づいて復号を行い、算術復号結果である二値化データを復号結果選択部524に出力する。また、算術復号部523-1~523-Nは、算術復号結果を変数選択部522-1~522-Nに出力して、変数選択部522-1~522-Nで選択されているコンテキスト変数における確率テーブルの番号を更新する。
 復号結果選択部524は、算術復号部523-0~523-Nから供給された算術復号結果を順に選択して多値化部525に出力する。
 多値化部525は、CABAC符号化器160の二値化部161に対応した処理を行い、復号結果選択部524から供給された二値化データを多値化することで、符号化前の多値化データすなわちシンタックス要素の値を出力する。また、多値化部525は、多値化を行うことにより生成されたシンタックス要素において、次の復号でコンテキストインデックス(ctxIdx)を設定するために用いる情報をレジスタ526に出力する。さらに、多値化部525は、シンタックス要素の値を並列処理数設定部527に出力する。
 レジスタ526は、多値化部525から供給された情報を保持して、保持している情報をコンテキストインデックス設定部521に出力する。
 並列処理数設定部527は、算術復号の並列処理数を設定する。並列処理数設定部527は、例えば符号化データに含まれている並列処理数を示すシンタックス要素に基づいて並列処理数を決定する。また、並列処理数設定部527は、復号する画像の解像度またはフレームレートに応じてスライス単位で設定する。並列処理数設定部527は、設定した並列処理数で算術復号が行われるようにCABAC復号器520を動作させる。
 <7.画像復号装置の動作>
 次に、図11のフローチャートを参照して、画像復号装置50の動作について説明する。ステップST51で蓄積バッファ51は、供給された符号化ストリームを蓄積する。ステップST52で可逆復号部52は、可逆復号処理を行う。可逆復号部52は、蓄積バッファ51から供給される符号化ストリームを復号する。すなわち、図4に示すCABAC符号化器160により符号化された各ピクチャの量子化データが得られる。また、可逆復号部52、符号化ストリームに含まれている予測モード情報等の可逆復号を行い、得られた予測モード情報がイントラ予測モードに関する情報である場合、予測モード情報をイントラ予測部71に出力する。また、可逆復号部52は、予測モード情報がインター予測モードに関する情報である場合、予測モード情報や動きベクトル情報を動き補償部72に出力する。
 ステップST53において逆量子化部53は、逆量子化処理を行う。逆量子化部53は、可逆復号部52により復号された量子化データを、図3に示す量子化部15の特性に対応する特性で逆量子化する。
 ステップST54において逆直交変換部54は、逆直交変換処理を行う。逆直交変換部54は、逆量子化部53により逆量子化された変換係数データを、図3に示す直交変換部14の特性に対応する特性で逆直交変換する。
 ステップST55において演算部55は、復号画像データの生成を行う。演算部55は、逆直交変換処理を行うことにより得られたデータと、後述するステップST59で選択された予測画像データを加算して復号画像データを生成する。これにより元の画像が復号される。
 ステップST56においてデブロッキングフィルタ56は、フィルタ処理を行う。デブロッキングフィルタ56は、演算部55より出力された復号画像データをフィルタリングしてブロック歪みを除去する。
 ステップST57においてフレームメモリ61は、データを記憶する。フレームメモリ61は、デブロッキングフィルタでフィルタリングが行われた復号画像データを記憶する。
 ステップST58においてイントラ予測部71と動き補償部72は、予測画像データの生成を行う。イントラ予測部71と動き補償部72は、可逆復号部52から供給される予測モード情報に対応してそれぞれ予測画像データの生成を行う。
 すなわち、可逆復号部52からイントラ予測の予測モード情報が供給された場合、イントラ予測部71は、予測モード情報に基づいて予測画像データを生成する。また、可逆復号部52からインター予測の予測モード情報が供給された場合、動き補償部72は、予測モード情報と動きベクトル情報に基づき動き補償を行い、予測画像データを生成する。
 ステップST59において、セレクタ73は予測画像データの選択を行う。セレクタ73は、イントラ予測部71から供給された予測画像データと動き補償部72から供給された予測画像データの選択を行い、選択した予測画像データを演算部55に供給して、ステップST55において逆直交変換部54の出力と加算させる。また、セレクタ73は、符号化歪み制御部からの制御信号に基づき、符号化/復号処理によって生じる画質劣化が大きい場合は、イントラ予測部71から供給された予測画像データを選択する。
 ステップST60において画面並べ替えバッファ57は、画像並べ替えを行う。すなわち画面並べ替えバッファ57は、図3に示す画像符号化装置10の画面並べ替えバッファ12により符号化のために並べ替えられたフレームの順序が、元の表示の順序に並べ替えられる。
 ステップST61において、D/A変換部58は、画面並べ替えバッファ57からの画像データをD/A変換する。この画像が図示せぬディスプレイに出力され、画像が表示される。
 <8.可逆復号部の動作>
 図12は可逆復号部におけるCABAC復号器の動作を示すフローチャートである。ステップST71でCABAC復号器520は、スライスヘッダから並列処理数を取得する。CABAC復号器520は、スライスヘッダ(slice_Header)のシンタックスから並列処理数N(parallel_processing_id)を取得する。
 ステップST72でCABAC復号器520は、マクロブロックヘッダから並列処理数を取得する。CABAC復号器520は、マクロブロックヘッダ(mb_Header)のシンタックスから並列処理数N(mb_parallel_processing_id)を取得する。
 ステップST73でCABAC復号器520は、並列処理数の決定および次のコンテキストインデックス(ctxIdx)とレベルリストインデックス(LevelListIdx)の設定を行う。可逆復号部52は、スライスヘッダから取得した並列処理数の情報に基づき、並列処理数を決定する。また、スライス内のマクロブロックで、マクロブロックヘッダから並列処理数を示す情報を取得している場合には、この情報に基づき並列処理数を決定する。また、CABAC復号器520は、次に復号を行うコンテキストインデックスとレベルリストインデックスを設定する。
 ステップST74でCABAC復号器520は、並列処理数に応じてコンテキストインデックス(ctxIdx)割り当てテーブルを選択する。CABAC復号器520は、CABAC符号化器160と同様に、並列処理数に応じてコンテキストインデックス割り当てテーブルの選択を行う。
 その後、CABAC復号器520は、並列処理数に応じて、ステップST75~ステップST78の処理を並列して行う。
 ステップST75-0でCABAC復号器520は、レベルリストインデックス(LevelListIdx)を設定してステップST76-0に進む。CABAC符号化器160は、1回目の並列処理を行う場合、レベルリストインデックス(LevelListIdx)を「0」に設定する。その後、並列処理が繰り返される毎に、並列処理数に応じてレベルリストインデックス(LevelListIdx)を更新する。例えば並列処理数が「2」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,2,4,・・・62」の順に更新する。並列処理数が「2」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,2,4,・・・60」の順に更新する。並列処理数が例えば「15」である場合、並列処理が繰り返される毎にレベルリストインデックス(LevelListIdx)を「0,15,30,・・・60」の順に更新する。
 ステップST76-0でCABAC復号器520は、コンテキストインデックス(ctxIdx)を決定する。CABAC復号器520は、レベルリストインデックス(LevelListIdx)に割り当てられているコンテキストインデックスインクリメント(ctxIdxInc)にコンテキストインデックスオフセット(ctxIdxOffset)を加算して、レベルリストインデックス(LevelListIdx)に対応するコンテキストインデックス(ctxIdx)とする。
 ステップST77-0でCABAC復号器520は、コンテキストインデックス(ctxIdx)に対応するコンテキスト変数の呼び出しを行う。CABAC復号器520は、ステップST76-0で決定したコンテキストインデックス(ctxIdx)に対応するコンテキスト変数をテーブルから呼び出す。
 ステップST78-0でCABAC復号器520は、算術復号を行う。CABAC復号器520は、ステップST77-0で呼び出したコンテキスト変数を用いて算術復号を行う。
 CABAC復号器520は、ステップST75-1において、ステップST75-0で設定したレベルリストインデックス(LevelListIdx)に「1」を加算して、レベルリストインデックス(LevelListIdx)とする。同様に、CABAC復号器520は、ステップST75-Nまでのレベルリストインデックス(LevelListIdx)の設定を行う。例えばステップST75-Nでは、ステップST75-1で設定したレベルリストインデックス(LevelListIdx)に「N=(M-1)」を加算して、レベルリストインデックス(LevelListIdx)を設定する。このように、ステップST75-1~75-Nでレベルリストインデックス(LevelListIdx)を設定して、ステップST76-1~76-NからステップST78-1~78-Nの処理を行うと、並列処理数分の算術復号を並列して行うことができる。
 ステップST79でCABAC復号器520は、コンテキスト変数の更新を行う。CABAC復号器520は、ステップST78-0~78-Nの算術復号結果に基づき、選択されているコンテキスト変数における確率テーブルの番号を更新してステップST80に進む。
 ステップST80でCABAC復号器520は、係数処理が終了したか判別する。CABAC復号器520は、1マクロブロック分の係数について算術復号が完了していない場合にはステップST73に戻り、1マクロブロック分の係数について算術復号が完了した場合にはステップST81に進む。
 ステップST81でCABAC復号器520は、マクロブロック処理が終了したか判別する。CABAC復号器520は、スライス内の各マクロブロックについて算術復号が完了していない場合にはステップST72に戻って次のマクロブロックについての処理を行い、完了した場合にはステップST82に進む。
 ステップST82でCABAC復号器520は、スライス処理が終了したか判別する。CABAC復号器520は、フレーム内の各スライスについて算術復号が完了していない場合にはステップST71に戻って次のスライスついての処理を行う。
 このように、算術符号化を並列に行うことで符号化ストリームが生成されていても、算術復号時には、算術符号化時に対応して算術復号が並列に行われるので、算術復号を正しく高速に行うことができる。また、画像の解像度やフレームレートに基づき、画像符号化装置と等しいルールを用いて並列処理数を設定すれば、上述のように、並列処理数を示すシンタックス要素を符号化ストリームに含めることなく、画像復号装置は、画像符号化装置と等しい並列処理数で算術復号処理を行うことができるので、符号化ストリームのデータ量を削減することが可能となる。
 <9.並列処理の具体例>
 次に、可逆符号化部や可逆復号部で行われる並列処理の具体例について説明する。図13は、1マクロブロックについての8×8直交変換成分に対するレベルリストインデックス(LevelListIdx)を示している。レベルリストインデックス(LevelListIdx)の順序は、図13の数字の順序のようにジグザクスキャン順序とされている。
 図14は、並列処理数に応じたコンテキストインデックス割り当てテーブルを例示している。例えば、並列処理数が「M=2(2並列)」である場合(parallel_processing_id=1の場合)、テーブルIdが「TableId=1」のコンテキストインデックス割り当てテーブル、すなわち図14の(A)のコンテキストインデックス割り当てテーブルを選択する。また、並列処理数が「M=4(4並列)」である場合(parallel_processing_id=2の場合)は、図14の(B)に示すテーブルIdが「TableId=2」のコンテキストインデックス割り当てテーブルを選択する。並列処理数が「M=8(8並列)」である場合(parallel_processing_id=3の場合)は、図14の(C)に示すテーブルIdが「TableId=3」のコンテキストインデックス割り当てテーブルを選択する。さらに、並列処理数が「M=15(15並列)」である場合、図14の(D)に示すテーブルIdが「TableId=4」のコンテキストインデックス割り当てテーブルを選択する。なお、図14の(E)に示すコンテキストインデックス割り当てテーブルは、並列処理を行わない場合(parallel_processing_id=0の場合)に用いられる従来のコンテキストインデックス順序を示している。
 図15は、並列処理数を「2」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示している。なお、図13に示すレベルリストインデックス(LevelListIdx)と図15に示すコンテキストインデックスインクリメント(ctxIdxInc)の関係は、図14の(A)に示すコンテキストインデックス割り当てテーブルで示される。ここで、並列処理数を「2」とした場合、レベルリストインデックス(LevelListIdx)の順序で符号化/復号を行うと、図16に示すように、コンテキストインデックスインクリメント(ctxIdxInc)が変化する。並列処理単位内では、コンテキストインデックスインクリメント(ctxIdxInc)が異なるようにコンテキストインデックスインクリメントの割り当てが行われている。したがって、並列処理単位内で同じコンテキストインデックスインクリメント(ctxIdxInc)が用いられることがないので、処理を高速に行うことが可能となる。
 図17は、並列処理数を「4」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示している。なお、図13に示すレベルリストインデックス(LevelListIdx)と図17に示すコンテキストインデックスインクリメント(ctxIdxInc)の関係は、図14の(B)に示すコンテキストインデックス割り当てテーブルで示される。
 並列処理数を「4」とした場合、レベルリストインデックス(LevelListIdx)の順序で符号化/復号を行うと、図18に示すように、コンテキストインデックスインクリメント(ctxIdxInc)が変化する。ここで、並列処理単位内では、コンテキストインデックスインクリメント(ctxIdxInc)が異なるようにコンテキストインデックスインクリメントの割り当てが行われている。したがって、並列処理単位内で同じコンテキストインデックスインクリメント(ctxIdxInc)が用いられることがないので、処理を高速に行うことが可能となる。
 図19は、並列処理数を「8」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示している。なお、図13に示すレベルリストインデックス(LevelListIdx)と図19に示すコンテキストインデックスインクリメント(ctxIdxInc)の関係は、図14の(C)に示すコンテキストインデックス割り当てテーブルで示される。
 並列処理数を「8」とした場合、レベルリストインデックス(LevelListIdx)の順序で符号化/復号を行うと、図20に示すように、コンテキストインデックスインクリメント(ctxIdxInc)が変化する。ここで、並列処理単位内では、コンテキストインデックスインクリメント(ctxIdxInc)が異なるようにコンテキストインデックスインクリメントの割り当てが行われている。したがって、並列処理単位内で同じコンテキストインデックスインクリメント(ctxIdxInc)が用いられることがないので、処理を高速に行うことが可能となる。
 図21は、並列処理数を「15」とした場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示している。なお、図13に示すレベルリストインデックス(LevelListIdx)と図21に示すコンテキストインデックスインクリメント(ctxIdxInc)の関係は、図14の(D)に示すコンテキストインデックス割り当てテーブルで示される。
 並列処理数を「15」とした場合、レベルリストインデックス(LevelListIdx)の順序で符号化/復号を行うと、図22に示すように、コンテキストインデックスインクリメント(ctxIdxInc)が変化する。ここで、並列処理単位内では、コンテキストインデックスインクリメント(ctxIdxInc)が異なるようにコンテキストインデックスインクリメントの割り当てが行われている。したがって、並列処理単位内で同じコンテキストインデックスインクリメント(ctxIdxInc)が用いられることがないので、処理を高速に行うことが可能となる。
 なお、図23は、並列処理を行わない場合の8×8直交変換成分に対するコンテキストインデックスインクリメント(ctxIdxInc)を示している。なお、図13に示すレベルリストインデックス(LevelListIdx)と図23に示すコンテキストインデックスインクリメント(ctxIdxInc)の関係は、図14の(E)に示すコンテキストインデックス割り当てテーブルで示される。
 並列処理を行わない場合、レベルリストインデックス(LevelListIdx)の順序で符号化/復号を行うと、図24に示すように、コンテキストインデックスインクリメント(ctxIdxInc)が変化する。この場合、同じコンテキストインデックスインクリメント(ctxIdxInc)が連続する場合を生じることから、処理を高速に行うことができない。
 このように、並列処理単位内で同じコンテキストインデックスインクリメント(ctxIdxInc)を用いないようにコンテキストインデックスインクリメント(ctxIdxInc)の割り当てが行われているので、処理を高速に行うことができる。
 また、図21では、同じコンテキストインデックスインクリメント(ctxIdxInc)がランダムに生じているが、周波数が近傍する直交変換係数では、等しいコンテキストインデックスインクリメント(ctxIdxInc)がより多く用いられるように割り当てを行う。例えば図21に比べて図15に示すように、周波数が近傍する直交変換係数では、等しいコンテキストインデックスインクリメント(ctxIdxInc)がより多く用いられるように割り当てを行い符号化効率を高めるようにしてもよい。なお、図15では、例えばコンテキストインデックスインクリメント(ctxIdxInc)=「4」が、周波数の近傍する直交変換係数で多く用いられている。
 <10.ソフトウェア処理の場合>
 明細書中において説明した一連の処理はハードウェア、またはソフトウェア、または両者の複合構成によって実行することが可能である。ソフトウェアによる処理を実行する場合は、処理シーケンスを記録したプログラムを、専用のハードウェアに組み込まれたコンピュータ内のメモリにインストールして実行させる。または、各種処理が実行可能な汎用コンピュータにプログラムをインストールして実行させることも可能である。
 例えば、プログラムは記録媒体としてのハードディスクやROM(Read Only Memory)に予め記録しておくことができる。または、プログラムはフレキシブルディスク、CD-ROM(Compact Disc Read Only Memory),MO(Magneto optical)ディスク,DVD(Digital Versatile Disc)、磁気ディスク、半導体メモリなどのリムーバブル記録媒体に、一時的または永続的に格納(記録)しておくことができる。このようなリムーバブル記録媒体は、いわゆるパッケージソフトウェアとして提供することができる。
 なお、プログラムは、上述したようなリムーバブル記録媒体からコンピュータにインストールする他、ダウンロードサイトから、コンピュータに無線転送したり、LAN(Local Area Network)、インターネットといったネットワークを介して、コンピュータに有線で転送する。コンピュータでは、そのようにして転送されてくるプログラムを受信し、内蔵するハードディスク等の記録媒体にインストールすることができる。
 プログラムを記述するステップは、記載された順序に沿って時系列的に行われる処理はもちろん、必ずしも時系列的に処理されなくとも、並列的あるいは個別に実行される処理をも含むものである。
 <11.電子機器に適用した場合>
 また、以上においては、符号化方式/復号方式としてH.264/AVC方式が用いられたが、本技術は、その他の符号化方式/復号方式を用いる画像符号化装置/画像復号装置に適用することもできる。
 さらに、本技術は、例えば、MPEG,H.26x等のように、離散コサイン変換等の直交変換と動き補償によって圧縮された画像情報(符号化ビットストリーム)を、衛星放送、ケーブルTV(テレビジョン)、インターネット、および携帯電話機などのネットワークメディアを介して受信する際に、あるいは、光、磁気ディスク、およびフラッシュメモリのような記憶メディア上で処理する際に用いられる画像符号化装置および画像復号装置に適用することができる。
 上述した画像符号化装置10や画像復号装置50は、任意の電子機器に適用することができる。以下にその例について説明する。
 図25は、本技術を適用したテレビジョン装置の概略構成を例示している。テレビジョン装置90は、アンテナ901、チューナ902、デマルチプレクサ903、デコーダ904、映像信号処理部905、表示部906、音声信号処理部907、スピーカ908、外部インタフェース部909を有している。さらに、テレビジョン装置90は、制御部910、ユーザインタフェース部911等を有している。
 チューナ902は、アンテナ901で受信された放送波信号から所望のチャンネルを選局して復調を行い、得られた符号化ビットストリームをデマルチプレクサ903に出力する。
 デマルチプレクサ903は、符号化ビットストリームから視聴対象である番組の映像や音声のパケットを抽出して、抽出したパケットのデータをデコーダ904に出力する。また、デマルチプレクサ903は、EPG(Electronic Program Guide)等のデータのパケットを制御部910に供給する。なお、スクランブルが行われている場合、デマルチプレクサ等でスクランブルの解除を行う。
 デコーダ904は、パケットの復号処理を行い、復号処理化によって生成された映像データを映像信号処理部905、音声データを音声信号処理部907に出力する。
 映像信号処理部905は、映像データに対して、ノイズ除去やユーザ設定に応じた映像処理等を行う。映像信号処理部905は、表示部906に表示させる番組の映像データや、ネットワークを介して供給されるアプリケーションに基づく処理による画像データなどを生成する。また、映像信号処理部905は、項目の選択などのメニュー画面等を表示するための映像データを生成し、それを番組の映像データに重畳する。映像信号処理部905は、このようにして生成した映像データに基づいて駆動信号を生成して表示部906を駆動する。
 表示部906は、映像信号処理部905からの駆動信号に基づき表示デバイス(例えば液晶表示素子等)を駆動して、番組の映像などを表示させる。
 音声信号処理部907は、音声データに対してノイズ除去などの所定の処理を施し、処理後の音声データのD/A変換処理や増幅処理を行いスピーカ908に供給することで音声出力を行う。
 外部インタフェース部909は、外部機器やネットワークと接続するためのインタフェースであり、映像データや音声データ等のデータ送受信を行う。
 制御部910にはユーザインタフェース部911が接続されている。ユーザインタフェース部911は、操作スイッチやリモートコントロール信号受信部等で構成されており、ユーザ操作に応じた操作信号を制御部910に供給する。
 制御部910は、CPU(Central Processing Unit)やメモリ等を用いて構成されている。メモリは、CPUにより実行されるプログラムやCPUが処理を行う上で必要な各種のデータ、EPGデータ、ネットワークを介して取得されたデータ等を記憶する。メモリに記憶されているプログラムは、テレビジョン装置90の起動時などの所定のタイミングでCPUにより読み出されて実行される。CPUは、プログラムを実行することで、テレビジョン装置90がユーザ操作に応じた動作となるように各部を制御する。
 なお、テレビジョン装置90では、チューナ902、デマルチプレクサ903、映像信号処理部905、音声信号処理部907、外部インタフェース部909等と制御部910を接続するためバス912が設けられている。
 このように構成されたテレビジョン装置では、デコーダ904に本技術の画像復号装置(画像復号方法)の機能が設けられる。このため、放送局側で本技術の画像符号化装置の機能を用いることにより、算術符号化を並列して行い符号化ビットストリームの生成が高速に行われても、テレビジョン装置で符号化ビットストリームの復号を正しく高速に行うことができる。
 図26は、本技術を適用した携帯電話機の概略構成を例示している。携帯電話機92は、通信部922、音声コーデック923、カメラ部926、画像処理部927、多重分離部928、記録再生部929、表示部930、制御部931を有している。これらは、バス933を介して互いに接続されている。また、通信部922にはアンテナ921が接続されており、音声コーデック923には、スピーカ924とマイクロホン925が接続されている。さらに制御部931には、操作部932が接続されている。
 携帯電話機92は、音声通話モードやデータ通信モード等の各種モードで、音声信号の送受信、電子メールや画像データの送受信、画像撮影、またはデータ記録等の各種動作を行う。
 音声通話モードにおいて、マイクロホン925で生成された音声信号は、音声コーデック923で音声データへの変換やデータ圧縮が行われて通信部922に供給される。通信部922は、音声データの変調処理や周波数変換処理等を行い送信信号を生成する。また、通信部922は、送信信号をアンテナ921に供給して図示しない基地局へ送信する。また、通信部922は、アンテナ921で受信した受信信号の増幅や周波数変換処理および復調処理等を行い、得られた音声データを音声コーデック923に供給する。音声コーデック923は、音声データのデータ伸張やアナログ音声信号への変換を行いスピーカ924に出力する。
 また、データ通信モードにおいて、メール送信を行う場合、制御部931は、操作部932の操作によって入力された文字データを受け付けて、入力された文字を表示部930に表示する。また、制御部931は、操作部932におけるユーザ指示等に基づいてメールデータを生成して通信部922に供給する。通信部922は、メールデータの変調処理や周波数変換処理等を行い、得られた送信信号をアンテナ921から送信する。また、通信部922は、アンテナ921で受信した受信信号の増幅や周波数変換処理および復調処理等を行い、メールデータを復元する。このメールデータを、表示部930に供給して、メール内容の表示を行う。
 なお、携帯電話機92は、受信したメールデータを、記録再生部929で記憶媒体に記憶させることも可能である。記憶媒体は、書き換え可能な任意の記憶媒体である。例えば、記憶媒体は、RAMや内蔵型フラッシュメモリ等の半導体メモリ、ハードディスク、磁気ディスク、光磁気ディスク、光ディスク、USBメモリ、またはメモリカード等のリムーバブルメディアである。
 データ通信モードにおいて画像データを送信する場合、カメラ部926で生成された画像データを、画像処理部927に供給する。画像処理部927は、画像データの符号化処理を行い符号化データを生成する。
 多重分離部928は、画像処理部927で生成された符号化データと、音声コーデック923から供給された音声データを所定の方式で多重化して通信部922に供給する。通信部922は、多重化データの変調処理や周波数変換処理等を行い、得られた送信信号をアンテナ921から送信する。また、通信部922は、アンテナ921で受信した受信信号の増幅や周波数変換処理および復調処理等を行い、多重化データを復元する。この多重化データを多重分離部928に供給する。多重分離部928は、多重化データの分離を行い、符号化データを画像処理部927、音声データを音声コーデック923に供給する。画像処理部927は、符号化データの復号処理を行い画像データを生成する。この画像データを表示部930に供給して、受信した画像の表示を行う。音声コーデック923は、音声データをアナログ音声信号に変換してスピーカ924に供給して、受信した音声を出力する。
 このように構成された携帯電話装置では、画像処理部927に本技術の画像符号化装置(画像符号化方法)や画像復号装置(画像復号方法)の機能が設けられる。したがって、画像データの通信を行う際に、画像の符号化や復号を高速に行うことができる。
 図27は、本技術を適用した記録再生装置の概略構成を例示している。記録再生装置94は、例えば受信した放送番組のオーディオデータとビデオデータを、記録媒体に記録して、その記録されたデータをユーザの指示に応じたタイミングでユーザに提供する。また、記録再生装置94は、例えば他の装置からオーディオデータやビデオデータを取得し、それらを記録媒体に記録させることもできる。さらに、記録再生装置94は、記録媒体に記録されているオーディオデータやビデオデータを復号して出力することで、モニタ装置等において画像表示や音声出力を行うことができるようにする。
 記録再生装置94は、チューナ941、外部インタフェース部942、エンコーダ943、HDD(Hard Disk Drive)部944、ディスクドライブ945、セレクタ946、デコーダ947、OSD(On-Screen Display)部948、制御部949、ユーザインタフェース部950を有している。
 チューナ941は、図示しないアンテナで受信された放送信号から所望のチャンネルを選局する。チューナ941は、所望のチャンネルの受信信号を復調して得られた符号化ビットストリームをセレクタ946に出力する。
 外部インタフェース部942は、IEEE1394インタフェース、ネットワークインタフェース部、USBインタフェース、フラッシュメモリインタフェース等の少なくとも何れかで構成されている。外部インタフェース部942は、外部機器やネットワーク、メモリカード等と接続するためのインタフェースであり、記録する映像データや音声データ等のデータ受信を行う。
 エンコーダ943は、外部インタフェース部942から供給された映像データや音声データが符号化されていないとき所定の方式で符号化を行い、符号化ビットストリームをセレクタ946に出力する。
 HDD部944は、映像や音声等のコンテンツデータ、各種プログラムやその他のデータ等を内蔵のハードディスクに記録し、また再生時等にそれらを当該ハードディスクから読み出す。
 ディスクドライブ945は、装着されている光ディスクに対する信号の記録および再生を行う。光ディスク、例えばDVDディスク(DVD-Video、DVD-RAM、DVD-R、DVD-RW、DVD+R、DVD+RW等)やBlu-ray(登録商標)ディスク等である。
 セレクタ946は、映像や音声の記録時には、チューナ941またはエンコーダ943からの何れかの符号化ビットストリームを選択して、HDD部944やディスクドライブ945の何れかに供給する。また、セレクタ946は、映像や音声の再生時に、HDD部944またはディスクドライブ945から出力された符号化ビットストリームをデコーダ947に供給する。
 デコーダ947は、符号化ビットストリームの復号化処理を行う。デコーダ947は、復号処理化を行うことにより生成された映像データをOSD部948に供給する。また、デコーダ947は、復号処理化を行うことにより生成された音声データを出力する。OSD部948は、項目の選択などのメニュー画面等を表示するための映像データを生成し、それをデコーダ947から出力された映像データに重畳して出力する。
 制御部949には、ユーザインタフェース部950が接続されている。ユーザインタフェース部950は、操作スイッチやリモートコントロール信号受信部等で構成されており、ユーザ操作に応じた操作信号を制御部949に供給する。
 制御部949は、CPUやメモリ等を用いて構成されている。メモリは、CPUにより実行されるプログラムやCPUが処理を行う上で必要な各種のデータを記憶する。メモリに記憶されているプログラムは、記録再生装置94の起動時などの所定のタイミングでCPUにより読み出されて実行される。CPUは、プログラムを実行することで、記録再生装置94がユーザ操作に応じた動作となるように各部を制御する。
 このように構成された記録再生装置では、エンコーダ943に本技術の画像符号化装置(画像符号化方法)の機能、デコーダ947に画像復号化装置(画像復号化方法)の機能が設けられて、映像の記録再生を高速に行うことができる。
 図28は、本技術を適用した撮像装置の概略構成を例示している。撮像装置96は、被写体を撮像し、被写体の画像を表示部に表示させたり、それを画像データとして、記録媒体に記録する。
 撮像装置96は、光学ブロック961、撮像部962、カメラ信号処理部963、画像データ処理部964、表示部965、外部インタフェース部966、メモリ部967、メディアドライブ968、OSD部969、制御部970を有している。また、制御部970には、ユーザインタフェース部971が接続されている。さらに、画像データ処理部964や外部インタフェース部966、メモリ部967、メディアドライブ968、OSD部969、制御部970等は、バス972を介して接続されている。
 光学ブロック961は、フォーカスレンズや絞り機構等を用いて構成されている。光学ブロック961は、被写体の光学像を撮像部962の撮像面に結像させる。撮像部962は、CCDまたはCMOSイメージセンサを用いて構成されており、光電変換によって光学像に応じた電気信号を生成してカメラ信号処理部963に供給する。
 カメラ信号処理部963は、撮像部962から供給された電気信号に対してニー補正やガンマ補正、色補正等の種々のカメラ信号処理を行う。カメラ信号処理部963は、カメラ信号処理後の画像データを画像データ処理部964に供給する。
 画像データ処理部964は、カメラ信号処理部963から供給された画像データの符号化処理を行う。画像データ処理部964は、符号化処理を行うことにより生成された符号化データを外部インタフェース部966やメディアドライブ968に供給する。また、画像データ処理部964は、外部インタフェース部966やメディアドライブ968から供給された符号化データの復号化処理を行う。画像データ処理部964は、復号化処理を行うことにより生成された画像データを表示部965に供給する。また、画像データ処理部964は、カメラ信号処理部963から供給された画像データを表示部965に供給する処理や、OSD部969から取得した表示用データを、画像データに重畳させて表示部965に供給する。OSD部969は、記号、文字、または図形からなるメニュー画面やアイコンなどの表示用データを生成して画像データ処理部964に出力する。
 外部インタフェース部966は、例えば、USB入出力端子などで構成され、画像の印刷を行う場合に、プリンタと接続される。また、外部インタフェース部966には、必要に応じてドライブが接続され、磁気ディスク、光ディスク等のリムーバブルメディアが適宜装着され、それらから読み出されたプログラムが、必要に応じてインストールされる。さらに、外部インタフェース部966は、LANやインターネット等の所定のネットワークに接続されるネットワークインタフェースを有する。制御部970は、例えば、ユーザインタフェース部971からの指示にしたがって、メモリ部967から符号化データを読み出し、それを外部インタフェース部966から、ネットワークを介して接続される他の装置に供給させることができる。また、制御部970は、ネットワークを介して他の装置から供給される符号化データや画像データを、外部インタフェース部966を介して取得し、それを画像データ処理部964に供給したりすることができる。
 メディアドライブ968で駆動される記録メディアとしては、例えば、磁気ディスク、光磁気ディスク、光ディスク、または半導体メモリ等の、読み書き可能な任意のリムーバブルメディアが用いられる。また、記録メディアは、リムーバブルメディアとしての種類も任意であり、テープデバイスであってもよいし、ディスクであってもよいし、メモリカードであってもよい。もちろん、非接触ICカード等であってもよい。
 また、メディアドライブ968と記録メディアを一体化し、例えば、内蔵型ハードディスクドライブやSSD(Solid State Drive)等のように、非可搬性の記憶媒体により構成されるようにしてもよい。
 制御部970は、CPUやメモリ等を用いて構成されている。メモリは、CPUにより実行されるプログラムやCPUが処理を行う上で必要な各種のデータ等を記憶する。メモリに記憶されているプログラムは、撮像装置96の起動時などの所定のタイミングでCPUにより読み出されて実行される。CPUは、プログラムを実行することで、撮像装置96がユーザ操作に応じた動作となるように各部を制御する。
 このように構成された撮像装置では、画像データ処理部964に本技術の画像符号化装置(画像符号化方法)や画像復号化装置(画像復号化方法)の機能が設けられる。したがって、撮像画像をメモリ部967や記録メディア等に記録する場合や記録されている撮像画像を再生する際に、高速に記録再生を行うことができる。
 また、本技術は上述した技術の実施の形態に限定して解釈されるべきではない。この技術の実施の形態は、例示という形態で本技術を開示しており、本技術の要旨を逸脱しない範囲で当業者が実施の形態の修正や代用をなし得ることは自明である。すなわち、本技術の要旨を判断するためには、請求の範囲を参酌すべきである。
 なお、本技術は以下のような構成も取ることができる。
 (1) シンタックス要素を二値化データに変換する二値化部と、
 前記シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、
 前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、
 前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて前記二値化データの算術符号化を並列して行う算術符号化処理部と
を備える画像符号化装置。
 (2) 前記シンタックス要素に、前記並列処理数を示す情報を含めた(1)に記載の画像符号化装置。
 (3) 前記並列処理数を設定する並列処理数設定部を更に備える(1)または(2)に記載の画像符号化装置。
 (4) 前記並列処理数設定部は、前記並列処理数を、スライス単位で設定する(3)に記載の画像符号化装置。
 (5) 前記並列処理数設定部は、前記並列処理数を、画像の解像度またはフレームレートに応じて設定する(4)に記載の画像符号化装置。
 (6) 前記並列処理数設定部は、前記並列処理数を、ブロック単位で設定する(3)に記載の画像符号化装置。
 (7) 前記並列処理数設定部は、前記並列処理数を、前記ブロック単位で行われた直交変換におけるゼロ係数の数に応じて設定する(6)に記載の画像符号化装置。
 (8) 前記並列処理数設定部は、前記並列処理数を、スライス単位とブロック単位の少なくとも何れかの単位で設定して、ブロック単位で並列処理数が設定されていない場合に、スライス単位で設定された並列処理数を用いる(3)に記載の画像符号化装置。
 (9) 前記コンテキストインデックス設定部は、直交変換係数を示すシンタックス要素毎のインデックスと前記コンテキストインデックスの関係を示す割り当てテーブルを用いて、前記コンテキストインデックスを設定する(1)乃至(8)の何れかに記載の画像符号化装置。
 (10) 前記割り当てテーブルでは、周波数が近傍する直交変換係数で、等しいコンテキストインデックスをより多く用いるように、前記インデックスと前記コンテキストインデックスが関係付けられている(9)に記載の画像符号化装置。
 (11) 復号するシンタックス要素に対応するコンテキスト変数を特定するためのコンテキストインデックスを、並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、
 前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、
 前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて符号化データの算術復号を並列して行う算術復号処理部と、
 前記算術復号を行うことによって得られた二値化データをシンタックス要素の値に変換する多値化部と
を備える画像復号装置。
 (12) 前記並列処理数を設定する並列処理数設定部を更に備える(11)に記載の画像復号装置。
 (13) 前記並列処理数設定部は、前記並列処理数を、前記符号化データに含まれている前記並列処理数を示すシンタックス要素に基づいて決定する(12)に記載の画像復号装置。
 (14) 前記並列処理数設定部は、前記並列処理数を、復号する画像の解像度またはフレームレートに応じてスライス単位で設定する(12)に記載の画像復号装置。
 (15) 前記コンテキストインデックス設定部は、直交変換係数を示すシンタックス要素毎のインデックスと前記コンテキストインデックスの関係を示す割り当てテーブルを用いて、前記コンテキストインデックスを設定する(11)乃至(14)の何れかに記載の画像復号装置。
 本技術の画像符号化装置と画像復号装置およびその方法では、算術符号化や算術復号を並列して行う場合に、並列処理単位内で重複を生じないようにコンテキストインデックスを設定して、設定されたコンテキストインデックスに対応するコンテキスト変数を用いて算術符号化や算術復号が行われる。このため、並列処理単位内において、コンテキスト変数を更新して、更新後のコンテキスト変数を用いて算術符号化や算術復号が行われることがなく、画像の符号化処理や復号処理を高速に行うことができるようになる。したがって、本技術は、MPEG、H.26x等のように、ブロック単位で符号化を行うことにより得られた符号化ストリームを、衛星放送、ケーブルTV、インターネット、携帯電話などのネットワークメディアを介して送受信する電子機器や、光ディスク、磁気ディスク、フラッシュメモリのような記憶メディアを用いて画像の記録再生を行う電子機器に適している。
 10・・・画像符号化装置、11・・・A/D変換部、12,57・・・画面並べ替えバッファ、13,23,55・・・演算部、14・・・直交変換部、15・・・量子化部、16・・・可逆符号化部、17・・・蓄積バッファ、18・・・レート制御部、21,53・・・逆量子化部、22,54・・・逆直交変換部、24,56・・・デブロッキングフィルタ、25,61・・・フレームメモリ、31・・・イントラ予測部、32・・・動き予測・補償部、33・・・予測画像・最適モード選択部、50・・・画像復号装置、51・・・蓄積バッファ、52・・・可逆復号部、53・・・逆量子化部、58・・・D/A変換部、71・・・イントラ予測部、72・・・動き補償部、73,946・・・セレクタ、90・・・テレビジョン装置、92・・・携帯電話機、94・・・記録再生装置、96・・・撮像装置、160・・・CABAC符号化器、161・・・二値化部、162,201,521・・・コンテキストインデックス(ctxIdx)設定部、163,522・・・コンテキスト変数選択処理部、163-0~163-N,202-0,202-1,522-0~522-N・・・変数選択部、164・・・算術符号化処理部、164-0~164-N・・・算術符号化部、165・・・符号化結果選択部、167,527・・・並列処理数設定部、520・・・CABAC復号器、523・・・算術復号処理部、203-0,203-1,523~0~523~N・・・算術復号部、524・・・復号結果選択部、525・・・多値化部、526・・・レジスタ、901,821・・・アンテナ、902・・・チューナ、903・・・デマルチプレクサ、904,947・・・デコーダ、905・・・映像信号処理部、906,930,965・・・表示部、907・・・音声信号処理部、908,924・・・スピーカ、909,942,966・・・外部インタフェース部、910,931,949,970・・・制御部、911,950,971・・・ユーザインタフェース部、912,933,972・・・バス、922・・・通信部、923・・・音声コーデック、925・・・マイクロホン、926・・・カメラ部、927・・・画像処理部、928・・・多重分離部、929・・・記録再生部、932・・・操作部、941・・・チューナ、943・・・エンコーダ、944・・・HDD部、945・・・ディスクドライブ、948,969・・・OSD部、961・・・光学ブロック、962・・・撮像部、963・・・カメラ信号処理部、964・・・画像データ処理部、967・・・メモリ部、968・・・メディアドライブ

Claims (17)

  1.  シンタックス要素を二値化データに変換する二値化部と、
     前記シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、
     前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、
     前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて前記二値化データの算術符号化を並列して行う算術符号化処理部と
    を備える画像符号化装置。
  2.  前記シンタックス要素に、前記並列処理数を示す情報を含めた
    請求項1記載の画像符号化装置。
  3.  前記並列処理数を設定する並列処理数設定部を更に備える
    請求項2記載の画像符号化装置。
  4.  前記並列処理数設定部は、前記並列処理数を、スライス単位で設定する
    請求項3記載の画像符号化装置。
  5.  前記並列処理数設定部は、前記並列処理数を、画像の解像度またはフレームレートに応じて設定する
    請求項4記載の画像符号化装置。
  6.  前記並列処理数設定部は、前記並列処理数を、ブロック単位で設定する
    請求項3記載の画像符号化装置。
  7.  前記並列処理数設定部は、前記並列処理数を、前記ブロック単位で行われた直交変換におけるゼロ係数の数に応じて設定する請求項6記載の画像符号化装置。
  8.  前記並列処理数設定部は、前記並列処理数を、スライス単位とブロック単位の少なくとも何れかの単位で設定して、ブロック単位で並列処理数が設定されていない場合に、スライス単位で設定された並列処理数を用いる
    請求項3記載の画像符号化装置。
  9.  前記コンテキストインデックス設定部は、直交変換係数を示すシンタックス要素毎のインデックスと前記コンテキストインデックスの関係を示す割り当てテーブルを用いて、前記コンテキストインデックスを設定する
    請求項1記載の画像符号化装置。
  10.  前記割り当てテーブルでは、周波数が近傍する直交変換係数で、等しいコンテキストインデックスをより多く用いるように、前記インデックスと前記コンテキストインデックスが関係付けられている
    請求項9記載の画像符号化装置。
  11.  シンタックス要素を二値化データに変換する二値化工程と、
     前記シンタックス要素に対するコンテキスト変数を特定するためのコンテキストインデックスを並列処理単位内で重複しないように設定するコンテキストインデックス設定工程と、
     前記コンテキストインデックス設定工程で設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理工程と、
     前記並列処理単位毎に、前記選択されたコンテキスト変数を用いて前記二値化データの算術符号化を並列して行う算術符号化処理工程と
    を含む画像符号化方法。
  12.  復号するシンタックス要素に対応するコンテキスト変数を特定するためのコンテキストインデックスを、並列処理単位内で重複しないように設定するコンテキストインデックス設定部と、
     前記コンテキストインデックス設定部により設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理部と、
     前記並列処理単位毎に、前記コンテキスト変数選択処理部により選択されたコンテキスト変数を用いて符号化データの算術復号を並列して行う算術復号処理部と、
     前記算術復号を行うことによって得られた二値化データをシンタックス要素の値に変換する多値化部と
    を備える画像復号装置。
  13.  前記並列処理数を設定する並列処理数設定部を更に備える
    請求項12記載の画像復号装置。
  14.  前記並列処理数設定部は、前記並列処理数を、前記符号化データに含まれている前記並列処理数を示すシンタックス要素に基づいて決定する
    請求項13記載の画像復号装置。
  15.  前記並列処理数設定部は、前記並列処理数を、復号する画像の解像度またはフレームレートに応じてスライス単位で設定する
    請求項13記載の画像復号装置。
  16.  前記コンテキストインデックス設定部は、直交変換係数を示すシンタックス要素毎のインデックスと前記コンテキストインデックスの関係を示す割り当てテーブルを用いて、前記コンテキストインデックスを設定する
    請求項12記載の画像復号装置。
  17.  復号するシンタックス要素に対応するコンテキストインデックスを、並列処理単位内で重複しないように設定するコンテキストインデックス設定工程と、
     前記コンテキストインデックス設定工程で設定されたコンテキストインデックスに応じてコンテキスト変数を選択するコンテキスト変数選択処理工程と、
     前記並列処理単位で、前記コンテキスト変数選択工程で選択されたコンテキスト変数を用いて符号化データの算術復号を並列して行う算術復号工程と、
     前記算術復号を行うことによって得られた二値化データをシンタックス要素に変換する多値化工程と
    を含む画像復号方法。
PCT/JP2012/059025 2011-05-20 2012-04-03 画像符号化装置と画像復号装置およびその方法 WO2012160879A1 (ja)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2011-113783 2011-05-20
JP2011113783A JP2012244482A (ja) 2011-05-20 2011-05-20 画像符号化装置と画像復号装置およびその方法

Publications (1)

Publication Number Publication Date
WO2012160879A1 true WO2012160879A1 (ja) 2012-11-29

Family

ID=47216966

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2012/059025 WO2012160879A1 (ja) 2011-05-20 2012-04-03 画像符号化装置と画像復号装置およびその方法

Country Status (2)

Country Link
JP (1) JP2012244482A (ja)
WO (1) WO2012160879A1 (ja)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016129031A1 (ja) * 2015-02-09 2016-08-18 株式会社日立情報通信エンジニアリング 画像圧縮伸長装置

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008113374A (ja) * 2006-10-31 2008-05-15 Canon Inc エントロピー符号化装置

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008113374A (ja) * 2006-10-31 2008-05-15 Canon Inc エントロピー符号化装置

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
HISAO SASAI ET AL.: "Parallel Context Processing for Significance map using block- based context updates", JOINT COLLABORATIVE TEAM ON VIDEO CODING (JCT-VC) OF ITU-T SG16 WP3 AND ISO/IEC JTC1/SC29/WG11 5TH MEETING: GENEVA, 16 March 2011 (2011-03-16) *
MADHUKAR BUDAGAVI ET AL.: "Parallel Context Processing techniques for high coding efficiency entropy coding in HEVC.", JOINT COLLABORATIVE TEAM ON VIDEO CODING (JCT-VC) OF ITU-T SG16 WP3 AND ISO/IEC JTC1/ SC29/WG11 2ND MEETING: GENEVA, 21 July 2010 (2010-07-21) *
MADHUKAR BUDAGAVI: "TE8: TI Parallel context processing (PCP) proposal", JOINT COLLABORATIVE TEAM ON VIDEO CODING (JCT-VC) OF ITU-T SG16 WP3 AND ISO/IEC JTC1/SC29/WG11 3RD MEETING: GUANGZHOU, 7 October 2010 (2010-10-07) *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016129031A1 (ja) * 2015-02-09 2016-08-18 株式会社日立情報通信エンジニアリング 画像圧縮伸長装置
JP6085065B2 (ja) * 2015-02-09 2017-02-22 株式会社日立情報通信エンジニアリング 画像圧縮伸長装置
JPWO2016129031A1 (ja) * 2015-02-09 2017-04-27 株式会社日立情報通信エンジニアリング 画像圧縮伸長装置

Also Published As

Publication number Publication date
JP2012244482A (ja) 2012-12-10

Similar Documents

Publication Publication Date Title
RU2680349C1 (ru) Устройство обработки изображений и способ обработки изображений
RU2595624C2 (ru) Устройство и способ обработки изображений
RU2701840C2 (ru) Устройство и способ обработки изображений
KR101958611B1 (ko) 화상 처리 장치 및 화상 처리 방법
CN107018424B (zh) 图像处理装置和图像处理方法
WO2011155332A1 (ja) 画像復号化装置と画像符号化装置およびその方法とプログラム
CN103636214A (zh) 图像处理设备及图像处理方法
JP2014207536A (ja) 画像処理装置および方法
WO2012160879A1 (ja) 画像符号化装置と画像復号装置およびその方法
WO2011162299A1 (ja) 情報処理装置と情報処理方法
WO2013027472A1 (ja) 画像処理装置および画像処理方法
WO2013046895A1 (ja) 画像処理装置と画像処理方法

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 12788806

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 12788806

Country of ref document: EP

Kind code of ref document: A1