Method and apparatus for encoding video, and method and apparatus for decoding video
Abstract
Disclosed are a video encoding method and apparatus and a video decoding method and apparatus. The method of encoding video includes: producing a first predicted coding unit of a current coding unit, which is to be encoded; determining whether the current coding unit comprises a portion located outside a boundary of a current picture; and producing a second predicted coding unit is produced by changing a value of pixels of the first predicted coding unit by using the pixels of the first predicted coding unit and neighboring pixels of the pixels when the current coding unit does not include a portion located outside a boundary of the current picture. Accordingly, a residual block that is the difference between the current encoding unit and the second predicted encoding unit, can be encoded, thereby improving video prediction efficiency.
Claims
exact text as granted — not AI-modifiedWhat is claimed is:
1. A method of decoding video, the method comprising:
extracting information regarding a prediction mode for a current decoding unit, which is to be decoded, from a received bitstream; producing a first predicted decoding unit of the current decoding unit, based on the extracted information; determining whether the current decoding unit includes a portion located outside a boundary of a current picture; and producing a second predicted decoding unit by changing values of pixels of the first predicted decoding unit by using pixels of the first predicted decoding unit and neighboring pixels of the pixels when the current decoding unit does not include the portion located outside the boundary of the current picture, and skipping the producing the second predicted decoding unit when the current decoding unit includes the portion located outside the boundary of the current picture.
2. The method of claim 1 , wherein the determining whether the current decoding unit includes the portion located outside the boundary of the current picture comprises obtaining index information indicating whether the producing the second predicted decoding unit is to be performed.
3. The method of claim 2 , wherein:
if the index information has a first predetermined value, the index information indicates that the producing the second predicted decoding unit is not to be performed; and if the index information has a second predetermined value, the index information indicates that the producing the second predicted decoding unit is to be performed.
4. An apparatus for decoding video, the apparatus comprising:
an entropy decoder which extracts information regarding a prediction mode for a current decoding unit, which is to be decoded, from a received bitstream; a predictor which produces a first predicted decoding unit of the current decoding unit, based on the extracted information; a determiner which determines whether the current decoding unit includes a portion located outside a boundary of a current picture; and a post-processor which produces a second predicted decoding unit by changing values of pixels of the first predicted decoding unit by using the pixels of the first predicted decoding unit and neighboring pixels of the pixels when the current decoding unit does not include the portion located outside the boundary of the current picture, and which skips the producing the second predicted decoding unit when the current decoding unit includes the portion located outside the boundary of the current picture.
5. The apparatus of claim 4 , wherein the determiner obtains index information indicating whether a process of producing the second predicted decoding unit is to be performed.
6. The apparatus of claim 5 , wherein:
if the index information has a first predetermined value, the index information indicates that the process of producing the second predicted decoding unit is not to be performed; and if the index information has a second predetermined value, the index information indicates that the process of producing the second predicted decoding unit is to be performed.
7. A non-transitory computer readable recording medium having recorded thereon a program code for executing the method of claim 1 .
8. An apparatus of restoring an encoded block, the apparatus comprising:
a processor; and a memory storing a program which causes the processor to:
split an image into a plurality of maximum coding units based on information about a size of a maximum coding unit, and determine at least one coding unit included in the maximum coding unit among the plurality of maximum coding units by splitting the maximum coding unit based on split information,
extract information regarding a prediction mode of a current block included in the at least one coding unit, from a received bitstream,
determine neighboring pixels of the current block used for intra prediction by using available neighboring pixels of the current block when the extracted information indicates the prediction mode of the current block is intra prediction,
produce a first prediction value of the current block including a first pixel located on a top border in the current block and a second pixel located on a left border in the current block, by calculating an average value of at least one of the neighboring pixels adjacent to the current block,
produce a second prediction value of the first pixel by using a weighted average value of the first prediction value and a pixel value of one neighboring pixel adjacent to the first pixel and located on same column with the first pixel,
produce a second prediction value of the second pixel by using a weighted average value of the first prediction value and a pixel value of one neighboring pixel adjacent to the second pixel and located on same row with the second pixel,
obtain, from the received bitstream, residual of the first pixel and residual of the second pixel included in the current block,
obtain a restored current block including a restored pixel value of the first pixel and a restored pixel value of the second pixel, wherein the restored pixel value of the first pixel is obtained by adding the residual of the first pixel and the second prediction value of the first pixel, and the restored pixel value of the second pixel is obtained by adding the residual of the second pixel and the second prediction value of the second pixel, and
output the restored current block including the restored pixel value of the first pixel and the restored pixel value of the second pixel,
wherein, when the neighboring pixels of the current block are located within a boundary of a current picture, the neighboring pixels of the current block located within the boundary of the current picture are determined as available.Cited by (0)
No later patents cite this yet.
References (0)
No backward citations on record.