Image encoding/decoding method and device, and recording medium in which bitstream is stored
The present invention is about an image encoding/decoding method and apparatus. According to present invention, a method of decoding an image, the method comprising, loading information of a neighboring block of a current block; decoding a current block using the loaded information of the neighboring block; and saving information of the current block that is decoded.
1. A method of decoding an image, the method comprising:
obtaining residual information of a current block and intra prediction mode information of the current block indicating an intra prediction mode of the current block;
determining a first intra prediction mode candidate of the current block from a left neighboring block of the current block and determining a second intra prediction mode candidate of the current block from a top neighboring block of the current block;
determining an intra prediction mode of the current block based on the first intra prediction mode candidate, the second intra prediction mode candidate and the intra prediction mode information;
deriving a prediction block of the current block based on the intra prediction mode of the current block;
deriving a quantization parameter of the current block and deriving a residual block of the current block based on the quantization parameter and the residual information; and
generating a reconstructed picture based on the prediction block and the residual block,
wherein the second intra prediction mode candidate of the current block is determined based on whether the top neighboring block of the current block is out of a current coding tree block row of the current block,
wherein based on the top neighboring block of the current block being out of the current coding tree block row of the current block, the quantization parameter of the current block is derived based on a quantization parameter of a previous coded block of the current block, and
wherein the current coding tree block row of the current block is a coding tree block row where the current block is located.
2. A method of encoding an image, the method comprising:
determining a first intra prediction mode candidate of a current block from a left neighboring block of the current block and determining a second intra prediction mode candidate of the current block from a top neighboring block of the current block;
determining an intra prediction mode of the current block based on the first intra prediction mode candidate and the second intra prediction mode candidate;
deriving a prediction block of the current block based on the intra prediction mode of the current block;
deriving a quantization parameter of the current block;
deriving a residual block of the current block based on the quantization parameter; and
encoding residual information of the current block and intra prediction mode information of the current block indicating the intra prediction mode of the current block,
wherein the second intra prediction mode candidate of the current block is determined based on whether the top neighboring block of the current block is out of a current coding tree block row of the current block,
wherein based on the top neighboring block of the current block being out of the current coding tree block row of the current block, the quantization parameter of the current block is derived based on a quantization parameter of a previous coded block of the current block, and
wherein the current coding tree block row of the current block is a coding tree block row where the current block is located.
3. A transmission method for image data, the method comprising:
obtaining a bitstream of encoded image information, wherein the encoded image information is generated based on determining a first intra prediction mode candidate of a current block from a left neighboring block of the current block and determining a second intra prediction mode candidate of the current block from a top neighboring block of the current block, determining an intra prediction mode of the current block based on the first intra prediction mode candidate, the second intra prediction mode, deriving a prediction block of the current block based on the intra prediction mode of the current block, deriving a quantization parameter of the current block, deriving a residual block of the current block based on the quantization parameter, and encoding the image information including intra prediction mode information of the current block indicating the intra prediction mode of the current block and the residual information of the current block; and
transmitting the image data comprising the bitstream,
wherein the second intra prediction mode candidate of the current block is determined based on whether the top neighboring block of the current block is out of a current coding tree block row of the current block,
wherein based on the top neighboring block of the current block being out of the current coding tree block row of the current block, the quantization parameter of the current block is derived based on a quantization parameter of a previous coded block of the current block, and
wherein the current coding tree block row of the current block is a coding tree block row where the current block is located.