WO2020137643A1 - 画像処理装置および方法 - Google Patents

画像処理装置および方法 Download PDF

Info

Publication number
WO2020137643A1
WO2020137643A1 PCT/JP2019/049090 JP2019049090W WO2020137643A1 WO 2020137643 A1 WO2020137643 A1 WO 2020137643A1 JP 2019049090 W JP2019049090 W JP 2019049090W WO 2020137643 A1 WO2020137643 A1 WO 2020137643A1
Authority
WO
WIPO (PCT)
Prior art keywords
prediction
unit
bio
vpu
size
Prior art date
Application number
PCT/JP2019/049090
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
Priority to MX2021007180A priority Critical patent/MX2021007180A/es
Application filed by ソニー株式会社 filed Critical ソニー株式会社
Priority to CA3120750A priority patent/CA3120750A1/en
Priority to BR112021012260-5A priority patent/BR112021012260A2/pt
Priority to CN201980085078.9A priority patent/CN113424530A/zh
Priority to EP19905764.7A priority patent/EP3905676A4/en
Priority to US17/312,405 priority patent/US20220070447A1/en
Priority to JP2020563093A priority patent/JP7414008B2/ja
Priority to AU2019417255A priority patent/AU2019417255A1/en
Priority to SG11202103292TA priority patent/SG11202103292TA/en
Publication of WO2020137643A1 publication Critical patent/WO2020137643A1/ja
Priority to JP2023220431A priority patent/JP2024038146A/ja
Priority to JP2023220432A priority patent/JP2024023955A/ja
Priority to US18/398,418 priority patent/US20240129459A1/en

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/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/43Hardware specially adapted for motion estimation or compensation
    • H04N19/433Hardware specially adapted for motion estimation or compensation characterised by techniques for memory access
    • 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/103Selection of coding mode or of prediction mode
    • H04N19/109Selection of coding mode or of prediction mode among a plurality of temporal predictive coding modes
    • 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/119Adaptive subdivision aspects, e.g. subdivision of a picture into rectangular or non-rectangular coding blocks
    • 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/17Methods 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 an image region, e.g. an object
    • H04N19/176Methods 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 an image region, e.g. an object the region being a block, e.g. a macroblock
    • 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/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/567Motion estimation based on rate distortion criteria
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/577Motion compensation with bidirectional frame interpolation, i.e. using B-pictures

Definitions

  • the present technology relates to an image processing device and method, and more particularly to an image processing device and method capable of reducing a buffer size.
  • VVC VVC/H.264 and HEVC/H.265.
  • the VPDU size is the buffer size that allows each pipeline stage to process without delay.
  • the VPDU size is often matched with the maximum size of TU (Transform Unit).
  • VVC 64x64 is the maximum TU size, and this size is also assumed for VPDU.
  • one PU corresponds to one CU, and it is necessary to perform inter prediction processing for a PU having a size larger than VPDU. Even in this case, it is possible to process by dividing the PU into virtual vPU (virtual PU), good compatibility with VPDU, and reasonable until BIO (Bi-directional optical flow) described later is adopted. It was possible to implement with HW resources.
  • the Optical Flow method is an image processing method that detects the movement of an object in a moving image and estimates in which direction it will move after a certain time. Coding efficiency is improved by adding this Optical Flow method as an option of codec inter prediction. It is called BIO in particular because it uses the Optical Flow method in Bi prediction (bidirectional prediction) that refers to each frame one after another temporally (see Non-Patent Document 1).
  • the difference MV (MVD) is coded because there is a difference between the optimal MV and the predicted MV (PMV), whereas in Bi prediction that applies BIO, the prediction MV (PMV) is generated.
  • the gradient (G) and velocity (V) are calculated for each of the prediction blocks by the Optical Flow method, and the same result as the ordinary Bi prediction is obtained. In such a case, the coding of the difference MV (MVD) is unnecessary or can be reduced, so that the coding efficiency is improved (see Non-Patent Document 2).
  • One of the various BIO reduction methods that has been proposed is to calculate the SAD (Sum of AbsoluteDifference) between blocks at the stage when the L0 prediction block and the L1 prediction block are generated, and set the threshold with the SAD value. If it falls below, there is one that does not apply BIO and executes normal Bi prediction.
  • SAD Sud of AbsoluteDifference
  • the BIO reduction method described above When the BIO reduction method described above is applied, the SAD of L0 and L1 prediction blocks is calculated for the entire PU, the applicability of BIO processing is determined by comparison with the threshold value, and the processing branches. .. Therefore, it becomes difficult to virtually divide a PU into multiple vPUs when performing inter prediction with a PU larger than VPDU.
  • the buffer required for gradient calculation and speed calculation needs a region that is slightly larger than the PU, and the inter prediction processing unit including BIO requires a large buffer resource.
  • the present technology has been made in view of such a situation, and makes it possible to reduce the buffer size.
  • An image processing device is a control unit that divides a processing unit for calculating a cost used for determining whether or not to perform bidirectional prediction into division processing units equivalent to VPDU size, or less than VPDU size, A determination unit that performs the determination using the cost calculated based on the division processing unit.
  • a processing unit for calculating a cost used for determining whether or not to perform bidirectional prediction is divided into VPDU size-equivalent or division processing units of VPDU size or less, and based on the division processing unit. The determination is performed using the cost calculated by the above.
  • FIG. 3 is a flowchart illustrating Bi prediction, which is one of the inter PU processes in the case of FIG. 1. It is a figure which shows the example which introduced VPDU and constructed the pipeline efficiently.
  • 4 is a flowchart illustrating Bi prediction, which is one of the inter PU processes in the case of FIG. 3. It is a figure which shows the example of normal Bi prediction. It is a figure which shows the example of Bi prediction which applied BIO.
  • FIG. 3 is a diagram showing an example of 2-block division of normal Bi prediction. It is a figure which shows the example of 2 block division
  • FIG. 20 is a block diagram showing a configuration example of an embodiment of a decoding device to which the present disclosure is applied. It is a flow chart explaining details of decoding processing of a decoding device. It is a block diagram which shows the structural example of the inter estimation part. It is a flow chart explaining Bi prediction including conventional BIO.
  • FIG. 16 is a flowchart illustrating Bi prediction including conventional BIO, following FIG. 15.
  • FIG. 17 It is a flow chart explaining Bi prediction including BIO of a 1st embodiment of this art.
  • 18 is a flowchart that follows FIG. 17 and describes Bi prediction including BIO according to the first embodiment of the present technology. It is a figure which shows PU size, vPU number, and the correspondence of processing position and size. It is a figure which shows the comparison when the conventional operation
  • FIG. 22 It is a figure which shows the example which used the BIO determination result of vPU number 0 also in other vPU, when PU is larger than VPDU. It is a flowchart explaining Bi prediction including BIO in the case of FIG. 22 and FIG.
  • FIG. 25 is a flowchart for explaining Bi prediction including BIO in the cases of FIGS. 22 and 23 following FIG. 24. It is a figure which shows the example which determines the application of BIO with the partial SAD value in each vPU. It is a figure which shows the example which determines the application of BIO with the partial SAD value in each vPU.
  • 11 is a flowchart illustrating a partial SAD calculation area determination process for determining BIO_vPU_ON of each vPU.
  • FIG. 29 is a flowchart illustrating a partial SAD calculation area determination process for determining the BIO_vPU_ON of each vPU, following FIG. 28.
  • 11 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the second embodiment of the present technology.
  • 31 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the second embodiment of the present technology, which is subsequent to FIG. 30. It is a figure which shows the correspondence of BIO_MAX_SAD_BLOCK_SIZE and sPU.
  • 16 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the third embodiment of the present technology.
  • FIG. 34 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the third embodiment of the present technology, which is subsequent to FIG. 33. It is a figure which shows the example of the area
  • FIG. 38 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the fourth embodiment of the present technology, which is subsequent to FIG. 37. It is a flow chart explaining Bi prediction including BIO which an inter prediction part 51 performs as an operation example of a 5th embodiment of this art.
  • 40 is a flowchart illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the fifth embodiment of the present technology, which is subsequent to FIG. 39.
  • FIG. 19 is a block diagram illustrating a configuration example of a computer.
  • VVC VVC/H.264 and HEVC/H.265.
  • the VPDU size is the buffer size that allows each pipeline stage to process without delay.
  • the VPDU size is often matched with the maximum size of TU (Transform Unit).
  • VVC 64x64 is the maximum TU size, and this size is also assumed for VPDU.
  • one PU corresponds to one CU, and it is necessary to perform inter prediction processing on a PU having a size larger than the VPDU size.
  • the PU can be divided into virtual vPUs (virtual PUs) for processing, and it has good compatibility with VPDUs, and until the BIO (Bi-directional optical flow) described below is adopted, As shown in FIG. 4, since the buffer can be reduced, it was possible to implement with a reasonable HW resource.
  • FIG. 1 is a diagram showing an example in which a pipeline is assembled without introducing VPDU.
  • FIG. 3 Each block of CU, inter PU, and TU is shown on the upper part of FIG.
  • the maximum size of CU is 128 x 128.
  • the maximum size of the inter PU is 128x128.
  • one PU corresponds to one CU.
  • the TU is composed of TU0 to TU3, and the maximum size of each TU is 64 ⁇ 64.
  • the TU size is also the VPDU size.
  • the CU is formed by adding the inter PU generated by the inter PU process and the TU obtained by the TU process.
  • a pipeline consisting of inter-PU processing, TU processing, and local decoding processing is shown.
  • inter-PU processing and TU0 to TU3 processing are performed in parallel, and when both are completed, CU local decoding processing is started. Therefore, the inter PU process requires a 128 ⁇ 128 buffer, and the TU process requires a 128 ⁇ 128 buffer for waiting with the PU.
  • FIG. 2 is a flowchart for explaining Bi prediction (bidirectional prediction), which is one of the processes of the inter PU in the case of FIG.
  • step S1 inter prediction parameters are acquired.
  • an L0 prediction block is generated.
  • step S3 an L1 prediction block is generated.
  • step S4 a Bi prediction block PU is generated from the L0 prediction block and the L1 prediction block.
  • FIG. 3 is a diagram showing an example in which a VPDU is introduced to efficiently form a pipeline.
  • FIG. 3 Each block of CU, inter PU, and TU is shown on the upper side of FIG. Unlike FIG. 1, the CU is composed of CU(0) to CU(3) divided by the PU being virtually divided into the vPUs and processed.
  • the PU is composed of virtual vPU(0) to vPU(3).
  • a pipeline consisting of inter-PU processing, TU processing, and local decoding processing is shown.
  • vPU(0) to vPU(3) processing and TU0 to TU3 processing in the inter PU are performed in parallel. Therefore, when the processing of vPU(0) and the processing of TU0 are completed, the local decoding processing of CU(0) is started.
  • the local decoding processing of CU(1) is started.
  • the processing of vPU(2) and the processing of TU2 are completed, the local decoding processing of CU(2) is started.
  • the processing of vPU(3) and the processing of TU3 are completed, the local decoding processing of CU(3) is started.
  • the inter-PU processing By constructing a pipeline in this way, it is sufficient for the inter-PU processing to have a 64 ⁇ 64 buffer, and the size of the vPU waiting buffer for TU processing is 64 ⁇ 64.
  • Bi prediction is one of the processes of the inter PU in the case of FIG.
  • step S11 inter prediction parameters are acquired.
  • step S12 the number of vPUs included in the PU is acquired.
  • step S13 vPU number is set to 0.
  • step S14 it is determined whether the vPU number is smaller than the vPU number.
  • the process proceeds to step S15.
  • step S15 the vPU position and size within the PU are acquired from the vPU number.
  • step S16 the L0 prediction block in the vPU area is generated.
  • step S17 an L1 prediction block in the vPU area is generated.
  • step S18 a Bi prediction block vPU is generated from the L0 prediction block and the L1 prediction block.
  • step S19 the vPU number is incremented, then the process returns to step S14 and the subsequent processing is repeated.
  • step S14 if it is determined in step S14 that the vPU number is greater than or equal to the vPU number, Bi prediction is ended.
  • the maximum buffer size may be a VPDU size smaller than the PU.
  • the Optical Flow method is an image processing method that detects the movement of an object in a moving image and estimates in which direction it will move after a certain amount of time. Coding efficiency is improved by adding this Optical Flow method as an option of codec inter prediction. It is especially called BIO because it uses the method of Optical Flow in Bi prediction that refers to one frame before and after temporally.
  • FIG. 5 is a diagram showing an example of normal Bi prediction.
  • arrow from left to right represents the time in the display order.
  • Bi prediction values of Bi prediction blocks in B pictures an example is shown in which an optimum MV is obtained for reference plane 0 in the L0 direction and reference plane 1 in the L1 direction. The same applies to the following figures.
  • the Bi prediction value corresponds to the pixel L0 of the L0 prediction block on the reference plane 0 and the pixel L1 of the L1 prediction block on the reference plane 1, and the Bi prediction value is calculated as (L0+L1)/2.
  • FIG. 6 is a diagram showing an example of Bi prediction to which BIO is applied.
  • the prediction MV (MVP_L0, MVP_L1) is used as it is as MV (MV_L0, MV_L1), so there is no need to code the difference MV (MVD_L0, MVD_L1), so the coding efficiency improves. ..
  • FIG. 7 is a figure which shows the example of 2 block division
  • FIG. 8 is a diagram showing an example of 2-block division of Bi prediction to which BIO is applied.
  • BIO reduction methods One of the various BIO reduction methods that has been proposed is to calculate the SAD (Sum of Absolute Difference) between blocks at the stage when the L0 prediction block and the L1 prediction block are generated, and set the threshold with the SAD value. If there is a drop, BIO is not applied and normal Bi prediction is executed.
  • SAD Sud of Absolute Difference
  • the BIO reduction method described above When the BIO reduction method described above is applied, the SAD of L0 and L1 prediction blocks is calculated for the entire PU, the applicability of BIO processing is determined by comparison with the threshold value, and the processing branches. .. Therefore, it becomes difficult to virtually divide a PU into multiple vPUs when performing inter prediction with a PU larger than VPDU.
  • the buffer required for gradient calculation and velocity calculation requires a region that is slightly larger than the PU, and a large buffer resource is required in the inter prediction unit including BIO.
  • BIO reduction method when the above-mentioned BIO reduction method is implemented in HW, the pipeline delay of inter prediction including BIO and the pipeline delay of TU processing are greatly different, so the difficulty of HW implementation to maintain throughput also increases. ..
  • the processing unit e.g., PU
  • the processing unit that calculates the cost used to determine whether or not to perform bidirectional prediction such as BIO is a division processing unit (e.g., vPU) corresponding to the VPDU size or the VPDU size. It is divided into the following division processing units (for example, sPU described later), and the determination is performed using the cost calculated based on the division processing units.
  • the VPDU size equivalent indicates a size that is slightly larger than the VPDU size.
  • a is larger than B with respect to the block size means “the horizontal size of A is larger than the horizontal size of B” or “the vertical size of A is larger than the vertical size of B”. To do.
  • A is B or less
  • the block size means "the horizontal size of A is less than or equal to the horizontal size of B, and the vertical size of A is less than or equal to the vertical size of B".
  • FIG. 9 is a block diagram showing a configuration example of an encoding device according to an embodiment of the present technology.
  • the encoding device 1 of FIG. 9 includes an A/D conversion unit 31, a screen rearrangement buffer 32, a calculation unit 33, an orthogonal conversion unit 34, a quantization unit 35, a lossless encoding unit 36, a storage buffer 37, and an inverse quantization unit. 38, an inverse orthogonal transformation unit 39, and an addition unit 40.
  • the encoding device 1 also includes a deblocking filter 41, an adaptive offset filter 42, an adaptive loop filter 43, a frame memory 44, a switch 45, an intra prediction unit 46, a motion prediction/compensation unit 47, a predicted image selection unit 48, and a rate. It has a control unit 49.
  • the A/D conversion unit 31 performs A/D conversion on the input frame-based image to be encoded.
  • the A/D conversion unit 31 outputs the image, which is the converted digital signal, to the screen rearrangement buffer 32 and stores it.
  • the screen rearrangement buffer 32 rearranges images in frame units in display order in encoding order according to the GOP structure.
  • the screen rearrangement buffer 32 outputs the rearranged images to the calculation unit 33, the intra prediction unit 46, and the motion prediction/compensation unit 47.
  • the arithmetic unit 33 performs encoding by subtracting the predicted image supplied from the predicted image selection unit 48 from the image supplied from the screen rearrangement buffer 32.
  • the calculation unit 33 outputs the image after the subtraction to the orthogonal transformation unit 34 as residual information (difference).
  • the calculation unit 33 outputs the image read from the screen rearrangement buffer 32 to the orthogonal transformation unit 34 as the residual information as it is.
  • the orthogonal transform unit 34 performs an orthogonal transform process on the residual information from the calculation unit 33.
  • the orthogonal transformation unit 34 outputs the image after the orthogonal transformation processing to the quantization unit 35.
  • the quantizer 35 quantizes the image after the orthogonal transform process supplied from the orthogonal transformer 34.
  • the quantization unit 35 outputs the quantized quantized value to the lossless encoding unit 36.
  • the lossless encoding unit 36 acquires intra prediction mode information, which is information indicating the optimum intra prediction mode, from the intra prediction unit 46.
  • the lossless encoding unit 36 also acquires inter prediction mode information, which is information indicating the optimum inter prediction mode, and inter prediction parameters such as motion information and reference image information from the motion prediction/compensation unit 47.
  • the lossless encoding unit 36 acquires the offset filter information regarding the offset filter from the adaptive offset filter 42, and acquires the filter coefficient from the adaptive loop filter 43.
  • the lossless encoding unit 36 performs variable-length encoding (for example, CAVLC (Context-Adaptive Variable Length Coding)) and arithmetic encoding (for example, CABAC (Context-Context) on the quantized value supplied from the quantization unit 35.
  • variable-length encoding for example, CAVLC (Context-Adaptive Variable Length Coding)
  • CABAC Context-Context
  • Reversible encoding such as Adaptive Binary Arithmetic Coding
  • the lossless encoding unit 36 losslessly encodes the intra prediction mode information, or the inter prediction mode information, the parameters of the inter prediction, the offset filter information, and the filter coefficient as the encoding information regarding the encoding.
  • the lossless encoding unit 36 outputs the lossless-encoded encoding information and the quantized value to the accumulation buffer 37 as encoded data and accumulates them.
  • the accumulation buffer 37 temporarily stores the encoded data supplied from the lossless encoding unit 36. Further, the accumulation buffer 37 outputs the stored encoded data to the subsequent stage as an encoded stream.
  • the quantized value output from the quantizer 35 is also input to the inverse quantizer 38.
  • the inverse quantization unit 38 inversely quantizes the quantized value.
  • the inverse quantization unit 38 outputs the inverse transformation result of the orthogonal transformation process to the inverse orthogonal transformation unit 39.
  • the inverse orthogonal transform unit 39 performs an inverse orthogonal transform process on the orthogonal transform process result supplied from the inverse quantization unit 38.
  • Examples of the inverse orthogonal transform method include IDCT (inverse discrete cosine transform) and IDST (inverse discrete sine transform).
  • IDCT inverse discrete cosine transform
  • IDST inverse discrete sine transform
  • the addition unit 40 adds the residual information supplied from the inverse orthogonal transform unit 39 and the prediction image supplied from the prediction image selection unit 48, and performs decoding.
  • the addition unit 40 outputs the decoded image to the deblocking filter 41 and the frame memory 44.
  • the deblock filter 41 performs a deblock filter process for removing block distortion on the decoded image supplied from the addition unit 40.
  • the deblocking filter 41 outputs the image after the deblocking filter processing to the adaptive offset filter 42.
  • the adaptive offset filter 42 performs an adaptive offset filter (SAO (Sample adaptive offset)) process that mainly removes ringing on the image after the deblocking filter process by the deblocking filter 41.
  • SAO Sample adaptive offset
  • the adaptive offset filter 42 outputs the image after the adaptive offset filter processing to the adaptive loop filter 43. Further, the adaptive offset filter 42 outputs information indicating the type and offset of the adaptive offset filter processing to the lossless encoding unit 36 as offset filter information.
  • the adaptive loop filter 43 is composed of, for example, a two-dimensional Wiener filter.
  • the adaptive loop filter 43 performs an adaptive loop filter (ALF (Adaptive Loop Filter)) process on the image after the adaptive offset filter process.
  • ALF Adaptive Loop Filter
  • the adaptive loop filter 43 outputs the image after the adaptive loop filter processing to the frame memory 44.
  • the adaptive loop filter 43 outputs the filter coefficient used for the adaptive loop filter process to the lossless encoding unit 36.
  • the frame memory 44 stores the image supplied from the adaptive loop filter 43 and the image supplied from the addition unit 40.
  • the image adjacent to the CU among the images that have not been subjected to the filter processing accumulated in the frame memory 44 are output to the intra prediction unit 46 via the switch 45 as peripheral images.
  • the filtered image accumulated in the frame memory 44 is output to the motion prediction/compensation unit 47 via the switch 45 as a reference image.
  • the intra-prediction unit 46 performs intra-prediction processing in all candidate intra-prediction modes using the peripheral image read from the frame memory 44 via the switch 45 in units of PU.
  • the intra prediction unit 46 calculates the RD cost for all candidate intra prediction modes based on the image read from the screen rearrangement buffer 32 and the predicted image predicted by the intra prediction process. To do. The intra prediction unit 46 determines the intra prediction mode in which the calculated RD cost is the minimum as the optimum intra prediction mode.
  • the intra prediction unit 46 outputs the prediction image generated in the optimum intra prediction mode to the prediction image selection unit 48.
  • the intra prediction unit 46 outputs the intra prediction mode information to the lossless encoding unit 36 when the selection of the predicted image generated in the optimum intra prediction mode is notified.
  • the intra prediction mode is a mode that represents the size of the PU, the prediction direction, and the like.
  • the motion prediction/compensation unit 47 performs motion prediction/compensation processing for all candidate inter prediction modes.
  • the motion prediction/compensation unit 47 includes an inter prediction unit 51 that compensates the predicted motion and generates a predicted image.
  • the motion prediction/compensation unit 47 based on the image supplied from the screen rearrangement buffer 32 and the reference image read from the frame memory 44 via the switch 45, motion information (motion information) of all candidate inter prediction modes. Vector).
  • the motion prediction/compensation unit 47 supplies the inter prediction unit 51 with the PU position in the frame, the PU size, the prediction direction, the reference image information, the motion information, etc., which correspond to the detected motion information, as an inter prediction parameter. ..
  • the inter prediction unit 51 uses the parameters of inter prediction supplied from the motion prediction/compensation unit 47 to generate a predicted image by Bi prediction including BIO processing.
  • the motion prediction/compensation unit 47 calculates the RD cost for all candidate inter prediction modes based on the image supplied from the screen rearrangement buffer 32 and the predicted image generated by the inter prediction unit 51. To do. The motion prediction/compensation unit 47 determines the inter prediction mode that minimizes the RD cost as the optimum inter prediction mode.
  • the determined RD cost and the predicted image in the optimum inter prediction mode are output to the predicted image selection unit 48.
  • the inter prediction parameter corresponding to the determined optimum inter prediction mode is output to the lossless encoding unit 36.
  • the predicted image selection unit 48 selects the optimum intra prediction mode supplied from the intra prediction unit 46 or the optimum inter prediction mode supplied from the motion prediction/compensation unit 47, whichever has the smaller RD cost, as the optimum prediction mode. To decide. Then, the predicted image selection unit 48 outputs the predicted image in the optimum prediction mode to the calculation unit 33 and the addition unit 40.
  • the rate control unit 49 controls the rate of the quantization operation of the quantization unit 35 based on the encoded data accumulated in the accumulation buffer 37 so that overflow or underflow does not occur.
  • step S31 of FIG. 10 the A/D conversion unit 31 performs A/D conversion on the frame-based image input as an encoding target.
  • the A/D conversion unit 31 outputs the image, which is the converted digital signal, to the screen rearrangement buffer 32 and stores it.
  • step S32 the screen rearrangement buffer 32 rearranges the images of the frames in the display order in the encoding order according to the GOP structure.
  • the screen rearrangement buffer 32 outputs the rearranged frame-based image to the calculation unit 33, the intra prediction unit 46, and the motion prediction/compensation unit 47.
  • step S33 the intra prediction unit 46 performs intra prediction processing in all candidate intra prediction modes. Further, the intra prediction unit 46 calculates the RD cost for all candidate intra prediction modes based on the image read from the screen rearrangement buffer 32 and the predicted image predicted by the intra prediction process. To do. The intra prediction unit 46 determines the intra prediction mode that minimizes the RD cost as the optimum intra prediction mode. The intra prediction unit 46 outputs the prediction image generated in the optimum intra prediction mode to the prediction image selection unit 48.
  • step S34 the motion prediction/compensation unit 47 performs motion prediction/compensation processing in all candidate inter prediction modes.
  • the motion prediction/compensation unit 47 based on the image supplied from the screen rearrangement buffer 32 and the reference image read from the frame memory 44 via the switch 45, motion information (motion information) of all candidate inter prediction modes. Vector).
  • the inter prediction unit 51 uses the parameters of inter prediction supplied from the motion prediction/compensation unit 47 to generate a predicted image by Bi prediction including BIO processing.
  • the motion prediction/compensation unit 47 calculates the RD cost for all candidate inter prediction modes based on the image supplied from the screen rearrangement buffer 32 and the predicted image generated by the inter prediction unit 51. To do. The motion prediction/compensation unit 47 determines the inter prediction mode that minimizes the RD cost as the optimum inter prediction mode.
  • the determined RD cost and the predicted image in the optimum inter prediction mode are output to the predicted image selection unit 48.
  • the inter prediction parameter in the determined optimum inter prediction mode is output to the lossless encoding unit 36.
  • step S35 the prediction image selection unit 48 determines the one with the smallest RD cost as the optimum prediction mode based on the RD costs in the optimum intra prediction mode and the optimum inter prediction mode. Then, the predicted image selection unit 48 outputs the predicted image in the optimum prediction mode to the calculation unit 33 and the addition unit 40.
  • step S36 the prediction image selection unit 48 determines whether the optimum prediction mode is the optimum inter prediction mode. When it is determined in step S36 that the optimum prediction mode is the optimum inter prediction mode, the prediction image selection unit 48 notifies the motion prediction/compensation unit 47 of the selection of the prediction image generated in the optimum inter prediction mode.
  • step S37 the motion prediction/compensation unit 47 outputs the inter prediction mode information and the parameters of the inter prediction to the lossless encoding unit 36. Then, a process progresses to step S39.
  • step S36 when the optimum prediction mode is the optimum intra prediction mode in step S36, the prediction image selection unit 48 notifies the intra prediction unit 46 of the selection of the prediction image generated in the optimum intra prediction mode. Then, in step S38, the intra prediction unit 46 outputs the intra prediction mode information to the lossless encoding unit 36. Then, a process progresses to step S39.
  • step S39 the calculation unit 33 performs encoding by subtracting the predicted image supplied from the predicted image selection unit 48 from the image supplied from the screen rearrangement buffer 32.
  • the calculation unit 33 outputs the image after the subtraction to the orthogonal transformation unit 34 as residual information.
  • step S40 the orthogonal transform unit 34 performs an orthogonal transform process on the residual information.
  • the orthogonal transform unit 34 outputs the result of the orthogonal transform process after the orthogonal transform process to the quantization unit 35.
  • step S41 the quantization unit 35 quantizes the orthogonal transformation processing result supplied from the orthogonal transformation unit 34.
  • the quantization unit 35 outputs the quantized quantized value to the lossless encoding unit 36 and the inverse quantization unit 38.
  • step S42 of FIG. 11 the inverse quantization unit 38 inversely quantizes the quantized value from the quantization unit 35.
  • the inverse quantization unit 38 outputs the inverse transformation result of the orthogonal transformation process to the inverse orthogonal transformation unit 39.
  • step S43 the inverse orthogonal transform unit 39 performs an inverse orthogonal transform process on the result of the orthogonal transform process.
  • the inverse orthogonal transform unit 39 outputs the residual information after the inverse orthogonal transform process to the addition unit 40.
  • step S44 the addition unit 40 adds the residual information supplied from the inverse orthogonal transform unit 39 and the prediction image supplied from the prediction image selection unit 48, and performs decoding.
  • the addition unit 40 outputs the decoded image to the deblocking filter 41 and the frame memory 44.
  • step S45 the deblocking filter 41 performs deblocking filter processing on the image supplied from the adding unit 40.
  • the deblocking filter 41 outputs the image after the deblocking filter processing to the adaptive offset filter 42.
  • step S46 the adaptive offset filter 42 performs adaptive offset filter processing on the image after the deblocking filter processing.
  • the adaptive offset filter 42 outputs the image after the adaptive offset filter processing to the adaptive loop filter 43.
  • the adaptive offset filter 42 outputs the offset filter information to the lossless encoding unit 36.
  • step S47 the adaptive loop filter 43 performs an adaptive loop filter process on the image after the adaptive offset filter process.
  • the adaptive loop filter 43 outputs the image after the adaptive loop filter processing to the frame memory 44.
  • the adaptive loop filter 43 also outputs the filter coefficient used in the adaptive loop filter process to the lossless encoding unit 36.
  • step S48 the frame memory 44 stores the image supplied from the adaptive loop filter 43 and the image supplied from the addition unit 40.
  • the image adjacent to the CU among the images that have not been subjected to the filter processing accumulated in the frame memory 44 are output to the intra prediction unit 46 via the switch 45 as peripheral images.
  • the filtered image accumulated in the frame memory 44 is output to the motion prediction/compensation unit 47 via the switch 45 as a reference image.
  • step S49 the lossless encoding unit 36 losslessly encodes the intra prediction mode information, the inter prediction mode information, the parameters of the inter prediction, the offset filter information, and the filter coefficient as the encoding information.
  • step S50 the lossless encoding unit 36 losslessly encodes the quantized value supplied from the quantization unit 35. Then, the lossless encoding unit 36 generates encoded data from the encoding information losslessly encoded in the process of step S49 and the quantization value losslessly encoded, and outputs the encoded data to the accumulation buffer 37.
  • step S51 the accumulation buffer 37 temporarily accumulates the encoded data supplied from the lossless encoding unit 36.
  • step S52 the rate control unit 49 controls the rate of the quantization operation of the quantization unit 35 based on the encoded data accumulated in the accumulation buffer 37 so that overflow or underflow does not occur. Then, the encoding process ends.
  • FIG. 12 is a block diagram showing a configuration example of an embodiment of a decoding device to which the present disclosure is applied, which decodes an encoded stream transmitted from the encoding device of FIG. 9.
  • the decoding device 101 of FIG. 12 includes a storage buffer 131, a lossless decoding unit 132, an inverse quantization unit 133, an inverse orthogonal transformation unit 134, an addition unit 135, a deblocking filter 136, an adaptive offset filter 137, an adaptive loop filter 138, and a screen. It has a rearrangement buffer 139.
  • the decoding device 101 also includes a D/A conversion unit 140, a frame memory 141, a switch 142, an intra prediction unit 143, an inter prediction unit 51, and a switch 144.
  • the accumulation buffer 131 of the decoding device 101 receives and accumulates the encoded data of the encoded stream transmitted from the encoding device 1 of FIG.
  • the accumulation buffer 131 outputs the accumulated encoded data to the lossless decoding unit 132.
  • the lossless decoding unit 132 obtains a quantized value and coding information by performing lossless decoding such as variable length decoding and arithmetic decoding on the coded data from the accumulation buffer 131.
  • the lossless decoding unit 132 outputs the quantized value to the inverse quantization unit 133.
  • the coding information includes intra prediction mode information, inter prediction mode information, inter prediction parameters, offset filter information, filter coefficients, and the like.
  • the lossless decoding unit 132 also outputs intra prediction mode information and the like to the intra prediction unit 143.
  • the lossless decoding unit 132 outputs inter prediction parameters, inter prediction mode information, and the like to the inter prediction unit 51.
  • the lossless decoding unit 132 outputs the intra prediction mode information or the inter prediction mode information to the switch 144.
  • the lossless decoding unit 132 outputs the offset filter information to the adaptive offset filter 137.
  • the lossless decoding unit 132 outputs the filter coefficient to the adaptive loop filter 138.
  • the same processing as that of the compensation unit 47 is performed. As a result, the image is decoded.
  • the dequantization unit 133 has the same configuration as the dequantization unit 38 in FIG. 9.
  • the inverse quantization unit 133 inversely quantizes the quantized value from the lossless decoding unit 132.
  • the inverse quantization unit 133 outputs the inverse-quantized orthogonal transformation processing result to the inverse orthogonal transformation unit 134.
  • the inverse orthogonal transform unit 134 is configured similarly to the inverse orthogonal transform unit 39 of FIG.
  • the inverse orthogonal transform unit 134 performs the inverse orthogonal transform process on the orthogonal transform process result supplied from the inverse quantization unit 133.
  • the inverse orthogonal transform unit 134 outputs the residual information after the inverse orthogonal transform process to the addition unit 135.
  • the addition unit 135 performs decoding by adding the residual information supplied from the inverse orthogonal transform unit 134 and the prediction image supplied from the switch 144.
  • the addition unit 135 outputs the decoded image to the deblocking filter 136 and the frame memory 141.
  • the deblock filter 136 performs deblock filter processing on the image supplied from the addition unit 135, and outputs the image after the deblock filter processing to the adaptive offset filter 137.
  • the adaptive offset filter 137 uses the offset represented by the offset filter information from the lossless decoding unit 132 to perform the adaptive offset filter processing of the type represented by the offset filter information on the image after the deblocking filter processing.
  • the adaptive offset filter 137 outputs the image after the adaptive offset filter processing to the adaptive loop filter 138.
  • the adaptive loop filter 138 performs adaptive loop filter processing on the image supplied from the adaptive offset filter 137 using the filter coefficient supplied from the lossless decoding unit 132.
  • the adaptive loop filter 138 outputs the image after the adaptive loop filter processing to the frame memory 141 and the screen rearrangement buffer 139.
  • the screen rearrangement buffer 139 stores the image after the adaptive loop filter processing in frame units.
  • the screen rearrangement buffer 139 rearranges the images in frame units in the encoding order in the original display order and outputs the rearranged images to the D/A conversion unit 140.
  • the D/A conversion unit 140 D/A converts the image in frame units supplied from the screen rearrangement buffer 139 and outputs it.
  • the frame memory 141 stores the image after the adaptive loop filter processing and the image supplied from the addition unit 135.
  • the image adjacent to the CU among the images that have not been subjected to the filter processing accumulated in the frame memory 141 are supplied to the intra prediction unit 143 via the switch 142 as peripheral images.
  • the filtered image accumulated in the frame memory 141 is output as a reference image to the inter prediction unit 51 via the switch 142.
  • the intra prediction unit 143 performs an intra prediction process in the optimal intra prediction mode indicated by the intra prediction mode information supplied from the lossless decoding unit 132 using the peripheral image read from the frame memory 141 via the switch 142.
  • the intra prediction unit 143 outputs the predicted image generated as a result to the switch 144.
  • the inter prediction unit 51 has the same configuration as in FIG.
  • the inter prediction unit 51 uses the parameters of the inter prediction supplied from the lossless decoding unit 132 to perform inter prediction in the optimum inter prediction mode indicated by the inter prediction mode information and generate a predicted image.
  • the inter prediction unit 51 reads out the reference image specified by the reference image information of the inter prediction parameter supplied from the lossless decoding unit 132 from the frame memory 141 via the switch 142.
  • the inter prediction unit 51 uses the motion information of the parameters of inter prediction supplied from the lossless decoding unit 132 and the read reference image to generate a prediction image by Bi prediction including BIO processing.
  • the generated predicted image is output to the switch 144.
  • the switch 144 When the intra prediction mode information is supplied from the lossless decoding unit 132, the switch 144 outputs the prediction image supplied from the intra prediction unit 143 to the addition unit 135. On the other hand, when the inter prediction mode information is supplied from the lossless decoding unit 132, the switch 144 outputs the predicted image supplied from the inter prediction unit 51 to the addition unit 135.
  • FIG. 13 is a flowchart illustrating details of the decoding process of the decoding device.
  • step S131 of FIG. 13 the accumulation buffer 131 of the decoding device 101 receives and accumulates the encoded data in frame units supplied from the preceding stage (not shown).
  • the accumulation buffer 131 outputs the accumulated encoded data to the lossless decoding unit 132.
  • step S132 the lossless decoding unit 132 losslessly decodes the encoded data from the accumulation buffer 131 to obtain a quantized value and encoded information.
  • the lossless decoding unit 132 outputs the quantized value to the inverse quantization unit 133.
  • the lossless decoding unit 132 outputs the intra prediction mode information and the like to the intra prediction unit 143.
  • the lossless decoding unit 132 outputs inter prediction parameters, inter prediction mode information, and the like to the inter prediction unit 51.
  • the lossless decoding unit 132 also outputs the intra prediction mode information or the inter prediction mode information to the switch 144.
  • the lossless decoding unit 132 supplies the offset filter information to the adaptive offset filter 137 and outputs the filter coefficient to the adaptive loop filter 138.
  • step S133 the dequantization unit 133 dequantizes the quantized value supplied from the lossless decoding unit 132.
  • the inverse quantization unit 133 outputs the inverse-quantized orthogonal transformation processing result to the inverse orthogonal transformation unit 134.
  • step S134 the inverse orthogonal transform unit 134 performs the orthogonal transform process on the orthogonal transform process result supplied from the inverse quantization unit 133.
  • step S135 the inter prediction unit 51 determines whether the inter prediction mode information is supplied from the lossless decoding unit 132. If it is determined in step S135 that the inter prediction mode information has been supplied, the process proceeds to step S136.
  • step S136 the inter prediction unit 51 reads the reference image based on the reference image identification information supplied from the lossless decoding unit 132, and uses the motion information and the reference image to determine the optimum inter prediction mode indicated by the inter prediction mode information. Perform motion compensation processing. For example, the inter prediction unit 51 generates a predicted image by Bi prediction including BIO processing. The inter prediction unit 51 outputs the generated predicted image to the addition unit 135 via the switch 144. Then, a process progresses to step S138.
  • step S135 determines whether the inter prediction mode information is supplied. If it is determined in step S135 that the inter prediction mode information is not supplied, that is, if the intra prediction mode information is supplied to the intra prediction unit 143, the process proceeds to step S137.
  • step S137 the intra prediction unit 143 uses the peripheral image read from the frame memory 141 via the switch 142 to perform intra prediction processing in the intra prediction mode indicated by the intra prediction mode information.
  • the intra prediction unit 143 outputs the predicted image generated as a result of the intra prediction process to the addition unit 135 via the switch 144. Then, a process progresses to step S138.
  • step S138 the addition unit 135 performs decoding by adding the residual information supplied from the inverse orthogonal transform unit 134 and the prediction image supplied from the switch 144.
  • the addition unit 135 outputs the decoded image to the deblocking filter 136 and the frame memory 141.
  • step S139 the deblocking filter 136 performs deblocking filter processing on the image supplied from the adding unit 135 to remove block distortion.
  • the deblocking filter 136 outputs the image after the deblocking filter processing to the adaptive offset filter 137.
  • step S140 the adaptive offset filter 137 performs adaptive offset filter processing on the image after deblocking filter processing based on the offset filter information supplied from the lossless decoding unit 132.
  • the adaptive offset filter 137 outputs the image after the adaptive offset filter processing to the adaptive loop filter 138.
  • step S141 the adaptive loop filter 138 performs adaptive loop filter processing on the image supplied from the adaptive offset filter 137 using the filter coefficient supplied from the lossless decoding unit 132.
  • the adaptive loop filter 138 supplies the image after the adaptive loop filter processing to the frame memory 141 and the screen rearrangement buffer 139.
  • step S142 the frame memory 141 stores the image supplied from the addition unit 135 and the image supplied from the adaptive loop filter 138.
  • the image adjacent to the CU among the images that have not been subjected to the filter processing accumulated in the frame memory 141 are supplied to the intra prediction unit 143 via the switch 142 as peripheral images.
  • the filtered image accumulated in the frame memory 141 is supplied as a reference image to the inter prediction unit 51 via the switch 142.
  • step S143 the screen rearrangement buffer 139 stores the images supplied from the adaptive loop filter 138 on a frame-by-frame basis, rearranges the images on a frame-by-frame basis in the encoding order in the original display order, and the D/A converter 140 Output to.
  • step S144 the D/A conversion unit 140 D/A converts the image after the adaptive loop filter processing and outputs the image.
  • FIG. 14 is a block diagram showing a configuration example of the inter prediction unit.
  • the inter prediction unit 51 includes an inter prediction control unit 201, an L0 prediction block generation unit 202, an L1 prediction block generation unit 203, a BIO cost calculation unit 204, a BIO application determination unit 205, a Bi prediction block generation unit 206, and a BIO. It includes a Bi prediction block generation unit 207 including processing, a Bi prediction block selection unit 208, and a prediction block selection unit 209.
  • the inter prediction control unit 201 is supplied with inter prediction parameters from the motion prediction/compensation unit 47 in the case of the encoding device 1 (from the lossless decoding unit 132 in the case of the decoding device 101).
  • Inter prediction parameters consist of PU position in frame, PU size, prediction direction (one of L0, L1, Bi is set), reference image information, motion information, etc.
  • the inter prediction control unit 201 includes, for example, a CPU (Central Processing Unit), a microprocessor, and the like.
  • the inter prediction control unit 201 executes a predetermined program by the CPU and controls each unit according to the content of the inter prediction parameter.
  • the inter prediction control unit 201 supplies L0 prediction parameters to the L0 prediction block generation unit 202 and controls the L0 prediction block generation unit 202.
  • the parameters of L0 prediction include PU position, PU size, reference image information REFIDX_L0, and motion information MV_L0.
  • the inter prediction control unit 201 supplies L1 prediction parameters to the L1 prediction block generation unit 203 and controls the L1 prediction block generation unit 203.
  • the parameters of L1 prediction include PU position, PU size, reference image information REFIDX_L1, and motion information MV_L1.
  • the inter prediction control unit 201 supplies the parameters of the Bi prediction to the BIO cost calculation unit 204, the Bi prediction block generation unit 206, and the Bi prediction block generation unit 207 including the BIO process, and the BIO cost calculation unit 204 and the Bi prediction block.
  • the generation unit 206 and the Bi prediction block generation unit 207 including the BIO process are controlled. Parameters of Bi prediction include PU size and the like.
  • the inter prediction control unit 201 supplies the BIO threshold to the BIO application determination unit 205 and controls the BIO application determination unit 205.
  • the inter prediction control unit 201 supplies the prediction direction to the prediction block selection unit 209 and controls the prediction block selection unit 209.
  • the L0 prediction block generation unit 202 operates when the prediction direction is L0 or Bi.
  • the L0 prediction block generation unit 202 accesses the frame memory 44 based on the L0 prediction parameter supplied from the inter prediction control unit 201, and generates the L0 prediction image from the reference image.
  • the generated L0 prediction image is generated from the L0 prediction block generation unit 202, BIO cost calculation unit 204, BIO application determination unit 205, Bi prediction block generation unit 206, Bi prediction block generation unit 207 including BIO processing, and prediction block selection. Is supplied to the unit 209.
  • the L1 prediction block generation unit 203 operates when the prediction direction is L1 or Bi.
  • the L1 prediction block generation unit 203 accesses the frame memory 44 based on the L1 prediction parameter supplied from the inter prediction control unit 201, and generates the L1 prediction image from the reference image.
  • the generated L1 predicted image includes a BIO cost calculation unit 204, a BIO application determination unit 205, a Bi prediction block generation unit 206, a Bi prediction block generation unit 207 including BIO processing, and a prediction block selection from the L1 prediction block generation unit 203. Is supplied to the unit 209.
  • the BIO cost calculation unit 204 operates when the prediction direction is Bi.
  • the BIO cost calculation unit 204 based on the Bi prediction parameters supplied from the inter prediction control unit 201, the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction supplied from the L1 prediction block generation unit 203. Calculate SAD with images.
  • the calculated SAD is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • the BIO application determination unit 205 operates when the prediction direction is Bi.
  • the determined BIO_ON flag is supplied from the BIO application determination unit 205 to the Bi prediction block generation unit 206, the Bi prediction block generation unit 207 including BIO processing, and the Bi prediction block selection unit 208.
  • the Bi prediction block generation unit 206 receives the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction block supplied from the L1 prediction block generation unit 203 based on the Bi prediction parameters supplied from the inter prediction control unit 201.
  • a Bi predicted image is generated from the predicted image.
  • the generated Bi prediction image is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208.
  • the Bi prediction block generation unit 206 receives the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction block supplied from the L1 prediction block generation unit 203 based on the Bi prediction parameters supplied from the inter prediction control unit 201.
  • a Bi predicted image including BIO processing is generated from the predicted image.
  • the generated Bi prediction image including the BIO process is supplied from the Bi prediction block generation unit 207 including the BIO process to the Bi prediction block selection unit 208.
  • the Bi prediction block selection unit 208 selects a Bi prediction image based on the BIO_ON flag supplied from the BIO application determination unit 205.
  • the selected Bi prediction image is supplied from the Bi prediction block selection unit 208 to the prediction block selection unit 209.
  • the prediction block selection unit 209 selects a prediction image according to the prediction direction supplied from the inter prediction control unit 201, and uses the selected prediction image as a prediction image for inter prediction, the prediction image selection unit in FIG. 9 in the subsequent stage. 48 (or the switch 144 of FIG. 12).
  • the prediction block selection unit 209 selects the L0 prediction image supplied from the L0 prediction block generation unit 202 when the prediction direction is L0, and is supplied from the L1 prediction block generation unit 203 when the prediction direction is L1. Select the L1 prediction image.
  • the prediction block selection unit 209 selects the Bi prediction image supplied from the Bi prediction block selection unit 208.
  • ⁇ Operation example of inter prediction unit> 15 and 16 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51.
  • this process is a Bi prediction process that includes a conventional BIO for comparison with a Bi prediction process that includes the BIO of the present technology described below.
  • the Bi prediction process including this BIO is a process performed on both the encoding side and the decoding side, and is a part of the motion prediction/compensation process performed in step S34 of FIG. This is a part of the inter prediction process performed in step S136.
  • step S301 of FIG. 15 the inter prediction control unit 201 acquires the parameters of the inter prediction supplied from the motion prediction/compensation unit 47.
  • the inter prediction parameter is supplied from the lossless decoding unit 132.
  • Inter prediction parameters consist of PU position in frame, PU size, prediction direction (one of L0, L1, Bi is set), reference image information, motion information, etc.
  • the inter prediction control unit 201 supplies the L0 prediction parameter to the L0 prediction block generation unit 202.
  • the parameters of L0 prediction include PU position, PU size, reference image information REFIDX_L0, and motion information MV_L0.
  • the inter prediction control unit 201 supplies the L1 prediction parameter to the L1 prediction block generation unit 203.
  • the parameters of L1 prediction include PU position, PU size, reference image information REFIDX_L1, and motion information MV_L1.
  • the inter prediction control unit 201 supplies the Bi prediction parameter to the BIO cost calculation unit 204, Bi prediction block generation unit 206, and Bi prediction block generation unit 207 including BIO processing.
  • the Bi prediction parameter is information indicating the PU size.
  • the inter prediction control unit 201 supplies the BIO threshold to the BIO application determination unit 205.
  • the inter prediction control unit 201 supplies the prediction direction to the prediction block selection unit 209 and controls the prediction block selection unit 209.
  • step S302 the L0 prediction block generation unit 202 accesses the frame memory 44 based on the L0 prediction parameter supplied from the inter prediction control unit 201, and generates an L0 prediction block from the reference image.
  • the reference image is accessed and referred to the frame memory 141.
  • step S303 the L1 prediction block generation unit 203 accesses the frame memory 44 based on the L1 prediction parameter supplied from the inter prediction control unit 201, and generates an L1 prediction block from the reference image.
  • the maximum buffer size in the processing of steps S302 and S303 is the PU' size.
  • the PU' size is a size corresponding to the size of the PU and is one size larger than the size of the PU.
  • step S304 the BIO cost calculation unit 204 calculates the SAD of the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203 in 4 ⁇ 4 units. .. SAD_4 ⁇ 4 block, which is the sum of SADs, is acquired by calculating and stacking SAD in units of 4 ⁇ 4.
  • step S305 the BIO cost calculation unit 204 calculates, for each PU, the SAD of the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • SAD_PU which is the sum of SADs, is obtained by calculating and stacking SADs for each PU.
  • the acquired SAD_PU is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • the determined BIO_PU_ON flag is supplied from the BIO application determination unit 205 to the Bi prediction block generation unit 206, the Bi prediction block generation unit 207 including BIO processing, and the Bi prediction block selection unit 208.
  • step S307 the Bi prediction block generation unit 206 and the Bi prediction block generation unit 207 including the BIO process determine whether or not the BIO_PU_ON flag is 1.
  • step S307 If it is determined in step S307 that the BIO_PU_ON flag is not 1, the process proceeds to step S308.
  • step S308 the Bi prediction block generation unit 206 generates a Bi prediction block PU from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • the generated Bi prediction block PU is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208. Then, the Bi prediction process including BIO is ended.
  • the maximum buffer size in the process of step S308 is the PU size.
  • step S307 if it is determined in step S307 that the BIO_PU_ON flag is 1, the process proceeds to step S309.
  • the Bi prediction block generation unit 207 including the BIO process performs the Bi prediction image generation process including the BIO process.
  • step S309 the Bi prediction block generation unit 207 including the BIO process determines a plurality of gradients from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203. calculate.
  • the maximum buffer size in the process of step S309 is PU′ size ⁇ 9.
  • step S310 the Bi prediction block generation unit 207 including BIO processing acquires the number of 4 ⁇ 4 blocks included in the PU.
  • step S311 the Bi prediction block generation unit 207 including the BIO process sets 0 to the 4 ⁇ 4 block number.
  • step S312 of FIG. 16 the Bi prediction block generation unit 207 including the BIO process determines whether the 4 ⁇ 4 block number is smaller than the 4 ⁇ 4 block number.
  • step S312 If it is determined in step S312 that the 4 ⁇ 4 block number is smaller than the number of 4 ⁇ 4 blocks, the process proceeds to step S313.
  • step S313 the Bi prediction block generation unit 207 including the BIO process acquires the position in the PU and SAD_4 ⁇ 4 from the 4 ⁇ 4 block number.
  • step S315 the Bi prediction block generation unit 207 including BIO processing determines whether or not the BIO_4 ⁇ 4_ON flag is 1.
  • step S315 If it is determined in step S315 that the BIO_4 ⁇ 4_ON flag is not 1, the process proceeds to step S316.
  • step S316 the Bi prediction block generation unit 207 including the BIO process generates a Bi prediction value from the L0 prediction image and the L1 prediction image in the area of 4 ⁇ 4 block numbers.
  • step S315 If it is determined in step S315 that the BIO_4 ⁇ 4_ON flag is 1, the process proceeds to step S317.
  • step S317 the Bi prediction block generation unit 207 including the BIO process calculates the speed from a plurality of gradients in the area of 4 ⁇ 4 block numbers.
  • step S318 the Bi prediction block generation unit 207 including the BIO process generates a BIO prediction value from the L0 prediction image, the L1 prediction image, the gradient, and the speed in the area of the 4 ⁇ 4 block number.
  • step S319 the Bi prediction block generation unit 207 including the BIO process stores the prediction value at the position of 4 ⁇ 4 block number in the buffer.
  • the maximum buffer size in the processing of step 319 is the PU size.
  • step S320 the Bi prediction block generation unit 207 including the BIO process increments the 4 ⁇ 4 block number. After that, the process returns to step S312 and the subsequent processes are repeated.
  • step S308 or when it is determined in step S312 that the 4 ⁇ 4 block number is not smaller than the 4 ⁇ 4 block number, Bi prediction including BIO is terminated.
  • step S305 the SADs of the L0 prediction block and the L1 prediction block are calculated for the entire PU, and in step S306, the SAD and the threshold are compared to determine whether or not the BIO process is applicable. The determination is made, and the process is branched in step S307.
  • the buffer required in steps S302, S303, and S309 needs PU', which is a region slightly larger than the PU, for the gradient calculation in step S309 and the speed calculation in step S317.
  • the maximum size of PU′ is a size of 130 ⁇ 130 which is the result of adding 2 each of the horizontal size and the vertical size of PU.
  • step S308 a PU size buffer is required. These means that the inter prediction unit 51 including BIO requires a large buffer resource.
  • the pipeline delay of the inter-prediction including BIO and the pipeline delay of the TU processing are greatly different, so that the HW for maintaining throughput is maintained.
  • the mounting difficulty also becomes high.
  • On the encoding side it is possible to avoid it by self-constraint, such as always decomposing the CU into 64 ⁇ 64 or less, but it is desirable to have a solution to secure the degree of freedom on the encoding side.
  • a large HW resource is indispensable on the decoding side that is required to conform to the standard.
  • the processing unit for calculating the cost used to determine whether or not to perform bidirectional prediction such as BIO is a division processing unit equivalent to VPDU size or a division processing unit equal to or smaller than VPDU size.
  • the cost is calculated based on the division processing unit, and the determination is performed.
  • VPDU' size which is an area slightly larger than VPDU size.
  • ⁇ Operation example of inter prediction unit> 17 and 18 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the first embodiment of the present technology.
  • step S401 the inter prediction control unit 201 acquires the parameters of inter prediction supplied from the motion prediction/compensation unit 47.
  • step S402 the inter prediction control unit 201 acquires the number of vPUs included in the PU. That is, when the PU is larger than the VPDU, the PU is virtually divided into a plurality of vPUs.
  • the PU is 128 ⁇ 128, 4 is set to the number of vPUs.
  • the PU is 128 ⁇ 64 or 64 ⁇ 128, 2 is set to the number of vPUs.
  • PU is 64x64 or less, 1 is set to the number of vPUs. If the number of vPUs is 1, virtual division is not performed, and substantially the same processing as in FIGS. 15 and 16 is performed.
  • step S403 the inter prediction control unit 201 sets 0 as the vPU number to be processed first.
  • step S404 the inter prediction control unit 201 determines whether the vPU number is smaller than the vPU number.
  • step S404 If it is determined in step S404 that the vPU number is smaller than the vPU number, the process proceeds to step S405.
  • step S405 the inter prediction control unit 201 acquires the vPU position and size indicating which area within the PU is processed from the PU size and vPU number.
  • FIG. 19 is a diagram showing a correspondence relationship between the PU size, the vPU number, the processing position and the size.
  • the processing position is at the upper left, and the size is 64x64.
  • the processing position is at the upper right, and the size is 64x64.
  • the processing position is at the lower left and the size is 64x64.
  • the processing position is at the lower right, and the size is 64x64.
  • the processing position is on the left and the size is 64x64.
  • the processing position is on the right and the size is 64x64.
  • the processing position is at the top and the size is 64x64.
  • the processing position is at the bottom and the size is 64x64.
  • the processing position is the PU itself.
  • the vPU position and size acquired in step S405 are supplied to the L0 prediction block generation unit 202 and the L1 prediction block generation unit 203.
  • step S406 the L0 prediction block generation unit 202 generates an L0 prediction block in the vPU number area.
  • step S407 the L1 prediction block generation unit 203 generates an L1 prediction block in the vPU number area.
  • the maximum buffer size in the processing of steps 406 and S407 is, for example, the VPDU' size that includes a slightly larger area required for the gradient calculation of step S413 and the speed calculation of step S421.
  • the VPDU' size represents the above-mentioned VPDU size, which is a size larger than the VPDU size, and is, for example, 66 ⁇ 66, which is the result of adding 2 to each of the horizontal and vertical sizes.
  • the buffer size for storing the L0 prediction block and L1 prediction block generated here can also be based on the VPDU size.
  • step S408 the BIO cost calculation unit 204 SADs the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203 in units of 4 ⁇ 4 in vPU.
  • SAD_4 ⁇ 4 block which is the sum of SADs, is acquired by calculating and stacking SAD in units of 4 ⁇ 4.
  • the buffer size for storing SAD_4 ⁇ 4 blocks can be reduced to 1/4 the size of that in step S304 of FIG.
  • step S409 the BIO cost calculation unit 204 calculates the SAD of the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203 for each vPU.
  • SAD_vPU which is the sum of SADs, is obtained by calculating and stacking SADs for each vPU.
  • the acquired SAD_vPU is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • the BIO threshold_vPU is a value obtained by scaling the BIO threshold_PU to a value according to the vPU size obtained in step S405.
  • the determined BIO_vPU_ON flag is supplied from the BIO application determination unit 205 to the Bi prediction block generation unit 206, the Bi prediction block generation unit 207 including BIO processing, and the Bi prediction block selection unit 208.
  • step S411 the Bi prediction block generation unit 206 and the Bi prediction block generation unit 207 including the BIO process determine whether the BIO_vPU_ON flag is 1.
  • step S411 If it is determined in step S411 that the BIO_vPU_ON flag is not 1, it is determined that BIO has no effect on the entire vPU, and the process proceeds to step S412.
  • the Bi prediction block generation unit 206 generates a Bi prediction block vPU from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • the generated Bi prediction block vPU is stored in the buffer and is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208.
  • the buffer for storing the Bi prediction prepared here may have the maximum VPDU size. Thereafter, the processing proceeds to step S425 of FIG.
  • step S411 determines whether the BIO_vPU_ON flag is 1, the process proceeds to step S413.
  • the Bi prediction block generation unit 207 including the BIO process determines a plurality of gradients from the L0 prediction block supplied from the L0 prediction block generation unit 202 and the L1 prediction block supplied from the L1 prediction block generation unit 203. calculate.
  • step S413 nine types of intermediate parameters are calculated from the L0 prediction block and the L1 prediction block. Since the amount of change between the L0 prediction block and the L1 prediction block and the amount of change of each pixel value in the horizontal and vertical directions in each prediction block are calculated, they are collectively called a gradient. Since the gradient needs to be calculated in the same number of pixels as the prediction block, the required buffer here may be the maximum VPDU′ size ⁇ 9.
  • the Bi prediction block generation unit 207 including the BIO process acquires the number of 4 ⁇ 4 blocks included in the vPU. For example, when vPU is 64 ⁇ 64, the number of 4 ⁇ 4 blocks is 256. In Optical flow, it is best to calculate the predicted value by obtaining the speed in pixel units, but this requires a huge amount of calculation. BIO balances by calculating the speed in units of 4 ⁇ 4 blocks, with a trade-off between performance and cost.
  • step S415 the Bi prediction block generation unit 207 including the BIO process sets 0 as the 4 ⁇ 4 block number to be processed first.
  • step S416 the Bi prediction block generation unit 207 including BIO processing determines whether the 4 ⁇ 4 block number is smaller than the 4 ⁇ 4 block number.
  • step S416 If it is determined in step S416 that the 4 ⁇ 4 block number is smaller than the 4 ⁇ 4 block number, the process proceeds to step S417.
  • step S417 the Bi prediction block generation unit 207 including the BIO process acquires the position in vPU and SAD_4 ⁇ 4 from the 4 ⁇ 4 block number. 4 ⁇ 4 blocks are processed in raster scan order.
  • step S419 the Bi prediction block generation unit 207 including BIO processing determines whether or not the BIO_4 ⁇ 4_ON flag is 1.
  • step S419 If it is determined in step S419 that the BIO_4 ⁇ 4_ON flag is not 1, the effect of BIO cannot be expected for the 4 ⁇ 4 block, and the process proceeds to step S420.
  • step S420 the Bi prediction block generation unit 207 including the BIO process generates a Bi prediction value by calculating the average of the L0 prediction image and the L1 prediction image in the area of 4 ⁇ 4 block numbers.
  • step S419 If it is determined in step S419 that the BIO_4 ⁇ 4_ON flag is 1, the process proceeds to step S421.
  • step S421 the Bi prediction block generation unit 207 including BIO processing calculates the speed from a plurality of gradients in the area of 4 ⁇ 4 block numbers.
  • step S422 the Bi prediction block generation unit 207 including the BIO process generates a BIO prediction value from the L0 prediction image, the L1 prediction image, the gradient, and the speed in the area of 4 ⁇ 4 block numbers.
  • the Bi prediction block generation unit 207 including the BIO process stores the prediction value generated in step S420 or step S422 in the position of 4 ⁇ 4 block number in the buffer.
  • the maximum buffer size in the processing of step 423 is the VPDU size.
  • the buffer may be shared with the buffer used in the process of S412.
  • step S424 the Bi prediction block generation unit 207 including the BIO process increments the 4 ⁇ 4 block number. Then, the process returns to step S416, and the subsequent processes are repeated.
  • step S412 if it is determined that the 4 ⁇ 4 block number is equal to or larger than the number of 4 ⁇ 4 blocks, the process proceeds to step S425.
  • step S425 the inter prediction control unit 201 increments the vPU number, returns to step S404, and the subsequent processing is repeated.
  • step S404 If it is determined in step S404 that the vPU number is greater than or equal to the vPU number, the Bi prediction including the BIO process is ended.
  • 20 and 21 are diagrams showing a comparison between the conventional operation and the operation of the first embodiment of the present technology.
  • the buffers used in steps S412, S413, and S423 of FIGS. 17 and 18 can be reduced by 1/4 as compared with the buffers used in steps S308, S309, and S319 of FIGS. 15 and 16.
  • FRUC Full Rate Up-Conversion
  • DMVR Decoder-side motion vector
  • PU is larger than VPDU, the same measure as this technology is required. Even in FRUC and DMVR, when PU is larger than VPDU as in the present technology, it can be dealt with by virtually dividing into multiple vPUs and performing MV correction for each vPU.
  • the SAD calculation and BIO application judgment of the entire PU of the conventional operation described above, or the SAD calculation and BIO application judgment of each vPU of the present technology are mainly intended for early termination in a large frame. Further reductions can be made.
  • ⁇ Modification 1> when the PU is larger than the VPDU, it is virtually divided into a plurality of vPUs, the SAD calculation is performed for each vPU, and the BIO application determination is performed. Since the vPUs that make up the PU are originally included in the same PU, it is considered that some partial tendencies are similar to the tendencies of different parts.
  • FIG. 22 and 23 are diagrams showing, as a first modification, an example in which the BIO determination result with the vPU number of 0 is also used in other vPUs as a first modification based on the above-described tendency.
  • the CU(PU) 64 ⁇ 64 or smaller the CU(PU) is composed of one vPU, which is the SAD calculation area for BIO_vPU_ON determination, is not divided.
  • ⁇ Operation example of inter prediction unit> 24 and 25 are flowcharts for explaining Bi prediction including BIO in the case of FIG.
  • steps S501 to S508 and steps S510 to S526 of FIGS. 24 and 25 perform basically the same processing as steps S401 to S425 of FIGS. 17 and 18, the description thereof will be repeated, and therefore, it will be omitted as appropriate. To be done.
  • step S508 of FIG. 25 the BIO cost calculation unit 204, in 4 ⁇ 4 units in the vPU, the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203. And calculate the SAD.
  • SAD_4 ⁇ 4 block which is the sum of SADs, is acquired by calculating and stacking SAD in units of 4 ⁇ 4.
  • step S509 the BIO cost calculation unit 204 determines whether the vPU number is 0.
  • step S509 If it is determined in step S509 that the vPU number is 0, the process proceeds to step S510.
  • step S510 the BIO cost calculation unit 204 calculates the SAD of the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203 for each vPU.
  • SAD_vPU which is the sum of SADs, is obtained by calculating and stacking SADs for each vPU.
  • the acquired SAD_vPU is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • step S510 and S511 are skipped and the process proceeds to step S512.
  • the PU is configured to stack the SAD of the vPU and determine the BIO only when the vPU is located first in the raster scan order, so the processing and processing time related to early termination can be shortened. ..
  • ⁇ Modification 2> 26 and 27 are diagrams showing, as a second modification, an example in which BIO application determination is performed based on partial SAD values in each vPU.
  • CU(PU) is the SAD calculation area for the BIO_vPU_ON judgment which is divided into two. To be done.
  • CU(PU) is the SAD calculation area for the BIO_vPU_ON judgment divided into two, and in each vPU, SAD is calculated for the upper left partial area (32 ⁇ 32) To be done.
  • CU(PU) is the SAD calculation area for the BIO_vPU_ON judgment divided into two, and in each vPU, SAD is calculated for the upper left partial area (32 ⁇ 32) To be done.
  • the CU(PU) does not divide vPU, which is the SAD calculation area for BIO_vPU_ON determination, and calculates the SAD for the upper left partial area (32 ⁇ 32).
  • FIG. 26 and FIG. 27 show an example in which the BIO application determination is performed in the upper left 1/4 area of each vPU, but the upper left 1/4 area is pipelined with HW. Compatibility with the case is also taken into consideration. BIO application determination is possible only when the L0 prediction block and the L1 prediction block in the upper left 1/4 area are ready.
  • the buffer prepared for each pipeline stage can be further reduced from the VPDU size.
  • SAD cost
  • ⁇ Operation example of inter prediction unit> 28 and 29 are flowcharts for explaining a partial SAD calculation area determination process for determining BIO_vPU_ON of each vPU.
  • two MVs for generating the L0 prediction block and the L1 prediction block are divided into four horizontal components and vertical components, and the one having the furthest reference position has the accuracy as the motion information. Assuming that the area is bad, it is judged whether or not there is an effect of correcting the area with BIO. This process is performed, for example, before step S509 in FIG. In this case, in step S509, it is possible to determine whether the area is the installed area, and the processes of steps S510 and S511 may be performed only in the set area.
  • step S601 the inter prediction control unit 201 acquires L0 predicted MVL0x and MVL0y and L1 predicted MVL1x and MVL1y.
  • step S602 the inter prediction control unit 201 selects the MV with the maximum absolute value from the four MVs and substitutes it into MV_MAX.
  • step S603 the inter prediction control unit 201 determines whether or not
  • step S603 If it is determined in step S603 that
  • step S604 the inter prediction control unit 201 sets the central part of the vPU to the SAD calculation area.
  • step S605 the inter prediction control unit 201 determines whether PU size ⁇ vPU size.
  • step S605 If it is determined in step S605 that PU size ⁇ vPU size, the process proceeds to step S606.
  • step S605 If it is determined in step S605 that PU size ⁇ vPU size is not satisfied, the process proceeds to step S607.
  • step S603 determines whether the process is satisfied. If it is determined in step S603 that
  • step S609 the inter prediction control unit 201 determines whether MV_MAX is smaller than 0.
  • step S609 If it is determined in step S609 that MV_MAX is smaller than 0, the process proceeds to step S610.
  • step S610 the inter prediction control unit 201 sets the left side of the vPU as the SAD calculation area.
  • step S609 If it is determined in step S609 that MV_MAX is 0 or more, the process proceeds to step S611.
  • step S611 the inter prediction control unit 201 sets the right side of the vPU as the SAD calculation area.
  • step S610 or S611 the process proceeds to step S612.
  • step S612 the inter prediction control unit 201 determines whether PU size ⁇ vPU size.
  • step S612 If it is determined in step S612 that PU size ⁇ vPU size, the process proceeds to step S613.
  • step S612 If it is determined in step S612 that PU size ⁇ vPU size is not satisfied, the process proceeds to step S614.
  • step S615 the inter prediction control unit 201 determines whether or not MV_MAX ⁇ 0.
  • step S615 If it is determined in step S615 that MV_MAX ⁇ 0, the process proceeds to step S616.
  • step S616 the inter prediction control unit 201 sets the upper side of the vPU in the SAD calculation area.
  • step S615 If it is determined in step S615 that MV_MAX ⁇ 0 is not satisfied, the process proceeds to step S617.
  • step S617 the inter prediction control unit 201 sets the lower side of the vPU to the SAD calculation area.
  • step S616 or S617 the process proceeds to step S618.
  • step S618 the inter prediction control unit 201 determines whether PU size ⁇ vPU size.
  • step S618 If it is determined in step S618 that PU size ⁇ vPU size, the process proceeds to step S619.
  • step S618 If it is determined in step S618 that PU size ⁇ vPU size is not satisfied, the process proceeds to step S620.
  • step S606 step S607, step S613, step S614, step S619, and step S620, the process proceeds to step S621 in FIG.
  • step S621 the inter prediction control unit 201 determines whether or not the horizontal size is ⁇ 4.
  • step S621 If it is determined in step S621 that the horizontal size is ⁇ 4, the process proceeds to step S622.
  • step S622 If it is determined in step S621 that horizontal size ⁇ 4 is not satisfied, step S622 is skipped and the process proceeds to step S623.
  • step S623 the inter prediction control unit 201 determines whether the vertical size is ⁇ 4.
  • step S623 If it is determined in step S623 that the vertical size is ⁇ 4, the process proceeds to step S624.
  • step S623 If it is determined in step S623 that the vertical size is not ⁇ 4, step S624 is skipped and the partial SAD calculation area determination process for BIO_vPU_ON determination is ended.
  • Second embodiment (example of sharing operation by flag)>
  • PU is virtually divided into vPUs and processing is performed in vPU units.
  • the bitstream transmitted and received between the encoding device 1 and the decoding device 101 includes one bit of the BIO_PU_ON flag.
  • the operation can be shared between the encryption device 1 and the decryption device 101.
  • ⁇ Operation example of inter prediction unit> 30 and 31 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the second embodiment of the present technology.
  • steps S701 to S708 and steps S715 to S728 of FIGS. 30 and 31 are basically the same as steps S401 to S408 and steps S412 to S425 of FIGS. 17 and 18, the description thereof will be repeated. Therefore, it is omitted as appropriate.
  • step S708 of FIG. 30 the BIO cost calculation unit 204, in 4 ⁇ 4 units in the vPU, the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203. And calculate the SAD.
  • SAD_4 ⁇ 4 block which is the sum of SADs, is acquired by calculating and stacking SAD in units of 4 ⁇ 4.
  • step S709 the inter prediction control unit 201 determines whether the number of vPUs is 1.
  • step S709 If it is determined in step S709 that the number of vPUs is 1, the process proceeds to step S710. In steps S710 and S711, processing similar to that for the PU unit is performed.
  • step S710 the BIO cost calculation unit 204, in units of vPU, the LIO prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • SAD_PU which is the sum of SADs, is obtained by calculating and stacking SADs for each vPU.
  • the acquired SAD_PU is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • step S709 If it is determined in step S709 that the vPU number is not 1, the process proceeds to step S712.
  • step S712 the inter prediction control unit 201 determines whether the vPU number is 0.
  • step S709 If it is determined in step S709 that the vPU number is 0, the process proceeds to step S713.
  • step S713 the inter prediction control unit 201 sets BIO_PU_ON.
  • BIO_PU_ON determined from the motion search (ME) result or the like is set.
  • BIO_PU_ON acquired from the stream is set.
  • step S712 If it is determined in step S712 that the vPU number is not 0, step S713 is skipped and the process proceeds to step S714 in FIG.
  • step S714 it is determined whether or not the BIO_PU_ON flag is 1.
  • step S714 If it is determined in step S714 that the BIO_PU_ON flag is not 1, it is determined that BIO has no effect on the entire PU, and the process proceeds to step S715.
  • step S715 the Bi prediction block generation unit 206 generates a Bi prediction block vPU from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • the generated Bi prediction block vPU is stored in the buffer and is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208.
  • step S714 if it is determined in step S714 that the BIO_PU_ON flag is 1, the process proceeds to step S716.
  • step S716 the Bi prediction block generation unit 207 including the BIO process determines a plurality of gradients from the L0 prediction block supplied from the L0 prediction block generation unit 202 and the L1 prediction block supplied from the L1 prediction block generation unit 203. calculate.
  • BIO_PU_ON flag in the bitstream, it is possible to share the operation between the encoding device 1 and the decoding device 101.
  • BIO_PU_ON flag is not included in all layers, and PUs with a relatively small 1-bit value are more important than VPDUs. Limited to large cases. In the case of PU other than VPDU is larger than VPDU, as in the case of the first embodiment, as shown in steps S709 to S713 of FIG. To
  • the encoding device 1 may freely set it to 0 or 1. If the encoding device 1 has sufficiently high performance, there is also a determination method in which the BIO_PU_ON flag is motion-compensated with both 0 and 1 to determine which one has obtained a good result. Further, according to the PU size, 128 ⁇ 128 may be determined by setting the BIO_PU_ON flag to 0 and otherwise determining to 1.
  • the BIO_PU_ON flag is decoded in the PU layer of the CU in Bi prediction mode where PU is larger than VPDU, when the vPU number is 0, the BIO_PU_ON flag is acquired in step S713, and the process proceeds. To be For vPUs with vPU numbers 1 and later, the BIO_PU_ON flag has already been set, so the process skips step S713 and proceeds from step S712 to step S714.
  • Third embodiment (example of division by sPU)>
  • the size of virtual division is different from that of the first embodiment.
  • PU is larger than VPDU, PU is virtually divided into sPUs and processing is performed in sPU units.
  • the processing unit for performing SAD calculation and determining the application of BIO may be equal to or smaller than the VPDU size that crosses the VPDU boundary. Therefore, in the third embodiment, a plurality of PUs are separately provided by the given information. It is virtually divided into sPUs, and the BIO application is determined for each sPU.
  • BIO_MAX_SAD_BLOCK_SIZE is added and included in the bitstream so that the encoding apparatus 1 and the decoding apparatus 101 share the information.
  • FIG. 32 is a diagram showing a correspondence relationship between BIO_MAX_SAD_BLOCK_SIZE and sPU.
  • BIO_MAX_SAD_BLOCK_SIZE When BIO_MAX_SAD_BLOCK_SIZE is 1, the sPU size is 8x8. When BIO_MAX_SAD_BLOCK_SIZE is 2, the sPU size is set to 16 ⁇ 16. When BIO_MAX_SAD_BLOCK_SIZE is 3, the sPU size is 32 ⁇ 32. When BIO_MAX_SAD_BLOCK_SIZE is 4, the sPU size is 64 ⁇ 64.
  • BIO_MAX_SAD_BLOCK_SIZE may be set to an arbitrary value depending on the performance of each encoding device 1, or may be set as a standard/Profile/Level constraint. Level constraints such as 0 for SD or less, 1 for HD, 2 for 4K, and 3 for 8k, depending on the picture size to be handled.
  • ⁇ Operation example of inter prediction unit> 33 and 34 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the third embodiment of the present technology.
  • steps S801 to S825 of FIGS. 33 and 34 the vPU is simply replaced with an sPU of a different size, and basically the same processing as steps S401 to S425 of FIGS. 17 and 18 is performed. Since the description will be repeated, it will be omitted as appropriate.
  • FIG. 35 and FIG. 36 are diagrams showing an example of a region for calculating the SAD of each PU when BIO_MAX_SAD_BLOCK_SIZE is set to 2.
  • the sPU does not cross the VPDU boundary and divides the PU into four.
  • the PU is virtually divided into a plurality of sPUs by the separately provided information, and the BIO application determination is performed for each sPU.
  • the buffer size can be made smaller than that of the vPU.
  • ⁇ Operation example of inter prediction unit> 37 and 38 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the fourth embodiment of the present technology.
  • steps S901 to S907 and S926 of FIGS. 37 and 38 are basically the same as steps S401 to S407 and S425 of FIGS. 17 and 18, the description thereof will be repeated, and accordingly, the description thereof will be appropriately omitted. To be done. Further, steps S909 to S925 of FIGS. 37 and 38 perform basically the same processing as steps S304 to S320 of FIGS. 15 and 16, and thus the description thereof will be repeated and accordingly omitted.
  • step S907 the L1 prediction block generation unit 203 generates an L1 prediction block in the vPU number area.
  • step S908 the inter prediction control unit 201 determines whether 1 ⁇ vPU number.
  • step S908 If it is determined in step S908 that 1 ⁇ vPU count is not satisfied, the process proceeds to step S909.
  • step S908 If it is determined in step S908 that 1 ⁇ vPU count, the process proceeds to step S913 in FIG.
  • step S912 If it is determined in step S912 that the BIO_vPU_ON flag is not 1, it is determined that BIO has no effect on the entire vPU, and the process proceeds to step S913.
  • the Bi prediction block generation unit 206 generates a Bi prediction block vPU from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • the generated Bi prediction block vPU is stored in the buffer and is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208.
  • step S908 is added to steps S907 to S913 as a conditional branch step for determining whether or not there are a plurality of vPUs, that is, whether or not PUs are larger than VPDUs. Has been done.
  • step S908 If PU is larger than VPDU, the normal Bi prediction of step S908 is branched to step S913, so BIO is not used, and therefore it is not necessary to calculate the SAD value for the entire PU. Can be divided into virtual vPUs for processing.
  • Steps S909 to S925 after branching from step S908 to step S909 are the same processes as the conventional Bi prediction including BIO (S304 to S320 in FIGS. 15 and 16).
  • branching to step S909 occurs when the PU is less than or equal to VPDU. Therefore, when performing SAD calculation for the entire PU, it is sufficient to have resources less than or equal to VPDU.
  • BIO is always applied to reduce the buffer size.
  • ⁇ Operation example of inter prediction unit> 39 and 40 are flowcharts illustrating Bi prediction including BIO performed by the inter prediction unit 51, as an operation example of the fifth embodiment of the present technology.
  • steps S1001 to S1008 and S1026 in FIGS. 39 and 40 perform basically the same processing as steps S401 to S408 and S425 in FIGS. 17 and 18, the description thereof will be repeated, and accordingly, will be appropriately omitted. To be done. Further, steps S1014 to S1025 of FIGS. 39 and 40 perform basically the same processing as steps S309 to S320 of FIGS. 15 and 16, and thus the description thereof will be repeated and accordingly omitted.
  • step S1008 the BIO cost calculation unit 204 SADs the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203 in units of 4 ⁇ 4 in vPU.
  • SAD_4 ⁇ 4 block which is the sum of SADs, is acquired by calculating and stacking SAD in units of 4 ⁇ 4.
  • step S1009 the inter prediction control unit 201 determines whether 1 ⁇ vPU number.
  • step S1009 If it is determined in step S1009 that 1 ⁇ vPU is not satisfied, the process proceeds to step S1010.
  • step S1010 the BIO cost calculation unit 204 calculates, for each PU, the SAD of the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • SAD_PU which is the sum of SADs, is obtained by calculating and stacking SADs for each PU.
  • the acquired SAD_PU is supplied from the BIO cost calculation unit 204 to the BIO application determination unit 205.
  • step S1012 it is determined whether the BIO_PU_ON flag is 1.
  • step S1012 If it is determined in step S1012 that the BIO_PU_ON flag is not 1, it is determined that BIO has no effect on the entire vPU, and the process proceeds to step S1013 in FIG.
  • the Bi prediction block generation unit 206 generates a Bi prediction block vPU from the L0 prediction image supplied from the L0 prediction block generation unit 202 and the L1 prediction image supplied from the L1 prediction block generation unit 203.
  • the generated Bi prediction block vPU is stored in the buffer and is supplied from the Bi prediction block generation unit 206 to the Bi prediction block selection unit 208.
  • step S1012 If it is determined in step S1012 that the BIO_PU_ON flag is 1, the process proceeds to step S1014 in FIG.
  • step S1009 If it is determined in step S1009 that 1 ⁇ vPU count, the process proceeds to step S1014.
  • step S1014 the same BIO processing as in steps S309 to S320 of FIG. 15 is performed.
  • step S1009 a conditional branch for determining whether or not there are a plurality of vPUs, that is, whether or not the PUs are larger than VPDUs is added.
  • PU is larger than VPDU, the process from SAD calculation in S1010 to S1012 to threshold determination is bypassed, and the process of applying BIO in step S1014 and subsequent steps is entered, so there is no need to calculate SAD for the entire PU, and as shown in FIG. Similarly, the PU can be divided into virtual vPUs for processing.
  • Steps S1010 to S1012 are entered when the PU is less than VPDU, so even if the SAD calculation is performed for the entire PU, resources below VPDU are sufficient.
  • the fifth embodiment cannot be applied to FRUC or DMVR. Since the BIO SAD calculation is for the purpose of early termination, it is possible to avoid the cost calculation by using another criterion such as the PU size as in the fifth embodiment. This is because the cost calculation of FRUC and DMVR is the basic processing of MV correction and is difficult to avoid.
  • the processing unit for calculating the cost used for determining whether or not to perform bidirectional prediction such as BIO is a division processing unit equivalent to VPDU size (for example, vPU) or a division processing of VPDU size or less. It is divided into units (for example, sPU), and the determination is made using the cost calculated based on the divided processing units. As a result, the buffer size can be reduced.
  • VIO can be implemented with VVC
  • the size of various required buffers can be reduced to 1/4 of the conventional buffer size.
  • FIG. 41 is a block diagram showing an example of the hardware configuration of a computer that executes the series of processes described above by a program.
  • a CPU (Central Processing Unit) 301, a ROM (Read Only Memory) 302, and a RAM (Random Access Memory) 303 are interconnected by a bus 304.
  • An input/output interface 305 is further connected to the bus 304.
  • the input/output interface 305 is connected to an input unit 306 including a keyboard and a mouse, and an output unit 307 including a display and a speaker. Further, the input/output interface 305 is connected with a storage unit 308 including a hard disk and a non-volatile memory, a communication unit 309 including a network interface, and a drive 310 that drives a removable medium 311.
  • the CPU 301 loads, for example, the program stored in the storage unit 308 into the RAM 303 via the input/output interface 305 and the bus 304 to execute the series of processing described above. Is done.
  • the program executed by the CPU 301 is recorded in the removable medium 311, or provided via a wired or wireless transmission medium such as a local area network, the Internet, or digital broadcasting, and installed in the storage unit 308.
  • the program executed by the computer may be a program in which processing is performed in time series in the order described in the present specification, or in parallel or at a necessary timing such as when a call is made. It may be a program for processing.
  • the system means a set of a plurality of constituent elements (devices, modules (parts), etc.), and it does not matter whether or not all constituent elements are in the same housing. Therefore, a plurality of devices housed in separate housings and connected via a network, and one device housing a plurality of modules in one housing are all systems. ..
  • the present technology can be configured as cloud computing in which one function is shared by a plurality of devices via a network and jointly processes.
  • each step described in the above flow chart can be executed by one device or shared by a plurality of devices.
  • one step includes a plurality of processes
  • the plurality of processes included in the one step can be executed by one device or shared by a plurality of devices.
  • a control unit that divides a processing unit that calculates a cost used for determining whether or not to perform bidirectional prediction into division processing units that are equivalent to the VPDU size or are equal to or smaller than the VPDU size
  • An image processing apparatus comprising: a determination unit that performs the determination using the cost calculated based on the division processing unit.
  • the image processing device according to (1), wherein the determination unit performs the determination using the cost calculated for each division processing unit.
  • the determination unit performs the determination of the first division processing unit using the cost calculated for the first division processing unit, and a result of the determination of the first division processing unit.
  • the image processing apparatus according to (1), wherein the determination of the other division processing unit is performed using.
  • the image processing device Divide the processing unit that calculates the cost used to determine whether or not to perform bidirectional prediction into a division processing unit that is equivalent to the VPDU size or equal to or less than the VPDU size, An image processing method for performing the determination using the cost calculated based on the division processing unit.

Abstract

本技術は、バッファサイズを削減することができるようにする画像処理装置および方法に関する。 画像処理装置は、双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割し、分割処理単位に基づいて計算されたコストを用いて判定を行う。本技術は、符号化装置または復号装置に適用することができる。

Description

画像処理装置および方法
 本技術は、画像処理装置および方法に関し、特に、バッファサイズを削減することができるようにした画像処理装置および方法に関する。
 AVC/H.264やHEVC/H.265に続く次世代コーデックとしてVVCの規格標準化が進められている。
 VVC規格では、最大128x128の大きなCU(Coding Unit)が採用されているが、特にHW Decoder実装での回路規模や消費電力の増大などを考慮して、VPDU(Virtual Pipeline Data Units)という概念も導入されている。
 VPDUのサイズは、各パイプラインステージが滞りなく処理可能となるバッファサイズである。VPDUのサイズは、TU(Transform Unit)の最大サイズに合わせる場合が多い。
 VVCでは64x64が最大TUサイズであり、VPDUにもこの大きさが想定されている。VVCでは1つのCUに1つのPUが対応しており、VPDUより大きなサイズのPUに対してインター予測処理をする必要がある。この場合でもPUを仮想的なvPU(virtual PU)に分割しての処理が可能であり、VPDUとの整合性もよく、後述するBIO(Bi-directional optical flow)が採用されるまではリーズナブルなHWリソースでの実装が可能であった。
 Optical Flowの手法は動画像中の物体の動きを検出し、ある時間経過後にどの方向に動くかを推定する画像処理手法である。このOptical Flowの手法をコーデックのインター予測のオプションとして追加することで符号化効率が向上する。時間的に前後の1フレームずつを参照するBi予測(双方向予測)でOptical Flowの手法を使うことから、特にBIOと呼ばれている(非特許文献1参照)。
 通常のBi予測では最適なMVと予測MV(PMV)の間に差異があるため差分MV(MVD)を符号化しているのに対して、BIOを適用したBi予測では予測MV(PMV)で生成した予測ブロック同士に対してOptical Flow手法で勾配(G)や速度(V)を求め、通常のBi予測と同等の結果を得ている。このような場合、差分MV(MVD)の符号化が不要または削減できるので符号化効率が改善される(非特許文献2参照)。
 一方で、BIOで求めている勾配(G)や速度(V)の計算コストは非常に高い。そのため勾配(G)や速度(V)を計算したものの、その絶対値が小さいなどの理由で通常のBi予測で得られる予測値とほとんど差がない場合は、費用対効果の面でリダクションが特に求められる。
 様々な提案がされているBIOのリダクション手法の1つに、L0予測ブロックとL1予測ブロックが生成された段階でブロック同士のSAD(Sum of Absolute Difference)を計算して、SAD値がある閾値を下回った場合はBIOを適用せず、通常のBi予測を実行するというものがある。
 これはSAD値が小さいと速度(V)も小さくなりBIOの効果があまり得られない傾向を考慮したもので、効果が見込めない場合には高コストな計算を省略するアーリーターミネーションとして機能する。
Jianle Chen , Yan Ye , Seung Hwan Kim、"Algorithm description for Versatile Video Coding and Test Model 3 (VTM 3)"、[online]、平成30年9月24日、Experts Team (JVET)、[平成30年12月21日検索]、インターネット, < http://phenix.it-sudparis.eu/jvet/doc_end_user/documents/12_Macao/wg11/JVET-L1002-v1.zip > Xiaoyu Xiu, Yuwen He, Yan Ye、"CE9-related: Complexity reduction and bit-width control for bi-directional optical flow (BIO)"、[online]、平成30年9月24日、Experts Team (JVET)、[平成30年12月21日検索]、インターネット, < http://phenix.it-sudparis.eu/jvet/doc_end_user/documents/12_Macao/wg11/JVET-L0256-v3.zip >
 上述したBIOのリダクション手法を適用した場合、PU全体でL0とL1予測ブロックのSADを計算し、閾値と比較してBIO処理の適用可否を判定し、処理が分岐するような流れになっている。そのため、VPDUより大きなPUでインター予測する場合に、PUを仮想的に複数のvPUに分割処理することが困難になってしまった。
 この場合、勾配計算や速度計算のために必要になるバッファは、PUよりひと回り大きな領域が必要となり、BIOを含むインター予測処理部において、大きなバッファリソースが必要になってしまう。
 本技術はこのような状況に鑑みてなされたものであり、バッファサイズを削減することができるようにするものである。
 本技術の一側面の画像処理装置は、双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割する制御部と、前記分割処理単位に基づいて計算された前記コストを用いて前記判定を行う判定部とを備える。
 本技術の一側面においては、双方向予測を行うか否かについての判定に用いるコストを計算する処理単位がVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割され、前記分割処理単位に基づいて計算された前記コストを用いて前記判定が行われる。
VPDUを導入せず、パイプラインを組んだ例を示す図である。 図1の場合のインターPU処理の1つであるBi予測を説明するフローチャートである。 VPDUを導入して、効率的にパイプラインを組んだ例を示す図である。 図3の場合のインターPU処理の1つであるBi予測を説明するフローチャートである。 通常のBi予測の例を示す図である。 BIOを適用したBi予測の例を示す図である。 通常のBi予測の2ブロック分割の例を示す図である。 BIOを適用したBi予測の2ブロック分割の例を示す図である。 本技術の一実施形態に係る符号化装置の構成例を示すブロック図である。 符号化装置の符号化処理の詳細を説明するフローチャートである。 図10に続く、符号化装置の符号化処理の詳細を説明するフローチャートである。 本開示を適用した復号装置の一実施の形態の構成例を示すブロック図である。 復号装置の復号処理の詳細を説明するフローチャートである。 インター予測部の構成例を示すブロック図である。 従来のBIOを含むBi予測を説明するフローチャートである。 図15に続く、従来のBIOを含むBi予測を説明するフローチャートである。 本技術の第1の実施の形態のBIOを含むBi予測を説明するフローチャートである。 図17に続く、本技術の第1の実施の形態のBIOを含むBi予測を説明するフローチャートである。 PUサイズ、vPU番号、および処理位置とサイズの対応関係を示す図である。 従来の動作と、本技術の第1の実施の形態の動作を実施した場合の比較を示す図である。 従来の動作と、本技術の第1の実施の形態の動作を実施した場合の比較を示す図である。 PUがVPDUより大きい場合に、vPU番号が0のBIO判定結果を他のvPUでも用いた例を示す図である。 PUがVPDUより大きい場合に、vPU番号が0のBIO判定結果を他のvPUでも用いた例を示す図である。 図22と図23の場合のBIOを含むBi予測を説明するフローチャートである。 図24に続く、図22と図23の場合のBIOを含むBi予測を説明するフローチャートである。 各vPU内の部分的なSAD値でBIOの適用判定を行う例を示す図である。 各vPU内の部分的なSAD値でBIOの適用判定を行う例を示す図である。 各vPUのBIO_vPU_ONの判定のための部分的なSAD計算領域の判定処理を説明するフローチャートである。 図28に続く、各vPUのBIO_vPU_ONの判定のための部分的なSAD計算領域の判定処理を説明するフローチャートである。 本技術の第2の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 図30に続く、本技術の第2の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 BIO_MAX_SAD_BLOCK_SIZEとsPUの対応関係を示す図である。 本技術の第3の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 図33に続く、本技術の第3の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 BIO_MAX_SAD_BLOCK_SIZEを2とした場合の各PUのSADを計算する領域の例を示す図である。 BIO_MAX_SAD_BLOCK_SIZEを2とした場合の各PUのSADを計算する領域の例を示す図である。 本技術の第4の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 図37に続く、本技術の第4の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 本技術の第5の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 図39に続く、本技術の第5の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。 コンピュータの構成例を示すブロック図である。
 以下、本技術を実施するための形態について説明する。説明は以下の順序で行う。
 0.概要
 1.第1の実施の形態(vPUによる分割の例)
 2.第2の実施の形態(フラグによる動作の共有の例)
 3.第3の実施の形態(sPUによる分割の例)
 4.第4の実施の形態(BIOの使用禁止の例)
 5.第5の実施の形態(常時BIOの適用の例)
 6.第6の実施の形態(コンピュータ)
<0.概要>
 AVC/H.264やHEVC/H.265に続く次世代コーデックとしてVVCの規格標準化が進められている。
 VVC規格では、最大128x128の大きなCU(Coding Unit)が採用されているが、HW Decoder実装での回路規模や消費電力の増大などを特に考慮して、VPDU(Virtual Pipeline Data Units)という概念も導入されている。
 VPDUのサイズは、各パイプラインステージが滞りなく処理可能となるバッファサイズである。VPDUのサイズは、TU(Transform Unit)の最大サイズに合わせる場合が多い。
 VVCでは64x64が最大TUサイズであり、VPDUにもこの大きさが想定されている。VVCでは1つのCUに1つのPUが対応しており、VPDUのサイズより大きなサイズのPUに対してインター予測処理を行う必要がある。この場合でもPUを仮想的なvPU(virtual PU)に分割しての処理が可能でありVPDUとの整合性もよく、後述するBIO(Bi-directional optical flow)が採用されるまでは、図1乃至図4に示すように、バッファを少なくできるため、リーズナブルなHWリソースでの実装が可能であった。
 <VPDUを導入しない場合のパイプラインの例>
 図1は、VPDUを導入せずに、パイプラインを組んだ例を示す図である。
 図1の上には、CU、インターPU、およびTUの各ブロックが示されている。
 CUの最大サイズは、128×128である。インターPUの最大サイズは、128×128である。VVCにおいては、1つのCUに1つのPUが対応する。TUは、TU0乃至TU3からなり、各TUの最大サイズは64×64である。TUのサイズは、VPDUのサイズでもある。
 図1の上側に示されるように、CUは、インターPU処理により生成されたインターPUと、TU処理により得られたTUとが加算されてなる。
 図1の下側には、インターPU処理、TU処理、およびローカルデコード処理からなるパイプラインが示されている。
 パイプラインにおいては、インターPUの処理とTU0乃至TU3の処理とが並列に行われ、両方が完了したときに、CUのローカルデコード処理が開始される。したがって、インターPUの処理では、128×128のバッファが必要であり、TUの処理では、PUとの待ち合わせ用に128×128のバッファが必要である。
 図2は、図1の場合のインターPUの処理の1つであるBi予測(双方向予測)を説明するフローチャートである。
 ステップS1において、インター予測のパラメータが取得される。
 ステップS2において、L0予測ブロックが生成される。
 ステップS3において、L1予測ブロックが生成される。
 ステップS4において、L0予測ブロックとL1予測ブロックとから、Bi予測ブロックPUが生成される。
 なお、ステップS2乃至S4においては、最大バッファサイズとして、PUのサイズが必要となる。
 <VPDUを導入した場合のパイプラインの例>
 図3は、VPDUを導入して、効率的にパイプラインを組んだ例を示す図である。
 なお、図3において、図1の説明と共通する点については、適宜、省略される。
 図3の上側には、CU、インターPU、およびTUの各ブロックが示されている。CUは、図1と異なり、PUがvPUに仮想的に分割されて処理されたことで、分割されたCU(0)乃至CU(3)で構成されている。PUは、仮想的なvPU(0)乃至vPU(3)で構成されている。
 図3の下側には、インターPU処理、TU処理、およびローカルデコード処理からなるパイプラインが示されている。
 パイプラインにおいては、インターPUにおけるvPU(0)乃至vPU(3)の処理とTU0乃至TU3の処理とが並列に行われる。したがって、vPU(0)の処理とTU0の処理が完了したときに、CU(0)のローカルデコード処理が開始される。vPU(1)の処理とTU1の処理が完了したときに、CU(1)のローカルデコード処理が開始される。vPU(2)の処理とTU2の処理が完了したときに、CU(2)のローカルデコード処理が開始される。vPU(3)の処理とTU3の処理が完了したときに、CU(3)のローカルデコード処理が開始される。
 このようにパイプラインを組むことで、インターPU処理においては、64×64のバッファがあればよく、TU処理におけるvPU待ち合わせ用バッファのサイズは、64×64で十分足りる。
 図4は、図3の場合のインターPUの処理の1つであるBi予測を説明するフローチャートである。
 ステップS11において、インター予測のパラメータが取得される。
 ステップS12において、PU内に含まれるvPU数が取得される。
 ステップS13において、vPU番号に0が設定される。
 ステップS14において、vPU番号がvPU数より小さいか否かが判定される。ステップS14において、vPU番号がvPU数より小さいと判定された場合、処理は、ステップS15に進む。
 ステップS15において、vPU番号からPU内のvPUの位置とサイズが取得される。
 ステップS16において、vPUの領域のL0予測ブロックが生成される。
 ステップS17において、vPUの領域のL1予測ブロックが生成される。
 ステップS18において、L0予測ブロックとL1予測ブロックとから、Bi予測ブロックvPUが生成される。
 ステップS19において、vPU番号がインクリメントされ、その後、ステップS14に戻り、それ以降の処理が繰り返される。
 また、ステップS14において、vPU番号がvPU数以上であると判定された場合、Bi予測は終了される。
 なお、ステップS16乃至S17においては、最大バッファサイズとして、PUよりも小さいVPDUのサイズがあればよい。
 Optical Flowの手法は動画像中の物体の動きを検出し、ある時間経過後にどの方向に動くかを推定する画像処理手法である。このOptical Flowの手法をコーデックのインター予測のオプションとして追加することで符号化効率が向上する。時間的に前後の1フレームずつを参照するBi予測でOptical Flowの手法を使うことから、特にBIOと呼ばれている。
 <通常のBi予測の例>
 図5は、通常のBi予測の例を示す図である。
 図5においては、左から右への矢印が表示順の時間を表している。また、BピクチャにおけるBi予測ブロックのBi予測値について、L0方向の参照面0と、L1方向の参照面1において、最適なMVを求める例が示されている。以下の図についても同様である。
 Bi予測値には、参照面0におけるL0予測ブロックの画素L0と、参照面1におけるL1予測ブロックの画素L1が対応しており、Bi予測値は、(L0+L1)/2で求められる。
 図5に示すように、通常のBi予測では、最適なMV(MV_L0,MV_L1)と予測MV(MVP_L0,MVP_L1)の間に差異があるため、差分MV(MVD_L0,MVD_L1)を符号化する必要がある。
 <BIOを適用したBi予測の例>
 図6は、BIOを適用したBi予測の例を示す図である。
 図6においては、BIOを適用したBi予測として、予測MV(MVP_L0,MVP_L1)で生成した予測ブロック同士に対してOptical Flow手法で勾配(G)や速度(V)を求める例が示されている。予測ブロック同士に対してOptical Flow手法で勾配(G)や速度(V)を求めることで、通常のBi予測と同等の結果が得られる。
 BIOを適用したBi予測の場合、予測MV(MVP_L0,MVP_L1)をそのままMV(MV_L0,MV_L1)とするので、差分MV(MVD_L0,MVD_L1)を符号化する必要がないため、符号化効率が改善する。
 Bi予測値には、参照面0におけるL0予測ブロックの画素L0’と、参照面1におけるL1予測ブロックの画素L1’がほぼ対応しており、Bi予測値は、(L0’+L1’+B)/2で求められる。すなわち、L0予測ブロックとL1予測ブロックから勾配(G:Gx,Gy)と速度(V:Vx,Vy)を計算し、補正値B=Vx*Gx+Vy*Gyを求める必要がある。
 <Bi予測の2ブロック分割の例>
 図7は、通常のBi予測の2ブロック分割の例を示す図である。
 通常のBi予測では、2つのブロックに分割しているため、図7に示すように、2つのブロック分のブロック分割情報と2つの差分MV(MVD)がそれぞれ求められる。したがって、2つのブロック分のブロック分割情報と2つの差分MV(MVD)を符号化する必要がある。
 <BIOを適用したBi予測の2ブロック分割の例>
 図8は、BIOを適用したBi予測の2ブロック分割の例を示す図である。
 BIOを適用したBi予測では、2つのブロックがあっても、図8に示すように、ブロックを分割せずにOptical Flow手法で勾配(G)と速度(V)が求められるので、通常Bi予測と同等の結果が得られる。
 以上のように、図8のBIOを適用したBi予測では、図7のBi予測で必要であったブロック分割情報の符号化の不要または削減が可能となったり、図7のBi予測で必要であった差分MV(MVD)の符号化が不要または削除が可能となったりするので、符号化効率を改善することができる。
 一方で、BIOで求めている勾配(G)および速度(V)の計算コストは非常に高い。そのため勾配(G) および速度(V)を計算したにもかかわらず、その絶対値が小さいなどの理由で通常のBi予測で得られる予測値とほとんど差がない場合は、費用対効果の面でリダクションが特に求められる。
 様々な提案がされているBIOのリダクション手法の1つに、L0予測ブロックとL1予測ブロックが生成された段階でブロック同士のSAD(Sum of Absolute Difference)を計算して、SAD値がある閾値を下回った場合はBIOを適用せず、通常のBi予測を実行するというものがある。
 これはSAD値が小さいと速度(V)も小さくなりBIOの効果があまり得られない傾向を考慮したもので、効果が見込めない場合には高コストな計算を省略するアーリーターミネーションとして機能する。
 上述したBIOのリダクション手法を適用した場合、PU全体でL0とL1予測ブロックのSADを計算し、閾値と比較してBIO処理の適用可否を判定し、処理が分岐するような流れになっている。そのため、VPDUより大きなPUでインター予測する場合に、PUを仮想的に複数のvPUに分割処理することが困難になってしまった。
 この場合、勾配計算や速度計算のために必要になるバッファは、PUよりひと回り大きな領域が必要となり、BIOを含むインター予測を行う部において、大きなバッファリソースが必要になってしまう。
 また、上述したBIOのリダクション手法をHW実装した場合、BIOを含むインター予測のパイプライン遅延とTU処理のパイプライン遅延が大きく異なるため、スループットを維持するためのHW実装難易度も高くなってしまう。
 そこで、本技術においては、BIOなどの双方向予測を行うか否かについての判定に用いるコストを計算する処理単位(例えば、PU)がVPDUサイズ相当の分割処理単位(例えば、vPU)またはVPDUサイズ以下の分割処理単位(例えば、後述するsPU)に分割され、分割処理単位に基づいて計算されたコストを用いて判定が行われる。なお、VPDUサイズ相当は、VPDUのサイズより一回り大きいサイズを表す。
 なお、本明細書において、ブロックサイズについての「AがBより大きい」は、「Aの水平サイズがBの水平サイズより大きい」または「Aの垂直サイズがBの垂直サイズより大きい」ことを意味する。
 また、ブロックサイズについての「AがB以下である」は、「Aの水平サイズがBの水平サイズ以下であり、かつ、Aの垂直サイズがBの垂直サイズ以下である」ことを意味する。
 以下、本技術について詳しく説明する。
<1.第1の実施の形態(vPUによる分割の例)>
 <符号化装置の構成例>
 図9は、本技術の一実施形態に係る符号化装置の構成例を示すブロック図である。
 図9の符号化装置1は、A/D変換部31、画面並べ替えバッファ32、演算部33、直交変換部34、量子化部35、可逆符号化部36、蓄積バッファ37、逆量子化部38、逆直交変換部39、および加算部40を有する。また、符号化装置1は、デブロックフィルタ41、適応オフセットフィルタ42、適応ループフィルタ43、フレームメモリ44、スイッチ45、イントラ予測部46、動き予測・補償部47、予測画像選択部48、およびレート制御部49を有する。
 A/D変換部31は、入力される符号化対象のフレーム単位の画像をA/D変換する。A/D変換部31は、変換後のデジタル信号である画像を画面並べ替えバッファ32に出力して記憶させる。
 画面並べ替えバッファ32は、表示順のフレーム単位の画像を、GOP構造に応じて、符号化順に並べ替える。画面並べ替えバッファ32は、並べ替え後の画像を、演算部33、イントラ予測部46、および動き予測・補償部47に出力する。
 演算部33は、画面並べ替えバッファ32から供給される画像から、予測画像選択部48から供給される予測画像を減算することにより符号化を行う。演算部33は、減算後の画像を、残差情報(差分)として直交変換部34に出力する。なお、予測画像選択部48から予測画像が供給されない場合、演算部33は、画面並べ替えバッファ32から読み出された画像をそのまま残差情報として直交変換部34に出力する。
 直交変換部34は、演算部33からの残差情報に対して直交変換処理を行う。直交変換部34は、直交変換処理後の画像を量子化部35に出力する。
 量子化部35は、直交変換部34から供給される直交変換処理後の画像を量子化する。量子化部35は、量子化後の量子化値を可逆符号化部36に出力する。
 可逆符号化部36は、最適イントラ予測モードを示す情報であるイントラ予測モード情報をイントラ予測部46から取得する。また、可逆符号化部36は、最適インター予測モードを示す情報であるインター予測モード情報と、動き情報および参照画像情報などのインター予測のパラメータとを動き予測・補償部47から取得する。
 また、可逆符号化部36は、適応オフセットフィルタ42からオフセットフィルタに関するオフセットフィルタ情報を取得し、適応ループフィルタ43からフィルタ係数を取得する。
 可逆符号化部36は、量子化部35から供給される量子化値に対して、可変長符号化(例えば、CAVLC(Context-Adaptive Variable Length Coding))、算術符号化(例えば、CABAC(Context-Adaptive Binary Arithmetic Coding))などの可逆符号化を行う。
 また、可逆符号化部36は、イントラ予測モード情報、または、インター予測モード情報、インター予測のパラメータ、オフセットフィルタ情報、並びにフィルタ係数を、符号化に関する符号化情報として可逆符号化する。可逆符号化部36は、可逆符号化された符号化情報と量子化値を、符号化データとして蓄積バッファ37に出力し、蓄積させる。
 蓄積バッファ37は、可逆符号化部36から供給される符号化データを、一時的に記憶する。また、蓄積バッファ37は、記憶している符号化データを、符号化ストリームとして後段に出力する。
 また、量子化部35より出力された量子化値は、逆量子化部38にも入力される。逆量子化部38は、量子化値を逆量子化する。逆量子化部38は、逆量化後の直交変換処理結果を逆直交変換部39に出力する。
 逆直交変換部39は、逆量子化部38から供給される直交変換処理結果に対して逆直交変換処理を行う。逆直交変換の方式としては、例えば、IDCT(逆離散コサイン変換)とIDST(逆離散サイン変換)がある。逆直交変換部39は、逆直交変換処理の結果得られる残差情報を加算部40に出力する。
 加算部40は、逆直交変換部39から供給される残差情報と、予測画像選択部48から供給される予測画像を加算し、復号を行う。加算部40は、復号された画像をデブロックフィルタ41とフレームメモリ44に出力する。
 デブロックフィルタ41は、加算部40から供給される復号された画像に対して、ブロック歪を除去するデブロックフィルタ処理を行う。デブロックフィルタ41は、デブロックフィルタ処理後の画像を適応オフセットフィルタ42に出力する。
 適応オフセットフィルタ42は、デブロックフィルタ41によるデブロックフィルタ処理後の画像に対して、主にリンギングを除去する適応オフセットフィルタ(SAO(Sample adaptive offset))処理を行う。
 適応オフセットフィルタ42は、適応オフセットフィルタ処理後の画像を適応ループフィルタ43に出力する。また、適応オフセットフィルタ42は、適応オフセットフィルタ処理の種類とオフセットを示す情報を、オフセットフィルタ情報として可逆符号化部36に出力する。
 適応ループフィルタ43は、例えば、2次元のウィナーフィルタ(Wiener Filter)により構成される。適応ループフィルタ43は、適応オフセットフィルタ処理後の画像に対して、適応ループフィルタ(ALF(Adaptive Loop Filter))処理を行う。
 適応ループフィルタ43は、適応ループフィルタ処理後の画像をフレームメモリ44に出力する。また、適応ループフィルタ43は、適応ループフィルタ処理に用いられたフィルタ係数を可逆符号化部36に出力する。
 フレームメモリ44は、適応ループフィルタ43から供給される画像と、加算部40から供給される画像を蓄積する。フレームメモリ44に蓄積されたフィルタ処理が行われていない画像のうちのCUに隣接する画像は、周辺画像としてスイッチ45を介してイントラ予測部46に出力される。一方、フレームメモリ44に蓄積されたフィルタ処理が行われた画像は、参照画像としてスイッチ45を介して動き予測・補償部47に出力される。
 イントラ予測部46は、PU単位で、フレームメモリ44からスイッチ45を介して読み出された周辺画像を用いて、候補となる全てのイントラ予測モードのイントラ予測処理を行う。
 また、イントラ予測部46は、画面並べ替えバッファ32から読み出された画像と、イントラ予測処理により予測された予測画像とに基づいて、候補となる全てのイントラ予測モードに対してRDコストを算出する。イントラ予測部46は、算出したRDコストが最小となるイントラ予測モードを、最適イントラ予測モードに決定する。
 イントラ予測部46は、最適イントラ予測モードで生成された予測画像を、予測画像選択部48に出力する。イントラ予測部46は、最適イントラ予測モードで生成された予測画像の選択が通知された場合、イントラ予測モード情報を可逆符号化部36に出力する。なお、イントラ予測モードとはPUのサイズ、予測方向などを表すモードである。
 動き予測・補償部47は、候補となる全てのインター予測モードの動き予測・補償処理を行う。動き予測・補償部47は、予測した動きを補償し、予測画像を生成するインター予測部51を含む。
 動き予測・補償部47は、画面並べ替えバッファ32から供給される画像と、フレームメモリ44からスイッチ45を介して読み出される参照画像に基づいて、候補となる全てのインター予測モードの動き情報(動きベクトル)を検出する。
 動き予測・補償部47は、インター予測部51に、検出した動き情報に対応する、フレーム内のPU位置、PUサイズ、予測方向、参照画像情報、動き情報などを、インター予測のパラメータとして供給する。
 インター予測部51は、動き予測・補償部47から供給されるインター予測のパラメータを用いて、BIO処理を含むBi予測などにより予測画像を生成する。
 動き予測・補償部47は、画面並べ替えバッファ32から供給される画像と、インター予測部51により生成された予測画像とに基づいて、候補となる全てのインター予測モードに対してRDコストを算出する。動き予測・補償部47は、RDコストが最小となるインター予測モードを、最適インター予測モードに決定する。
 決定された最適インター予測モードのRDコストと予測画像は、予測画像選択部48に出力される。決定された最適インター予測モードに対応するインター予測のパラメータは、可逆符号化部36に出力される。
 予測画像選択部48は、イントラ予測部46から供給される最適イントラ予測モードと動き予測・補償部47から供給される最適インター予測モードのうちの、対応するRDコストが小さい方を、最適予測モードに決定する。そして、予測画像選択部48は、最適予測モードの予測画像を、演算部33および加算部40に出力する。
 レート制御部49は、蓄積バッファ37に蓄積された符号化データに基づいて、オーバーフローあるいはアンダーフローが発生しないように、量子化部35の量子化動作のレートを制御する。
 <符号化装置の動作>
 図10および図11は、符号化装置の符号化処理の詳細を説明するフローチャートである。
 図10のステップS31において、A/D変換部31は、符号化対象として入力されたフレーム単位の画像をA/D変換する。A/D変換部31は、変換後のデジタル信号である画像を画面並べ替えバッファ32に出力して記憶させる。
 ステップS32において、画面並べ替えバッファ32は、表示順のフレームの画像を、GOP構造に応じて、符号化順に並べ替える。画面並べ替えバッファ32は、並べ替え後のフレーム単位の画像を、演算部33、イントラ予測部46、および動き予測・補償部47に出力する。
 ステップS33において、イントラ予測部46は、候補となる全てのイントラ予測モードのイントラ予測処理を行う。また、イントラ予測部46は、画面並べ替えバッファ32から読み出された画像と、イントラ予測処理により予測された予測画像とに基づいて、候補となる全てのイントラ予測モードに対してRDコストを算出する。イントラ予測部46は、RDコストが最小となるイントラ予測モードを、最適イントラ予測モードに決定する。イントラ予測部46は、最適イントラ予測モードで生成された予測画像を予測画像選択部48に出力する。
 ステップS34において、動き予測・補償部47は、候補となる全てのインター予測モードの動き予測・補償処理を行う。
 動き予測・補償部47は、画面並べ替えバッファ32から供給される画像と、フレームメモリ44からスイッチ45を介して読み出される参照画像に基づいて、候補となる全てのインター予測モードの動き情報(動きベクトル)を検出する。
 インター予測部51は、動き予測・補償部47から供給されるインター予測のパラメータを用いて、BIO処理を含むBi予測などにより予測画像を生成する。
 動き予測・補償部47は、画面並べ替えバッファ32から供給される画像と、インター予測部51により生成された予測画像とに基づいて、候補となる全てのインター予測モードに対してRDコストを算出する。動き予測・補償部47は、RDコストが最小となるインター予測モードを、最適インター予測モードに決定する。
 決定された最適インター予測モードのRDコストと予測画像は、予測画像選択部48に出力される。決定された最適インター予測モードにおけるインター予測のパラメータは、可逆符号化部36に出力される。
 ステップS35において、予測画像選択部48は、最適イントラ予測モードおよび最適インター予測モードのRDコストに基づいて、RDコストが最小となる方を、最適予測モードに決定する。そして、予測画像選択部48は、最適予測モードの予測画像を、演算部33および加算部40に出力する。
 ステップS36において、予測画像選択部48は、最適予測モードが最適インター予測モードであるかどうかを判定する。ステップS36で最適予測モードが最適インター予測モードであると判定された場合、予測画像選択部48は、最適インター予測モードで生成された予測画像の選択を動き予測・補償部47に通知する。
 そして、ステップS37において、動き予測・補償部47は、インター予測モード情報とインター予測のパラメータとを可逆符号化部36に出力する。その後、処理は、ステップS39に進む。
 一方、ステップS36で最適予測モードが最適イントラ予測モードである場合、予測画像選択部48は、最適イントラ予測モードで生成された予測画像の選択をイントラ予測部46に通知する。そして、ステップS38において、イントラ予測部46は、イントラ予測モード情報を可逆符号化部36に出力する。その後、処理は、ステップS39に進む。
 ステップS39において、演算部33は、画面並べ替えバッファ32から供給される画像から、予測画像選択部48から供給される予測画像を減算することにより符号化を行う。演算部33は、減算後の画像を、残差情報として直交変換部34に出力する。
 ステップS40において、直交変換部34は、残差情報に対して直交変換処理を行う。直交変換部34は、直交変換処理後の直交変換処理結果を量子化部35に出力する。
 ステップS41において、量子化部35は、直交変換部34から供給される直交変換処理結果を量子化する。量子化部35は、量子化後の量子化値を可逆符号化部36と逆量子化部38に出力する。
 図11のステップS42において、逆量子化部38は、量子化部35からの量子化値に対して逆量子化を行う。逆量子化部38は、逆量化後の直交変換処理結果を逆直交変換部39に出力する。
 ステップS43において、逆直交変換部39は、直交変換処理結果に対して逆直交変換処理を行う。逆直交変換部39は、逆直交変換処理後の残差情報を加算部40に出力する。
 ステップS44において、加算部40は、逆直交変換部39から供給される残差情報と、予測画像選択部48から供給される予測画像を加算し、復号を行う。加算部40は、復号された画像をデブロックフィルタ41とフレームメモリ44に出力する。
 ステップS45において、デブロックフィルタ41は、加算部40から供給される画像に対して、デブロックフィルタ処理を行う。デブロックフィルタ41は、デブロックフィルタ処理後の画像を適応オフセットフィルタ42に出力する。
 ステップS46において、適応オフセットフィルタ42は、デブロックフィルタ処理後の画像に対して適応オフセットフィルタ処理を行う。適応オフセットフィルタ42は、適応オフセットフィルタ処理後の画像を適応ループフィルタ43に出力する。また、適応オフセットフィルタ42は、オフセットフィルタ情報を可逆符号化部36に出力する。
 ステップS47において、適応ループフィルタ43は、適応オフセットフィルタ処理後の画像に対して、適応ループフィルタ処理を行う。適応ループフィルタ43は、適応ループフィルタ処理後の画像をフレームメモリ44に出力する。また、適応ループフィルタ43は、適応ループフィルタ処理で用いられたフィルタ係数を可逆符号化部36に出力する。
 ステップS48において、フレームメモリ44は、適応ループフィルタ43から供給される画像と加算部40から供給される画像を蓄積する。フレームメモリ44に蓄積されたフィルタ処理が行われていない画像のうちのCUに隣接する画像は、周辺画像としてスイッチ45を介してイントラ予測部46に出力される。一方、フレームメモリ44に蓄積されたフィルタ処理が行われた画像は、参照画像としてスイッチ45を介して動き予測・補償部47に出力される。
 ステップS49において、可逆符号化部36は、イントラ予測モード情報、または、インター予測モード情報、インター予測のパラメータ、オフセットフィルタ情報、並びにフィルタ係数を、符号化情報として可逆符号化する。
 ステップS50において、可逆符号化部36は、量子化部35から供給される量子化値を可逆符号化する。そして、可逆符号化部36は、ステップS49の処理で可逆符号化された符号化情報と可逆符号化された量子化値から、符号化データを生成し、蓄積バッファ37に出力する。
 ステップS51において、蓄積バッファ37は、可逆符号化部36から供給される符号化データを、一時的に蓄積する。
 ステップS52において、レート制御部49は、蓄積バッファ37に蓄積された符号化データに基づいて、オーバーフローあるいはアンダーフローが発生しないように、量子化部35の量子化動作のレートを制御する。その後、符号化処理は終了される。
 なお、図10および図11の符号化処理では、説明を簡単化するため、常に、イントラ予測処理と動き予測・補償処理が行われるようにしたが、実際には、ピクチャタイプ等によっていずれか一方のみが行われる場合もある。
 <復号装置の構成例>
 図12は、図9の符号化装置から伝送される符号化ストリームを復号する、本開示を適用した復号装置の一実施の形態の構成例を示すブロック図である。
 図12の復号装置101は、蓄積バッファ131、可逆復号部132、逆量子化部133、逆直交変換部134、加算部135、デブロックフィルタ136、適応オフセットフィルタ137、適応ループフィルタ138、および画面並べ替えバッファ139を有する。また、復号装置101は、D/A変換部140、フレームメモリ141、スイッチ142、イントラ予測部143、インター予測部51、およびスイッチ144を有する。
 復号装置101の蓄積バッファ131は、図9の符号化装置1から伝送される符号化ストリームの符号化データを受け取り、蓄積する。蓄積バッファ131は、蓄積されている符号化データを可逆復号部132に出力する。
 可逆復号部132は、蓄積バッファ131からの符号化データに対して、可変長復号や、算術復号などの可逆復号を施すことで、量子化値と符号化情報を得る。可逆復号部132は、量子化値を逆量子化部133に出力する。符号化情報は、イントラ予測モード情報、インター予測モード情報、インター予測のパラメータ、オフセットフィルタ情報、フィルタ係数などで構成される。
 また、可逆復号部132は、イントラ予測モード情報などをイントラ予測部143に出力する。可逆復号部132は、インター予測のパラメータ、インター予測モード情報などをインター予測部51に出力する。
 可逆復号部132は、イントラ予測モード情報またはインター予測モード情報をスイッチ144に出力する。可逆復号部132は、オフセットフィルタ情報を適応オフセットフィルタ137に出力する。可逆復号部132は、フィルタ係数を適応ループフィルタ138に出力する。
 逆量子化部133、逆直交変換部134、加算部135、デブロックフィルタ136、適応オフセットフィルタ137、適応ループフィルタ138、フレームメモリ141、スイッチ142、イントラ予測部143、およびインター予測部51は、図9の逆量子化部38、逆直交変換部39、加算部40、デブロックフィルタ41、適応オフセットフィルタ42、適応ループフィルタ43、フレームメモリ44、スイッチ45、イントラ予測部46、および動き予測・補償部47とそれぞれ同様の処理を行う。これにより、画像が復号される。
 具体的には、逆量子化部133は、図9の逆量子化部38と同様に構成される。逆量子化部133は、可逆復号部132からの量子化値を逆量子化する。逆量子化部133は、逆量子化後の直交変換処理結果を逆直交変換部134に出力する。
 逆直交変換部134は、図9の逆直交変換部39と同様に構成される。逆直交変換部134は、逆量子化部133から供給される直交変換処理結果に対して逆直交変換処理を行う。逆直交変換部134は、逆直交変換処理後の残差情報を加算部135に出力する。
 加算部135は、逆直交変換部134から供給される残差情報と、スイッチ144から供給される予測画像を加算することにより、復号を行う。加算部135は、復号された画像をデブロックフィルタ136とフレームメモリ141に出力する。
 デブロックフィルタ136は、加算部135から供給される画像に対してデブロックフィルタ処理を行い、デブロックフィルタ処理後の画像を適応オフセットフィルタ137に出力する。
 適応オフセットフィルタ137は、可逆復号部132からのオフセットフィルタ情報が表すオフセットを用いて、デブロックフィルタ処理後の画像に対して、オフセットフィルタ情報が表す種類の適応オフセットフィルタ処理を行う。適応オフセットフィルタ137は、適応オフセットフィルタ処理後の画像を、適応ループフィルタ138に出力する。
 適応ループフィルタ138は、適応オフセットフィルタ137から供給される画像に対して、可逆復号部132から供給されるフィルタ係数を用いて、適応ループフィルタ処理を行う。適応ループフィルタ138は、適応ループフィルタ処理後の画像をフレームメモリ141および画面並べ替えバッファ139に出力する。
 画面並べ替えバッファ139は、適応ループフィルタ処理後の画像をフレーム単位で記憶する。画面並べ替えバッファ139は、符号化順のフレーム単位の画像を、元の表示順に並び替え、D/A変換部140に出力する。
 D/A変換部140は、画面並べ替えバッファ139から供給されるフレーム単位の画像をD/A変換し、出力する。
 フレームメモリ141は、適応ループフィルタ処理後の画像と加算部135から供給される画像を蓄積する。フレームメモリ141に蓄積されたフィルタ処理が行われていない画像のうちのCUに隣接する画像は、周辺画像としてスイッチ142を介してイントラ予測部143に供給される。一方、フレームメモリ141に蓄積されたフィルタ処理が行われた画像は、参照画像として、スイッチ142を介してインター予測部51に出力される。
 イントラ予測部143は、フレームメモリ141からスイッチ142を介して読み出された周辺画像を用いて、可逆復号部132から供給されるイントラ予測モード情報が示す最適イントラ予測モードのイントラ予測処理を行う。イントラ予測部143は、その結果生成される予測画像をスイッチ144に出力する。
 インター予測部51は、図9と同様に構成される。インター予測部51は、可逆復号部132から供給されるインター予測のパラメータを用いて、インター予測モード情報が示す最適インター予測モードのインター予測を行い、予測画像を生成する。
 インター予測部51は、フレームメモリ141からスイッチ142を介して、可逆復号部132から供給されるインター予測のパラメータの参照画像情報により特定される参照画像を読み出す。インター予測部51は、可逆復号部132から供給されるインター予測のパラメータの動き情報および読み出した参照画像を用いて、BIO処理を含むBi予測などにより予測画像を生成する。生成された予測画像は、スイッチ144に出力される。
 スイッチ144は、可逆復号部132からイントラ予測モード情報が供給された場合、イントラ予測部143から供給される予測画像を加算部135に出力する。一方、可逆復号部132からインター予測モード情報が供給された場合、スイッチ144は、インター予測部51から供給される予測画像を加算部135に出力する。
 <復号装置の動作>
 図13は、復号装置の復号処理の詳細を説明するフローチャートである。
 図13のステップS131において、復号装置101の蓄積バッファ131は、図示せぬ前段から供給されるフレーム単位の符号化データを受け取り、蓄積する。蓄積バッファ131は、蓄積されている符号化データを可逆復号部132に出力する。
 ステップS132において、可逆復号部132は、蓄積バッファ131からの符号化データを可逆復号し、量子化値と符号化情報を得る。可逆復号部132は、量子化値を逆量子化部133に出力する。
 可逆復号部132は、イントラ予測モード情報などをイントラ予測部143に出力する。可逆復号部132は、インター予測のパラメータ、インター予測モード情報などをインター予測部51に出力する。
 また、可逆復号部132は、イントラ予測モード情報またはインター予測モード情報をスイッチ144に出力する。可逆復号部132は、オフセットフィルタ情報を適応オフセットフィルタ137に供給し、フィルタ係数を適応ループフィルタ138に出力する。
 ステップS133において、逆量子化部133は、可逆復号部132から供給される量子化値を逆量子化する。逆量子化部133は、逆量子化後の直交変換処理結果を逆直交変換部134に出力する。
 ステップS134において、逆直交変換部134は、逆量子化部133から供給される直交変換処理結果に対して直交変換処理を行う。
 ステップS135において、インター予測部51は、可逆復号部132からインター予測モード情報が供給されたかどうかを判定する。ステップS135でインター予測モード情報が供給されたと判定された場合、処理はステップS136に進む。
 ステップS136において、インター予測部51は、可逆復号部132から供給される参照画像特定情報に基づいて参照画像を読み出し、動き情報と参照画像を用いて、インター予測モード情報が示す最適インター予測モードの動き補償処理を行う。例えば、インター予測部51は、BIO処理を含むBi予測などにより予測画像を生成する。インター予測部51は、生成した予測画像を、スイッチ144を介して加算部135に出力する。その後、処理は、ステップS138に進む。
 一方、ステップS135でインター予測モード情報が供給されていないと判定された場合、すなわち、イントラ予測モード情報がイントラ予測部143に供給された場合、処理はステップS137に進む。
 ステップS137において、イントラ予測部143は、フレームメモリ141からスイッチ142を介して読み出された周辺画像を用いて、イントラ予測モード情報が示すイントラ予測モードのイントラ予測処理を行う。イントラ予測部143は、イントラ予測処理の結果生成される予測画像を、スイッチ144を介して加算部135に出力する。その後、処理は、ステップS138に進む。
 ステップS138において、加算部135は、逆直交変換部134から供給される残差情報と、スイッチ144から供給される予測画像を加算することにより、復号を行う。加算部135は、復号された画像をデブロックフィルタ136とフレームメモリ141に出力する。
 ステップS139において、デブロックフィルタ136は、加算部135から供給される画像に対してデブロックフィルタ処理を行い、ブロック歪を除去する。デブロックフィルタ136は、デブロックフィルタ処理後の画像を適応オフセットフィルタ137に出力する。
 ステップS140において、適応オフセットフィルタ137は、可逆復号部132から供給されるオフセットフィルタ情報に基づいて、デブロックフィルタ処理後の画像に対して、適応オフセットフィルタ処理を行う。適応オフセットフィルタ137は、適応オフセットフィルタ処理後の画像を、適応ループフィルタ138に出力する。
 ステップS141において、適応ループフィルタ138は、適応オフセットフィルタ137から供給される画像に対して、可逆復号部132から供給されるフィルタ係数を用いて、適応ループフィルタ処理を行う。適応ループフィルタ138は、適応ループフィルタ処理後の画像をフレームメモリ141および画面並べ替えバッファ139に供給する。
 ステップS142において、フレームメモリ141は、加算部135から供給される画像と、適応ループフィルタ138から供給される画像を蓄積する。フレームメモリ141に蓄積されたフィルタ処理が行われていない画像のうちのCUに隣接する画像は、周辺画像としてスイッチ142を介してイントラ予測部143に供給される。一方、フレームメモリ141に蓄積されたフィルタ処理が行われた画像は、参照画像として、スイッチ142を介してインター予測部51に供給される。
 ステップS143において、画面並べ替えバッファ139は、適応ループフィルタ138から供給される画像をフレーム単位で記憶し、符号化順のフレーム単位の画像を、元の表示順に並び替え、D/A変換部140に出力する。
 ステップS144において、D/A変換部140は、適応ループフィルタ処理後の画像をD/A変換し、出力する。
 <インター予測部の構成例>
 図14は、インター予測部の構成例を示すブロック図である。
 図14において、インター予測部51は、インター予測制御部201、L0予測ブロック生成部202、L1予測ブロック生成部203、BIOコスト計算部204、BIO適用判定部205、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、Bi予測ブロック選択部208、および予測ブロック選択部209から構成される。
 インター予測制御部201には、符号化装置1の場合、動き予測・補償部47から(復号装置101の場合、可逆復号部132から)インター予測のパラメータが供給される。
 インター予測のパラメータは、フレーム内のPU位置、PUサイズ、予測方向(L0,L1,Biのうちいずれか1つが設定される)、参照画像情報、動き情報などからなる。
 インター予測制御部201は、例えば、CPU(Central Processing Unit)やマイクロプロセッサなどから構成される。インター予測制御部201は、CPUにより所定のプログラムを実行し、インター予測パラメータの内容に応じて、各部を制御する。
 インター予測制御部201は、L0予測のパラメータをL0予測ブロック生成部202に供給し、L0予測ブロック生成部202を制御する。L0予測のパラメータは、PU位置、PUサイズ、参照画像情報REFIDX_L0、動き情報MV_L0からなる。
 インター予測制御部201は、L1予測のパラメータをL1予測ブロック生成部203に供給し、L1予測ブロック生成部203を制御する。L1予測のパラメータは、PU位置、PUサイズ、参照画像情報REFIDX_L1、動き情報MV_L1からなる。
 インター予測制御部201は、Bi予測のパラメータを、BIOコスト計算部204、Bi予測ブロック生成部206、およびBIO処理を含むBi予測ブロック生成部207に供給し、BIOコスト計算部204、Bi予測ブロック生成部206、およびBIO処理を含むBi予測ブロック生成部207を制御する。Bi予測のパラメータは、PUサイズなどからなる。
 インター予測制御部201は、BIO閾値をBIO適用判定部205に供給し、BIO適用判定部205を制御する。
 インター予測制御部201は、予測方向を予測ブロック選択部209に供給し、予測ブロック選択部209を制御する。
 L0予測ブロック生成部202は、予測方向がL0またはBiのときに動作する。L0予測ブロック生成部202は、インター予測制御部201から供給されるL0予測のパラメータに基づいて、フレームメモリ44にアクセスし、参照画像からL0予測画像を生成する。生成されたL0予測画像は、L0予測ブロック生成部202から、BIOコスト計算部204、BIO適用判定部205、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、および予測ブロック選択部209に供給される。
 L1予測ブロック生成部203は、予測方向がL1またはBiのときに動作する。L1予測ブロック生成部203は、インター予測制御部201から供給されるL1予測のパラメータに基づいて、フレームメモリ44にアクセスし、参照画像からL1予測画像を生成する。生成されたL1予測画像は、L1予測ブロック生成部203から、BIOコスト計算部204、BIO適用判定部205、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、および予測ブロック選択部209に供給される。
 BIOコスト計算部204は、予測方向がBiのとき動作する。BIOコスト計算部204は、インター予測制御部201から供給されるBi予測のパラメータに基づいて、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。計算されたSADは、BIOコスト計算部204からBIO適用判定部205に供給される。
 BIO適用判定部205は、予測方向がBiのとき動作する。BIO適用判定部205は、インター予測制御部201から供給されるBIO閾値と、BIOコスト計算部204から供給されるSADとを比較し、BIO_ONフラグを決定する。BIO閾値よりもSADが大きいとき、BIO_ONフラグが、BIO適用を示すBIO_ON=1に決定され、BIO閾値よりもSADが小さいとき、BIO_ONフラグが、BIO不適用を示すBIO_ON=0に決定される。
 決定されたBIO_ONフラグは、BIO適用判定部205から、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、Bi予測ブロック選択部208に供給される。
 Bi予測ブロック生成部206は、BIO適用判定部205から供給されるBIO_ONフラグに基づいて、予測方向がBiで、BIO_ON=0のとき動作する。Bi予測ブロック生成部206は、インター予測制御部201から供給されるBi予測のパラメータに基づいて、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測画像を生成する。生成されたBi予測画像は、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。
 BIO処理を含むBi予測ブロック生成部207は、BIO適用判定部205から供給されるBIO_ONフラグに基づいて、予測方向がBiで、BIO_ON=1のとき動作する。Bi予測ブロック生成部206は、インター予測制御部201から供給されるBi予測のパラメータに基づいて、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、BIO処理を含むBi予測画像を生成する。生成されたBIO処理を含むBi予測画像は、BIO処理を含むBi予測ブロック生成部207からBi予測ブロック選択部208に供給される。
 Bi予測ブロック選択部208は、BIO適用判定部205から供給されるBIO_ONフラグに基づいて、Bi予測画像を選択する。Bi予測ブロック選択部208は、BIO_ON=0の場合、Bi予測ブロック生成部206から供給されるBi予測画像を選択し、BIO_ON=1の場合、BIO処理を含むBi予測ブロック生成部207から供給されるBIO処理を含むBi予測画像を選択する。選択されたBi予測画像は、Bi予測ブロック選択部208から予測ブロック選択部209に供給される。
 予測ブロック選択部209は、インター予測制御部201から供給される予測方向に応じて、予測画像を選択し、選択した予測画像を、インター予測の予測画像として、後段の図9の予測画像選択部48(または図12のスイッチ144)に出力する。
 予測ブロック選択部209は、予測方向がL0である場合、L0予測ブロック生成部202から供給されるL0予測画像を選択し、予測方向がL1である場合、L1予測ブロック生成部203から供給されるL1予測画像を選択する。予測ブロック選択部209は、予測方向がBiである場合、Bi予測ブロック選択部208から供給されるBi予測画像を選択する。
 <インター予測部の動作例>
 図15および図16は、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 なお、この処理は、後述する本技術のBIOを含むBi予測処理と比較するための従来のBIOを含むBi予測処理である。また、このBIOを含むBi予測処理は、符号化側と復号側の両方で行われる処理であり、図10のステップS34で行われる動き予測・補償処理の一部の処理であり、図13のステップS136で行われるインター予測処理の一部の処理である。
 図15のステップS301において、インター予測制御部201は、動き予測・補償部47から供給されるインター予測のパラメータを取得する。なお、復号装置101の場合、インター予測のパラメータは、可逆復号部132から供給される。
 インター予測のパラメータは、フレーム内のPU位置、PUサイズ、予測方向(L0,L1,Biのうちいずれか1つが設定される)、参照画像情報、動き情報などからなる。
 インター予測制御部201は、L0予測のパラメータをL0予測ブロック生成部202に供給する。L0予測のパラメータは、PU位置、PUサイズ、参照画像情報REFIDX_L0、動き情報MV_L0からなる。インター予測制御部201は、L1予測のパラメータをL1予測ブロック生成部203に供給する。L1予測のパラメータは、PU位置、PUサイズ、参照画像情報REFIDX_L1、動き情報MV_L1からなる。
 インター予測制御部201は、Bi予測のパラメータを、BIOコスト計算部204、Bi予測ブロック生成部206、およびBIO処理を含むBi予測ブロック生成部207に供給する。Bi予測のパラメータは、PUサイズを示す情報である。
 インター予測制御部201は、BIO閾値をBIO適用判定部205に供給する。インター予測制御部201は、予測方向を予測ブロック選択部209に供給し、予測ブロック選択部209を制御する。
 ステップS302において、L0予測ブロック生成部202は、インター予測制御部201から供給されるL0予測のパラメータに基づいて、フレームメモリ44にアクセスし、参照画像からL0予測ブロックを生成する。なお、復号装置101の場合、参照画像は、フレームメモリ141にアクセスされて参照される。
 ステップS303において、L1予測ブロック生成部203は、インター予測制御部201から供給されるL1予測のパラメータに基づいて、フレームメモリ44にアクセスし、参照画像からL1予測ブロックを生成する。
 ステップS302およびS303の処理における最大バッファサイズは、PU´サイズである。PU´サイズは、PUのサイズ相当のサイズであり、PUのサイズより一回り大きいサイズを表す。
 ステップS304において、BIOコスト計算部204は、4×4単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。4×4単位にSADを計算し、積み上げることで、SADの総和であるSAD_4×4ブロックが取得される。
 ステップS305において、BIOコスト計算部204は、PU単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。PU単位にSADを計算し、積み上げることで、SADの総和であるSAD_PUが取得される。取得されたSAD_PUは、BIOコスト計算部204からBIO適用判定部205に供給される。
 ステップS306において、BIO適用判定部205は、BIO_PU_ONフラグを、BIOコスト計算部204から供給されるSAD_PU>=インター予測制御部201から供給されるBIO閾値_PUに基づいて決定する。決定されたBIO_PU_ONフラグは、BIO適用判定部205から、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、Bi予測ブロック選択部208に供給される。
 BIO閾値よりもSADが大きいとき、BIO_PU_ONフラグが、BIO適用を示すBIO_PU_ON=1に決定され、BIO閾値よりもSADが小さいとき、BIO_PU_ONフラグが、BIO不適用を示すBIO_PU_ON=0に決定される。
 ステップS307において、Bi予測ブロック生成部206およびBIO処理を含むBi予測ブロック生成部207は、BIO_PU_ONフラグが1であるか否かを判定する。
 ステップS307において、BIO_PU_ONフラグが1ではないと判定された場合、処理は、ステップS308に進む。
 ステップS308において、Bi予測ブロック生成部206は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測ブロックPUを生成する。生成されたBi予測ブロックPUは、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。その後、BIOを含むBi予測処理は終了される。
 ステップS308の処理における最大バッファサイズは、PUサイズである。
 一方、ステップS307において、BIO_PU_ONフラグが1であると判定された場合、処理は、ステップS309に進む。
 以降のステップS309乃至S320においては、BIO処理を含むBi予測ブロック生成部207により、BIO処理を含むBi予測画像の生成処理が行われる。
 ステップS309において、BIO処理を含むBi予測ブロック生成部207は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、複数の勾配を計算する。ステップS309の処理における最大バッファサイズは、PU´サイズ×9個である。
 ステップS310において、BIO処理を含むBi予測ブロック生成部207は、PU内に含まれる4×4ブロック数を取得する。
 ステップS311において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号に0を設定する。
 図16のステップS312において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号が4×4ブロック数より小さいか否かを判定する。
 ステップS312において、4×4ブロック番号が4×4ブロック数より小さいと判定された場合、処理は、ステップS313に進む。
 ステップS313において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号からPU内の位置とSAD_4×4を取得する。
 ステップS314において、BIO処理を含むBi予測ブロック生成部207は、BIO_4×4_ONをSAD_4×4>=BIO閾値_4×4に基づいて決定する。
 ステップS315において、BIO処理を含むBi予測ブロック生成部207は、BIO_4×4_ONフラグが1であるか否かを判定する。
 ステップS315において、BIO_4×4_ONフラグが1ではないと判定された場合、処理は、ステップS316に進む。
 ステップS316において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域のL0予測画像とL1予測画像からBi予測値を生成する。
 ステップS315において、BIO_4×4_ONフラグが1であると判定された場合、処理は、ステップS317に進む。
 ステップS317において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域の複数の勾配から速度を計算する。
 ステップS318において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域のL0予測画像、L1予測画像、勾配、および速度からBIO予測値を生成する。
 ステップS316およびS318の後、処理は、ステップS319に進む。
 ステップS319において、BIO処理を含むBi予測ブロック生成部207は、予測値を、バッファにおける4×4ブロック番号の位置に保存する。ステップ319の処理における最大バッファサイズは、PUサイズである。
 ステップS320において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号をインクリメントする。その後、ステップS312に戻り、それ以降の処理が繰り返される。
 ステップS308の後、または、ステップS312において、4×4ブロック番号が4×4ブロック数より小さくないと判定された場合、BIOを含むBi予測は終了される。
 なお、上述したBIOを含むBi処理においては、ステップS305で、PU全体でL0予測ブロックとL1予測ブロックのSADが計算され、ステップS306において、SADと閾値とを比較してBIO処理の適用可否が判定されて、ステップS307において、処理が分岐されている。
 そのため、VPDUより大きなPUでインター予測する場合に、PUを仮想的に複数のvPUに分割処理することが困難になってしまった。その結果、ステップS302、S303、およびS309で必要になるバッファは、ステップS309の勾配計算やステップS317の速度計算のためにPUより一回り大きな領域であるPU´が必要となっている。PU´の最大サイズは、PUの水平サイズと垂直サイズとをそれぞれ2加算した結果である130×130のサイズである。
 さらに、ステップS308では、PUサイズのバッファが必要となる。これらのことは、BIOを含むインター予測部51では、大きなバッファリソースが必要となることを意味する。
 また、このバッファを必要とするインター予測部51をHW(ハードウェア)実装した場合、BIOを含むインター予測のパイプライン遅延とTU処理のパイプライン遅延が大きく異なるため、スループットを維持するためのHW実装難易度も高くなってしまう。
 これは、符号化側、復号側の両方に関わる。符号化側では、CUを常に64×64以下に分解するなどの自己制約で回避することは可能であるが、符号化側の自由度を確保するためにも解決方法があると望ましい。規格適合が求められる復号側では、大きなHWリソースが必要不可欠である。
 そこで、上述したように、本技術においては、BIOなどの双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当の分割処理単位またはVPDUサイズ以下の分割処理単位に分割し、分割処理単位に基づいて計算されたコストを用いて判定を行うようにした。
 VPDUサイズ相当は、VPDUサイズより一回り大きな領域であるVPDU´サイズを表す。
 <インター予測部の動作例>
 図17および図18は、本技術の第1の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 図17および図18においては、符号化装置1の場合について説明するが、復号装置101の場合も同様の処理が行われるので、その説明については省略される。
 ステップS401において、インター予測制御部201は、動き予測・補償部47から供給されるインター予測のパラメータを取得する。
 ステップS402において、インター予測制御部201は、PU内に含まれるvPU数を取得する。すなわち、PUがVPDUより大きい場合、PUは、仮想的に複数のvPUに分割されている。PUが128×128である場合、vPU数には4が設定される。PUが128×64または64×128である場合、vPU数には2が設定される。PUが64×64以下である場合、vPU数には1が設定される。vPU数が1である場合は、仮想的な分割はなされず、実質的に、図15および図16と同様の処理が行われる。
 ステップS403において、インター予測制御部201は、最初に処理するvPU番号として0を設定する。
 ステップS404において、インター予測制御部201は、vPU番号がvPU数より小さいか否かを判定する。
 ステップS404において、vPU番号がvPU数より小さいと判定された場合、処理は、ステップS405に進む。
 ステップS405において、インター予測制御部201は、PUサイズとvPU番号から、PU内のどの領域を処理するかを示すvPUの位置とサイズを取得する。
 図19は、PUサイズ、vPU番号、および処理位置とサイズの対応関係を示す図である。
 PUサイズが128×128において、vPU番号が0のとき、処理する位置が左上であり、サイズが64×64である。vPU番号が1のとき、処理する位置が右上であり、サイズが64×64である。vPU番号が2のとき、処理する位置が左下であり、サイズが64×64である。vPU番号が3のとき、処理する位置が右下であり、サイズが64×64である。
 PUサイズが128×64において、vPU番号が0のとき、処理する位置が左であり、サイズが64×64である。vPU番号が1のとき、処理する位置が右であり、サイズが64×64である。
 PUサイズが64×128において、vPU番号が0のとき、処理する位置が上であり、サイズが64×64である。vPU番号が1のとき、処理する位置が下であり、サイズが64×64である。
 PUサイズが64×64以下において、vPU番号が0のとき、処理する位置がPUそのものである。
 図17に戻って、ステップS405で取得されたvPUの位置とサイズは、L0予測ブロック生成部202およびL1予測ブロック生成部203に供給される。
 ステップS406において、L0予測ブロック生成部202は、vPU番号の領域のL0予測ブロックを生成する。
 ステップS407において、L1予測ブロック生成部203は、vPU番号の領域のL1予測ブロックを生成する。
 ステップ406およびS407の処理における最大バッファサイズは、例えば、ステップS413の勾配計算やステップS421の速度計算で必要となる一回り大きな領域が含まれるVPDU´サイズである。VPDU´サイズは、VPDUのサイズより一回り大きいサイズである、上述したVPDUサイズ相当を表し、例えば、水平・垂直サイズをそれぞれ2を加算した結果である66×66とされる。
 後段のBIO適用判定は最大でもVPDUサイズのSAD値で行われるため、ここで生成されたL0予測ブロックやL1予測ブロックを保存しておくバッファサイズも、VPDUサイズをベースとすることができる。
 ステップS408において、BIOコスト計算部204は、vPU内の4×4単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。4×4単位にSADを計算し、積み上げることで、SADの総和であるSAD_4×4ブロックが取得される。
 後段において、速度計算の単位である4×4ブロックでも、再度BIOの適用判定を行い、効果が見込めない場合のアーリーターミネーションとするため、このSAD_4×4ブロックも保存しておく必要がある。ただし、SAD_4×4ブロックの保存のためのバッファサイズは、図15のステップS304と比較して、1/4のサイズに削減することができる。
 ステップS409において、BIOコスト計算部204は、vPU単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。vPU単位にSADを計算し、積み上げることで、SADの総和であるSAD_vPUが取得される。取得されたSAD_vPUは、BIOコスト計算部204からBIO適用判定部205に供給される。
 ステップS410において、BIO適用判定部205は、BIO_vPU_ONフラグを、BIOコスト計算部204から供給されるSAD_vPU>=インター予測制御部201から供給されるBIO閾値_vPUに基づいて決定する。BIO閾値_vPUは、BIO閾値_PUが、ステップS405で求めたvPUのサイズに応じた値にスケールされた値である。
 決定されたBIO_vPU_ONフラグは、BIO適用判定部205から、Bi予測ブロック生成部206、BIO処理を含むBi予測ブロック生成部207、Bi予測ブロック選択部208に供給される。
 ステップS411において、Bi予測ブロック生成部206およびBIO処理を含むBi予測ブロック生成部207は、BIO_vPU_ONフラグが1であるか否かを判定する。
 ステップS411において、BIO_vPU_ONフラグが1ではないと判定された場合、vPU全体に対してBIOの効果がないとして、処理は、ステップS412に進む。
 ステップS412において、Bi予測ブロック生成部206は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測ブロックvPUを生成する。生成されたBi予測ブロックvPUは、バッファに保存されるとともに、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。
 HW実装時にパイプラインを組む場合、vPUのインター予測と並列にVPDU単位のTU処理も実行されており、このタイミングで次の処理が開始できるようになる。そのため、ここに用意しておくBi予測を保存しておくバッファも最大VPDUサイズであればよい。その後、処理は、図18のステップS425に進む。
 一方、ステップS411において、BIO_vPU_ONフラグが1であると判定された場合、処理は、ステップS413に進む。
 ステップS413において、BIO処理を含むBi予測ブロック生成部207は、L0予測ブロック生成部202から供給されるL0予測ブロックとL1予測ブロック生成部203から供給されるL1予測ブロックとから、複数の勾配を計算する。
 ステップS413では、L0予測ブロックとL1予測ブロックとから9種類の中間パラメータが計算される。L0予測ブロックとL1予測ブロック同士の変化量やそれぞれの予測ブロックでの水平・垂直方向でのそれぞれの画素値の変化量が計算されるので、それらをまとめて勾配と呼ぶ。勾配は、予測ブロックと同じ画素数ずつ計算する必要があるため、ここで、必要となるバッファは最大VPDU´サイズ×9個でよい。
 図18のステップS414において、BIO処理を含むBi予測ブロック生成部207は、vPU内に含まれる4×4ブロック数を取得する。例えば、vPUが64×64の場合、4×4ブロック数は256個となる。Optical flowでは、ピクセル単位で速度を求めて予測値を計算するのが最も予測精度がよいが、それには、膨大な計算が必要となる。BIOでは、性能とコストのトレードオフで、4×4ブロック単位に速度を計算することで、バランスをとっている。
 ステップS415において、BIO処理を含むBi予測ブロック生成部207は、最初に処理する4×4ブロック番号として0を設定する。
 ステップS416において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号が4×4ブロック数より小さいか否かを判定する。
 ステップS416において、4×4ブロック番号が4×4ブロック数より小さいと判定された場合、処理は、ステップS417に進む。
 ステップS417において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号からvPU内の位置とSAD_4×4を取得する。4×4ブロックは、ラスタスキャン順で処理されていく。
 ステップS418において、BIO処理を含むBi予測ブロック生成部207は、BIO_4×4_ONをSAD_4×4>=BIO閾値_4×4に基づいて決定する。
 ステップS419において、BIO処理を含むBi予測ブロック生成部207は、BIO_4×4_ONフラグが1であるか否かを判定する。
 ステップS419において、BIO_4×4_ONフラグが1ではないと判定された場合、4×4ブロックに対してBIOの効果が見込めないとし、処理は、ステップS420に進む。
 ステップS420において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域のL0予測画像とL1予測画像との平均を計算することで、Bi予測値を生成する。
 ステップS419において、BIO_4×4_ONフラグが1であると判定された場合、処理は、ステップS421に進む。
 ステップS421において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域の複数の勾配から速度を計算する。
 ステップS422において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号の領域のL0予測画像、L1予測画像、勾配、および速度からBIO予測値を生成する。
 ステップS420およびS422の後、処理は、ステップS423に進む。
 ステップS423において、BIO処理を含むBi予測ブロック生成部207は、ステップS420またはステップS422で生成された予測値を、バッファにおける4×4ブロック番号の位置に保存する。ステップ423の処理における最大バッファサイズは、VPDUサイズである。バッファは、S412の処理で用いるバッファと共通化してもよい。
 ステップS424において、BIO処理を含むBi予測ブロック生成部207は、4×4ブロック番号をインクリメントする。その後、ステップS416に戻り、それ以降の処理が繰り返される。
 ステップS412の後、または、ステップS416において、4×4ブロック番号が4×4ブロック数以上であると判定された場合、処理は、ステップS425に進む。
 ステップS425において、インター予測制御部201は、vPU番号をインクリメントし、ステップS404に戻り、それ以降の処理が繰り返される。
 ステップS404において、vPU番号がvPU数以上であると判定された場合、BIO処理を含むBi予測は終了される。
 図20および図21は、従来の動作と、本技術の第1の実施の形態の動作を実施した場合の比較を示す図である。
 図20の上側においては、CU(PU)128×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が、従来の動作と本技術の第1の実施の形態の動作の場合についてそれぞれ示されている。CU(PU)128×128の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが4つに分割されている。
 図20の下側においては、CU(PU)128×64で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が、従来の動作と本技術の第1の実施の形態の動作の場合についてそれぞれ示されている。CU(PU)128×64の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが左右の2つに分割されている。
 図21の上側においては、CU(PU)64×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が、従来の動作と本技術の第1の実施の形態の動作の場合についてそれぞれ示されている。CU(PU)64×128の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが上下の2つに分割されている。
 図21の下側においては、CU(PU)64×64以下で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が、従来の動作と本技術の第1の実施の形態の動作の場合についてそれぞれ示されている。CU(PU)64×64以下の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが分割されず、1つで構成される。
 従来動作では、PU全体のSADが必要なため、広範囲のL0予測ブロックとL1予測ブロックとを予め準備、保存しておく必要があるが、本技術では、VPDUより大きなPUでは仮想的に分割したvPU毎にBIOの適用判定を行うため、予め準備、保存しておくL0予測ブロックとL1予測ブロックのバッファを削減することが可能である。
 また、図15および図16のステップS308、S309、およびS319で用いるバッファと比較して、図17および図18のステップS412、S413、およびS423で用いるバッファも1/4の削減が可能となる。
 BIOのような復号側で2つの予測ブロックを生成し、コスト計算から判定を行い、インター予測の符号化効率を改善させるツールとして、FRUC(Frame Rate Up-Conversion)やDMVR(Decoder-side motion vector refinement)がある。BIOのアーリーターミネーション目的と異なり、FRUCやDMVRでは、MV補正を目的としてPUサイズより大きなL0予測ブロックとL1予測ブロックとが生成され、SADまたは類似するコスト計算が行われている。
 PUがVPDUより大きい場合には、本技術と同様の対応が必要となる。FRUCやDMVRでも本技術のように、PUがVPDUより大きい場合、仮想的に複数のvPUに分割し、vPU毎にMV補正することで対応することができる。
 ここまで上述してきた従来動作のPU全体でのSAD計算とBIOの適用判定、または、本技術のvPU毎のSAD計算とBIOの適用判定は、大枠でのアーリーターミネーションが主な目的であるため、さらなる削減を行うことができる。
 <変形例1>
 上述した第1の実施の形態では、PUがVPDUより大きい場合に、仮想的に複数のvPUに分割し、vPU毎にSAD計算をしてBIOの適用判定する例を説明した。PUを構成するvPUは、元々同じPUに含まれているということで、ある部分的な傾向が異なる部分の傾向と似ているのではないかと考えられる。
 図22および図23は、上述した傾向を前提とし、変形例1として、PUがVPDUより大きい場合に、vPU番号が0のBIO判定結果を、他のvPUでも用いた例を示す図である。
 図22の上側においては、CU(PU)128×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×128の場合、CU(PU)は、4つに分割されたBIO_vPU_ON判定のためのSAD計算領域であるvPUのうち、左上(vPU番号=0)のvPUについてSADが計算され、残りのvPU(右上、左下、右上)においては、vPU番号=0のvPUの結果がコピーして用いられる。
 図22の下側においては、CU(PU)128×64で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×64の場合、CU(PU)は、2つに分割されたBIO_vPU_ON判定のためのSAD計算領域であるvPUのうち、左(vPU番号=0)のvPUについてSADが計算され、残りのvPU(右)においては、vPU番号=0のvPUの結果がコピーして用いられる。
 図23の上側においては、CU(PU)64×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×64の場合、CU(PU)は、2つに分割されたBIO_vPU_ON判定のためのSAD計算領域であるvPUのうち、上(vPU番号=0)のvPUについてSADが計算され、残りのvPU(下)においては、vPU番号=0のvPUの結果がコピーして用いられる。
 図23の下側においては、CU(PU)64×64以下で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)64×64以下の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが分割されず、1つで構成される。
 <インター予測部の動作例>
 図24および図25は、図23の場合のBIOを含むBi予測を説明するフローチャートである。
 図24および図25のステップS501乃至S508と、ステップS510乃至S526は、図17および図18のステップS401乃至S425と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。
 図25のステップS508において、BIOコスト計算部204は、vPU内の4×4単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。4×4単位にSADを計算し、積み上げることで、SADの総和であるSAD_4×4ブロックが取得される。
 ステップS509において、BIOコスト計算部204は、vPU番号が0であるか否かを判定する。
 ステップS509において、vPU番号が0であると判定された場合、ステップS510に進む。
 ステップS510において、BIOコスト計算部204は、vPU単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。vPU単位にSADを計算し、積み上げることで、SADの総和であるSAD_vPUが取得される。取得されたSAD_vPUは、BIOコスト計算部204からBIO適用判定部205に供給される。
 ステップS511において、BIO適用判定部205は、BIO_vPU_ONフラグを、BIOコスト計算部204から供給されるSAD_vPU>=インター予測制御部201から供給されるBIO閾値_vPUに基づいて決定する。その後、処理は、ステップS512に進む。
 一方、vPU番号が0ではないと判定された場合、ステップS510およびS511はスキップされ、処理は、ステップS512に進む。
 以上のように、PUにおいて、ラスタスキャン順に最初に位置するvPUのときだけ、vPUのSADの積み上げとBIOの判定を行うようにしたので、アーリーターミネーションに係る処理や処理時間を短縮することができる。
 <変形例2>
 図26および図27は、変形例2として、各vPU内の部分的なSAD値でBIOの適用判定を行う例を示す図である。
 図26の上側においては、CU(PU)128×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×128の場合、CU(PU)は、2つに分割されたBIO_vPU_ON判定のためのSAD計算領域である各vPUにおいて、左上の一部分の領域(32×32)についてSADが計算される。
 図26の下側においては、CU(PU)128×64で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×64の場合、CU(PU)は、2つに分割されたBIO_vPU_ON判定のためのSAD計算領域である各vPUにおいて、左上の一部分の領域(32×32)についてSADが計算される。
 図27の上側においては、CU(PU)64×128で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)128×64の場合、CU(PU)は、2つに分割されたBIO_vPU_ON判定のためのSAD計算領域である各vPUにおいて、左上の一部分の領域(32×32)についてSADが計算される。
 図27の下側においては、CU(PU)64×64以下で、VPDU=64×64の場合における最初にBIOの適用判定のためにSADを計算した範囲が示されている。CU(PU)64×64以下の場合、CU(PU)は、BIO_vPU_ON判定のためのSAD計算領域であるvPUが分割されず、左上の一部分の領域(32×32)についてSADが計算される。
 以上のように、図26および図27においては、各vPUの左上1/4の領域でBIOの適用判定を行う例が示されているが、左上1/4の領域はHWでパイプラインを組む場合との相性も考慮されている。BIOの適用判定が可能となるのは、左上1/4領域のL0予測ブロックとL1予測ブロックが準備できたときだからである。
 各vPUの一部の領域のみ、BIOの適用判定に用いるようにすることで、各パイプラインステージに用意しておくバッファをVPDUサイズからさらに削減することができる。
 なお、一部の領域は、どんな大きさでもよく、例えば、0×0のサイズでコスト計算(SAD)をすることも可能である。すなわち、0ということは、コスト計算しないで、アーリーターミネーションをスキップすることと同意である。
 さらに、各vPUのBIO_vPU_ONの判定するために必要なSADを計算する領域を動的に変更することも可能である。
 <インター予測部の動作例>
 図28および図29は、各vPUのBIO_vPU_ONの判定のための部分的なSAD計算領域の判定処理を説明するフローチャートである。
 図28および図29では、L0予測ブロックとL1予測ブロックを生成するための2つのMVを水平成分と垂直成分の4つに分けて、参照位置が一番離れているものが動き情報として精度が悪いと仮定して、その領域をBIOで補正する効果があるかが判定される。この処理は、例えば、図25のステップS509の前に行われる。この場合、ステップS509においては、設置された領域であるか否かが判定され、ステップS510およびS511の処理は、設定された領域のみ行われるようなフローが考えられる。
 ステップS601において、インター予測制御部201は、L0予測のMVL0x、MVL0yとL1予測のMVL1x、MVL1yとを取得する。
 ステップS602において、インター予測制御部201は、4つのMVから絶対値最大のMVを選択してMV_MAXに代入する。
 ステップS603において、インター予測制御部201は、|MV_MAX|<MV_閾値であるか否かを判定する。
 ステップS603において、|MV_MAX|<MV_閾値であると判定された場合、処理は、ステップS604に進む。
 ステップS604において、インター予測制御部201は、vPUの中心部をSAD計算領域に設定する。
 ステップS605において、インター予測制御部201は、PUサイズ<vPUサイズであるか否かを判定する。
 ステップS605において、PUサイズ<vPUサイズであると判定された場合、処理は、ステップS606に進む。
 ステップS606において、インター予測制御部201は、水平サイズ=水平PUサイズ/2とし、垂直サイズ=垂直PUサイズ/2とする。
 ステップS605において、PUサイズ<vPUサイズではないと判定された場合、処理は、ステップS607に進む。
 ステップS607において、インター予測制御部201は、水平サイズ=水平vPUサイズ/2とし、垂直サイズ=垂直vPUサイズ/2とする。
 一方、ステップS603において、|MV_MAX|<MV_閾値ではないと判定された場合、処理は、ステップS608に進む。
 ステップS608において、インター予測制御部201は、MV_MAX==MVL0x||MV_MAX==MVL1xであるか否かを判定する。
 ステップS608において、MV_MAX==MVL0x||MV_MAX==MVL1xであると判定された場合、処理は、ステップS609に進む。
 ステップS609において、インター予測制御部201は、MV_MAXが0より小さいか否かを判定する。
 ステップS609において、MV_MAXが0より小さいと判定された場合、処理は、ステップS610に進む。
 ステップS610において、インター予測制御部201は、vPUの左側をSAD計算領域に設定する。
 ステップS609において、MV_MAXが0以上であると判定された場合、処理は、ステップS611に進む。
 ステップS611において、インター予測制御部201は、vPUの右側をSAD計算領域に設定する。
 ステップS610またはS611の後、処理は、ステップS612に進む。
 ステップS612において、インター予測制御部201は、PUサイズ<vPUサイズであるか否かを判定する。
 ステップS612において、PUサイズ<vPUサイズであると判定された場合、処理は、ステップS613に進む。
 ステップS613において、インター予測制御部201は、水平サイズ=水平PUサイズ/4とし、垂直サイズ=垂直PUサイズとする。
 ステップS612において、PUサイズ<vPUサイズではないと判定された場合、処理は、ステップS614に進む。
 ステップS614において、インター予測制御部201は、水平サイズ=水平vPUサイズ/4とし、垂直サイズ=垂直vPUサイズとする。
 また、ステップS608において、MV_MAX==MVL0x||MV_MAX==MVL1xではないと判定された場合、処理は、ステップS615に進む。
 ステップS615において、インター予測制御部201は、MV_MAX<0であるか否かを判定する。
 ステップS615において、MV_MAX<0であると判定された場合、処理は、ステップS616に進む。
 ステップS616において、インター予測制御部201は、vPUの上側をSAD計算領域に設定する。
 ステップS615において、MV_MAX<0ではないと判定された場合、処理は、ステップS617に進む。
 ステップS617において、インター予測制御部201は、vPUの下側をSAD計算領域に設定する。
 ステップS616またはS617の後、処理は、ステップS618に進む。
 ステップS618において、インター予測制御部201は、PUサイズ<vPUサイズであるか否かを判定する。
 ステップS618において、PUサイズ<vPUサイズであると判定された場合、処理は、ステップS619に進む。
 ステップS619において、インター予測制御部201は、水平サイズ=水平PUサイズとし、垂直サイズ=垂直PUサイズ/4とする。
 ステップS618において、PUサイズ<vPUサイズではないと判定された場合、処理は、ステップS620に進む。
 ステップS620において、インター予測制御部201は、水平サイズ=水平vPUサイズとし、垂直サイズ=垂直vPUサイズ/4とする。
 ステップS606、ステップS607、ステップS613、ステップS614、ステップS619、およびステップS620の後、処理は、図29のステップS621に進む。
 ステップS621において、インター予測制御部201は、水平サイズ<4であるか否かを判定する。
 ステップS621において、水平サイズ<4であると判定された場合、処理は、ステップS622に進む。
 ステップS622において、インター予測制御部201は、水平サイズ=4とし、処理は、ステップS623に進む。
 ステップS621において、水平サイズ<4ではないと判定された場合、ステップS622はスキップされ、処理は、ステップS623に進む。
 ステップS623において、インター予測制御部201は、垂直サイズ<4であるか否かを判定する。
 ステップS623において、垂直サイズ<4であると判定された場合、処理は、ステップS624に進む。
 ステップS624において、インター予測制御部201は、垂直サイズ=4とし、BIO_vPU_ON判定のための部分的なSAD計算領域の判定処理は終了される。
 ステップS623において、垂直サイズ<4ではないと判定された場合、ステップS624はスキップされ、BIO_vPU_ON判定のための部分的なSAD計算領域の判定処理は終了される。
 以上のような部分的にSAD計算を行ってのBIOの適用判定を行うような処理も、FRUCやDMVRに適用することは可能である。しかしながら、BIOのアーリーターミネーション目的とは異なり、FRUCやDMVRでは、SADまたは類似のコスト計算とその後の判定が、ダイレクトにインター予測精度に反映される。したがって、コスト計算を省略した場合のペナルティが大きくなる恐れがあるため、部分的にSAD計算を行い、BIOの適用判定を行うような処理は、BIO特有の処理といえる。
<2.第2の実施の形態(フラグによる動作の共有の例)>
 第2の実施の形態では、第1の実施の形態と同様に、PUがVPDUより大きい場合、PUが仮想的にvPUに分割され、vPU単位で処理が行われる。
 第1の実施の形態との違いとしては、第2の実施の形態においては、符号化装置1と復号装置101の間で送受信されるビットストリームに、BIO_PU_ONフラグを1ビット含ませることで、符号化装置1と復号装置101で動作を共有させることができる。
 <インター予測部の動作例>
 図30および図31は、本技術の第2の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 図30および図31のステップS701乃至S708と、ステップS715乃至S728は、図17および図18のステップS401乃至S408と、ステップS412乃至S425と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。
 図30のステップS708において、BIOコスト計算部204は、vPU内の4×4単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。4×4単位にSADを計算し、積み上げることで、SADの総和であるSAD_4×4ブロックが取得される。
 ステップS709において、インター予測制御部201は、vPU数が1であるか否かを判定する。
 ステップS709において、vPU数が1であると判定された場合、処理は、ステップS710に進む。ステップS710およびS711においては、PU単位と同様な処理が行われる。
 ステップS710において、BIOコスト計算部204は、BIOコスト計算部204は、vPU単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。vPU単位にSADを計算し、積み上げることで、SADの総和であるSAD_PUが取得される。取得されたSAD_PUは、BIOコスト計算部204からBIO適用判定部205に供給される。
 ステップS711において、BIO適用判定部205は、BIO_PU_ONフラグを、BIOコスト計算部204から供給されるSAD_PU>=インター予測制御部201から供給されるBIO閾値_PUに基づいて決定する。その後、処理は、ステップS714に進む。
 ステップS709において、vPU番号が1ではないと判定された場合、処理は、ステップS712に進む。
 ステップS712において、インター予測制御部201は、vPU番号が0であるか否かを判定する。
 ステップS709において、vPU番号が0であると判定された場合、処理は、ステップS713に進む。
 ステップS713において、インター予測制御部201は、BIO_PU_ONを設定する。符号化装置1の場合、動き探索(ME)結果などから決定されたBIO_PU_ONが設定される。復号装置101の場合、ストリームから取得されたBIO_PU_ONが設定される。
 ステップS712において、vPU番号が0ではいと判定された場合、ステップS713をスキップし、処理は、図31のステップS714に進む。
 ステップS714において、BIO_PU_ONフラグが1であるか否かが判定される。
 ステップS714において、BIO_PU_ONフラグが1ではないと判定された場合、PU全体に対してBIOの効果がないとして、処理は、ステップS715に進む。
 ステップS715において、Bi予測ブロック生成部206は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測ブロックvPUを生成する。生成されたBi予測ブロックvPUは、バッファに保存するとともに、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。
 一方、ステップS714において、BIO_PU_ONフラグが1であると判定された場合、処理は、ステップS716に進む。
 ステップS716において、BIO処理を含むBi予測ブロック生成部207は、L0予測ブロック生成部202から供給されるL0予測ブロックとL1予測ブロック生成部203から供給されるL1予測ブロックとから、複数の勾配を計算する。
 以上のように、ビットストリームに、BIO_PU_ONフラグを含ませることにより、符号化装置1と復号装置101で動作を共有化することが可能となる。
 なお、ビットストリームにフラグを含ませることは、符号化効率の悪化が懸念されるので、BIO_PU_ONフラグは、すべてのレイヤーに含ませるのではなく、1ビットの価値が相対的に小さいPUがVPDUより大きい場合に限定する。PUがVPDUより大きい以外の場合のPUでは、図30のステップS709乃至S713に示すように、第1の実施の形態の場合と同様に、PUでSAD値を計算して、BIO適用判定するようにする。
 BIO_PU_ONフラグがビットストリームに含まれる場合は、符号化装置1が自由に0または1にしてよい。符号化装置1が十分に高性能であれば、BIO_PU_ONフラグを0と1の両方で動き補償して、良好な結果が得られた方を決定するような判定方法もある。また、PUサイズに応じて128×128は、BIO_PU_ONフラグを0、それ以外は1に決めうちする判定方法でもよい。
 一方、復号装置101では、PUがVPDUより大きいBi予測モードのCUのPUレイヤーでBIO_PU_ONフラグが復号されているので、vPU番号が0のとき、ステップS713でBIO_PU_ONフラグを取得して、処理が進められる。vPU番号が1以降のvPUでは、BIO_PU_ONフラグが設定済みのため、処理は、ステップS713をスキップし、ステップS712から、ステップS714に進む。
 上述した第2の実施の形態と同様の手法をFRUCやDMVRに適用するのは、不可能ではないが、殆ど意味がない。なぜならば、MV補正のためのデータをビットストリームでもつのは、差分MV(MVD)を符号化することと同義であるからである。
<3.第3の実施の形態(sPUによる分割の例)>
 第3の実施の形態では、第1の実施の形態と仮想的な分割のサイズが異なり、PUがVPDUより大きい場合、PUが仮想的にsPUに分割され、sPU単位で処理が行われる。
 すなわち、SAD計算して、BIOの適用判定する処理単位は、VPDU境界を跨がすVPDUサイズ以下であればよいので、第3の実施の形態では、別途、与えられた情報でPUが複数のsPUに仮想的に分割され、sPU毎にBIOの適用判定が行われる。
 情報の与え方としては、BIO_MAX_SAD_BLOCK_SIZEのような変数をビットストリームに追加し含めることで、符号化装置1と復号装置101で共有する。
 図32は、BIO_MAX_SAD_BLOCK_SIZEとsPUの対応関係を示す図である。
 BIO_MAX_SAD_BLOCK_SIZEが1の場合、sPUサイズは、8×8とされる。BIO_MAX_SAD_BLOCK_SIZEが2の場合、sPUサイズは、16×16とされる。BIO_MAX_SAD_BLOCK_SIZEが3の場合、sPUサイズは、32×32とされる。BIO_MAX_SAD_BLOCK_SIZEが4の場合、sPUサイズは、64×64とされる。
 BIO_MAX_SAD_BLOCK_SIZEの値は、個々の符号化装置1の性能によって任意の値を設定してもよいし、規格として、Profile/Level制約として決めておいてもよい。扱うピクチャサイズに応じて、SD以下で0、HDで1、4Kで2、8kで3のようなLevel制約である。
 <インター予測部の動作例>
 図33および図34は、本技術の第3の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 なお、図33および図34のステップS801乃至S825は、vPUが、サイズの異なるsPUと入れ替わっただけであり、図17および図18のステップS401乃至S425と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。
 図35および図36は、BIO_MAX_SAD_BLOCK_SIZEを2とした場合の各PUのSADを計算する領域の例を示す図である。
 図35の上側においては、CU(PU)128×128で、VPDU=64×64で、BIO_MAX_SAD_BLOCK_SIZEを2(sPU=32×32)とした場合の各sPUのSADを計算する領域が示されている。図35の上側の場合、sPUは、VPDUの境界を跨がず、PUを16分割している。
 図35の下側においては、CU(PU)128×64で、VPDU=64×64で、BIO_MAX_SAD_BLOCK_SIZEを2(sPU=32×32)とした場合の各sPUのSADを計算する領域が示されている。図35の下側の場合、sPUは、VPDUの境界を跨がず、PUを8分割している。
 図36の上側においては、CU(PU)64×128で、VPDU=64×64で、BIO_MAX_SAD_BLOCK_SIZEを2(sPU=32×32)とした場合の各sPUのSADを計算する領域が示されている。図36の上側の場合、sPUは、VPDUの境界を跨がず、PUを8分割している。
 図36の下側においては、CU(PU)64×64以下で、VPDU=64×64で、BIO_MAX_SAD_BLOCK_SIZEを2(sPU=32×32)とした場合の各sPUのSADを計算する領域が示されている。図36の上側の場合、sPUは、VPDUの境界を跨がず、PUを4分割している。
 以上のように、本技術の第3の実施の形態においては、別途、与えられた情報でPUが複数のsPUに仮想的に分割され、sPU毎にBIOの適用判定が行われる。これにより、vPUの場合のバッファサイズより、バッファサイズをさらに小さくすることができる。
<4.第4の実施の形態(BIOの使用禁止の例)>
 第4の実施の形態では、PUがVPDUより大きい場合、BIOを使用しないように制約される。これにより、バッファサイズが削減可能である。
 <インター予測部の動作例>
 図37および図38は、本技術の第4の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 図37および図38のステップS901乃至S907、およびS926は、図17および図18のステップS401乃至S407、およびS425と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。また、図37および図38のステップS909乃至S925は、図15および図16のステップS304乃至S320と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。
 ステップS907において、L1予測ブロック生成部203は、vPU番号の領域のL1予測ブロックを生成する。
 ステップS908において、インター予測制御部201は、1<vPU数であるか否かを判定する。
 ステップS908において、1<vPU数ではないと判定された場合、ステップS909に進む。vPU数が1である場合、すなわち、vPU=PUであり、ステップS909以降においては、図15のステップS309以降の処理と同様の処理が行われる。
 ステップS908において、1<vPU数であると判定された場合、図38のステップS913に進む。
 また、ステップS912において、BIO_vPU_ONフラグが1ではないと判定された場合、vPU全体に対してBIOの効果がないとして、処理は、ステップS913に進む。
 ステップS913において、Bi予測ブロック生成部206は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測ブロックvPUを生成する。生成されたBi予測ブロックvPUは、バッファに保存するとともに、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。
 以上のように、図37および図38においては、ステップS907乃至S913に、複数のvPUがあるか否か、すなわち、PUがVPDUより大きいか否かを判定する条件分岐ステップとして、ステップS908が追加されている。
 PUがVPDUより大きい場合は、ステップS908からステップS913の通常のBi予測に分岐されるので、BIOを使用しないため、PU全体でのSAD値を計算する必要がなく、図4と同様に、PUを仮想的なvPUに分割しての処理が可能となる。
 ステップS908からステップS909に分岐してからのステップS909乃至S925は、従来のBIOを含むBi予測(図15および図16のS304乃至S320)と同様の処理である。ただし、ステップS909に分岐するのは、PUがVPDU以下の場合であるので、PU全体でSAD計算する場合、VPDU以下のリソースがあれば十分足りる。
<5.第5の実施の形態(常時BIOの適用の例)>
 第5の実施の形態では、PUがVPDUより大きい場合、常時BIOを適用するようにすることで、バッファサイズを削減するようにした。
 <インター予測部の動作例>
 図39および図40は、本技術の第5の実施の形態の動作例として、インター予測部51が行うBIOを含むBi予測を説明するフローチャートである。
 図39および図40のステップS1001乃至S1008、およびS1026は、図17および図18のステップS401乃至S408、およびS425と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。また、図39および図40のステップS1014乃至S1025は、図15および図16のステップS309乃至S320と基本的に同様の処理を行うので、その説明は繰り返しになるので、適宜、省略される。
 ステップS1008において、BIOコスト計算部204は、vPU内の4×4単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。4×4単位にSADを計算し、積み上げることで、SADの総和であるSAD_4×4ブロックが取得される。
 ステップS1009において、インター予測制御部201は、1<vPU数であるか否かを判定する。
 ステップS1009において、1<vPU数ではないと判定された場合、処理は、ステップS1010に進む。
 ステップS1010において、BIOコスト計算部204は、PU単位に、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とのSADを計算する。PU単位にSADを計算し、積み上げることで、SADの総和であるSAD_PUが取得される。取得されたSAD_PUは、BIOコスト計算部204からBIO適用判定部205に供給される。
 ステップS1011において、BIO適用判定部205は、BIO_PU_ONフラグを、BIOコスト計算部204から供給されるSAD_PU>=インター予測制御部201から供給されるBIO閾値_PUに基づいて決定する。
 ステップS1012において、BIO_PU_ONフラグが1であるか否かが判定される。
 ステップS1012において、BIO_PU_ONフラグが1ではないと判定された場合、vPU全体に対してBIOの効果がないとして、処理は、図40のステップS1013に進む。
 ステップS1013において、Bi予測ブロック生成部206は、L0予測ブロック生成部202から供給されるL0予測画像とL1予測ブロック生成部203から供給されるL1予測画像とから、Bi予測ブロックvPUを生成する。生成されたBi予測ブロックvPUは、バッファに保存するとともに、Bi予測ブロック生成部206からBi予測ブロック選択部208に供給される。
 ステップS1012において、BIO_PU_ONフラグが1であると判定された場合、処理は、図40のステップS1014に進む。
 また、ステップS1009において、1<vPU数であると判定された場合、ステップS1014に進む。
 ステップS1014以降においては、図15のステップS309乃至S320と同様のBIO処理が行われる。
 以上のように、図39および図40においては、ステップS1009において、複数のvPUがあるか否か、すなわち、PUがVPDUより大きいか否かを判定する条件分岐が追加される。
 PUがVPDUより大きい場合は、S1010乃至S1012のSAD計算から閾値判定までをバイパスして、ステップS1014以降のBIOを適用する処理に入るため、PU全体でSADの計算をする必要がなく、図4と同様に、PUを仮想的なvPUに分割しての処理が可能となる。
 ステップS1010乃至S1012に入るのは、PUがVPDU以下の場合のため、PU全体でSAD計算するにしてもVPDU以下のリソースがあれば十分足りる。
 なお、第5の実施の形態は、FRUCやDMVRに適用することはできない。BIOのSAD計算はアーリーターミネーション目的のため、第5の実施の形態のようにPUサイズのようなほかの判定基準にてコスト計算を回避することが可能である。FRUCやDMVRのコスト計算はMV補正の根幹処理であり、回避することが困難であるからである。
 以上、本技術によれば、BIOなどの双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当の分割処理単位(例えば、vPU)またはVPDUサイズ以下の分割処理単位(例えば、sPU)に分割し、分割された処理単位に基づいて計算されたコストを用いて判定を行うようにした。これにより、バッファサイズを削減することができる。
 VVCでBIOを実施可能であるため、必要な各種バッファのサイズを、従来のバッファサイズの1/4に削減することができる。
 また、HW構成を最適化することも可能となり、一部のバッファを、従来の1/4より大幅に削減しつつ、BIOを実装することが可能となる。
<6.第6の実施の形態(コンピュータ)>
 <コンピュータの構成例>
 上述した一連の処理は、ハードウェアにより実行することもできるし、ソフトウェアにより実行することもできる。一連の処理をソフトウェアにより実行する場合には、そのソフトウェアを構成するプログラムが、専用のハードウェアに組み込まれているコンピュータ、または汎用のパーソナルコンピュータなどに、プログラム記録媒体からインストールされる。
 図41は、上述した一連の処理をプログラムにより実行するコンピュータのハードウェアの構成例を示すブロック図である。
 CPU(Central Processing Unit)301、ROM(Read Only Memory)302、RAM(Random Access Memory)303は、バス304により相互に接続されている。
 バス304には、さらに、入出力インタフェース305が接続されている。入出力インタフェース305には、キーボード、マウスなどよりなる入力部306、ディスプレイ、スピーカなどよりなる出力部307が接続される。また、入出力インタフェース305には、ハードディスクや不揮発性のメモリなどよりなる記憶部308、ネットワークインタフェースなどよりなる通信部309、リムーバブルメディア311を駆動するドライブ310が接続される。
 以上のように構成されるコンピュータでは、CPU301が、例えば、記憶部308に記憶されているプログラムを入出力インタフェース305及びバス304を介してRAM303にロードして実行することにより、上述した一連の処理が行われる。
 CPU301が実行するプログラムは、例えばリムーバブルメディア311に記録して、あるいは、ローカルエリアネットワーク、インターネット、デジタル放送といった、有線または無線の伝送媒体を介して提供され、記憶部308にインストールされる。
 なお、コンピュータが実行するプログラムは、本明細書で説明する順序に沿って時系列に処理が行われるプログラムであっても良いし、並列に、あるいは呼び出しが行われたとき等の必要なタイミングで処理が行われるプログラムであっても良い。
 なお、本明細書において、システムとは、複数の構成要素(装置、モジュール(部品)等)の集合を意味し、すべての構成要素が同一筐体中にあるか否かは問わない。したがって、別個の筐体に収納され、ネットワークを介して接続されている複数の装置、及び、1つの筐体の中に複数のモジュールが収納されている1つの装置は、いずれも、システムである。
 なお、本明細書に記載された効果はあくまで例示であって限定されるものでは無く、また他の効果があってもよい。
 本技術の実施の形態は、上述した実施の形態に限定されるものではなく、本技術の要旨を逸脱しない範囲において種々の変更が可能である。
 例えば、本技術は、1つの機能をネットワークを介して複数の装置で分担、共同して処理するクラウドコンピューティングの構成をとることができる。
 また、上述のフローチャートで説明した各ステップは、1つの装置で実行する他、複数の装置で分担して実行することができる。
 さらに、1つのステップに複数の処理が含まれる場合には、その1つのステップに含まれる複数の処理は、1つの装置で実行する他、複数の装置で分担して実行することができる。
<構成の組み合わせ例>
 本技術は、以下のような構成をとることもできる。
(1) 双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割する制御部と、
 前記分割処理単位に基づいて計算された前記コストを用いて前記判定を行う判定部と
 を備える画像処理装置。
(2) 前記判定部は、前記分割処理単位毎に計算された前記コストを用いて前記判定を行う
 前記(1)に記載の画像処理装置。
(3) 前記判定部は、最初の前記分割処理単位に対して計算された前記コストを用いて前記最初の前記分割処理単位の前記判定を行い、前記最初の前記分割処理単位の前記判定の結果を用いて他の前記分割処理単位の前記判定を行う
 前記(1)に記載の画像処理装置。
(4) 前記判定部は、前記分割処理単位内の一部の領域に対して計算された前記コストを用いて前記分割処理単位毎の前記判定を行う
 前記(1)に記載の画像処理装置。
(5) 前記判定部は、前記分割処理単位毎に対して設定された前記双方向予測を行うか否かを示すフラグに基づいて、前記分割処理単位毎の前記判定を行う
 前記(1)に記載の画像処理装置。
(6) 前記双方向予測は、BIOを適用した前記双方向予測である
 前記(1)乃至(5)のいずれかに記載の画像処理装置。
(7) 前記双方向予測は、FRUCまたはDMVRを適用した前記双方向予測である
 前記(1)または(2)に記載の画像処理装置。
(8) 画像処理装置が、
 双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割し、
 前記分割処理単位に基づいて計算された前記コストを用いて前記判定を行う
 画像処理方法。
 1 符号化装置, 36 可逆符号化部, 47 動き予測・補償部, 51 インター予測部, 101 復号装置, 132 可逆復号部,201 インター予測制御部, 202 L0予測ブロック生成部, 203 L1予測ブロック生成部, 204 BIOコスト計算部, 205 BIO適用判定部, 206 Bi予測ブロック生成部, 207 BIO処理を含むBi予測ブロック生成部, 208 Bi予測ブロック選択部, 209 予測ブロック選択部

Claims (8)

  1.  双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割する制御部と、
     前記分割処理単位に基づいて計算された前記コストを用いて前記判定を行う判定部と
     を備える画像処理装置。
  2.  前記判定部は、前記分割処理単位毎に計算された前記コストを用いて前記判定を行う
     請求項1に記載の画像処理装置。
  3.  前記判定部は、最初の前記分割処理単位に対して計算された前記コストを用いて前記最初の前記分割処理単位の前記判定を行い、前記最初の前記分割処理単位の前記判定の結果を用いて他の前記分割処理単位の前記判定を行う
     請求項1に記載の画像処理装置。
  4.  前記判定部は、前記分割処理単位内の一部の領域に対して計算された前記コストを用いて前記分割処理単位毎の前記判定を行う
     請求項1に記載の画像処理装置。
  5.  前記判定部は、前記分割処理単位毎に対して設定された前記双方向予測を行うか否かを示すフラグに基づいて、前記分割処理単位毎の前記判定を行う
     請求項1に記載の画像処理装置。
  6.  前記双方向予測は、BIOを適用した前記双方向予測である
     請求項1に記載の画像処理装置。
  7.  前記双方向予測は、FRUCまたはDMVRを適用した前記双方向予測である
     請求項1に記載の画像処理装置。
  8.  画像処理装置が、
     双方向予測を行うか否かについての判定に用いるコストを計算する処理単位をVPDUサイズ相当、またはVPDUサイズ以下の分割処理単位に分割し、
     前記分割処理単位に基づいて計算された前記コストを用いて前記判定を行う
     画像処理方法。
PCT/JP2019/049090 2018-12-28 2019-12-16 画像処理装置および方法 WO2020137643A1 (ja)

Priority Applications (12)

Application Number Priority Date Filing Date Title
US17/312,405 US20220070447A1 (en) 2018-12-28 2019-12-16 Image processing device and method
CA3120750A CA3120750A1 (en) 2018-12-28 2019-12-16 Image processing device and method
BR112021012260-5A BR112021012260A2 (pt) 2018-12-28 2019-12-16 Dispositivo e método de processamento de imagens
CN201980085078.9A CN113424530A (zh) 2018-12-28 2019-12-16 图像处理装置和方法
EP19905764.7A EP3905676A4 (en) 2018-12-28 2019-12-16 IMAGE FORMING METHOD AND APPARATUS
MX2021007180A MX2021007180A (es) 2018-12-28 2019-12-16 Dispositivo y metodo de procesamiento de imagen.
JP2020563093A JP7414008B2 (ja) 2018-12-28 2019-12-16 画像処理装置および方法
AU2019417255A AU2019417255A1 (en) 2018-12-28 2019-12-16 Image processing device and method
SG11202103292TA SG11202103292TA (en) 2018-12-28 2019-12-16 Image processing device and method
JP2023220431A JP2024038146A (ja) 2018-12-28 2023-12-27 画像符号化装置および方法
JP2023220432A JP2024023955A (ja) 2018-12-28 2023-12-27 画像復号装置および方法
US18/398,418 US20240129459A1 (en) 2018-12-28 2023-12-28 Image processing device and method for partitioning a coding unit into partitioned processing units

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2018248147 2018-12-28
JP2018-248147 2018-12-28

Related Child Applications (2)

Application Number Title Priority Date Filing Date
US17/312,405 A-371-Of-International US20220070447A1 (en) 2018-12-28 2019-12-16 Image processing device and method
US18/398,418 Continuation US20240129459A1 (en) 2018-12-28 2023-12-28 Image processing device and method for partitioning a coding unit into partitioned processing units

Publications (1)

Publication Number Publication Date
WO2020137643A1 true WO2020137643A1 (ja) 2020-07-02

Family

ID=71129761

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2019/049090 WO2020137643A1 (ja) 2018-12-28 2019-12-16 画像処理装置および方法

Country Status (10)

Country Link
US (2) US20220070447A1 (ja)
EP (1) EP3905676A4 (ja)
JP (3) JP7414008B2 (ja)
CN (1) CN113424530A (ja)
AU (1) AU2019417255A1 (ja)
BR (1) BR112021012260A2 (ja)
CA (1) CA3120750A1 (ja)
MX (1) MX2021007180A (ja)
SG (1) SG11202103292TA (ja)
WO (1) WO2020137643A1 (ja)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11909993B1 (en) * 2021-07-30 2024-02-20 Meta Platforms, Inc. Fractional motion estimation engine with parallel code unit pipelines

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012046435A1 (ja) * 2010-10-04 2012-04-12 パナソニック株式会社 画像処理装置、画像符号化方法および画像処理方法
WO2018173895A1 (ja) * 2017-03-21 2018-09-27 シャープ株式会社 予測画像生成装置、動画像復号装置、および動画像符号化装置

Family Cites Families (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7369707B2 (en) * 2003-10-28 2008-05-06 Matsushita Electric Industrial Co., Ltd. Intra-picture prediction coding method
JP5215951B2 (ja) * 2009-07-01 2013-06-19 キヤノン株式会社 符号化装置及びその制御方法、コンピュータプログラム
US9247266B2 (en) * 2011-04-18 2016-01-26 Texas Instruments Incorporated Temporal motion data candidate derivation in video coding
JP2013085096A (ja) * 2011-10-07 2013-05-09 Sony Corp 画像処理装置および方法
KR101895295B1 (ko) * 2014-02-12 2018-09-05 주식회사 칩스앤미디어 동영상 처리 방법 및 장치
US10298927B2 (en) * 2014-03-28 2019-05-21 Sony Corporation Image decoding device and method
EP4138392A1 (en) * 2016-02-05 2023-02-22 HFI Innovation Inc. Method and apparatus of motion compensation based on bi-directional optical flow techniques for video coding
US10798385B2 (en) * 2016-04-25 2020-10-06 Lg Electronics Inc. Inter-prediction method and apparatus in image coding system
WO2017205701A1 (en) * 2016-05-25 2017-11-30 Arris Enterprises Llc Weighted angular prediction for intra coding
CN116437104A (zh) * 2017-05-19 2023-07-14 松下电器(美国)知识产权公司 解码方法和编码方法
US10904565B2 (en) * 2017-06-23 2021-01-26 Qualcomm Incorporated Memory-bandwidth-efficient design for bi-directional optical flow (BIO)
WO2018235405A1 (ja) * 2017-06-23 2018-12-27 ソニー株式会社 画像処理装置と画像処理方法
CN110832858B (zh) * 2017-07-03 2023-10-13 Vid拓展公司 用于视频编解码的设备、方法
JP6508553B2 (ja) * 2017-09-19 2019-05-08 ソニー株式会社 画像処理装置および方法
US10812823B2 (en) * 2018-07-11 2020-10-20 Apple Inc. Global motion vector video encoding systems and methods
WO2020085235A1 (ja) * 2018-10-22 2020-04-30 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ 符号化装置、復号装置、符号化方法及び復号方法
CN112970259A (zh) * 2018-11-05 2021-06-15 北京字节跳动网络技术有限公司 视频处理中具有细化的帧间预测
CN113228681A (zh) * 2018-12-21 2021-08-06 韩国电子通信研究院 图像编码/解码方法和装置以及存储比特流的记录介质

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012046435A1 (ja) * 2010-10-04 2012-04-12 パナソニック株式会社 画像処理装置、画像符号化方法および画像処理方法
WO2018173895A1 (ja) * 2017-03-21 2018-09-27 シャープ株式会社 予測画像生成装置、動画像復号装置、および動画像符号化装置

Non-Patent Citations (7)

* Cited by examiner, † Cited by third party
Title
CHIH-WEI HSU , TZU-DER CHUANG , CHING-YEH CHEN , YU-WEN HUANG , SHAW-MIN LEI : "CEl-related: Constraint for binary and ternary partitions", 11. JVET MEETING; 20180711 - 20180718; LJUBLJANA; (THE JOINT VIDEO EXPLORATION TEAM OF ISO/IEC JTC1/SC29/WG11 AND ITU-T SG.16 ), no. JVET-K0556-v2, 16 July 2018 (2018-07-16), Ljubljana , SI, pages 1 - 3, XP030199974 *
HUANGBANG CHEN , XIANG MA , SEMIH ESENLIK , HAITAO YANG , JIANLE CHEN : "CE9-related: BDOF buffer reduction and enabling VPDU based application", 13. JVET MEETING; 20190109 - 20190118; MARRAKECH; (THE JOINT VIDEO EXPLORATION TEAM OF ISO/IEC JTC1/SC29/WG11 AND ITU-T SG.16 ), no. JVET-M0890-v2, 15 January 2019 (2019-01-15), Marrakech, MA, pages 1 - 3, XP030202285 *
JIANLE CHENYAN YESEUNG HWAN KIM: "Algorithm description for Versatile Video Coding and Test Model 3 (VTM 3", EXPERTS TEAM (JVET, 24 September 2018 (2018-09-24), Retrieved from the Internet <URL:http://phenix.it-sudparis.eu/jvet/docenduser/documents/12Macao/wgll/JVET-L1002-vl.zip>
KENJI KONDO , MASARU IKEDA , TERUHIKO SUZUKI: "Non-CE9: On early termination for BDOF", 13. JVET MEETING; 20190109 - 20190118; MARRAKECH; (THE JOINT VIDEO EXPLORATION TEAM OF ISO/IEC JTC1/SC29/WG11 AND ITU-T SG.16 ), no. JVET-M0073-r2, 8 January 2019 (2019-01-08), Marrakech, MA, pages 1 - 5, XP030200900 *
See also references of EP3905676A4
XIAOYU XIU , YUWEN HE , YAN YE : "CE9-related: Complexity reduction and bit-width control for bi-directional optical flow (BIO)", 12. JVET MEETING; 20181003 - 20181012; MACAO; (THE JOINT VIDEO EXPLORATION TEAM OF ISO/IEC JTC1/SC29/WG11 AND ITU-T SG.16 ), no. JVET-L0256-v2, September 2018 (2018-09-01), Macao, CN, pages 1 - 15, XP030251694 *
XIAOYU XIUYUWEN HEYAN YE: "CE9-related: Complexity reduction and bit-width control for bi-directional optical flow (BIO", EXPERTS TEAM (JVET, 24 September 2018 (2018-09-24), Retrieved from the Internet <URL:http://phenix.it-sudparis.eu/jvet/docenduser/documents/12Macao/wgll/JVET-L0256-v3.zip>

Also Published As

Publication number Publication date
US20240129459A1 (en) 2024-04-18
SG11202103292TA (en) 2021-04-29
JP2024023955A (ja) 2024-02-21
JP7414008B2 (ja) 2024-01-16
CN113424530A (zh) 2021-09-21
EP3905676A4 (en) 2022-10-26
MX2021007180A (es) 2021-08-05
CA3120750A1 (en) 2020-07-02
JPWO2020137643A1 (ja) 2021-11-11
US20220070447A1 (en) 2022-03-03
JP2024038146A (ja) 2024-03-19
EP3905676A1 (en) 2021-11-03
AU2019417255A1 (en) 2021-06-10
BR112021012260A2 (pt) 2021-08-31

Similar Documents

Publication Publication Date Title
CN112585966B (zh) 以基于历史的运动向量为基础的帧间预测方法及其装置
JP6766195B2 (ja) 符号化装置、復号装置、符号化方法、復号方法、及びプログラム
US11310526B2 (en) Hardware friendly constrained motion vector refinement
US11343541B2 (en) Signaling for illumination compensation
US10390034B2 (en) Innovations in block vector prediction and estimation of reconstructed sample values within an overlap area
KR101684208B1 (ko) 동화상 복호 장치, 동화상 부호화 장치, 동화상 복호 방법, 및 동화상 부호화 방법
KR101759461B1 (ko) 부호화 장치, 복호화 장치, 부호화 방법, 복호화 방법, 및 컴퓨터 판독가능 기억 매체
CN104320664B (zh) 图像处理设备和方法
JP2024038146A (ja) 画像符号化装置および方法
JP6272194B2 (ja) 動画像符号化装置、動画像復号装置、および動画像符号化・復号化方法
JP2018037936A (ja) 画像符号化装置および画像復号装置
WO2023193769A1 (en) Implicit multi-pass decoder-side motion vector refinement
WO2024016955A1 (en) Out-of-boundary check in video coding
US20230128882A1 (en) Dc down-scaled weighted cost function for image/video coding
WO2023202569A1 (en) Extended template matching for video coding
WO2023241340A1 (en) Hardware for decoder-side intra mode derivation and prediction
JP6080726B2 (ja) 動画像符号化装置及び画面内予測モード決定方法及びプログラム
CN112740673A (zh) 图像数据编码和解码
KR20150021821A (ko) 영상 데이터 메모리 관리 방법 및 영상 데이터 메모리 장치

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: 19905764

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 3120750

Country of ref document: CA

ENP Entry into the national phase

Ref document number: 2020563093

Country of ref document: JP

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2019417255

Country of ref document: AU

Date of ref document: 20191216

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

REG Reference to national code

Ref country code: BR

Ref legal event code: B01A

Ref document number: 112021012260

Country of ref document: BR

ENP Entry into the national phase

Ref document number: 2019905764

Country of ref document: EP

Effective date: 20210728

ENP Entry into the national phase

Ref document number: 112021012260

Country of ref document: BR

Kind code of ref document: A2

Effective date: 20210621