CPC H04N 19/12 (2014.11) [H04N 19/124 (2014.11); H04N 19/159 (2014.11); H04N 19/176 (2014.11); H04N 19/18 (2014.11); H04N 19/186 (2014.11)] | 12 Claims |
1. An image decoding apparatus comprising:
a memory; and
at least one processor connected to the memory,
wherein the at least one processor is configured to:
obtain color space transform information, for applying color space transform to a residual sample of the current coding unit, based on a prediction mode being an intra prediction mode and a tree type being a single tree type;
derive first quantization parameter for the current coding unit;
derive final quantization parameter based on adding a value of the first quantization parameter for the current coding unit to a value of quantization parameter offset for the current coding unit;
derive transform coefficient for the current coding unit based on the final quantization parameter for the current coding unit; and
derive the residual sample for the current coding unit based on the transform coefficient for the current coding unit;
wherein the current coding unit comprises a luma component block, first color component block, and second color component block,
wherein based on the color space transform information indicating not applying the color space transform to the residual sample of the current coding unit, values of the quantization parameter offsets for the luma component block, the first color component block, and the second color component block of the current coding unit are derived as 0, respectively,
wherein based on the color space transform information indicating applying the color space transform to the residual sample of the current coding unit:
the values of the quantization parameter offsets for the luma component block, the first color component block, and the second color component block of the current coding unit are derived to be different from each other,
the values of the residual samples for the luma component block, the first color component block, and the second color component block are respectively updated based on the value of the residual sample for the luma component block,
the value of the residual sample for the first color component block is updated based on subtracting a first value and a second value from the value of the residual sample for the luma component block, wherein the first value is a value obtained by applying right shift operation to the value of the residual sample for the first color component block, and the second value is a value obtained by applying right shift operation to the value of the residual sample for the second color component block,
the value of the residual sample for the second color component block is updated based on adding the updated value of the residual sample for the first color component block and the value of the residual sample for the second color component block.
|