WO2019107916A1 - 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치 - Google Patents

영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치 Download PDF

Info

Publication number
WO2019107916A1
WO2019107916A1 PCT/KR2018/014822 KR2018014822W WO2019107916A1 WO 2019107916 A1 WO2019107916 A1 WO 2019107916A1 KR 2018014822 W KR2018014822 W KR 2018014822W WO 2019107916 A1 WO2019107916 A1 WO 2019107916A1
Authority
WO
WIPO (PCT)
Prior art keywords
block
current block
mvp candidate
mvp
motion vector
Prior art date
Application number
PCT/KR2018/014822
Other languages
English (en)
French (fr)
Inventor
박내리
파루리시탈
남정학
서정동
이재호
장형문
Original Assignee
엘지전자 주식회사
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 엘지전자 주식회사 filed Critical 엘지전자 주식회사
Priority to KR1020207015435A priority Critical patent/KR102387363B1/ko
Priority to US16/767,925 priority patent/US11057640B2/en
Publication of WO2019107916A1 publication Critical patent/WO2019107916A1/ko

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/157Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
    • H04N19/159Prediction type, e.g. intra-frame, inter-frame or bidirectional frame prediction
    • 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/56Motion estimation with initialisation of the vector search, e.g. estimating a good candidate to initiate a search
    • 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/513Processing of motion vectors
    • H04N19/517Processing of motion vectors by encoding
    • H04N19/52Processing of motion vectors by encoding by predictive encoding
    • 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/105Selection of the reference unit for prediction within a chosen coding or prediction mode, e.g. adaptive choice of position and number of pixels used for prediction
    • 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/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/186Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a colour or a chrominance component

Definitions

  • the present invention relates to a video coding technique, and more particularly, to a video decoding method and apparatus according to inter prediction in a video coding system.
  • HD high definition
  • UHD ultra high definition
  • the present invention provides a method and apparatus for enhancing video coding efficiency.
  • an MVP candidate list including a MVP candidate list including MVP candidates based on motion vectors of neighboring blocks of a current block, A method and an apparatus.
  • Another object of the present invention is to provide an image decoding method and apparatus for deriving a cost for an MVP candidate and performing prediction on the current block based on a modified MVP candidate list derived by reordering an MVP candidate list based on a cost .
  • Another object of the present invention is to provide a method and apparatus for estimating a cost for an MVP candidate by considering a luma component and a chroma component of a current block and rearranging the MVP candidate list based on the cost, And to provide an image decoding method and apparatus for performing prediction on the image.
  • Another object of the present invention is to provide an image decoding method and apparatus for predicting the current block based on an MVP candidate list to which a refinement MVP candidate derived by performing a refinement process on an MVP candidate is added .
  • an image decoding method performed by a decoding apparatus includes obtaining information about inter prediction of a current block through a bitstream, constructing an MVP candidate list based on a neighboring block of the current block, estimating costs of MVP candidates included in the MVP candidate list, Deriving a modified MVP candidate list based on the costs for the MVP candidates, deriving an MVP of the current block based on the modified MVP candidate list, deriving the MVP of the current block, Deriving a motion vector of the current block based on MVD and performing prediction of the current block based on the reference picture index and the motion vector of the current block, The reference picture index and the MVD.
  • a decoding apparatus for performing image decoding.
  • the decoding apparatus includes an entropy decoding unit that obtains information on inter prediction of a current block through a bitstream, and a motion vector predictor (MVP) candidate list based on neighboring blocks of the current block, Deriving costs for the included MVP candidates, deriving a modified MVP candidate list based on the costs for the MVP candidates, deriving the MVP of the current block based on the modified MVP candidate list, And a predictor for deriving a motion vector of the current block based on the MVP and a motion vector difference (MVD) of the block and performing prediction of the current block based on the reference picture index and the motion vector of the current block, ,
  • the information on the inter prediction may include the reference picture index and the MVD. It shall be.
  • a video encoding method performed by an encoding apparatus.
  • the method includes constructing a motion vector predictor (MVP) candidate list based on neighboring blocks of a current block, deriving costs for MVP candidates included in the MVP candidate list, Deriving an MVP candidate list modified by the MVP candidate list, deriving an MVP of the current block based on the modified MVP candidate list, deriving a motion vector of the current block based on the MVP of the current block, Performing prediction of the current block based on the motion vector of the current block, and encoding information about inter prediction of the current block, wherein the information on the inter prediction is a reference of the current block A reference picture index indicating a picture, and a motion vector difference (MVD).
  • MVP motion vector predictor
  • a video encoding apparatus constructs a motion vector predictor (MVP) candidate list based on neighboring blocks of the current block, derives the costs for the MVP candidates included in the MVP candidate list, and extracts, based on the costs for the MVP candidates Derives a modified MVP candidate list, derives an MVP of the current block based on the modified MVP candidate list, derives a motion vector of the current block based on the MVP of the current block, A predictor for performing prediction of the current block based on the motion vector, and an entropy encoding unit for encoding information about inter prediction of the current block, wherein the information on the inter prediction is a reference picture of the current block, And a reference picture index and a motion vector difference (MVD) pointing to the reference picture.
  • MVP motion vector predictor
  • MVP candidate lists including various MVP candidates based on neighboring blocks, thereby improving the prediction accuracy, reducing the bit amount for MVD transmission and improving the overall coding efficiency.
  • the optimal MVP candidates for the current block can be rearranged in the order indicated by a small MVP index, thereby reducing the bit amount for prediction and improving the overall coding efficiency .
  • a cost considering a luma component and a chroma component of a current block can be derived, and an optimum MVP candidate list for a current block can be constructed based on the cost.
  • prediction accuracy of a luma component and a chroma component And improve efficiency and overall coding efficiency.
  • a refinement MVP candidate as an optimal MVP candidate based on the MVP candidate of the current block, thereby improving the prediction accuracy and efficiency and improving the overall coding efficiency.
  • FIG. 1 is a view for schematically explaining a configuration of a video encoding apparatus to which the present invention can be applied.
  • FIG. 2 is a schematic view illustrating a configuration of a video decoding apparatus to which the present invention can be applied.
  • FIG. 3 shows an example of constructing the MVP candidate list through the ALR.
  • FIG. 4 illustrates an example of deriving a cost for an MVP candidate of the current block through the template matching method.
  • FIG. 5 shows an example of deriving MVP candidates of the MVP candidate list based on A0 and A1.
  • FIG. 6 shows an example of constructing the MVP candidate list through an existing procedure.
  • FIG. 7 shows an example of constructing an MVP candidate list based on neighboring blocks of the current block.
  • Fig. 8 exemplarily shows the cost according to the position and size of the template.
  • FIG. 9 shows an example of constructing a modified MVP candidate list including refinement MVP candidates.
  • Fig. 10 shows an example of deriving the cost of the MVP candidate based on the template.
  • FIG. 11 shows an example of deriving the cost L0 for the current block and the L0 reference block, and the cost L1 for the current block and the L1 reference block.
  • FIG. 12 shows an example of a restricted refinement performed based on the cost L0 and the cost L1.
  • FIG. 13 schematically shows a video encoding method by the encoding apparatus according to the present invention.
  • FIG. 14 schematically shows an encoding apparatus for performing a video encoding method according to the present invention.
  • FIG. 15 schematically shows a video decoding method by a decoding apparatus according to the present invention.
  • FIG. 16 schematically shows a decoding apparatus for performing an image decoding method according to the present invention.
  • a picture generally refers to a unit that represents one image in a specific time zone
  • a slice is a unit that constitutes a part of a picture in coding.
  • One picture may be composed of a plurality of slices, and pictures and slices may be used in combination if necessary.
  • a pixel or a pel may mean a minimum unit of a picture (or image). Also, a 'sample' may be used as a term corresponding to a pixel.
  • a sample may generally represent a pixel or pixel value and may only represent a pixel / pixel value of a luma component or only a pixel / pixel value of a chroma component.
  • a unit represents a basic unit of image processing.
  • a unit may include at least one of a specific area of a picture and information related to the area.
  • the unit may be used in combination with terms such as a block or an area in some cases.
  • an MxN block may represent a set of samples or transform coefficients consisting of M columns and N rows.
  • FIG. 1 is a view for schematically explaining a configuration of a video encoding apparatus to which the present invention can be applied.
  • the video encoding apparatus 100 includes a picture dividing unit 105, a predicting unit 110, a residual processing unit 120, an entropy encoding unit 130, an adding unit 140, a filter unit 150 And a memory 160.
  • the residual processing unit 120 may include a subtracting unit 121, a transforming unit 122, a quantizing unit 123, a reordering unit 124, an inverse quantizing unit 125 and an inverse transforming unit 126.
  • the picture dividing unit 105 may divide the inputted picture into at least one processing unit.
  • the processing unit may be referred to as a coding unit (CU).
  • the coding unit may be recursively partitioned according to a quad-tree binary-tree (QTBT) structure from the largest coding unit (LCU).
  • QTBT quad-tree binary-tree
  • LCU largest coding unit
  • one coding unit may be divided into a plurality of coding units of deeper depth based on a quadtree structure and / or a binary tree structure.
  • the quadtree structure is applied first and the binary tree structure can be applied later.
  • a binary tree structure may be applied first.
  • the coding procedure according to the present invention can be performed based on the final coding unit which is not further divided.
  • the maximum coding unit may be directly used as the final coding unit based on the coding efficiency or the like depending on the image characteristics, or the coding unit may be recursively divided into lower-depth coding units Lt; / RTI > may be used as the final coding unit.
  • the coding procedure may include a procedure such as prediction, conversion, and restoration, which will be described later.
  • the processing unit may include a coding unit (CU) prediction unit (PU) or a transform unit (TU).
  • the coding unit may be split from the largest coding unit (LCU) into coding units of deeper depth along the quad tree structure.
  • LCU largest coding unit
  • the maximum coding unit may be directly used as the final coding unit based on the coding efficiency or the like depending on the image characteristics, or the coding unit may be recursively divided into lower-depth coding units Lt; / RTI > may be used as the final coding unit.
  • SCU smallest coding unit
  • the coding unit can not be divided into smaller coding units than the minimum coding unit.
  • the term " final coding unit " means a coding unit on which the prediction unit or the conversion unit is partitioned or divided.
  • a prediction unit is a unit that is partitioned from a coding unit, and may be a unit of sample prediction. At this time, the prediction unit may be divided into sub-blocks.
  • the conversion unit may be divided along the quad-tree structure from the coding unit, and may be a unit for deriving a conversion coefficient and / or a unit for deriving a residual signal from the conversion factor.
  • the coding unit may be referred to as a coding block (CB)
  • the prediction unit may be referred to as a prediction block (PB)
  • the conversion unit may be referred to as a transform block (TB).
  • the prediction block or prediction unit may refer to a specific area in the form of a block in a picture and may include an array of prediction samples.
  • a transform block or transform unit may refer to a specific region in the form of a block within a picture, and may include an array of transform coefficients or residual samples.
  • the prediction unit 110 may perform a prediction on a current block to be processed (hereinafter, referred to as a current block), and may generate a predicted block including prediction samples for the current block.
  • the unit of prediction performed in the prediction unit 110 may be a coding block, a transform block, or a prediction block.
  • the prediction unit 110 may determine whether intra prediction or inter prediction is applied to the current block. For example, the prediction unit 110 may determine whether intra prediction or inter prediction is applied in units of CU.
  • the prediction unit 110 may derive a prediction sample for a current block based on a reference sample outside the current block in a picture to which the current block belongs (hereinafter referred to as a current picture). At this time, the prediction unit 110 may derive a prediction sample based on (i) an average or interpolation of neighboring reference samples of the current block, (ii) The prediction sample may be derived based on a reference sample existing in a specific (prediction) direction with respect to the prediction sample among the samples. (i) may be referred to as a non-directional mode or a non-angle mode, and (ii) may be referred to as a directional mode or an angular mode.
  • the prediction mode may have, for example, 33 directional prediction modes and at least two non-directional modes.
  • the non-directional mode may include a DC prediction mode and a planar mode (Planar mode).
  • the prediction unit 110 may determine a prediction mode applied to a current block using a prediction mode applied to a neighboring block.
  • the prediction unit 110 may derive a prediction sample for a current block based on a sample specified by a motion vector on a reference picture.
  • the prediction unit 110 may derive a prediction sample for a current block by applying one of a skip mode, a merge mode, and a motion vector prediction (MVP) mode.
  • the prediction unit 110 can use motion information of a neighboring block as motion information of a current block.
  • difference residual between the predicted sample and the original sample is not transmitted unlike the merge mode.
  • MVP mode a motion vector of a current block can be derived by using a motion vector of a neighboring block as a motion vector predictor to use as a motion vector predictor of a current block.
  • a neighboring block may include a spatial neighboring block existing in a current picture and a temporal neighboring block existing in a reference picture.
  • the reference picture including the temporal neighboring block may be referred to as a collocated picture (colPic).
  • the motion information may include a motion vector and a reference picture index.
  • Information such as prediction mode information and motion information may be (entropy) encoded and output in the form of a bit stream.
  • the highest picture on the reference picture list may be used as a reference picture.
  • the reference pictures included in the picture order count can be sorted on the basis of the picture order count (POC) difference between the current picture and the corresponding reference picture.
  • POC picture order count
  • the POC corresponds to the display order of the pictures and can be distinguished from the coding order.
  • the subtraction unit 121 generates residual samples that are the difference between the original sample and the predicted sample. When the skip mode is applied, a residual sample may not be generated as described above.
  • the transforming unit 122 transforms the residual samples on a transform block basis to generate a transform coefficient.
  • the transforming unit 122 can perform the transform according to the size of the transform block and a prediction mode applied to the coding block or the prediction block spatially overlapping the transform block. For example, if intraprediction is applied to the coding block or the prediction block that overlaps the transform block and the transform block is a 4 ⁇ 4 residue array, the residual sample is transformed into a discrete sine transform (DST) In other cases, the residual samples can be converted using a DCT (Discrete Cosine Transform) conversion kernel.
  • DST discrete sine transform
  • the quantization unit 123 may quantize the transform coefficients to generate quantized transform coefficients.
  • the reordering unit 124 rearranges the quantized transform coefficients.
  • the reordering unit 124 may rearrange the block-shaped quantized transform coefficients into a one-dimensional vector form through a scanning method of coefficients.
  • the reordering unit 124 may be a part of the quantization unit 123, although the reordering unit 124 is described as an alternative configuration.
  • the entropy encoding unit 130 may perform entropy encoding on the quantized transform coefficients.
  • Entropy encoding may include, for example, an encoding method such as exponential Golomb, context-adaptive variable length coding (CAVLC), context-adaptive binary arithmetic coding (CABAC)
  • CAVLC context-adaptive variable length coding
  • CABAC context-adaptive binary arithmetic coding
  • the entropy encoding unit 130 may encode the information necessary for video restoration (such as the value of a syntax element) together with the quantized transform coefficient or separately.
  • the entropy encoded information may be transmitted or stored in units of NAL (network abstraction layer) units in the form of a bit stream.
  • NAL network abstraction layer
  • the inverse quantization unit 125 inversely quantizes the quantized values (quantized transform coefficients) in the quantization unit 123 and the inverse transformation unit 126 inversely quantizes the inversely quantized values in the inverse quantization unit 125, .
  • the adder 140 combines the residual sample and the predicted sample to reconstruct the picture.
  • the residual samples and the prediction samples are added in units of blocks so that a reconstruction block can be generated.
  • the adding unit 140 may be a part of the predicting unit 110, Meanwhile, the addition unit 140 may be referred to as a restoration unit or a restoration block generation unit.
  • the filter unit 150 may apply a deblocking filter and / or a sample adaptive offset. Through deblocking filtering and / or sample adaptive offsets, artifacts in the block boundary in the reconstructed picture or distortion in the quantization process can be corrected.
  • the sample adaptive offset can be applied on a sample-by-sample basis and can be applied after the process of deblocking filtering is complete.
  • the filter unit 150 may apply an ALF (Adaptive Loop Filter) to the restored picture.
  • the ALF may be applied to the reconstructed picture after the deblocking filter and / or sample adaptive offset is applied.
  • the memory 160 may store restored pictures (decoded pictures) or information necessary for encoding / decoding.
  • the reconstructed picture may be a reconstructed picture whose filtering procedure has been completed by the filter unit 150.
  • the stored restored picture may be used as a reference picture for (inter) prediction of another picture.
  • the memory 160 may store (reference) pictures used for inter prediction. At this time, the pictures used for inter prediction can be designated by a reference picture set or a reference picture list.
  • FIG. 2 is a schematic view illustrating a configuration of a video decoding apparatus to which the present invention can be applied.
  • the video decoding apparatus 200 includes an entropy decoding unit 210, a residual processing unit 220, a predicting unit 230, an adding unit 240, a filter unit 250, and a memory 260 .
  • the residual processing unit 220 may include a rearrangement unit 221, an inverse quantization unit 222, and an inverse transformation unit 223.
  • the video decoding apparatus 200 can restore video in response to a process in which video information is processed in the video encoding apparatus.
  • the video decoding apparatus 200 can perform video decoding using a processing unit applied in the video encoding apparatus.
  • the processing unit block of video decoding may be, for example, a coding unit and, in another example, a coding unit, a prediction unit or a conversion unit.
  • the coding unit may be partitioned along the quad tree structure and / or the binary tree structure from the maximum coding unit.
  • a prediction unit and a conversion unit may be further used as the case may be, in which case the prediction block is a block derived or partitioned from the coding unit and may be a unit of sample prediction. At this time, the prediction unit may be divided into sub-blocks.
  • the conversion unit may be divided along the quad tree structure from the coding unit and may be a unit that derives the conversion factor or a unit that derives the residual signal from the conversion factor.
  • the entropy decoding unit 210 may parse the bitstream and output information necessary for video restoration or picture restoration. For example, the entropy decoding unit 210 decodes information in a bitstream based on a coding method such as exponential Golomb coding, CAVLC, or CABAC, and calculates a value of a syntax element necessary for video restoration, a quantized value Lt; / RTI >
  • a coding method such as exponential Golomb coding, CAVLC, or CABAC
  • the CABAC entropy decoding method includes receiving a bean corresponding to each syntax element in a bitstream, decoding decoding target information of the decoding target syntax element, decoding information of a surrounding and decoding target block, or information of a symbol / A context model is determined and an occurrence probability of a bin is predicted according to the determined context model to perform arithmetic decoding of the bean to generate a symbol corresponding to the value of each syntax element have.
  • the CABAC entropy decoding method can update the context model using the information of the decoded symbol / bin for the context model of the next symbol / bean after determining the context model.
  • the residual value i.e., the quantized transform coefficient, which is entropy-decoded in the entropy decoding unit 210, 221).
  • the reordering unit 221 may rearrange the quantized transform coefficients into a two-dimensional block form.
  • the reordering unit 221 may perform reordering in response to the coefficient scanning performed in the encoding apparatus.
  • the rearrangement unit 221 may be a part of the inverse quantization unit 222, although the rearrangement unit 221 has been described as an alternative configuration.
  • the inverse quantization unit 222 may dequantize the quantized transform coefficients based on the (inverse) quantization parameters, and output the transform coefficients. At this time, the information for deriving the quantization parameter may be signaled from the encoding device.
  • the inverse transform unit 223 may invert the transform coefficients to derive the residual samples.
  • the prediction unit 230 may predict a current block and may generate a predicted block including prediction samples of the current block.
  • the unit of prediction performed in the prediction unit 230 may be a coding block, a transform block, or a prediction block.
  • the prediction unit 230 may determine whether intra prediction or inter prediction is to be applied based on the prediction information.
  • a unit for determining whether to apply intra prediction or inter prediction may differ from a unit for generating a prediction sample.
  • units for generating prediction samples in inter prediction and intra prediction may also be different.
  • whether inter prediction or intra prediction is to be applied can be determined in units of CU.
  • the prediction mode may be determined in units of PU to generate prediction samples.
  • a prediction mode may be determined in units of PU, and prediction samples may be generated in units of TU.
  • the prediction unit 230 may derive a prediction sample for the current block based on the surrounding reference samples in the current picture.
  • the prediction unit 230 may apply a directional mode or a non-directional mode based on the neighbor reference samples of the current block to derive a prediction sample for the current block.
  • a prediction mode to be applied to the current block may be determined using the intra prediction mode of the neighboring block.
  • the prediction unit 230 may derive a prediction sample for a current block based on a sample specified on a reference picture by a motion vector on a reference picture.
  • the prediction unit 230 may derive a prediction sample for a current block by applying a skip mode, a merge mode, or an MVP mode.
  • motion information necessary for inter-prediction of a current block provided in the video encoding apparatus for example, information on a motion vector, a reference picture index, and the like may be acquired or derived based on the prediction information
  • motion information of a neighboring block can be used as motion information of the current block.
  • the neighboring block may include a spatial neighboring block and a temporal neighboring block.
  • the prediction unit 230 may construct a merge candidate list using the motion information of the available neighboring blocks and use the information indicated by the merge index on the merge candidate list as the motion vector of the current block.
  • the merge index may be signaled from the encoding device.
  • the motion information may include a motion vector and a reference picture. When the motion information of temporal neighboring blocks is used in the skip mode and the merge mode, the highest picture on the reference picture list can be used as a reference picture.
  • the difference between the predicted sample and the original sample is not transmitted.
  • a motion vector of a current block can be derived using a motion vector of a neighboring block as a motion vector predictor.
  • the neighboring block may include a spatial neighboring block and a temporal neighboring block.
  • a merge candidate list may be generated using a motion vector of the reconstructed spatial neighboring block and / or a motion vector corresponding to a Col block that is a temporally neighboring block.
  • the motion vector of the candidate block selected in the merge candidate list is used as the motion vector of the current block.
  • the prediction information may include a merge index indicating a candidate block having an optimal motion vector selected from the candidate blocks included in the merge candidate list.
  • the predicting unit 230 can derive the motion vector of the current block using the merge index.
  • a motion vector predictor candidate list is generated by using a motion vector of the reconstructed spatial neighboring block and / or a motion vector corresponding to a Col block which is a temporally neighboring block . That is, the motion vector of the reconstructed spatial neighboring block and / or the motion vector corresponding to the neighboring block Col may be used as a motion vector candidate.
  • the information on the prediction may include a predicted motion vector index indicating an optimal motion vector selected from the motion vector candidates included in the list.
  • the predicting unit 230 can use the motion vector index to select a predictive motion vector of the current block from the motion vector candidates included in the motion vector candidate list.
  • the predicting unit of the encoding apparatus can obtain the motion vector difference (MVD) between the motion vector of the current block and the motion vector predictor, and can output it as a bit stream. That is, MVD can be obtained by subtracting the motion vector predictor from the motion vector of the current block.
  • the predicting unit 230 may obtain the motion vector difference included in the information on the prediction, and derive the motion vector of the current block through addition of the motion vector difference and the motion vector predictor.
  • the prediction unit may also acquire or derive a reference picture index or the like indicating the reference picture from the information on the prediction.
  • the adder 240 may add a residual sample and a prediction sample to reconstruct a current block or a current picture.
  • the adder 240 may add the residual samples and the prediction samples on a block-by-block basis to reconstruct the current picture.
  • the adder 240 has been described as an alternative configuration, but the adder 240 may be a part of the predictor 230.
  • the addition unit 240 may be referred to as a restoration unit or a restoration block generation unit.
  • the filter unit 250 may apply deblocking filtered sample adaptive offsets, and / or ALFs, to the reconstructed pictures.
  • the sample adaptive offset may be applied on a sample-by-sample basis and may be applied after deblocking filtering.
  • the ALF may be applied after deblocking filtering and / or sample adaptive offsets.
  • the memory 260 may store restored pictures (decoded pictures) or information necessary for decoding.
  • the reconstructed picture may be a reconstructed picture whose filtering procedure has been completed by the filter unit 250.
  • the memory 260 may store pictures used for inter prediction.
  • the pictures used for inter prediction may be designated by a reference picture set or a reference picture list.
  • the reconstructed picture can be used as a reference picture for another picture.
  • the memory 260 may output the restored picture according to the output order.
  • Inter prediction of the current block can be performed in consideration of the motion of the target object or the image between the pictures as described above.
  • the encoding apparatus / decoding apparatus may derive a prediction sample for a current block by applying an advanced motion vector prediction (AMVP) mode.
  • AMVP advanced motion vector prediction
  • MVP motion vector prediction
  • the motion information for inter prediction may be bi-predictive motion information or single-predictive motion information.
  • the bipolite prediction motion information may include an L0 reference picture index, an L0 motion vector (L0 motion information), an L1 reference picture index, and an L1 motion vector (L1 motion information) An index and an L0 motion vector (L0 motion information), or an L1 reference picture index and an L1 motion vector (L1 motion information).
  • L0 denotes a reference picture list L0 (List 0)
  • L1 denotes a reference picture list L1 (List 1).
  • prediction mode information indicating the inter prediction mode of the current block can be signaled from the encoding device to the decoding device.
  • the prediction mode information may be included in the bitstream and received by the decoding device.
  • the prediction mode information may include index information indicating one of a plurality of candidate modes.
  • the inter prediction mode may be indicated through hierarchical signaling of the flag information.
  • the prediction mode information may include one or more flags. For example, a skip flag is signaled to indicate whether a skip mode is applied, and when a skip mode is not applied, a merge flag is signaled to indicate whether merge mode is applied or not. When the merge mode is not applied, Or may further signal flags for further identification.
  • a motion vector predictor (MVP) is predicted using a motion vector of the reconstructed spatial neighboring block and / or a motion vector corresponding to a temporally neighboring block (or a Col block) )
  • Candidate list can be generated. That is, the motion vector of the reconstructed spatial neighboring block and / or the motion vector corresponding to the temporal neighboring block may be used as a motion vector predictor candidate.
  • Information on the prediction of the current block may be signaled, and the information on the prediction may include selection information ex indicating the optimal motion vector predictor candidate selected from among the motion vector predictor candidates included in the MVP candidate list . MVP flag or MVP index).
  • the predicting unit can use the selection information to select a motion vector predictor of the current block from the motion vector predictor candidates included in the motion vector candidate list.
  • the predicting unit of the encoding apparatus can obtain the motion vector difference (MVD) between the motion vector of the current block and the motion vector predictor, and can output it as a bit stream. That is, MVD can be obtained by subtracting the motion vector predictor from the motion vector of the current block.
  • the predicting unit of the decoding apparatus may obtain the motion vector difference included in the information on the prediction, and derive the motion vector of the current block through addition of the motion vector difference and the motion vector predictor.
  • the predicting unit of the decoding apparatus can acquire or derive a reference picture index or the like indicating the reference picture from the information on the prediction.
  • the present invention proposes a method (ALR) capable of constructing an effective MVP candidate by rearranging the MVP candidate list in order to further improve the coding efficiency.
  • ALR ALR improvement methods for more effectively applying the ALR method.
  • FIG. 3 shows an example of constructing the MVP candidate list through the ALR.
  • the encoder / decoder can construct MVP candidates based on neighboring blocks of the current block, calculate the cost of each of the MVP candidates, and then, based on the costs of the MVP candidates, The MVP candidates can be rearranged and the MVP candidate list can be finally reconstructed by performing a refinement process based on the MVP candidates in the reordered order.
  • the encoding apparatus / decoding apparatus can construct MVP candidates of the maximum number of the current block through an existing MVP candidate list constructing method (S300). That is, the encoding apparatus / decoding apparatus can construct the MVP candidate list including the maximum number of MVP candidates through the conventional method of constructing the MVP candidate list. For example, the maximum number of candidates may be five.
  • the encoding apparatus / decoding apparatus may calculate a cost for the MVP candidate of the MVP candidate list (S310).
  • the cost may be calculated based on a template. That is, the cost may be derived through a template matching method.
  • FIG. 4 illustrates an example of deriving a cost for an MVP candidate of the current block through the template matching method.
  • a cost for the MVP candidate may be derived based on sample values of neighboring samples of the current block and sample values of neighboring samples of a candidate block indicated by the MVP candidate.
  • the neighboring samples of the current block may include left neighboring samples and upper neighboring samples that are causal in the current block. 4 an arbitrary surrounding region of the current block may be set as a template of the current block, and the cost of the MVP candidate may be determined using the template of the candidate block indicated by the MVP candidate on the reference picture, Can be derived.
  • the template of the candidate block for the MVP candidate may have the same size as the template of the current block.
  • the left neighboring samples and the upper neighboring samples of the current block may be already decoded at the decoding time of the current block and may be used in a motion estimation process in the decoding apparatus, Upper neighboring samples may be included in the template of the current block. That is, the template of the current block may be a specific region including the left surrounding samples and the upper surrounding samples.
  • the cost may be derived as a sum of the absolute values of the differences between the templates of the current block and the corresponding samples of the template of the candidate block. For example, the cost may be derived based on the following equation.
  • i, j denotes the position (i, j) of a sample template block
  • Cost distortion is the cost
  • Temp ref is the sample values of the template of the candidate block
  • Temp cur is the sample values of the template of the current block .
  • the difference between the template of the candidate block and the corresponding sample between the templates of the current block can be accumulated and the accumulation of the difference can be used as a cost for the MVP candidate.
  • the encoding device / decoding device may reorder MVP candidates based on the costs for the MVP candidates of the MVP candidate list (S320). For example, the encoding device / decoding device may rearrange the MVP candidates in order of cost. Alternatively, in another example, the encoding device / decoding device may reorder the MVP candidates with the lowest cost in first order.
  • the MVP candidate may be referred to as an AMVP candidate.
  • the encoding device / decoding device may derive a refine MVP candidate for the re-ordered MVP candidate of the MVP candidate list (S330). If there are a plurality of the re-arranged MVP candidates, a refine MVP candidate may be derived in the order of rearrangement. For example, the refined MVP candidate may be derived by refining the motion vector of the reordered MVP candidate. Specifically, the encoding apparatus / decoding apparatus can derive a template having a small cost from the template of the current block among the templates of the reference blocks included in an arbitrary peripheral region of the candidate block indicated by the re-ordered MVP candidate.
  • the encoding apparatus / decoding apparatus may derive a motion vector indicating a reference block of the derived template as a refine motion vector. That is, the encoding apparatus / decoding apparatus may derive a modified motion vector indicating the reference block of the derived template as the refine MVP candidate.
  • the encoding device / decoding device may derive the order of the refined MVP candidates in the MVP candidate list to the order of the reordered MVP candidates. That is, the encoding device / decoding device may assign the value of the index for the refined MVP candidate to a value smaller than the value of the index for the reordered MVP candidate.
  • the encoding / decoding device may select a specific number of MVP candidates and refine MVP candidates to derive a modified MVP candidate list (S340). For example, if five MVP candidates are derived and one refine MVP candidate is derived, the encoding device / decoding device may select two candidates out of the six candidates, and based on the two candidates, The candidate MVP candidate list can be derived. In addition, the encoding apparatus can signal information on the selected candidates.
  • a method of constructing the MVP candidate of the current block may be the same as the following description.
  • the types of motion information and the check order that can be configured as MVP candidates for the current block can be derived as shown in the following table.
  • the neighboring blocks in the same position as the merge mode may be checked for consistency with the merge mode as shown in Table 1, and the order of checking the neighboring blocks may also be set to the same.
  • the MVD since the MVD is signaled in the AMVP mode, it may not be suitable to construct the MVP candidate including the motion vector in units of subblocks.
  • ATMVP and STMVP including a motion vector in units of subblocks may not be considered as MVP candidates of the current block.
  • the combined bi-pred candidate is generated by combining the L0 motion vector and the L1 motion vector, it may not be suitable for the AMVP mode for deriving different MVPs for L0 prediction and L1 prediction.
  • the combined bi-pred candidate may not be considered as an MVP candidate.
  • the L0 prediction may represent uni-prediction based on L0 motion information
  • the L1 prediction may represent a single prediction based on L1 motion information.
  • A1 represents a motion vector of a left neighboring block of the current block
  • B1 represents a motion vector of an upper neighboring block of the current block
  • B0 represents a motion vector of an upper right neighbor block of the current block
  • ATMVP indicates a motion vector of a co-located block indicated by motion information of a specific neighboring block of the current block
  • STMVP indicates motion information of a neighboring block of the current block
  • B2 denotes motion information of a left upper block of the current block
  • TMVP denotes a motion vector of a temporally neighboring block of the current block
  • Combined denotes motion information of the current block
  • Zero indicates a motion vector value is zero.
  • the left neighboring block is the (-1, H-1)
  • the upper neighboring block is a block including upper left samples of a (W-1, -1) coordinate
  • the upper right neighboring block is a block including upper left samples of a (W, Blocks
  • the lower left neighboring block is a block including upper left samples of (-1, H) coordinates
  • the upper left neighboring block is a block including upper left samples of (-1, -1) coordinates.
  • a scheme of constructing the MVP candidate list as the arrangement order of the merge candidate list as described above can be proposed.
  • one of A0 and A1 may be derived as an MVP candidate of the current block
  • one of B0, B1 and B2 may be derived as an MVP candidate of the current block.
  • FIG. 5 shows an example of deriving MVP candidates of the MVP candidate list based on A0 and A1.
  • the encoding apparatus / decoding apparatus can select one MVP candidate from the motion vectors of the neighboring block A0 and the neighboring block A1 located at the left and lower left sides of the current block.
  • the encoding apparatus / decoding apparatus can check a motion vector of a neighboring block A0 (S500).
  • the reference picture index of the current block and the reference picture index of the neighboring block A0 are the same, and the reference picture index of the current block and the reference picture index of the neighboring block A0 Is included in the same reference picture list, the motion vector of the neighboring block A0 can be derived as an MVP candidate.
  • the encoding / decoding apparatus determines that the reference picture index of the current block and the surrounding If the reference picture indicated by the reference picture index of the block A0 is the same and the reference picture index of the current block and the reference picture index of the neighboring block A0 are included in different reference picture lists, As an MVP candidate. That is, when the reference picture indicated by the reference picture index of the neighboring block A0 is included in the reference picture list which is the same as the reference picture indicated by the reference picture index of the current block and is the same picture, the encoding / The motion vector of A0 can be derived as the MVP candidate.
  • the motion vector of the neighboring block A0 can be derived as the MVP candidate.
  • the encoding / decoding device may determine whether the neighboring block A0 is not available (S510). If the MVP candidate is not derived through the checking process for the neighboring block A0, the encoding / decoding device can determine that the neighboring block A0 is not available.
  • the encoding / decoding apparatus can check the motion vector of the neighboring block A1 (S520).
  • the encoding apparatus / decoding apparatus can perform the same check process as the check process for the neighboring block A0 to the neighboring block A1.
  • the reference picture index of the current block and the reference picture index of the neighboring block A1 are the same, and the reference picture index of the current block and the reference picture index Is included in the same reference picture list, the motion vector of the neighboring block A1 can be derived as an MVP candidate.
  • the encoding / decoding apparatus determines whether the reference picture index of the current block and the surrounding If the reference picture indicated by the reference picture index of the block A1 is the same and the reference picture indicated by the reference picture index of the current block and the reference picture index of the neighboring block A1 is included in the different reference picture list, As an MVP candidate. That is, when the reference picture indicated by the reference picture index of the neighboring block A1 is included in the reference picture list which is the same as the reference picture indicated by the reference picture index of the current block and is the same picture, the encoding / The motion vector of A1 can be derived as the MVP candidate.
  • the motion vector of the neighboring block A1 can be derived as the MVP candidate.
  • the encoding / decoding device may determine whether the neighboring block A1 is not available (S530). If the MVP candidate is not derived through the checking process for the neighboring block A1, the encoding / decoding apparatus can determine that the neighboring block A1 is not available.
  • the encoder / decoder can derive the motion vector scaledA0 by scaling the motion vector of the neighboring block A0, and the motion vector scaledA0 is used as the MVP candidate of the current block (S540).
  • the encoding apparatus / decoding apparatus can scale the motion vector A0 for the reference picture different from the reference picture of the current block, and derive the scaled motion vector scaledA0 as the MVP candidate.
  • the encoder / decoder can derive a motion vector scaledA1 by scaling the motion vector of the neighboring block A1, deriving the motion vector scaledA1 as an MVP candidate of the current block (S550).
  • the encoding apparatus / decoding apparatus can scale the motion vector A1 for the reference picture different from the reference picture of the current block, and derive the scaled motion vector scaledA1 as the MVP candidate.
  • the same process as that for deriving the MVP candidate based on the motion vectors for the neighboring block A0 and the neighboring block A1 is performed on the motion vectors for the neighboring block B0, the neighboring block B1, .
  • the neighboring block B0, the neighboring block B1, and the neighboring block B2 are not available, the neighboring block B0, the neighboring block B1, and the neighboring block B2 can be checked in order.
  • FIG. 6 shows an example of constructing the MVP candidate list through an existing procedure.
  • one of A0 and A1 may be derived as an MVP candidate of the current block
  • one of B0, B1, and B2 may be derived as an MVP candidate of the current block.
  • the order of deriving the MVP candidates based on A0 and A1 may be as follows.
  • the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list
  • the reference picture index indicating the specific reference picture included in the specific reference picture list The first motion vector included in the first motion information may be derived as the MVP candidate of the current block.
  • a second motion vector included in the second motion information may be derived as an MVP candidate of the current block.
  • a third motion vector included in the third motion information may be derived as an MVP candidate of the current block.
  • a fourth motion vector included in the fourth motion information may be derived as an MVP candidate of the current block.
  • the fifth motion information included in the fifth motion information may be derived as an MVP candidate of the current block.
  • a sixth motion vector included in the sixth motion information may be derived as an MVP candidate of the current block have.
  • the seventh motion vector included in the seventh motion information is derived as the MVP candidate of the current block .
  • a vector may be derived as an MVP candidate of the current block.
  • the order of deriving the MVP candidates based on B0, B1 and B2 may be as follows.
  • the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list
  • the reference picture index indicating the specific reference picture included in the specific reference picture list The first motion vector included in the first motion information may be derived as an MVP candidate of the current block.
  • a second motion vector included in the second motion information may be derived as an MVP candidate of the current block.
  • a third motion vector included in the third motion information may be derived as an MVP candidate of the current block.
  • a fourth motion vector included in the fourth motion information may be derived as an MVP candidate of the current block.
  • the fifth motion vector included in the fifth motion information may be derived as an MVP candidate of the current block.
  • a sixth motion vector included in the sixth motion information may be derived as an MVP candidate of the current block if there is the sixth motion information of the neighboring block B2 that includes a reference picture index indicating a picture.
  • the seventh motion vector included in the seventh motion information is derived as the MVP candidate of the current block .
  • a vector may be derived as an MVP candidate of the current block.
  • a motion vector may be derived as an MVP candidate of the current block.
  • a tenth motion vector included in the tenth motion information may be derived as an MVP candidate of the current block.
  • the first motion information, the second motion information, the third motion information, the fourth motion information, the fifth motion information, the sixth motion information, the seventh motion information, the eighth motion information, 9 motion information and the tenth motion information are not present and the 11th motion information of the neighboring block B2 including the reference picture index indicating the reference picture other than the specific reference picture contained in the specific reference picture list exists .
  • An eleventh motion vector included in the eleventh motion information may be derived as an MVP candidate of the current block.
  • a twelfth motion vector included in the twelfth motion information may be derived as an MVP candidate of the current block.
  • the MVP candidate list configuration scheme proposed by the present invention can include up to five MVP candidates, not up to two MVP candidates.
  • One MVP candidate is derived from A0 and A1, and B0, B1, It is necessary to change the existing configuration method to derive one MVP candidate based on B2.
  • FIG. 7 shows an example of constructing an MVP candidate list based on neighboring blocks of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block A1 of the current block (S700). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding / decoding apparatus may determine whether the neighboring block A1 is not available (S705). If the MVP candidate is not derived through the checking process for the neighboring block A1, the encoding / decoding apparatus can determine that the neighboring block A1 is not available. If the first motion vector and the second motion vector of the neighboring block A1 do not exist, the encoding / decoding apparatus can determine that the neighboring block A1 is not available.
  • the encoding / decoding apparatus scales the third motion vector included in the third motion information of the neighboring block A1 including the reference picture index indicating the reference picture other than the specific reference picture , And a scaled motion vector may be derived as an MVP candidate of the current block (S710).
  • the scaled motion vector may be represented as scaled A1.
  • the encoding apparatus / decoding apparatus can check the peripheral block B1 of the current block (S715). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the second motion information of the neighboring block B1 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the specific reference picture list and the first motion information of the neighboring block B1 does not exist If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus may determine whether the neighboring block B1 is not available (S720). If the MVP candidate is not derived through the checking process for the neighboring block B 1, the encoding / decoding apparatus can determine that the neighboring block B 1 is not available. If the first motion vector and the second motion vector of the neighboring block B1 do not exist, the encoding / decoding apparatus can determine that the neighboring block B1 is not available.
  • the encoding / decoding device scales the third motion vector included in the third motion information of the neighboring block B 1 including the reference picture index indicating the reference picture other than the specific reference picture , And a scaled motion vector may be derived as an MVP candidate of the current block (S725).
  • the scaled motion vector may be represented as scaled B1.
  • the encoding apparatus / decoding apparatus can check the neighboring block B0 of the current block (S730). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as an MVP candidate of the current block, if the first motion information of the neighboring block B0 exists.
  • the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can determine whether the neighboring block B0 is not available (S735). If the MVP candidate is not derived through the checking process for the neighboring block B0, the encoding / decoding device may determine that the neighboring block B0 is not available. If the first motion vector and the second motion vector of the neighboring block B0 do not exist, the encoding / decoding device can determine that the neighboring block B0 is not available.
  • the encoding / decoding apparatus scales the third motion vector included in the third motion information of the neighboring block B0 including the reference picture index indicating the reference picture other than the specific reference picture , And a scaled motion vector may be derived as an MVP candidate of the current block (S740).
  • the scaled motion vector may be expressed as scaled B0.
  • the encoding apparatus / decoding apparatus can check the neighboring block A0 of the current block (S745). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list Decoding apparatus can derive a first motion vector included in the first motion information as an MVP candidate of the current block if the first motion information of the neighboring block A0 exists.
  • the second motion information of the neighboring block A0 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the first motion information of the neighboring block A0 and is not the specific reference picture list If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding / decoding apparatus may determine whether the neighboring block A0 is not available (S750). If the MVP candidate is not derived through the checking process for the neighboring block A0, the encoding / decoding device may determine that the neighboring block A0 is not available. If the first motion vector and the second motion vector of the neighboring block A0 do not exist, the encoding / decoding device can determine that the neighboring block A0 is not available.
  • the encoding / decoding apparatus scales the third motion vector included in the third motion information of the neighboring block A0 including the reference picture index indicating a reference picture other than the specific reference picture , And a scaled motion vector may be derived as an MVP candidate of the current block (S755).
  • the scaled motion vector may be expressed as scaled A0.
  • the encoding apparatus / decoding apparatus can check the neighboring block B2 of the current block (S760). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding device / decoding device may derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the second motion information of the neighboring block B2 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the specific reference picture list and the first motion information of the neighboring block B2 does not exist If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can determine whether the neighboring block B2 is not available (S765). If the MVP candidate is not derived through the checking process for the neighboring block B2 described above, the encoding / decoding apparatus can determine that the neighboring block B2 is not available. If the first motion vector and the second motion vector of the neighboring block B2 do not exist, the encoding apparatus / decoding apparatus can determine that the neighboring block B2 is not available.
  • the encoding / decoding apparatus scales the third motion vector included in the third motion information of the neighboring block B2 including the reference picture index indicating the reference picture other than the specific reference picture , And a scaled motion vector may be derived as an MVP candidate of the current block (S770).
  • the scaled motion vector may be expressed as scaled B2.
  • the order of deriving the MVP candidates to construct the MVP candidate list may be changed.
  • the encoding apparatus / decoding apparatus checks the spatial neighboring blocks of the current block in order of the neighboring block A1, the neighboring block B1, the neighboring block B0, the neighboring block A0, and the neighboring block B2 in order of deriving the MVP candidate Scaled A1, scaled B1, scaled B0, scaled A0, and scaled B2 are added in the order of the number of MVP candidates, And the MVP candidate list including the MVP candidate list.
  • the scaled A 1 is a motion vector derived by scaling a motion vector of the neighboring block A 1
  • the scaled B 1 is a motion vector derived by scaling a motion vector of the neighboring block B 1
  • the scaled B 0 is a motion vector of the neighboring block B 0
  • the scaled A0 is a motion vector derived by scaling a motion vector of the neighboring block A0
  • the scaled B2 is a motion vector derived by scaling a motion vector of the neighboring block B2 .
  • FIG. 8 shows an example of constructing an MVP candidate list based on neighboring blocks of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block A1 of the current block (S800). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block B1 of the current block (S805). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the second motion information of the neighboring block B1 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the specific reference picture list and the first motion information of the neighboring block B1 does not exist If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block B0 of the current block (S810). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding / decoding apparatus can derive the first motion vector included in the first motion information as an MVP candidate of the current block, if the first motion information of the neighboring block B0 exists.
  • the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block A0 of the current block (S815). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list Decoding apparatus can derive a first motion vector included in the first motion information as an MVP candidate of the current block if the first motion information of the neighboring block A0 exists.
  • the second motion information of the neighboring block A0 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the first motion information of the neighboring block A0 and is not the specific reference picture list If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can check the neighboring block B2 of the current block (S820). For example, when the reference picture indicated by the reference picture index for the current block is a specific reference picture included in the specific reference picture list, the reference picture index includes a reference picture index indicating the specific reference picture included in the specific reference picture list , The encoding device / decoding device may derive the first motion vector included in the first motion information as the MVP candidate of the current block.
  • the second motion information of the neighboring block B2 including the reference picture index indicating the specific reference picture included in the reference picture list that is not the specific reference picture list and the first motion information of the neighboring block B2 does not exist If so, the encoding apparatus / decoding apparatus may derive the second motion vector included in the second motion information as an MVP candidate of the current block.
  • the encoding apparatus / decoding apparatus can determine whether the number of derived MVP candidates is less than 5 (S825). If the number of derived MVP candidates is 5, the encoding apparatus / decoding apparatus may construct an MVP candidate list including the derived MVP candidate, and may not derive an additional MVP candidate.
  • the encoder / decoder can scale the motion vector of the neighboring block A1 and check the scaled vector (S830). For example, if the same MVP candidate as the scaled vector does not exist, the encoder / decoder can derive the scaled vector to the MVP candidate of the current block, and the MVP candidate equal to the scaled vector If so, the encoding device / decoding device may not derive the scaled vector to the MVP candidate of the current block.
  • the scaled vector may be denoted as scaled A1.
  • the encoding apparatus / decoding apparatus can determine whether the number of derived MVP candidates is smaller than 5 (S835). If the number of derived MVP candidates is 5, the encoding apparatus / decoding apparatus may construct an MVP candidate list including the derived MVP candidate, and may not derive an additional MVP candidate.
  • the encoding apparatus / decoding apparatus can scale the motion vector of the neighboring block B1 and check the scaled vector (S840). For example, if the same MVP candidate as the scaled vector does not exist, the encoder / decoder can derive the scaled vector to the MVP candidate of the current block, and the MVP candidate equal to the scaled vector If so, the encoding device / decoding device may not derive the scaled vector to the MVP candidate of the current block.
  • the scaled vector may be denoted as scaled B1.
  • the encoding apparatus / decoding apparatus can determine whether the number of derived MVP candidates is less than 5 (S845). If the number of derived MVP candidates is 5, the encoding apparatus / decoding apparatus may construct an MVP candidate list including the derived MVP candidate, and may not derive an additional MVP candidate.
  • the encoder / decoder can scale the motion vector of the neighboring block B0 and check the scaled vector (S850). For example, if the same MVP candidate as the scaled vector does not exist, the encoder / decoder can derive the scaled vector to the MVP candidate of the current block, and the MVP candidate equal to the scaled vector If so, the encoding device / decoding device may not derive the scaled vector to the MVP candidate of the current block.
  • the scaled vector may be denoted as scaled B0.
  • the encoding apparatus / decoding apparatus can determine whether the number of derived MVP candidates is less than 5 (S855). If the number of derived MVP candidates is 5, the encoding apparatus / decoding apparatus may construct an MVP candidate list including the derived MVP candidate, and may not derive an additional MVP candidate.
  • the encoding apparatus / decoding apparatus can scale the motion vector of the neighboring block A0 and check the scaled vector (S860). For example, if the same MVP candidate as the scaled vector does not exist, the encoder / decoder can derive the scaled vector to the MVP candidate of the current block, and the MVP candidate equal to the scaled vector If so, the encoding device / decoding device may not derive the scaled vector to the MVP candidate of the current block.
  • the scaled vector may be denoted as scaled A0.
  • the encoding apparatus / decoding apparatus can determine whether the number of derived MVP candidates is less than 5 (S865). If the number of derived MVP candidates is 5, the encoding apparatus / decoding apparatus may construct an MVP candidate list including the derived MVP candidate, and may not derive an additional MVP candidate.
  • the encoding apparatus / decoding apparatus can scale the motion vector of the neighboring block B2 and check the scaled vector (S870). For example, if the same MVP candidate as the scaled vector does not exist, the encoder / decoder can derive the scaled vector to the MVP candidate of the current block, and the MVP candidate equal to the scaled vector If so, the encoding device / decoding device may not derive the scaled vector to the MVP candidate of the current block.
  • the scaled vector may be denoted as scaled B2.
  • an MVP index indicating one candidate of the MVP candidates included in the configured MVP candidate list can be signaled, so that various MVP candidates that are not duplicated without signaling overhead can be added to the MVP candidate list A redundant check process is required. Accordingly, for example, when the first MVP candidate and the second MVP candidate are the same, that is, when the first MVP candidate and the second MVP candidate are the same motion vector, the first MVP candidate and the second MVP candidate The MVP candidate of the second MVP candidate in the order of the MVP candidate list may be removed.
  • the MVP candidate list is composed of five spatial MVP candidates and / or temporal MVP candidates ⁇ C0, C1, C2, C3, C4 ⁇ as follows
  • the spatial MVP candidate may represent an MVP candidate derived based on a motion vector of a spatial neighboring block of a current block
  • the temporal MVP candidate may be an MVP candidate derived based on a motion vector of a temporally neighboring block of the current block Lt; / RTI >
  • the C0 may be derived as an MVP candidate of the current block.
  • C2 it can be judged whether or not the C2 is available. If C2 is available, a duplicate check for C0 and C2 and a duplicate check for C1 and C2 can be performed. For example, if C2 is equal to C0, i.e., C2 is the same motion vector as C0, C2 may not be derived as MVP candidate of the current block. If C2 is the same as C1, i.e., C2 is the same motion vector as C1, C2 may not be derived as an MVP candidate of the current block. If C2 is not equal to C0 and C0, that is, if C2 is not the same motion vector as C0 and C1, C2 may be derived as MVP candidate of the current block.
  • C3 it can be determined whether the C3 is available. If C3 is available, a duplicate check for C0 and C3, a duplicate check for C1 and C3, and a duplicate check for C2 and C3 can be performed. For example, if C3 is equal to C0, i.e., C3 is the same motion vector as C0, C3 may not be derived as MVP candidate of the current block. Also, when the C3 is the same as the C1, that is, when the C3 is the same motion vector as the C1, the C3 may not be derived as the MVP candidate of the current block. Also, when the C3 is the same as the C2, that is, when the C3 is the same motion vector as the C2, the C3 may not be derived as the MVP candidate of the current block. If C3 is not equal to C0, C1 and C2, that is, if C3 is not the same motion vector as C0, C1 and C2, C3 is derived as an MVP candidate of the current block .
  • C4 it can be determined whether the C4 is available. If the C4 is available, a redundancy check for C0 and C4, a redundancy check for C1 and C4, a redundancy check for C2 and C4 and a redundancy check for C3 and C4 may be performed have. For example, if C4 is equal to C0, i.e., if C4 is a motion vector equal to C0, C4 may not be derived as an MVP candidate of the current block. Also, when C4 is the same as C1, i.e., C4 is the same motion vector as C1, C4 may not be derived as an MVP candidate of the current block.
  • C4 when C4 is the same as C2, i.e., C4 is the same motion vector as C2, C4 may not be derived as MVP candidate of the current block. Also, when the C4 is the same as the C3, that is, when the C4 is the same motion vector as the C3, the C4 may not be derived as the MVP candidate of the current block. If C4 is not the same as C0, C1, C2, and C3, i.e., if C4 is not the same motion vector as C0, C1, C2, and C3, Of MVP candidates.
  • the MVP candidate may be rounded, and then a duplicate check may be performed based on the rounded motion vector. Also, even if the AMVR tool is applied to the current block, the duplication check on the MVP candidate may be performed based on the unrounded motion vector of the MVP candidate. Meanwhile, the rounded motion vector, the motion vector removed through the redundancy check process, or the rounded motion vector removed through the redundancy check process can be stored as candidates for ALR (AMVP candidate List Refinement).
  • ALR AVP candidate List Refinement
  • reordering and / or refinement of the MVP candidate list is performed through the ALR to obtain a modified MVP candidate list have. For example, if an arbitrary neighboring area of the current block or a template of the current block is available, a reordering and / or refinement process for the MVP candidate list may be performed through the ALR. Specifically, the encoding device / decoding device may derive the costs for the MVP candidates included in the MVP candidate list of the current block, reorder the MVP candidates based on the costs, and / or reorder the MVP candidates A modified MVP candidate list can be derived by deriving a refinement MVP candidate for the MVP candidate.
  • the MVP indexes for the MVP candidate list including the MVP candidates may be signaled in the order not rearranged.
  • the cost of the MVP candidate may be derived as a Sum of Absolute Difference (SAD) between the template of the current block and the template of the MVP candidate.
  • the MVP candidate template may represent a template of the reference block indicated by the MVP candidate, and may be an area of the same size as the template of the current block.
  • the encoding apparatus / decoding apparatus can check whether there is an MVP candidate indicating the same motion vector, and if there are MVP candidates indicating the same motion information, the MVP candidate excluding the MVP candidate in the order Can be removed from the modified MVP candidate list.
  • the process of checking whether there is an MVP candidate indicating the same motion information may be referred to as a pruning check.
  • the pruning check may be performed only on the reordered MVP candidates.
  • the pruning check process can be performed only with respect to the reordered MVP candidates and the MVP candidates in an order higher than the reordered MVP candidates, and the calculation complexity is reduced. Also, it can be determined whether there is an MVP candidate indicating the same motion vector only for the motion vector of the refinement MVP candidate derived in the refinement process. In addition, it may be determined whether there is an MVP candidate indicating the same motion vector only for the MVP candidate representing the zero vector. This makes it possible to improve the coding efficiency.
  • a modified MVP candidate list may be constructed as described below.
  • FIG. 9 shows an example of constructing a modified MVP candidate list including refinement MVP candidates. Since the selectivity of the refinement MVP candidate may vary depending on the location of the refinement MVP candidate, another modified method of constructing the modified MVP candidate list may be considered according to the order of the refinement MVP candidates.
  • the encoding device / decoding device may determine whether the refined MVP candidates are MVP candidates in the first order in the reordered order (S900). If the refinement MVP candidate is the first-order MVP candidate, the encoding device / decoding device rearranges the refinement MVP candidate in the first order (S910), and the MVP candidates other than the refinement MVP candidate in the order of the existing MVP candidate list, (S920). If the refined MVP candidate is not the MVP candidate in the first order, the encoding device / decoding device may maintain the modified MVP candidate list (S930).
  • a scheme for constructing a modified MVP candidate list different from the above-described embodiment may be proposed.
  • it may be proposed to make a modified MVP list configuration based on the order of refinement MVP candidates.
  • it may be proposed to construct a modified MVP candidate list such that the MVP candidates smaller than the specific threshold value maintain the order of rearrangement and the MVP candidates whose cost is larger than the specific threshold value maintain the order in the existing MVP candidate list have.
  • a method of differentiating the reordering method according to a specific condition may be proposed, and a method of always applying the same reordering method may be proposed.
  • the cost of the MVP candidate may be derived using the template of the current block and the template of the reference block indicated by the MVP candidate on the reference picture, and the cost may be determined based on the template of the current block and the template (Sum of Absolute Differences, SAD).
  • SAD Sample of Absolute Differences
  • the accuracy of the motion information can be predicted based on the similarity degree of the neighboring region between the current block and the reference block.
  • Fig. 10 shows an example of deriving the cost of the MVP candidate based on the template.
  • the template of the current block may include a left peripheral region and / or an upper peripheral region of the current block, and the template of the current block may be a region corresponding to the template of the current block ,
  • the template of the reference block may include a left peripheral region and / or an upper peripheral region of the reference block. If the left peripheral region and / or the upper peripheral region of the current block are available, the cost of the MVP candidate may be calculated with SAD for each peripheral region. That is, for example, the SAD between the left peripheral area of the current block and the left peripheral area of the reference block indicated by the MVP candidate, the upper peripheral area of the current block and the upper peripheral area of the reference block indicated by the MVP candidate The cost can be calculated with SAD.
  • the upper peripheral region included in the template of the current block may be referred to as an upper template of the current block, and the left peripheral region included in the template of the current block may be referred to as a left template of the current block have.
  • the upper peripheral region included in the template of the reference block may be referred to as an upper template of the reference block and the left peripheral region included in the template of the reference block may be referred to as a left template of the reference block have.
  • the motion information for the inter prediction may be the bi-predictive motion information or the single-predictive motion information as described above.
  • the bipolite prediction motion information may include an L0 reference picture index, an L0 motion vector (L0 motion information), an L1 reference picture index, and an L1 motion vector (L1 motion information) An index and an L0 motion vector (L0 motion information), or an L1 reference picture index and an L1 motion vector (L1 motion information).
  • L0 denotes a reference picture list L0 (List 0)
  • L1 denotes a reference picture list L1 (List 1).
  • the MVP candidate may represent a L0 motion vector or may represent an L1 motion vector.
  • the cost of the MVP candidate may be derived as the SAD of the template of the current block and the template of the L0 reference block indicated by the MVP candidate.
  • the cost of the MVP candidate is determined by the cost L0_A between the upper peripheral area of the current block and the upper peripheral area of the reference block indicated by the MVP candidate, the left peripheral area of the current block, And the cost L0_L with the left peripheral region of the left-hand side of FIG.
  • the cost L0_A may be the SAD between the upper peripheral region of the current block and the upper peripheral region of the reference block and the cost L0_L may be the left peripheral region of the current block and the left peripheral region of the reference block, Lt; / RTI >
  • the cost of the MVP candidate may be derived based on the following equation.
  • costL0 represents the cost of the MVP candidate
  • costL0_A represents the cost L0_A of the MVP candidate
  • costL0_L represents the cost L0_L of the MVP candidate.
  • the cost of the MVP candidate may be derived as a SAD between the template of the current block and the template of the L1 reference block indicated by the MVP candidate.
  • the cost L1_A may be the SAD between the upper peripheral area of the current block and the upper peripheral area of the reference block and the cost L1_L may be the left peripheral area of the current block and the left peripheral area of the reference block Lt; / RTI >
  • the cost L1 of the MVP candidate may be derived based on the following equation.
  • costL1 denotes the cost L1 of the MVP candidate
  • costL1_A denotes the cost L1_A of the MVP candidate
  • costL1_L denotes the cost L1_L of the MVP candidate.
  • the cost of the bi-predictive motion information can be calculated as an average of the cost L0 and the cost L1.
  • the cost L0 may be derived as a SAD of a template of the current block and a template of a reference block indicated by the L0 motion information of the bi-predictive motion information
  • the cost Ll is a sum of the template of the current block and the bi- Can be derived as the SAD of the template of the reference block indicated by the L1 motion information of the information.
  • the cost of the bi-predictive motion information may be derived based on the following equation.
  • costBi represents the cost of the predictive motion information
  • costL0 represents the cost L1 of the predictive motion information
  • costL1 represents the cost L1 of the predictive motion information
  • the availability of the template can be judged based on the following conditions.
  • whether or not the template is available can be determined based on whether or not a sample included in the template exists.
  • the availability of the template may be determined based on whether the template is adjacent to a slice or tile boundary.
  • whether the template is available or not can be determined based on whether the template is a decoded region based on an intra mode.
  • the cost for the MVP candidate When the cost for the MVP candidate is derived based on the template as described above, the cost of the MVP candidate may be changed according to the position of the neighboring block. Accordingly, the present invention proposes a scheme for preventing a significant difference in cost depending on a position and further improving a cost deriving method.
  • the cost for the left template of the motion vector of the left neighboring block can be deduced to be smaller than the cost for the left template of other MVP candidates.
  • the cost for the left template of the motion vector of the left neighbor block may be derived as the SAD of the left template of the reference block indicated by the motion vector of the left neighbor block and the left template of the current block.
  • the left template is a left peripheral region of the current block, it can represent a restoration block of the left neighboring block, and the reference block is a reference block derived based on the motion vector of the left neighboring block,
  • the cost for the left template of the motion vector of the left neighboring block may be a distortion between the restoring block and the reference block and the cost for the left template of the left neighboring block may be set to the left template of another MVP candidate The cost can be reduced.
  • the cost for the upper template of the motion vector of the upper neighboring block can be deduced to be smaller than the cost for the upper template of the other MVP candidate.
  • the cost for the upper template of the motion vector of the upper neighboring block may be derived as the SAD of the upper template of the reference block indicated by the motion vector of the upper neighboring block and the upper template of the current block.
  • the upper-side template is the upper peripheral region of the current block, it can represent the reconstructed block of the upper neighboring block, and the reference block is the reference block derived based on the motion vector of the upper neighboring block
  • the cost for the upper template of the motion vector of the upper neighboring block may be a distortion of the reconstruction block and the reference block and the cost of the upper template of the motion vector of the upper neighboring block may be The cost can be reduced.
  • the phenomenon that the cost varies depending on the position and size of the template may be further enhanced when the current block is a non-square block.
  • the size of the left template may be (2 x height) and the size of the upper template may be (width x 2).
  • the cost of the normalized left template and the cost of the top template may be derived based on the following equation.
  • costL denotes the cost of the normalized left template
  • costA' denotes the cost of the normalized upper template
  • costL denotes the cost of the left template
  • costA denotes the cost of the upper template
  • Width represents the width of the current block
  • height represents the height of the current block.
  • the size of the template may be set to two.
  • the size of the template may be changed as in the following embodiments.
  • the size of the template may be derived based on the size of the current block. For example, if the size of the current block is smaller than the 16x16 size, the size of the template may be derived as 2. If the size of the current block is greater than or equal to 16x16 size, .
  • the template for the MVP candidate includes the upper left sample of (-n, 0), the left surrounding area (left template) having the size of nxH, Sample, and may include an upper peripheral region (upper template) having a Wxn size.
  • n represents the size of the template.
  • the present invention proposes a method of deriving a cost for an MVP candidate as described later.
  • modified cost and the modified cost of the upper template of the current block may be derived based on the following equation.
  • costA (LX) represents the corrected cost for the upper template of the luma block of the current block and the upper template of the chroma block
  • costL (LX) represents the corrected cost for the left template of the luma block of the current block and the left template of the chroma block
  • CostL (LX, L) represents the cost of the left template of the luma block of the current block
  • costA (LX, L) represents the cost of the left template of the luma block of the current block
  • LX, C) represents the cost of the upper template of the chroma block of the current block
  • costL (LX, C) represents the cost of the left template of the chroma block of the current block.
  • W L is the current represents the width of the luma blocks of the block
  • H L is the current block represents a height of the luma blocks
  • W C represents the width of the chroma blocks of the current block
  • H C is And the height of the chroma block of the current block.
  • w represents a weighting factor.
  • the weighting factor for the luma block may be set to be greater than the weighting factor for the chroma block. That is, since w can be set to be larger than (1-w), w can be set to a value larger than 0.5.
  • the weighting factor may be derived based on the current block. That is, the weighting factor may be set in units of blocks.
  • the weighting factor may be preset in slice units, and the cost for the MVP candidate may be derived based on the weighting factor.
  • the line buffer for the luma block and the chroma block may be defined as 2 and 1, respectively.
  • the line buffer for the luma block and the chroma block may be defined with different values, and a normalized value based on the size of the luma block and the chroma block may be used.
  • IC_SAD Illumination Compensation_SAD
  • Cur represents a sample value in a template of a current block
  • Ref represents a sample value in a template of a reference block
  • W represents a width of the current block
  • H represents a height of the current block.
  • the method of compensating the illuminance of the reference block to improve the efficiency of the prediction can be called local illumination compensation (LIC).
  • the LIC may be mixed with an illumination compensation (IC).
  • the IC_SAD may indicate a value for the intensity compensation. That is, if the LIC is applied to a current block, the compensated reference block may be derived based on the IC_SAD. For example, the reference sample value of the compensated reference block may be derived by adding the IC_SAD to the reference sample value of the reference block.
  • an LIC flag may be used to indicate whether the LIC is applied or not. For example, if the value of the LIC flag is 1 (i.e., the value of the LIC flag is 'true'), the LIC flag may indicate that the LIC is applied to the current block, (I.e., the value of the LIC flag is 'false'), the LIC flag may indicate that the LIC is not applied to the current block.
  • LIC In order to increase the efficiency of the LIC, it is important to improve the prediction performance while minimizing the additional information for the LIC. For example, in order to minimize additional information, it is possible to determine whether LIC is applied considering a block size or a partition type, such as limited application to a PU having a partition size of 2Nx2N or a CU of a specific size.
  • a partition type such as limited application to a PU having a partition size of 2Nx2N or a CU of a specific size.
  • CUs of various sizes can be used without discrimination of CU, PU, and TU, so that the accuracy of prediction can be improved by applying LIC to the structure.
  • the IC_SAD is derived based on the template of the current block and the template of the reference block indicated by the MVP candidate, and the IC_SAD can be used as a cost for the MVP candidate. For example, when the value of the LIC flag is 'true', that is, when the LIC flag indicates that the LIC is applied to the current block, the cost of the MVP candidate for the luma block of the current block is The cost of the MVP candidate for the chroma block of the current block may be derived as the SAD of the template of the chroma block of the current block and the template of the chroma block of the reference block.
  • the cost of the MVP candidate for the luma block of the current block is determined by the SAD of the template of the luma block of the current block and the template of the luma block of the reference block, And the SAD of the template of the chroma block of the reference block.
  • the manner in which the IC_SAD is used may be variously changed depending on whether or not the chroma block is considered.
  • the weighting factor may be derived based on the value of the LIC flag.
  • DMVR Decoder Side Motion Vector Refinement
  • the refinement process for the MVP candidate list requires access to a large area memory. That is, a lot of hardware resources may be needed to perform the refinement process. Accordingly, the present invention proposes a refinement process that is performed based on restricted access to a reference picture.
  • FIG. 11 shows an example of deriving the cost L0 for the current block and the L0 reference block, and the cost L1 for the current block and the L1 reference block.
  • the cost L0 for the current block and the L0 reference block may be derived as a sum of absolute difference (SAD) between the template of the current block and the template of the L0 reference block. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the L0 reference block.
  • the L0 reference block may be a reference block indicated by the MVP candidate indicating the L0 motion vector.
  • the template of the current block may include an upper template and a left template
  • the cost L0 may be derived as the sum of the upper cost L0 and the left cost L0.
  • the upper cost L0 may be derived as the SAD between the upper template of the current block and the upper template of the L0 reference block and the left cost L0 may be derived as the SAD between the left template of the current block and the left template of the L0 reference block . ≪ / RTI >
  • the cost L1 for the current block and the L1 reference block may be derived as a sum of absolute difference (SAD) between the template of the current block and the template of the L1 reference block. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the L1 reference block.
  • the L1 reference block may be a reference block indicated by the MVP candidate representing the L1 motion vector.
  • the template of the current block may include an upper template and a left template
  • the cost L1 may be derived as the sum of the upper cost L1 and the left cost L1.
  • the upper cost Ll may be derived as the SAD between the upper template of the current block and the upper template of the L1 reference block and the left cost L1 may be derived as the SAD between the left template of the current block and the left template of the L0 reference block. . ≪ / RTI >
  • the following refinement process may be performed based on the cost L0 and the cost L1.
  • FIG. 12 shows an example of a restricted refinement performed based on the cost L0 and the cost L1.
  • the encoding / decoding apparatus derives the cost L0 for the current block and the L0 reference block (S1200).
  • the cost L0 for the current block and the L0 reference block may be derived as a sum of absolute difference (SAD) between the template of the current block and the template of the L0 reference block. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the L0 reference block.
  • the L0 reference block may be a reference block indicated by the MVP candidate indicating the L0 motion vector.
  • the encoding / decoding device derives the cost L1 for the current block and the L1 reference block (S1210).
  • the cost L1 for the current block and the L1 reference block may be derived as a sum of absolute difference (SAD) between the template of the current block and the template of the L1 reference block. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the L1 reference block.
  • the L1 reference block may be a reference block indicated by the MVP candidate representing the L1 motion vector.
  • the encoding apparatus / decoding apparatus may determine whether the cost L1 is greater than the cost L0 (S1220).
  • the encoding / decoding device may derive a refine MVP candidate for the MVP candidate representing the L1 motion vector (S1230).
  • the encoding apparatus / decoding apparatus may include a template having a small cost with respect to a template of the current block among templates of reference blocks included in an arbitrary surrounding region of the L1 reference block indicated by the MVP candidate indicating the L1 motion vector .
  • the encoding apparatus / decoding apparatus may derive a motion vector indicating a reference block of the derived template as a refine motion vector. That is, the encoding apparatus / decoding apparatus can derive a refine motion vector indicating the reference block of the derived template as the refine MVP candidate.
  • the encoding apparatus / decoding apparatus may derive a refine MVP candidate for the MVP candidate representing the L0 motion vector (S1240).
  • the encoding apparatus / decoding apparatus may include a template having a small cost with respect to a template of the current block among templates of reference blocks included in an arbitrary peripheral region of the L0 reference block indicated by the MVP candidate indicating the L0 motion vector .
  • the encoding apparatus / decoding apparatus may derive a motion vector indicating a reference block of the derived template as a refine motion vector. That is, the encoding apparatus / decoding apparatus can derive a refine motion vector indicating the reference block of the derived template as the refine MVP candidate.
  • the L0 prediction may indicate inter prediction that is performed based on the reference pictures included in the reference picture list L0
  • the L1 prediction may indicate inter prediction that is performed based on the reference pictures included in the reference picture list L1.
  • a refinement process for a predetermined specific reference picture list may be performed without any additional condition.
  • the above-described restricted refinement process can also be applied to the DMVR and may be effective in reducing memory access to the DMVR.
  • FIG. 13 schematically shows a video encoding method by the encoding apparatus according to the present invention.
  • the method disclosed in Fig. 13 can be performed by the encoding apparatus disclosed in Fig. Specifically, for example, S1300 to S1350 in FIG. 13 may be performed by the predicting unit of the encoding apparatus, and S1360 may be performed by the entropy encoding unit of the encoding apparatus.
  • the encoding apparatus constructs an MVP candidate list based on the neighboring blocks of the current block (S1300).
  • the neighboring block may include a left neighbor block, an upper neighbor block, an upper right neighbor block, a lower left neighbor block, and a left upper neighbor block.
  • the neighboring block may include a co-located block including a position in a reference picture corresponding to a lower right position or a center position of the current block.
  • the left neighboring block is the upper left corner of the (-1, H-1)
  • the upper left neighbor block is a block including a left upper sample of the (W-1, -1) coordinate
  • the upper right neighbor block is a block including a left upper sample of the (W, )
  • the lower left neighboring block is a block including upper left samples of the (-1, H) coordinate
  • the upper left neighboring block is a block including upper left samples of (-1, -1) coordinates.
  • the encoding apparatus may determine the motion vector of the left neighboring block, the motion vector of the upper neighboring block, the motion vector of the upper right neighboring block, the motion vector of the lower left neighboring block, It is possible to judge the validity, and a valid motion vector can be sequentially added to the MVP candidate list as an MVP candidate.
  • the validity of the motion vector of the neighboring block may be determined as follows. Specifically, it may be sequentially determined whether a motion vector of the neighboring block corresponds to a first motion vector or a second motion vector, and if the motion vector of the neighboring block is the first motion vector and the second motion vector, , It can be determined that the motion vector of the neighboring block is not valid.
  • the first motion vector may be a motion vector for a specific reference picture included in a specific reference picture list
  • the second motion vector may be a motion vector for the specific reference picture included in the reference picture list, Lt; / RTI >
  • the specific reference picture included in the specific reference picture list may be a reference picture of the current block.
  • the motion vector may be scaled, and a scaled motion vector may be added to the MVP candidate list with the MVP candidate.
  • the encoding apparatus may construct an MVP candidate list including a maximum number of MVP candidates based on the neighboring blocks.
  • the maximum number of MVP candidates included in the MVP candidate list may be five.
  • the encoding apparatus calculates a scaled motion vector of a left neighboring block of the current block, a scaled motion vector of an upper neighboring block,
  • the MVP candidate list including the maximum number of MVP candidates based on the scaled motion vector of the lower left neighboring block, the scaled motion vector of the lower left neighboring block, and the scaled motion vector of the upper left neighboring block.
  • the scaled motion vector of the left neighboring block, the scaled motion vector of the upper neighboring block, the scaled motion vector of the upper right neighboring block, the scaled motion vector of the lower left neighboring block, And may be sequentially added to the MVP candidate list in the order of the scaled motion vectors of the upper left neighboring blocks.
  • the encoding apparatus can determine whether any one of a skip mode, a merge mode, and an adaptive motion vector prediction (AMVP) mode is applied to the current block, and the prediction mode information of the current block Can be generated.
  • the prediction mode information may indicate whether one of a skip mode, a merge mode, and an adaptive motion vector prediction (AMVP) mode is applied to the current block.
  • the information on the inter prediction of the current block may include the prediction mode information.
  • the encoding apparatus derives the costs for the MVP candidates included in the MVP candidate list (S1310).
  • the encoding apparatus can derive the costs for the MVP candidates.
  • the cost of the MVP candidate may be derived as a Sum of Absolute Difference (SAD) between the template of the current block and the template of the reference block for the MVP candidate.
  • the reference block may indicate a reference block indicated by the MVP candidate. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the reference block with respect to the MVP candidate.
  • SAD Sum of Absolute Difference
  • the cost can be derived based on Equation (1).
  • the template of the current block may include an upper template and a left template
  • the cost may be derived as a sum of an upper cost and a left cost.
  • the upper cost may be derived as an SAD between an upper template of the current block and an upper template of the reference block with respect to the MVP candidate and the left cost may be derived by adding the left cost of the reference block to the left template of the current block and the reference block Can be derived as the SAD with the left template of FIG.
  • the template of the current block is the (-n, 0) coordinate
  • the upper template including the upper left sample, the upper template having the nxH size and the upper left sample of (0, -n), and having the Wxn size.
  • n may represent a value indicated by size information on the template.
  • the encoding apparatus can determine the size for the template and generate size information for the template.
  • the information on the inter prediction may include size information on the template.
  • the upper cost may be derived as a value obtained by normalizing the SAD between the upper template of the current block and the upper template of the reference block with respect to the MVP candidate by the size of the upper template
  • the cost can be derived by normalizing the SAD between the left template of the current block and the left template of the reference block with respect to the MVP candidate to the size of the left template.
  • the left cost and the upper cost can be derived based on Equation (5).
  • the cost of the MVP candidate may be derived as the sum of the upper cost of the MVP candidate and the left cost of the MVP candidate
  • the upper cost of the MVP candidate may be the sum of the upper cost of the MVP candidate and the cost of the MVP candidate
  • the left cost of the MVP candidate may be derived based on the left luma cost of the MVP candidate and the left chroma cost of the MVP candidate.
  • the upper luma cost of the MVP candidate may be derived as a Sum of Absolute Difference (SAD) between an upper template of a luma block of the current block and an upper template of a chroma block of a reference block for the MVP candidate
  • the upper chroma cost of the current block can be derived as the SAD between the upper template of the chroma block of the current block and the upper template of the chroma block of the reference block with respect to the MVP candidate.
  • the upper cost of the MVP candidate can be derived based on the following equation.
  • LX, L may represent the upper cost of the luma block of the current block
  • costA (LX, C) may represent the upper cost of the MVP candidate
  • W L may represent the width of the luma block of the current block
  • W C may represent the width of the chroma block of the current block
  • w can represent a weighting factor.
  • the weighting coefficient may be set to a value of 0.5 or more and 1 or less.
  • the left luma cost of the MVP candidate may be derived as a sum of absolute differences (SAD) between the left template of the luma block of the current block and the left template of the chroma block of the reference block for the MVP candidate,
  • the left chroma cost of the MVP candidate can be derived as the SAD between the left template of the chroma block of the current block and the left template of the chroma block of the reference block with respect to the MVP candidate.
  • the left cost of the MVP candidate may be derived based on the following equation.
  • costL (LX) represents the left cost of the MVP candidate
  • costL (LX, L) represents the left cost of the luma block of the current block
  • costL H L may represent the height of the luma block of the current block
  • H C may represent the height of the chroma block of the current block
  • w may represent a weighting factor.
  • the weighting coefficient may be set to a value of 0.5 or more and 1 or less.
  • the luma cost may be derived as IC_SAD. If the LIC is not applied to the current block, the luma cost may be derived based on Equation (1).
  • the IC_SAD can be derived based on the following equation.
  • Cur may represent a reconstructed sample included in a template of a luma block of the current block
  • Ref may represent a reconstructed sample included in a template of a luma block of a reference block for the MVP candidate
  • the width of the luma block of the current block, and H may represent the height of the luma block of the current block.
  • the chroma cost can be derived by the IC_SAD.
  • the chroma cost may be derived to a value different from the luma cost.
  • the chroma cost may be derived based on Equation (1).
  • the encoding apparatus may generate an LIC flag indicating whether the LIC is applied to the current block. For example, if the value of the LIC flag is 1, the LIC flag may indicate that the LIC is applied to the current block, and if the value of the LIC flag is 0, It may indicate that the LIC is not applied.
  • the encoding device derives the modified MVP candidate list based on the costs for the MVP candidates (S1320).
  • the encoding apparatus can derive the reordered MVP candidate list by rearranging the MVP candidates in descending order of costs, derive refinement MVP candidates based on the specific MVP candidate among the MVP candidates, An MVP candidate may be added to the reordered MVP candidate list to derive the modified MVP candidate list.
  • the encoding device may derive the modified MVP candidate list by rearranging the MVP candidates in descending order of cost.
  • the encoding device may derive a refinement MVP candidate based on a specific MVP candidate of the MVP candidates in the MVP candidate list, and add the refined MVP candidate to the MVP candidate list to derive the modified MVP candidate list .
  • the cost for the MVP candidate may include luma cost and chroma cost, and the luma cost and chroma cost may be derived to different values.
  • a modified MVP candidate list for the luma block of the current block may be derived based on the luma cost
  • a modified MVP candidate list for the chroma block of the current block may be derived based on the chroma cost .
  • the encoding apparatus can derive MVP candidate lists that are rearranged by rearranging the MVP candidates included in the MVP candidate list for the luma block of the current block in order of smaller luma cost, and obtain a specific MVP candidate among the MVP candidates , And derive the modified MVP candidate list for the luma block by adding the refined MVP candidate to the reordered MVP candidate list.
  • the encoding apparatus may derive MVP candidate lists rearranged by rearranging MVP candidates included in the MVP candidate list for the chroma block of the current block in order of smaller chroma cost, , And derive the modified MVP candidate list for the chroma block by adding the refined MVP candidate to the reordered MVP candidate list.
  • the MVP candidates may be derived as the specific MVP candidate in the order of rearrangement.
  • the MVP candidate having the smallest cost among the MVP candidates may be derived as the specific MVP candidate.
  • the refinement MVP candidate can be derived as follows.
  • the encoding apparatus may derive a template having the smallest cost from the template of the current block among the templates of the reference blocks in the search range, and determine a motion vector indicating a reference block of the derived template as the refine MVP candidate .
  • the search range may be an integer pel range around the position indicated by the specific MVP candidate.
  • the search range may be a range of two integers around the location indicated by the particular MVP candidate.
  • the search range may be a half integer pel range around the location indicated by the particular MVP candidate.
  • the search range may be set to a range other than the above-described examples.
  • the encoding device may add the refined MVP candidate to the reordered MVP candidate list to derive the modified MVP candidate list.
  • the refinement MVP candidate may be added to the modified MVP candidate list in the order preceding the specific MVP candidate.
  • the refinement MVP candidate is added to the modified MVP candidate list, the MVP candidates of the modified MVP candidate list may be rearranged.
  • the refinement MVP candidate is the MVP candidate in the first order of the modified MVP candidate list, the MVP candidates other than the refined MVP candidate may be rearranged in the order of the MVP candidate list.
  • the encoding apparatus can determine whether the MVP candidate of the modified MVP candidate list indicates the same motion vector as the MVP candidate in the previous order. If the MVP candidate indicates the same motion vector as the MVP candidate in the previous order, the MVP candidate may be removed from the modified MVP candidate list. The encoding apparatus can determine whether or not the MVP candidate of the modified MVP candidate list indicates the same motion vector as the MVP candidate of the previous order. Alternatively, the encoding apparatus may determine whether or not the refinement MVP candidate represents the same motion vector as the MVP candidate of the preceding sequence. Alternatively, the encoding apparatus may determine whether or not the motion vector indicates the same motion vector as the MVP candidate in the previous order with respect to the reordered MVP candidate.
  • the rearranged MVP candidates may be MVP candidates whose order in the MVP candidate list is different from the order in the rearranged MVP candidate list.
  • the encoding apparatus derives MVP of the current block based on the modified MVP candidate list (S1330).
  • the encoding apparatus can select one MVP candidate of the MVP candidate list of the modified MVP candidate list and derive the motion vector represented by the selected MVP candidate as the MVP of the current block.
  • the encoding apparatus may generate an MVP index indicating the selected MVP candidate among MVP candidates included in the modified MVP candidate list.
  • the information on the inter prediction may include the MVP index.
  • the encoding apparatus derives a motion vector of the current block based on the MVP of the current block (S1340).
  • the encoding apparatus can derive a motion vector of the current block and generate a motion vector difference (MVD) of the current block based on the MVP.
  • the information on the inter prediction may include the MVD.
  • the encoding apparatus may derive the motion vector of the current block through addition of the MVP and the MVD.
  • the encoding apparatus predicts the current block based on the motion vector of the current block (S1350).
  • a prediction block of the current block may be derived based on the motion vector, and a reconstruction block may be derived based on the prediction block.
  • the encoding apparatus may derive a reference block in the reference picture of the current block based on the motion vector.
  • the encoding apparatus can derive a specific reference picture included in a specific reference picture list as a reference picture of the current block and derive a block indicated by the motion vector in the reference picture as a reference block of the current block.
  • the encoding apparatus may generate a prediction sample based on the reference block.
  • the encoding apparatus can generate a reference picture index indicating a reference picture of the current block.
  • the information about the inter prediction of the current block may include the reference picture index.
  • the encoding apparatus can generate residual samples based on the original sample and the generated prediction sample.
  • the encoding apparatus may generate information on the residual based on the residual samples.
  • the information on the residual may include transform coefficients relating to the residual sample.
  • the encoding apparatus may derive the reconstructed sample based on the prediction sample and the residual sample. That is, the encoding apparatus may add the prediction sample and the residual sample to derive the reconstructed sample.
  • the encoding apparatus can encode the information on the residual and output it in the form of a bit stream.
  • the bitstream may be transmitted to a decoding device via a network or a storage medium.
  • the encoding apparatus encodes the information about the inter prediction of the current block (S1360).
  • the encoding apparatus can generate an MVP index indicating an MVP candidate selected to derive the MVP of the current block.
  • the encoding apparatus can encode and output the MVP index.
  • the information on the inter prediction may include the MVP index.
  • the encoding apparatus may generate a reference picture index of the current block, and the information on the inter prediction may include the reference picture index.
  • the encoding apparatus may generate the MVD of the current block, and the information on the inter prediction may include the MVD.
  • the information on the inter prediction may include the reference picture index.
  • the encoding apparatus can generate the LIC flag of the current block, and the information on the inter prediction can include the LIC flag.
  • the encoding apparatus may generate information on the residual based on the residual samples.
  • the information on the residual may include transform coefficients relating to the residual sample.
  • the encoding apparatus may encode the information on the residual and output the encoded information in the form of a bit stream.
  • the bitstream may be transmitted to a decoding device via a network or a storage medium.
  • FIG. 14 schematically shows an encoding apparatus for performing a video encoding method according to the present invention.
  • the method disclosed in Fig. 13 can be performed by the encoding apparatus disclosed in Fig. Specifically, for example, the predicting unit of the encoding apparatus of FIG. 14 may perform S1300 to S1350 of FIG. 13, and the entropy encoding unit of the encoding apparatus may perform S1360 of FIG.
  • FIG. 15 schematically shows a video decoding method by a decoding apparatus according to the present invention.
  • the method disclosed in Fig. 15 can be performed by the decoding apparatus disclosed in Fig. Specifically, for example, S1500 in FIG. 15 may be performed by the entropy decoding unit of the decoding apparatus, and S1510 to S1560 may be performed by the predicting unit of the decoding apparatus.
  • the decoding apparatus obtains information on inter prediction of the current block through the bit stream (S1500).
  • the decoding apparatus may obtain information on inter prediction of the current block through a bit stream.
  • the information on the inter prediction may include prediction mode information indicating whether a skip mode, a merge mode, or an adaptive motion vector prediction (AMVP) mode is applied to the current block.
  • AMVP adaptive motion vector prediction
  • the decoding apparatus can construct a motion vector predictor (MVP) candidate list based on neighboring blocks of the current block, and the MVP candidate list includes MVP candidates
  • An MVP index (merge index) indicating a candidate can be obtained.
  • the information on the inter prediction may include the MVP index.
  • the information on the inter prediction may include a motion vector difference (MVD).
  • the information on the inter prediction may include a reference picture index of the current block.
  • the reference picture index may indicate a specific reference picture included in a specific reference picture list, and the specific reference picture may be derived as a reference picture of the current block.
  • the specific reference picture list may be a reference picture list L0 (List 0) or a reference picture list L1 (List 1).
  • the decoding apparatus constructs an MVP candidate list based on the neighboring blocks of the current block (S1510).
  • the neighboring block may include a left neighbor block, an upper neighbor block, an upper right neighbor block, a lower left neighbor block, and a left upper neighbor block.
  • the neighboring block may include a co-located block including a position in a reference picture corresponding to a lower right position or a center position of the current block.
  • the left neighboring block is the upper left corner of the (-1, H-1)
  • the upper left neighbor block is a block including a left upper sample of the (W-1, -1) coordinate
  • the upper right neighbor block is a block including a left upper sample of the (W, )
  • the lower left neighboring block is a block including upper left samples of the (-1, H) coordinate
  • the upper left neighboring block is a block including upper left samples of (-1, -1) coordinates.
  • the decoding apparatus may determine the motion vector of the left neighboring block, the motion vector of the upper neighboring block, the motion vector of the upper right neighboring block, the motion vector of the lower left neighboring block, It is possible to judge the validity, and a valid motion vector can be sequentially added to the MVP candidate list as an MVP candidate.
  • the validity of the motion vector of the neighboring block may be determined as follows. Specifically, it may be sequentially determined whether a motion vector of the neighboring block corresponds to a first motion vector or a second motion vector, and if the motion vector of the neighboring block is the first motion vector and the second motion vector, , It can be determined that the motion vector of the neighboring block is not valid.
  • the first motion vector is a motion vector for the specific reference picture included in the specific reference picture list
  • the second motion vector is a motion vector for the specific reference picture included in the reference picture list May be a motion vector.
  • the motion vector may be scaled, and a scaled motion vector may be added to the MVP candidate list with the MVP candidate.
  • the decoding apparatus may construct an MVP candidate list including the maximum number of MVP candidates based on the neighboring blocks.
  • the maximum number of MVP candidates included in the MVP candidate list may be five.
  • the decoding apparatus scales the scaled motion vector of the left neighboring block of the current block, the scaled motion vector of the upper neighboring block, The MVP candidate list including the maximum number of MVP candidates based on the scaled motion vector of the lower left neighboring block, the scaled motion vector of the lower left neighboring block, and the scaled motion vector of the upper left neighboring block.
  • the scaled motion vector of the left neighboring block, the scaled motion vector of the upper neighboring block, the scaled motion vector of the upper right neighboring block, the scaled motion vector of the lower left neighboring block, And may be sequentially added to the MVP candidate list in the order of the scaled motion vectors of the upper left neighboring blocks.
  • the decoding apparatus derives the costs for the MVP candidates included in the MVP candidate list (S1520).
  • the decoding device may derive the costs for the MVP candidates.
  • the cost of the MVP candidate may be derived as a Sum of Absolute Difference (SAD) between the template of the current block and the template of the reference block for the MVP candidate.
  • the reference block may indicate a reference block indicated by the MVP candidate. That is, the cost may be derived as a Sum of Absolute Difference (SAD) of the difference between the template of the current block and the corresponding sample of the template of the reference block with respect to the MVP candidate.
  • SAD Sum of Absolute Difference
  • the cost can be derived based on Equation (1).
  • the template of the current block may include an upper template and a left template
  • the cost may be derived as a sum of an upper cost and a left cost.
  • the upper cost may be derived as an SAD between an upper template of the current block and an upper template of the reference block with respect to the MVP candidate and the left cost may be derived by adding the left cost of the reference block to the left template of the current block and the reference block Can be derived as the SAD with the left template of FIG.
  • the template of the current block is the (-n, 0) coordinate
  • the upper template including the upper left sample, the upper template having the nxH size and the upper left sample of (0, -n), and having the Wxn size.
  • n may represent a value indicated by size information on the template.
  • the decoding apparatus can obtain size information on the template through a bit stream.
  • the information on the inter prediction may include the size information.
  • the upper cost may be derived as a value obtained by normalizing the SAD between the upper template of the current block and the upper template of the reference block with respect to the MVP candidate by the size of the upper template
  • the cost can be derived by normalizing the SAD between the left template of the current block and the left template of the reference block with respect to the MVP candidate to the size of the left template.
  • the left cost and the upper cost can be derived based on Equation (5).
  • the cost of the MVP candidate may be derived as the sum of the upper cost of the MVP candidate and the left cost of the MVP candidate
  • the upper cost of the MVP candidate may be the sum of the upper cost of the MVP candidate and the cost of the MVP candidate
  • the left cost of the MVP candidate may be derived based on the left luma cost of the MVP candidate and the left chroma cost of the MVP candidate.
  • the upper luma cost of the MVP candidate may be derived as a Sum of Absolute Difference (SAD) between an upper template of a luma block of the current block and an upper template of a chroma block of a reference block for the MVP candidate
  • the upper chroma cost of the current block can be derived as the SAD between the upper template of the chroma block of the current block and the upper template of the chroma block of the reference block with respect to the MVP candidate.
  • the upper cost of the MVP candidate can be derived based on the following equation.
  • LX, L may represent the upper cost of the luma block of the current block
  • costA (LX, C) may represent the upper cost of the MVP candidate
  • W L may represent the width of the luma block of the current block
  • W C may represent the width of the chroma block of the current block
  • w can represent a weighting factor.
  • the weighting coefficient may be set to a value of 0.5 or more and 1 or less.
  • the left luma cost of the MVP candidate may be derived as a sum of absolute differences (SAD) between the left template of the luma block of the current block and the left template of the chroma block of the reference block for the MVP candidate,
  • the left chroma cost of the MVP candidate can be derived as the SAD between the left template of the chroma block of the current block and the left template of the chroma block of the reference block with respect to the MVP candidate.
  • the left cost of the MVP candidate may be derived based on the following equation.
  • costL (LX) represents the left cost of the MVP candidate
  • costL (LX, L) represents the left cost of the luma block of the current block
  • costL H L may represent the height of the luma block of the current block
  • H C may represent the height of the chroma block of the current block
  • w may represent a weighting factor.
  • the weighting coefficient may be set to a value of 0.5 or more and 1 or less.
  • the information on the inter prediction may include the LIC flag
  • the cost of the MVP candidate may include luma cost and chroma cost. If the value of the LIC flag is 1, the luma cost can be derived as IC_SAD. If the value of the LIC flag is 0, the luma cost can be derived based on Equation (1).
  • the IC_SAD can be derived based on the following equation.
  • Cur may represent a reconstructed sample included in a template of a luma block of the current block
  • Ref may represent a reconstructed sample included in a template of a luma block of a reference block for the MVP candidate
  • the width of the luma block of the current block, and H may represent the height of the luma block of the current block.
  • the chroma cost can be derived by the IC_SAD.
  • the chroma cost may be derived to a value different from the luma cost.
  • the chroma cost may be derived based on Equation (1).
  • the decoding apparatus derives the modified MVP candidate list based on the costs for the MVP candidates (S1530).
  • the decoding apparatus may derive the reordered MVP candidate list by rearranging the MVP candidates in descending order of costs, derive refinement MVP candidates based on the specific MVP candidate among the MVP candidates, An MVP candidate may be added to the reordered MVP candidate list to derive the modified MVP candidate list.
  • the decoding apparatus may derive the modified MVP candidate list by rearranging the MVP candidates in descending order of cost.
  • the decoding apparatus may derive a refinement MVP candidate based on a specific MVP candidate among the MVP candidates of the MVP candidate list, and add the refinement MVP candidate to the MVP candidate list to derive the modified MVP candidate list .
  • the cost for the MVP candidate may include luma cost and chroma cost, and the luma cost and chroma cost may be derived to different values.
  • a modified MVP candidate list for the luma block of the current block may be derived based on the luma cost
  • a modified MVP candidate list for the chroma block of the current block may be derived based on the chroma cost .
  • the decoding apparatus can derive MVP candidate lists that are rearranged by rearranging the MVP candidates included in the MVP candidate list for the luma block of the current block in order of smaller luma cost, and obtain a specific MVP candidate among the MVP candidates , And derive the modified MVP candidate list for the luma block by adding the refined MVP candidate to the reordered MVP candidate list.
  • the decoding apparatus can derive MVP candidate lists rearranged by rearranging the MVP candidates included in the MVP candidate list for the chroma block of the current block in descending order of chroma cost, , And derive the modified MVP candidate list for the chroma block by adding the refined MVP candidate to the reordered MVP candidate list.
  • the MVP candidates may be derived as the specific MVP candidate in the order of rearrangement.
  • the MVP candidate having the smallest cost among the MVP candidates may be derived as the specific MVP candidate.
  • the refinement MVP candidate can be derived as follows.
  • the decoding apparatus can derive a template having the smallest cost from the template of the current block among the templates of the reference blocks in the search range, and outputs a motion vector indicating the reference block of the derived template to the refine MVP candidate .
  • the search range may be an integer pel range around the position indicated by the specific MVP candidate.
  • the search range may be a range of two integers around the location indicated by the particular MVP candidate.
  • the search range may be a half integer pel range around the location indicated by the particular MVP candidate.
  • the search range may be set to a range other than the above-described examples.
  • the decoding device may add the refined MVP candidate to the reordered MVP candidate list to derive the modified MVP candidate list.
  • the refinement MVP candidate may be added to the modified MVP candidate list in the order preceding the specific MVP candidate.
  • the refinement MVP candidate is added to the modified MVP candidate list, the MVP candidates of the modified MVP candidate list may be rearranged.
  • the refinement MVP candidate is the MVP candidate in the first order of the modified MVP candidate list, the MVP candidates other than the refined MVP candidate may be rearranged in the order of the MVP candidate list.
  • the decoding apparatus can determine whether or not the MVP candidate of the modified MVP candidate list indicates the same motion vector as the MVP candidate of the previous order. If the MVP candidate indicates the same motion vector as the MVP candidate in the previous order, the MVP candidate may be removed from the modified MVP candidate list. The decoding apparatus can determine whether or not the MVP candidate of the modified MVP candidate list indicates the same motion vector as the MVP candidate of the previous order. Alternatively, the decoding apparatus can determine whether or not the refinement MVP candidate indicates the same motion vector as the MVP candidate in the preceding order. Alternatively, the decoding apparatus can determine whether or not the MVP candidate is the same motion vector as the MVP candidate in the previous order.
  • the rearranged MVP candidates may be MVP candidates whose order in the MVP candidate list is different from the order in the rearranged MVP candidate list.
  • the decoding apparatus derives the MVP of the current block based on the modified MVP candidate list (S1540).
  • the decoding apparatus can select one MVP candidate of the MVP candidate list of the modified MVP candidate list and derive the motion vector represented by the selected MVP candidate as the MVP of the current block.
  • the decoding apparatus may obtain an MVP index indicating a MVP candidate of MVP candidates included in the modified MVP candidate list through a bitstream.
  • the information on the inter prediction may include the MVP index.
  • the decoding apparatus may derive a MVP candidate motion vector indicated by the MVP index among the MVP candidates of the modified MVP candidate list as the MVP of the current block.
  • the decoding apparatus derives a motion vector of the current block based on the MVP and the motion vector difference (MVD) of the current block (S1550).
  • the decoding apparatus can obtain the MVD of the current block through a bitstream.
  • the information on the inter prediction may include the MVD.
  • the decoding apparatus may derive the motion vector of the current block through addition of the MVP and the MVD.
  • the decoding apparatus predicts the current block based on the reference picture index of the current block and the motion vector (S1560).
  • a prediction block of the current block may be derived based on the reference picture index of the current block and the motion vector, and a reconstruction block may be derived based on the prediction block.
  • the decoding apparatus may derive a reference block reference block based on the reference picture index and the motion vector of the current block.
  • the decoding apparatus may derive a specific reference picture included in the specific reference picture list pointed to by the reference picture index as a reference picture of the current block and set a block indicated by the motion vector in the reference picture as a reference block of the current block .
  • the decoding apparatus may generate a prediction sample based on the reference block and may use the prediction sample directly as a reconstruction sample according to a prediction mode or may add a residual sample to the prediction sample to generate a reconstruction sample .
  • the decoding apparatus may obtain information on the residual for the current block from the bitstream if there is a residual sample for the current block.
  • the information on the residual may include a transform coefficient relating to the residual sample.
  • the decoding apparatus may derive the residual sample (or residual sample array) for the current block based on the residual information.
  • the decoding apparatus may generate a reconstructed sample based on the prediction sample and the residual sample, and may derive a reconstructed block or a reconstructed picture based on the reconstructed sample.
  • an in-loop filtering procedure such as deblocking filtering and / or SAO procedure to the restored picture in order to improve subjective / objective picture quality as necessary.
  • FIG. 16 schematically shows a decoding apparatus for performing an image decoding method according to the present invention.
  • the method disclosed in Fig. 15 can be performed by the decoding apparatus disclosed in Fig.
  • the entropy decoding unit of the decoding apparatus of FIG. 16 may perform S1500 of FIG. 15, and the predicting unit of the decoding apparatus of FIG. 16 may perform S1510 to S1560 of FIG.
  • the MVP candidate list including various MVP candidates can be derived based on the neighboring blocks, thereby improving the prediction accuracy, reducing the bit amount for MVD transmission and improving the overall coding efficiency have.
  • the optimal MVP candidates for the current block can be rearranged in the order indicated by the MVP index with a small value, thereby reducing the bit amount for prediction and improving the overall coding efficiency .
  • the cost considering the luma component and the chroma component of the current block can be derived, and the optimal MVP candidate list for the current block can be constructed based on the cost, Improve prediction accuracy and efficiency, and improve overall coding efficiency.
  • the above-described method according to the present invention can be implemented in software, and the encoding apparatus and / or decoding apparatus according to the present invention can perform image processing of, for example, a TV, a computer, a smart phone, a set- Device.
  • the above-described method may be implemented by a module (a process, a function, and the like) that performs the above-described functions.
  • the module is stored in memory and can be executed by the processor.
  • the memory may be internal or external to the processor and may be coupled to the processor by any of a variety of well known means.
  • the processor may comprise an application-specific integrated circuit (ASIC), other chipset, logic circuitry and / or a data processing device.
  • the memory may include read-only memory (ROM), random access memory (RAM), flash memory, memory cards, storage media, and / or other storage devices. That is, the embodiments described in the present invention can be implemented and executed on a processor, a microprocessor, a controller, or a chip.
  • the functional units depicted in the figures may be implemented and implemented on a computer, processor, microprocessor, controller, or chip.
  • the decoding apparatus and encoding apparatus to which the present invention is applied include a multimedia broadcasting transmitting and receiving apparatus, a mobile communication terminal, a home cinema video apparatus, a digital cinema video apparatus, a surveillance camera, a video chatting apparatus, (3D) video device, a video telephone video device, a medical video device, and the like, for example, a device, a storage medium, a camcorder, a video-on-demand (VoD) service providing device, an OTT video over the top video device, And may be used to process video signals or data signals.
  • the OTT video (Over the top video) device may include a game console, a Blu-ray player, an Internet access TV, a home theater system, a smart phone, a tablet PC, a DVR (Digital Video Recorder)
  • the processing method to which the present invention is applied may be produced in the form of a computer-executed program, and may be stored in a computer-readable recording medium.
  • the multimedia data having the data structure according to the present invention can also be stored in a computer-readable recording medium.
  • the computer-readable recording medium includes all kinds of storage devices and distributed storage devices in which computer-readable data is stored.
  • the computer-readable recording medium may be, for example, a Blu-ray Disc (BD), a Universal Serial Bus (USB), a ROM, a PROM, an EPROM, an EEPROM, a RAM, a CD- Data storage devices.
  • the computer-readable recording medium includes media implemented in the form of a carrier wave (for example, transmission over the Internet).
  • bit stream generated by the encoding method can be stored in a computer-readable recording medium or transmitted over a wired or wireless communication network.
  • an embodiment of the present invention may be embodied as a computer program product by program code, and the program code may be executed in a computer according to an embodiment of the present invention.
  • the program code may be stored on a carrier readable by a computer.
  • the content streaming system to which the present invention is applied may include an encoding server, a streaming server, a web server, a media repository, a user device, and a multimedia input device.
  • the encoding server compresses content input from multimedia input devices such as a smart phone, a camera, and a camcorder into digital data to generate a bit stream and transmit the bit stream to the streaming server.
  • multimedia input devices such as a smart phone, a camera, a camcorder, or the like directly generates a bitstream
  • the encoding server may be omitted.
  • the bitstream may be generated by an encoding method or a bitstream generating method to which the present invention is applied, and the streaming server may temporarily store the bitstream in the process of transmitting or receiving the bitstream.
  • the streaming server transmits multimedia data to a user device based on a user request through the web server, and the web server serves as a medium for informing the user of what services are available.
  • the web server delivers it to the streaming server, and the streaming server transmits the multimedia data to the user.
  • the content streaming system may include a separate control server. In this case, the control server controls commands / responses among the devices in the content streaming system.
  • the streaming server may receive content from a media repository and / or an encoding server. For example, when receiving the content from the encoding server, the content can be received in real time. In this case, in order to provide a smooth streaming service, the streaming server can store the bit stream for a predetermined time.
  • Examples of the user device include a mobile phone, a smart phone, a laptop computer, a digital broadcasting terminal, a personal digital assistant (PDA), a portable multimedia player (PMP), a navigation device, a slate PC, Such as tablet PCs, ultrabooks, wearable devices (e.g., smartwatches, smart glass, HMDs (head mounted displays)), digital TVs, desktops Computers, and digital signage.
  • PDA personal digital assistant
  • PMP portable multimedia player
  • slate PC Such as tablet PCs, ultrabooks, wearable devices (e.g., smartwatches, smart glass, HMDs (head mounted displays)), digital TVs, desktops Computers, and digital signage.
  • Each of the servers in the content streaming system can be operated as a distributed server. In this case, data received at each server can be distributed.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

본 발명에 따른 디코딩 장치에 의하여 수행되는 영상 디코딩 방법은 비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득하는 단계, 상기 현재 블록의 주변 블록을 기반으로 MVP 후보 리스트를 구성하는 단계, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하는 단계, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하는 단계, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하는 단계, 상기 현재 블록의 상기 MVP 및 MVD를 기반으로 상기 현재 블록의 움직임 벡터를 도출하는 단계, 및 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 단계를 포함하되, 상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스 및 상기 MVD를 포함하는 것을 특징으로 한다.

Description

영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치
본 발명은 영상 코딩 기술에 관한 것으로서 보다 상세하게는 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치에 관한 것이다.
최근 HD(High Definition) 영상 및 UHD(Ultra High Definition) 영상과 같은 고해상도, 고품질의 영상에 대한 수요가 다양한 분야에서 증가하고 있다. 영상 데이터가 고해상도, 고품질이 될수록 기존의 영상 데이터에 비해 상대적으로 전송되는 정보량 또는 비트량이 증가하기 때문에 기존의 유무선 광대역 회선과 같은 매체를 이용하여 영상 데이터를 전송하거나 기존의 저장 매체를 이용해 영상 데이터를 저장하는 경우, 전송 비용과 저장 비용이 증가된다.
이에 따라, 고해상도, 고품질 영상의 정보를 효과적으로 전송하거나 저장하고, 재생하기 위해 고효율의 영상 압축 기술이 요구된다.
본 발명의 기술적 과제는 영상 코딩 효율을 높이는 방법 및 장치를 제공함에 있다.
본 발명의 다른 기술적 과제는 현재 블록의 주변 블록의 움직임 벡터를 기반으로 다양한 MVP 후보를 포함하는 MVP 후보 리스트를 도출하고, 도출된 MVP 후보 리스트를 기반으로 상기 현재 블록에 대한 예측을 수행하는 영상 디코딩 방법 및 장치를 제공함에 있다.
본 발명의 다른 기술적 과제는 MVP 후보에 대한 코스트를 도출하고 코스트를 기반으로 MVP 후보 리스트를 재정렬하여 도출된 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록에 대한 예측을 수행하는 영상 디코딩 방법 및 장치를 제공함에 있다.
본 발명의 다른 기술적 과제는 현재 블록의 루마 성분 및 크로마 성분으로 고려하여 MVP 후보에 대한 코스트를 도출하고 코스트를 기반으로 MVP 후보 리스트를 재정렬하여 도출된 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록에 대한 예측을 수행하는 영상 디코딩 방법 및 장치를 제공함에 있다.
본 발명의 다른 기술적 과제는 MVP 후보에 대한 리파인먼트(refinement) 과정을 수행하여 도출된 리파인 MVP 후보를 추가한 MVP 후보 리스트를 기반으로 상기 현재 블록에 대한 예측을 수행하는 영상 디코딩 방법 및 장치를 제공함에 있다.
본 발명의 일 실시예에 따르면, 디코딩 장치에 의하여 수행되는 영상 디코딩 방법이 제공된다. 상기 방법은 비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득하는 단계, 상기 현재 블록의 주변 블록을 기반으로 MVP 후보 리스트를 구성하는 단계, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하는 단계, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하는 단계, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하는 단계, 상기 현재 블록의 상기 MVP 및 MVD를 기반으로 상기 현재 블록의 움직임 벡터를 도출하는 단계, 및 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 단계를 포함하되, 상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스 및 상기 MVD를 포함하는 것을 특징으로 한다.
본 발명의 다른 일 실시예에 따르면, 영상 디코딩을 수행하는 디코딩 장치가 제공된다. 상기 디코딩 장치는 비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득하는 엔트로피 디코딩부, 및 상기 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하고, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하고, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하고, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하고, 상기 현재 블록의 상기 MVP 및 MVD(motion vector difference)를 기반으로 상기 현재 블록의 움직임 벡터를 도출하고, 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 예측부를 포함하되, 상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스 및 상기 MVD를 포함하는 것을 특징으로 한다.
본 발명의 또 다른 일 실시예에 따르면, 인코딩 장치에 의하여 수행되는 비디오 인코딩 방법을 제공한다. 상기 방법은 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하는 단계, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하는 단계, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하는 단계, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하는 단계, 상기 현재 블록의 상기 MVP 를 기반으로 상기 현재 블록의 움직임 벡터를 도출하는 단계, 상기 현재 블록의 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 단계, 및 상기 현재 블록의 인터 예측에 대한 정보를 인코딩하는 단계를 포함하되, 상기 인터 예측에 대한 정보는 상기 현재 블록의 참조 픽처를 가리키는 참조 픽처 인덱스 및 MVD(motion vector difference)를 포함하는 것을 특징으로 한다.
본 발명의 또 다른 일 실시예에 따르면, 비디오 인코딩 장치를 제공한다. 상기 인코딩 장치는 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하고, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하고, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하고, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하고, 상기 현재 블록의 상기 MVP 를 기반으로 상기 현재 블록의 움직임 벡터를 도출하고, 상기 현재 블록의 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 예측부, 및 상기 현재 블록의 인터 예측에 대한 정보를 인코딩하는 엔트로피 인코딩부를 포함하되, 상기 인터 예측에 대한 정보는 상기 현재 블록의 참조 픽처를 가리키는 참조 픽처 인덱스 및 MVD(motion vector difference)를 포함하는 것을 특징으로 한다.
본 발명에 따르면 주변 블록들을 기반으로 다양한 MVP 후보를 포함한 MVP 후보 리스트를 도출할 수 있고, 이를 통하여, 예측 정확도를 향상시키고 MVD 의 전송을 위한 비트량을 감소시키고 전반적인 코딩 효율을 향상시킬 수 있다.
본 발명에 따르면 코스트를 고려하여 현재 블록에 대한 최적의 MVP 후보가 작은 값의 MVP 인덱스로 나타내는 순서로 재정렬될 수 있고, 이를 통하여, 예측을 위한 비트량을 감소시키고 전반적인 코딩 효율을 향상시킬 수 있다.
본 발명에 따르면 현재 블록의 루마 성분 및 크로마 성분을 고려한 코스트를 도출하고, 상기 코스트를 기반으로 현재 블록에 대한 최적의 MVP 후보 리스트를 구성할 수 있고, 이를 통하여, 루마 성분 및 크로마 성분의 예측 정확도 및 효율을 향상시키고 전반적인 코딩 효율을 향상시킬 수 있다.
본 발명에 따르면 현재 블록의 MVP 후보를 기반으로 최적의 MVP 후보인 리파인 MVP 후보를 도출할 수 있고, 이를 통하여, 예측 정확도 및 효율을 향상시킬 수 있고 전반적인 코딩 효율을 향상시킬 수 있다.
도 1은 본 발명이 적용될 수 있는 비디오 인코딩 장치의 구성을 개략적으로 설명하는 도면이다.
도 2는 본 발명이 적용될 수 있는 비디오 디코딩 장치의 구성을 개략적으로 설명하는 도면이다.
도 3은 상기 ALR 을 통하여 상기 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 4는 상기 템플릿 정합 방법을 통하여 상기 현재 블록의 MVP 후보에 대한 코스트를 도출하는 일 예를 나타낸다.
도 5는 상기 A0 및 상기 A1을 기반으로 상기 MVP 후보 리스트의 MVP 후보를 도출하는 일 예를 나타낸다.
도 6은 기존의 순서를 통하여 상기 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 7은 현재 블록의 주변 블록들을 기반으로 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 8은 템플릿의 위치 및 사이즈에 따른 코스트를 예시적으로 나타낸다.
도 9는 리파인 MVP 후보를 포함하는 수정된 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 10은 템플릿을 기반으로 MVP 후보의 코스트를 도출하는 일 예를 나타낸다.
도 11은 현재 블록과 L0 참조 블록에 대한 코스트L0 와 상기 현재 블록과 L1 참조 블록에 대한 코스트L1을 도출하는 일 예를 나타낸다.
도 12는 상기 코스트L0 및 상기 코스트L1 를 기반으로 수행되는 제한된(restricted) 리파인먼트의 일 예를 나타낸다.
도 13은 본 발명에 따른 인코딩 장치에 의한 비디오 인코딩 방법을 개략적으로 나타낸다.
도 14는 본 발명에 따른 영상 인코딩 방법을 수행하는 인코딩 장치를 개략적으로 나타낸다.
도 15는 본 발명에 따른 디코딩 장치에 의한 비디오 디코딩 방법을 개략적으로 나타낸다.
도 16은 본 발명에 따른 영상 디코딩 방법을 수행하는 디코딩 장치를 개략적으로 나타낸다.
본 발명은 다양한 변경을 가할 수 있고 여러 가지 실시예를 가질 수 있는 바, 특정 실시예들을 도면에 예시하고 상세하게 설명하고자 한다. 그러나, 이는 본 발명을 특정 실시예에 한정하려고 하는 것이 아니다. 본 명세서에서 상용하는 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명의 기술적 사상을 한정하려는 의도로 사용되는 것은 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 명세서에서 "포함하다" 또는 "가지다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성 요소, 부품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성 요소, 부품 도는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.
한편, 본 발명에서 설명되는 도면상의 각 구성들은 서로 다른 특징적인 기능들에 관한 설명의 편의를 위해 독립적으로 도시된 것으로서, 각 구성들이 서로 별개의 하드웨어나 별개의 소프트웨어로 구현된다는 것을 의미하지는 않는다. 예컨대, 각 구성 중 두 개 이상의 구성이 합쳐져 하나의 구성을 이룰 수도 있고, 하나의 구성이 복수의 구성으로 나뉘어질 수도 있다. 각 구성이 통합 및/또는 분리된 실시예도 본 발명의 본질에서 벗어나지 않는 한 본 발명의 권리범위에 포함된다.
이하, 첨부한 도면들을 참조하여, 본 발명의 바람직한 실시예를 보다 상세하게 설명하고자 한다. 이하, 도면상의 동일한 구성 요소에 대해서는 동일한 참조 부호를 사용하고 동일한 구성 요소에 대해서 중복된 설명은 생략한다.
본 명세서에서 픽처(picture)는 일반적으로 특정 시간대의 하나의 영상을 나타내는 단위를 의미하며, 슬라이스(slice)는 코딩에 있어서 픽처의 일부를 구성하는 단위이다. 하나의 픽처는 복수의 슬라이스로 구성될 수 있으며, 필요에 따라서 픽처 및 슬라이스는 서로 혼용되어 사용될 수 있다.
픽셀(pixel) 또는 펠(pel)은 하나의 픽처(또는 영상)을 구성하는 최소의 단위를 의미할 수 있다. 또한, 픽셀에 대응하는 용어로서 '샘플(sample)'이 사용될 수 있다. 샘플은 일반적으로 픽셀 또는 픽셀의 값을 나타낼 수 있으며, 휘도(luma) 성분의 픽셀/픽셀값만을 나타낼 수도 있고, 채도(chroma) 성분의 픽셀/픽셀 값만을 나타낼 수도 있다.
유닛(unit)은 영상 처리의 기본 단위를 나타낸다. 유닛은 픽처의 특정 영역 및 해당 영역에 관련된 정보 중 적어도 하나를 포함할 수 있다. 유닛은 경우에 따라서 블록(block) 또는 영역(area) 등의 용어와 혼용하여 사용될 수 있다. 일반적인 경우, MxN 블록은 M개의 열과 N개의 행으로 이루어진 샘플들 또는 변환 계수(transform coefficient)들의 집합을 나타낼 수 있다.
도 1은 본 발명이 적용될 수 있는 비디오 인코딩 장치의 구성을 개략적으로 설명하는 도면이다.
도 1을 참조하면, 비디오 인코딩 장치(100)는 픽처 분할부(105), 예측부(110), 레지듀얼 처리부(120), 엔트로피 인코딩부(130), 가산부(140), 필터부(150) 및 메모리(160)을 포함할 수 있다. 레지듀얼 처리부(120)는 감산부(121), 변환부(122), 양자화부(123), 재정렬부(124), 역양자화부(125) 및 역변환부(126)를 포함할 수 있다.
픽처 분할부(105)는 입력된 픽처를 적어도 하나의 처리 유닛(processing unit)으로 분할할 수 있다.
일 예로, 처리 유닛은 코딩 유닛(coding unit, CU)이라고 불릴 수 있다. 이 경우 코딩 유닛은 최대 코딩 유닛(largest coding unit, LCU)으로부터 QTBT (Quad-tree binary-tree) 구조에 따라 재귀적으로(recursively) 분할될 수 있다. 예를 들어, 하나의 코딩 유닛은 쿼드 트리 구조 및/또는 바이너리 트리 구조를 기반으로 하위(deeper) 뎁스의 복수의 코딩 유닛들로 분할될 수 있다. 이 경우 예를 들어 쿼드 트리 구조가 먼저 적용되고 바이너리 트리 구조가 나중에 적용될 수 있다. 또는 바이너리 트리 구조가 먼저 적용될 수도 있다. 더 이상 분할되지 않는 최종 코딩 유닛을 기반으로 본 발명에 따른 코딩 절차가 수행될 수 있다. 이 경우 영상 특성에 따른 코딩 효율 등을 기반으로, 최대 코딩 유닛이 바로 최종 코딩 유닛으로 사용될 수 있고, 또는 필요에 따라 코딩 유닛은 재귀적으로(recursively) 보다 하위 뎁스의 코딩 유닛들로 분할되어 최적의 사이즈의 코딩 유닛이 최종 코딩 유닛으로 사용될 수 있다. 여기서 코딩 절차라 함은 후술하는 예측, 변환, 및 복원 등의 절차를 포함할 수 있다.
다른 예로, 처리 유닛은 코딩 유닛(coding unit, CU) 예측 유닛(prediction unit, PU) 또는 변환 유닛(transform unit, TU)을 포함할 수도 있다. 코딩 유닛은 최대 코딩 유닛(largest coding unit, LCU)으로부터 쿼드 트리 구조를 따라서 하위(deeper) 뎁스의 코딩 유닛들로 분할(split)될 수 있다. 이 경우 영상 특성에 따른 코딩 효율 등을 기반으로, 최대 코딩 유닛이 바로 최종 코딩 유닛으로 사용될 수 있고, 또는 필요에 따라 코딩 유닛은 재귀적으로(recursively) 보다 하위 뎁스의 코딩 유닛들로 분할되어 최적의 사이즈의 코딩 유닛이 최종 코딩 유닛으로 사용될 수 있다. 최소 코딩 유닛(smallest coding unit, SCU)이 설정된 경우 코딩 유닛은 최소 코딩 유닛보다 더 작은 코딩 유닛으로 분할될 수 없다. 여기서 최종 코딩 유닛이라 함은 예측 유닛 또는 변환 유닛으로 파티셔닝 또는 분할되는 기반이 되는 코딩 유닛을 의미한다. 예측 유닛은 코딩 유닛으로부터 파티셔닝(partitioning)되는 유닛으로서, 샘플 예측의 유닛일 수 있다. 이 때, 예측 유닛은 서브 블록(sub block)으로 나뉠 수도 있다. 변환 유닛은 코딩 유닛으로부터 쿼드 트리 구조를 따라서 분할 될 수 있으며, 변환 계수를 유도하는 유닛 및/또는 변환 계수로부터 레지듀얼 신호(residual signal)를 유도하는 유닛일 수 있다. 이하, 코딩 유닛은 코딩 블록(coding block, CB), 예측 유닛은 예측 블록(prediction block, PB), 변환 유닛은 변환 블록(transform block, TB) 으로 불릴 수 있다. 예측 블록 또는 예측 유닛은 픽처 내에서 블록 형태의 특정 영역을 의미할 수 있고, 예측 샘플의 어레이(array)를 포함할 수 있다. 또한, 변환 블록 또는 변환 유닛은 픽처 내에서 블록 형태의 특정 영역을 의미할 수 있고, 변환 계수 또는 레지듀얼 샘플의 어레이를 포함할 수 있다.
예측부(110)는 처리 대상 블록(이하, 현재 블록이라 함)에 대한 예측을 수행하고, 상기 현재 블록에 대한 예측 샘플들을 포함하는 예측된 블록(predicted block)을 생성할 수 있다. 예측부(110)에서 수행되는 예측의 단위는 코딩 블록일 수 있고, 변환 블록일 수도 있고, 예측 블록일 수도 있다.
예측부(110)는 현재 블록에 인트라 예측이 적용되는지 인터 예측이 적용되는지를 결정할 수 있다. 일 예로, 예측부(110)는 CU 단위로 인트라 예측 또는 인터 예측이 적용되는지를 결정할 수 있다.
인트라 예측의 경우에, 예측부(110)는 현재 블록이 속하는 픽처(이하, 현재 픽처) 내의 현재 블록 외부의 참조 샘플을 기반으로 현재 블록에 대한 예측 샘플을 유도할 수 있다. 이 때, 예측부(110)는 (i) 현재 블록의 주변(neighboring) 참조 샘플들의 평균(average) 혹은 인터폴레이션(interpolation)을 기반으로 예측 샘플을 유도할 수 있고, (ii) 현재 블록의 주변 참조 샘플들 중 예측 샘플에 대하여 특정 (예측) 방향에 존재하는 참조 샘플을 기반으로 상기 예측 샘플을 유도할 수도 있다. (i)의 경우는 비방향성 모드 또는 비각도 모드, (ii)의 경우는 방향성(directional) 모드 또는 각도(angular) 모드라고 불릴 수 있다. 인트라 예측에서 예측 모드는 예를 들어 33개의 방향성 예측 모드와 적어도 2개 이상의 비방향성 모드를 가질 수 있다. 비방향성 모드는 DC 예측 모드 및 플래너 모드(Planar 모드)를 포함할 수 있다. 예측부(110)는 주변 블록에 적용된 예측 모드를 이용하여, 현재 블록에 적용되는 예측 모드를 결정할 수도 있다.
인터 예측의 경우에, 예측부(110)는 참조 픽처 상에서 움직임 벡터에 의해 특정되는 샘플을 기반으로, 현재 블록에 대한 예측 샘플을 유도할 수 있다. 예측부(110)는 스킵(skip) 모드, 머지(merge) 모드, 및 MVP(motion vector prediction) 모드 중 어느 하나를 적용하여 현재 블록에 대한 예측 샘플을 유도할 수 있다. 스킵 모드와 머지 모드의 경우에, 예측부(110)는 주변 블록의 움직임 정보를 현재 블록의 움직임 정보로 이용할 수 있다. 스킵 모드의 경우, 머지 모드와 달리 예측 샘플과 원본 샘플 사이의 차(레지듀얼)가 전송되지 않는다. MVP 모드의 경우, 주변 블록의 움직임 벡터를 움직임 벡터 예측자(Motion Vector Predictor)로 이용하여 현재 블록의 움직임 벡터 예측자로 이용하여 현재 블록의 움직임 벡터를 유도할 수 있다.
인터 예측의 경우에, 주변 블록은 현재 픽처 내에 존재하는 공간적 주변 블록(spatial neighboring block)과 참조 픽처(reference picture)에 존재하는 시간적 주변 블록(temporal neighboring block)을 포함할 수 있다. 상기 시간적 주변 블록을 포함하는 참조 픽처는 동일 위치 픽처(collocated picture, colPic)라고 불릴 수도 있다. 움직임 정보(motion information)는 움직임 벡터와 참조 픽처 인덱스를 포함할 수 있다. 예측 모드 정보와 움직임 정보 등의 정보는 (엔트로피) 인코딩되어 비트스트림 형태로 출력될 수 있다.
스킵 모드와 머지 모드에서 시간적 주변 블록의 움직임 정보가 이용되는 경우에, 참조 픽처 리스트(reference picture list) 상의 최상위 픽처가 참조 픽처로서 이용될 수도 있다. 참조 픽처 리스트(Picture Order Count)에 포함되는 참조 픽처들은 현재 픽처와 해당 참조 픽처 간의 POC(Picture order count) 차이 기반으로 정렬될 수 있다. POC는 픽처의 디스플레이 순서에 대응하며, 코딩 순서와 구분될 수 있다.
감산부(121)는 원본 샘플과 예측 샘플 간의 차이인 레지듀얼 샘플을 생성한다. 스킵 모드가 적용되는 경우에는, 상술한 바와 같이 레지듀얼 샘플을 생성하지 않을 수 있다.
변환부(122)는 변환 블록 단위로 레지듀얼 샘플을 변환하여 변환 계수(transform coefficient)를 생성한다. 변환부(122)는 해당 변환 블록의 사이즈와, 해당 변환 블록과 공간적으로 겹치는 코딩 블록 또는 예측 블록에 적용된 예측 모드에 따라서 변환을 수행할 수 있다. 예컨대, 상기 변환 블록과 겹치는 상기 코딩 블록 또는 상기 예측 블록에 인트라 예측이 적용되었고, 상기 변환 블록이 4×4의 레지듀얼 어레이(array)라면, 레지듀얼 샘플은 DST(Discrete Sine Transform) 변환 커널을 이용하여 변환되고, 그 외의 경우라면 레지듀얼 샘플은 DCT(Discrete Cosine Transform) 변환 커널을 이용하여 변환할 수 있다.
양자화부(123)는 변환 계수들을 양자화하여, 양자화된 변환 계수를 생성할 수 있다.
재정렬부(124)는 양자화된 변환 계수를 재정렬한다. 재정렬부(124)는 계수들 스캐닝(scanning) 방법을 통해 블록 형태의 양자화된 변환 계수들을 1차원 벡터 형태로 재정렬할 수 있다. 여기서 재정렬부(124)는 별도의 구성으로 설명하였으나, 재정렬부(124)는 양자화부(123)의 일부일 수 있다.
엔트로피 인코딩부(130)는 양자화된 변환 계수들에 대한 엔트로피 인코딩을 수행할 수 있다. 엔트로피 인코딩은 예를 들어 지수 골롬(exponential Golomb), CAVLC(context-adaptive variable length coding), CABAC(context-adaptive binary arithmetic coding) 등과 같은 인코딩 방법을 포함할 수 있다. 엔트로피 인코딩부(130)는 양자화된 변환 계수 외 비디오 복원에 필요한 정보들(예컨대 신택스 요소(syntax element)의 값 등)을 함께 또는 별도로 인코딩할 수도 있다. 엔트로피 인코딩된 정보들은 비트스트림 형태로 NAL(network abstraction layer) 유닛 단위로 전송 또는 저장될 수 있다.
역양자화부(125)는 양자화부(123)에서 양자화된 값(양자화된 변환 계수)들을 역양자화하고, 역변환부(126)는 역양자화부(125)에서 역양자화된 값들을 역변환하여 레지듀얼 샘플을 생성한다.
가산부(140)는 레지듀얼 샘플과 예측 샘플을 합쳐서 픽처를 복원한다. 레지듀얼 샘플과 예측 샘플은 블록 단위로 더해져서 복원 블록이 생성될 수 있다. 여기서 가산부(140)는 별도의 구성으로 설명하였으나, 가산부(140)는 예측부(110)의 일부일 수 있다. 한편, 가산부(140)는 복원부 또는 복원 블록 생성부로 불릴 수도 있다.
복원된 픽처(reconstructed picture)에 대하여 필터부(150)는 디블록킹 필터 및/또는 샘플 적응적 오프셋(sample adaptive offset)을 적용할 수 있다. 디블록킹 필터링 및/또는 샘플 적응적 오프셋을 통해, 복원 픽처 내 블록 경계의 아티팩트나 양자화 과정에서의 왜곡이 보정될 수 있다. 샘플 적응적 오프셋은 샘플 단위로 적용될 수 있으며, 디블록킹 필터링의 과정이 완료된 후 적용될 수 있다. 필터부(150)는 ALF(Adaptive Loop Filter)를 복원된 픽처에 적용할 수도 있다. ALF는 디블록킹 필터 및/또는 샘플 적응적 오프셋이 적용된 후의 복원된 픽처에 대하여 적용될 수 있다.
메모리(160)는 복원 픽처(디코딩된 픽처) 또는 인코딩/디코딩에 필요한 정보를 저장할 수 있다. 여기서 복원 픽처는 상기 필터부(150)에 의하여 필터링 절차가 완료된 복원 픽처일 수 있다. 상기 저장된 복원 픽처는 다른 픽처의 (인터) 예측을 위한 참조 픽처로 활용될 수 있다. 예컨대, 메모리(160)는 인터 예측에 사용되는 (참조) 픽처들을 저장할 수 있다. 이 때, 인터 예측에 사용되는 픽처들은 참조 픽처 세트(reference picture set) 혹은 참조 픽처 리스트(reference picture list)에 의해 지정될 수 있다.
도 2는 본 발명이 적용될 수 있는 비디오 디코딩 장치의 구성을 개략적으로 설명하는 도면이다.
도 2를 참조하면, 비디오 디코딩 장치(200)는 엔트로피 디코딩부(210), 레지듀얼 처리부(220), 예측부(230), 가산부(240), 필터부(250) 및 메모리(260)을 포함할 수 있다. 여기서 레지듀얼 처리부(220)는 재정렬부(221), 역양자화부(222), 역변환부(223)을 포함할 수 있다.
비디오 정보를 포함하는 비트스트림이 입력되면, 비디오 디코딩 장치(200)는 비디오 인코딩 장치에서 비디오 정보가 처리된 프로세스에 대응하여 비디오를 복원할 수 있다.
예컨대, 비디오 디코딩 장치(200)는 비디오 인코딩 장치에서 적용된 처리 유닛을 이용하여 비디오 디코딩을 수행할 수 있다. 따라서 비디오 디코딩의 처리 유닛 블록은 일 예로 코딩 유닛일 수 있고, 다른 예로 코딩 유닛, 예측 유닛 또는 변환 유닛일 수 있다. 코딩 유닛은 최대 코딩 유닛으로부터 쿼드 트리 구조 및/또는 바이너리 트리 구조를 따라서 분할될 수 있다.
예측 유닛 및 변환 유닛이 경우에 따라 더 사용될 수 있으며, 이 경우 예측 블록은 코딩 유닛으로부터 도출 또는 파티셔닝되는 블록으로서, 샘플 예측의 유닛일 수 있다. 이 때, 예측 유닛은 서브 블록으로 나뉠 수도 있다. 변환 유닛은 코딩 유닛으로부터 쿼드 트리 구조를 따라서 분할 될 수 있으며, 변환 계수를 유도하는 유닛 또는 변환 계수로부터 레지듀얼 신호를 유도하는 유닛일 수 있다.
엔트로피 디코딩부(210)는 비트스트림을 파싱하여 비디오 복원 또는 픽처 복원에 필요한 정보를 출력할 수 있다. 예컨대, 엔트로피 디코딩부(210)는 지수 골롬 부호화, CAVLC 또는 CABAC 등의 코딩 방법을 기초로 비트스트림 내 정보를 디코딩하고, 비디오 복원에 필요한 신택스 엘리먼트의 값, 레지듀얼에 관한 변환 계수의 양자화된 값 들을 출력할 수 있다.
보다 상세하게, CABAC 엔트로피 디코딩 방법은, 비트스트림에서 각 구문 요소에 해당하는 빈을 수신하고, 디코딩 대상 구문 요소 정보와 주변 및 디코딩 대상 블록의 디코딩 정보 혹은 이전 단계에서 디코딩된 심볼/빈의 정보를 이용하여 문맥(context) 모델을 결정하고, 결정된 문맥 모델에 따라 빈(bin)의 발생 확률을 예측하여 빈의 산술 디코딩(arithmetic decoding)를 수행하여 각 구문 요소의 값에 해당하는 심볼을 생성할 수 있다. 이때, CABAC 엔트로피 디코딩 방법은 문맥 모델 결정 후 다음 심볼/빈의 문맥 모델을 위해 디코딩된 심볼/빈의 정보를 이용하여 문맥 모델을 업데이트할 수 있다.
엔트로피 디코딩부(210)에서 디코딩된 정보 중 예측에 관한 정보는 예측부(230)로 제공되고, 엔트로피 디코딩부(210)에서 엔트로피 디코딩이 수행된 레지듀얼 값, 즉 양자화된 변환 계수는 재정렬부(221)로 입력될 수 있다.
재정렬부(221)는 양자화되어 있는 변환 계수들을 2차원의 블록 형태로 재정렬할 수 있다. 재정렬부(221)는 인코딩 장치에서 수행된 계수 스캐닝에 대응하여 재정렬을 수행할 수 있다. 여기서 재정렬부(221)는 별도의 구성으로 설명하였으나, 재정렬부(221)는 역양자화부(222)의 일부일 수 있다.
역양자화부(222)는 양자화되어 있는 변환 계수들을 (역)양자화 파라미터를 기반으로 역양자화하여 변환 계수를 출력할 수 있다. 이 때, 양자화 파라미터를 유도하기 위한 정보는 인코딩 장치로부터 시그널링될 수 있다.
역변환부(223)는 변환 계수들을 역변환하여 레지듀얼 샘플들을 유도할 수 있다.
예측부(230)는 현재 블록에 대한 예측을 수행하고, 상기 현재 블록에 대한 예측 샘플들을 포함하는 예측된 블록(predicted block)을 생성할 수 있다. 예측부(230)에서 수행되는 예측의 단위는 코딩 블록일 수도 있고, 변환 블록일 수도 있고, 예측 블록일 수도 있다.
예측부(230)는 상기 예측에 관한 정보를 기반으로 인트라 예측을 적용할 것인지 인터 예측을 적용할 것인지를 결정할 수 있다. 이 때, 인트라 예측과 인터 예측 중 어느 것을 적용할 것인지를 결정하는 단위와 예측 샘플을 생성하는 단위는 상이할 수 있다. 아울러, 인터 예측과 인트라 예측에 있어서 예측 샘플을 생성하는 단위 또한 상이할 수 있다. 예를 들어, 인터 예측과 인트라 예측 중 어느 것을 적용할 것인지는 CU 단위로 결정할 수 있다. 또한 예를 들어, 인터 예측에 있어서 PU 단위로 예측 모드를 결정하고 예측 샘플을 생성할 수 있고, 인트라 예측에 있어서 PU 단위로 예측 모드를 결정하고 TU 단위로 예측 샘플을 생성할 수도 있다.
인트라 예측의 경우에, 예측부(230)는 현재 픽처 내의 주변 참조 샘플을 기반으로 현재 블록에 대한 예측 샘플을 유도할 수 있다. 예측부(230)는 현재 블록의 주변 참조 샘플을 기반으로 방향성 모드 또는 비방향성 모드를 적용하여 현재 블록에 대한 예측 샘플을 유도할 수 있다. 이 때, 주변 블록의 인트라 예측 모드를 이용하여 현재 블록에 적용할 예측 모드가 결정될 수도 있다.
인터 예측의 경우에, 예측부(230)는 참조 픽처 상에서 움직임 벡터에 의해 참조 픽처 상에서 특정되는 샘플을 기반으로 현재 블록에 대한 예측 샘플을 유도할 수 있다. 예측부(230)는 스킵(skip) 모드, 머지(merge) 모드 및 MVP 모드 중 어느 하나를 적용하여 현재 블록에 대한 예측 샘플을 유도할 수 있다. 이때, 비디오 인코딩 장치에서 제공된 현재 블록의 인터 예측에 필요한 움직임 정보, 예컨대 움직임 벡터, 참조 픽처 인덱스 등에 관한 정보는 상기 예측에 관한 정보를 기반으로 획득 또는 유도될 수 있다
스킵 모드와 머지 모드의 경우에, 주변 블록의 움직임 정보가 현재 블록의 움직임 정보로 이용될 수 있다. 이 때, 주변 블록은 공간적 주변 블록과 시간적 주변 블록을 포함할 수 있다.
예측부(230)는 가용한 주변 블록의 움직임 정보로 머지 후보 리스트를 구성하고, 머지 인덱스가 머지 후보 리스트 상에서 지시하는 정보를 현재 블록의 움직임 벡터로 사용할 수 있다. 머지 인덱스는 인코딩 장치로부터 시그널링될 수 있다. 움직임 정보는 움직임 벡터와 참조 픽처를 포함할 수 있다. 스킵 모드와 머지 모드에서 시간적 주변 블록의 움직임 정보가 이용되는 경우에, 참조 픽처 리스트 상의 최상위 픽처가 참조 픽처로서 이용될 수 있다.
스킵 모드의 경우, 머지 모드와 달리 예측 샘플과 원본 샘플 사이의 차이(레지듀얼)이 전송되지 않는다.
MVP 모드의 경우, 주변 블록의 움직임 벡터를 움직임 벡터 예측자(motion vector predictor)로 이용하여 현재 블록의 움직임 벡터가 유도될 수 있다. 이 때, 주변 블록은 공간적 주변 블록과 시간적 주변 블록을 포함할 수 있다.
일 예로, 머지 모드가 적용되는 경우, 복원된 공간적 주변 블록의 움직임 벡터 및/또는 시간적 주변 블록인 Col 블록에 대응하는 움직임 벡터를 이용하여, 머지 후보 리스트가 생성될 수 있다. 머지 모드에서는 머지 후보 리스트에서 선택된 후보 블록의 움직임 벡터가 현재 블록의 움직임 벡터로 사용된다. 상기 예측에 관한 정보는 상기 머지 후보 리스트에 포함된 후보 블록들 중에서 선택된 최적의 움직임 벡터를 갖는 후보 블록을 지시하는 머지 인덱스를 포함할 수 있다. 이 때, 예측부(230)는 상기 머지 인덱스를 이용하여, 현재 블록의 움직임 벡터를 도출할 수 있다.
다른 예로, MVP(Motion Vector Prediction) 모드가 적용되는 경우, 복원된 공간적 주변 블록의 움직임 벡터 및/또는 시간적 주변 블록인 Col 블록에 대응하는 움직임 벡터를 이용하여, 움직임 벡터 예측자 후보 리스트가 생성될 수 있다. 즉, 복원된 공간적 주변 블록의 움직임 벡터 및/또는 시간적 주변 블록인 Col 블록에 대응하는 움직임 벡터는 움직임 벡터 후보로 사용될 수 있다. 상기 예측에 관한 정보는 상기 리스트에 포함된 움직임 벡터 후보 중에서 선택된 최적의 움직임 벡터를 지시하는 예측 움직임 벡터 인덱스를 포함할 수 있다. 이 때, 예측부(230)는 상기 움직임 벡터 인덱스를 이용하여, 움직임 벡터 후보 리스트에 포함된 움직임 벡터 후보 중에서, 현재 블록의 예측 움직임 벡터를 선택할 수 있다. 인코딩 장치의 예측부는 현재 블록의 움직임 벡터와 움직임 벡터 예측자 간의 움직임 벡터 차분(MVD)을 구할 수 있고, 이를 인코딩하여 비트스트림 형태로 출력할 수 있다. 즉, MVD는 현재 블록의 움직임 벡터에서 상기 움직임 벡터 예측자를 뺀 값으로 구해질 수 있다. 이 때, 예측부(230)는 상기 예측에 관한 정보에 포함된 움직임 벡터 차분을 획득하고, 상기 움직임 벡터 차분과 상기 움직임 벡터 예측자의 가산을 통해 현재 블록의 상기 움직임 벡터를 도출할 수 있다. 예측부는 또한 참조 픽처를 지시하는 참조 픽처 인덱스 등을 상기 예측에 관한 정보로부터 획득 또는 유도할 수 있다.
가산부(240)는 레지듀얼 샘플과 예측 샘플을 더하여 현재 블록 혹은 현재 픽처를 복원할 수 있다. 가산부(240)는 레지듀얼 샘플과 예측 샘플을 블록 단위로 더하여 현재 픽처를 복원할 수도 있다. 스킵 모드가 적용된 경우에는 레지듀얼이 전송되지 않으므로, 예측 샘플이 복원 샘플이 될 수 있다. 여기서는 가산부(240)를 별도의 구성으로 설명하였으나, 가산부(240)는 예측부(230)의 일부일 수도 있다. 한편, 가산부(240)는 복원부 또는 복원 블록 생성부로 불릴 수도 있다.
필터부(250)는 복원된 픽처에 디블록킹 필터링 샘플 적응적 오프셋, 및/또는 ALF 등을 적용할 수 있다. 이 때, 샘플 적응적 오프셋은 샘플 단위로 적용될 수 있으며, 디블록킹 필터링 이후 적용될 수도 있다. ALF는 디블록킹 필터링 및/또는 샘플 적응적 오프셋 이후 적용될 수도 있다.
메모리(260)는 복원 픽처(디코딩된 픽처) 또는 디코딩에 필요한 정보를 저장할 수 있다. 여기서 복원 픽처는 상기 필터부(250)에 의하여 필터링 절차가 완료된 복원 픽처일 수 있다. 예컨대, 메모리(260)는 인터 예측에 사용되는 픽처들을 저장할 수 있다. 이 때, 인터 예측에 사용되는 픽처들은 참조 픽처 세트 혹은 참조 픽처 리스트에 의해 지정될 수도 있다. 복원된 픽처는 다른 픽처에 대한 참조 픽처로서 이용될 수 있다. 또한, 메모리(260)는 복원된 픽처를 출력 순서에 따라서 출력할 수도 있다.
상술한 내용과 같이 픽처들 간 대상 객체 또는 이미지의 움직임을 고려하여 현재 블록에 대한 인터 예측이 수행될 수 있다. 상기 인터 예측의 일 예로, 인코딩 장치/디코딩 장치는 AMVP(advanced motion vector prediction) 모드를 적용하여 현재 블록에 대한 예측 샘플을 유도할 수 있다. 상기 AMVP 모드는 MVP(motion vector prediction) 모드라고 불릴 수도 있다.
한편, 여기서, 인터 예측에 대한 움직임 정보는 쌍예측 움직임 정보 또는 단예측 움직임 정보일 수 있다. 여기서, 상기 쌍예측 움직임 정보는 L0 참조 픽처 인덱스 및 L0 움직임 벡터(L0 움직임 정보), L1 참조 픽처 인덱스 및 L1 움직임 벡터(L1 움직임 정보)를 포함할 수 있고, 상기 단예측 움직임 정보는 L0 참조 픽처 인덱스 및 L0 움직임 벡터(L0 움직임 정보)를 포함할 수 있고, 또는 L1 참조 픽처 인덱스 및 L1 움직임 벡터(L1 움직임 정보)를 포함할 수 있다. 상기 L0은 참조 픽처 리스트 L0(List 0)를 나타내고, 상기 L1은 참조 픽처 리스트 L1(List 1)를 나타낸다.
한편, 현재 블록의 인터 예측 모드를 가리키는 예측 모드 정보가 인코딩 장치로부터 디코딩 장치로 시그널링될 수 있다. 상기 예측 모드 정보는 비트스트림에 포함되어 디코딩 장치에 수신될 수 있다. 상기 예측 모드 정보는 다수의 후보 모드들 중 하나를 지시하는 인덱스 정보를 포함할 수 있다. 또는, 플래그 정보의 계층적 시그널링을 통하여 인터 예측 모드를 지시할 수도 있다. 이 경우 상기 예측 모드 정보는 하나 이상의 플래그들을 포함할 수 있다. 예를 들어, 스킵 플래그를 시그널링하여 스킵 모드 적용 여부를 지시하고, 스킵 모드가 적용 안되는 경우에 머지 플래그를 시그널링하여 머지 모드 적용 여부를 지시하고, 머지 모드가 적용 안되는 경우에 MVP 모드 적용되는 것으로 지시하거나 추가적인 구분을 위한 플래그를 더 시그널링할 수도 있다.
현재 블록에 대하여 상기 AMVP 모드가 적용되는 경우, 복원된 공간적 주변 블록의 움직임 벡터 및/또는 시간적 주변 블록(또는 Col 블록)에 대응하는 움직임 벡터를 이용하여, 움직임 벡터 예측자(motion vector predictor, MVP) 후보 리스트가 생성될 수 있다. 즉, 복원된 공간적 주변 블록의 움직임 벡터 및/또는 시간적 주변 블록에 대응하는 움직임 벡터는 움직임 벡터 예측자 후보로 사용될 수 있다. 한편, 상기 현재 블록의 예측에 관한 정보가 시그널링될 수 있고, 상기 예측에 관한 정보는 상기 MVP 후보 리스트에 포함된 움직임 벡터 예측자 후보들 중에서 선택된 최적의 움직임 벡터 예측자 후보를 지시하는 선택 정보(ex. MVP 플래그 또는 MVP 인덱스)를 포함할 수 있다. 이 때, 예측부는 상기 선택 정보를 이용하여, 움직임 벡터 후보 리스트에 포함된 움직임 벡터 예측자 후보들 중에서, 현재 블록의 움직임 벡터 예측자를 선택할 수 있다. 인코딩 장치의 예측부는 현재 블록의 움직임 벡터와 움직임 벡터 예측자 간의 움직임 벡터 차분(MVD)을 구할 수 있고, 이를 인코딩하여 비트스트림 형태로 출력할 수 있다. 즉, MVD는 현재 블록의 움직임 벡터에서 상기 움직임 벡터 예측자를 뺀 값으로 구해질 수 있다. 이 때, 디코딩 장치의 예측부는 상기 예측에 관한 정보에 포함된 움직임 벡터 차분을 획득하고, 상기 움직임 벡터 차분과 상기 움직임 벡터 예측자의 가산을 통해 현재 블록의 상기 움직임 벡터를 도출할 수 있다. 디코딩 장치의 예측부는 참조 픽처를 지시하는 참조 픽처 인덱스 등을 상기 예측에 관한 정보로부터 획득 또는 유도할 수 있다.
한편, 상기 MVP 모드가 적용되는 경우에 사용되는 비트량을 줄이고 코딩 효율을 향상시키기 위해서는, 다양한 주변 블록을 사용함으로써 상기 현재 블록의 MVP의 정확도를 높여 MVD 정보량을 줄이는 방안이나, 머지 모드와 비교하여 상대적으로 전송되는 정보량이 많기 때문에 인덱스가 아닌 0/1의 값을 갖는 MVP 플래그만을 사용하여 부가 정보량을 줄이는 방안이 제안될 수 있다.
하지만, 상기 MVP 후보 리스트는 기설정된 개수 및 순서대로 MVP 후보가 나열되기 때문에, 상기 현재 블록에 대하여 특정 주변 블록의 움직임 정확도가 높더라도 MPV 인덱스 또는 MVP 플래그로 인하여 발생하는 비트량을 고려하여 상기 특정 주변 블록의 움직임 벡터를 기반으로 도출된 MVP 후보가 상기 현재 블록의 MVP로 선택되지 않는 경우가 발생한다. 이에, 본 발명에서는 코딩 효율을 보다 높이기 위해 MVP 후보 리스트를 재정렬함으로써 효과적인 MVP 후보 구성을 할 수 있는 방법(ALR)을 제안한다. 또한, 본 발명에서는 상기 ALR 방법을 보다 효과적으로 적용하기 위한 다양한 ALR 개선 방법을 제안한다.
도 3은 상기 ALR 을 통하여 상기 MVP 후보 리스트를 구성하는 일 예를 나타낸다. 도 3을 참조하면 인코딩 장치/디코딩 장치는 현재 블록의 주변 블록을 기반으로 MVP 후보들을 구성할 수 있고, 상기 MVP 후보들 각각의 코스트(cost)를 계산한 뒤, 상기 MVP 후보들의 코스트들을 기반으로 상기 MVP 후보들을 재정렬할 수 있고, 상기 재정렬된 순서의 MVP 후보들을 기반으로 리파인먼트(refinement) 과정을 수행하여 최종적으로 MVP 후보 리스트를 재구성할 수 있다.
구체적으로, 인코딩 장치/디코딩 장치는 기존의 MVP 후보 리스트 구성 방법을 통하여 현재 블록의 최대 후보 개수의 MVP 후보들을 구성할 수 있다(S300). 즉, 인코딩 장치/디코딩 장치는 기존의 MVP 후보 리스트 구성 방법을 통하여 최대 후보 개수의 MVP 후보들을 포함한 MVP 후보 리스트를 구성할 수 있다. 예를 들어, 상기 최대 후보 개수는 5개일 수 있다.
인코딩 장치/디코딩 장치는 상기 MVP 후보 리스트의 MVP 후보에 대한 코스트를 계산할 수 있다(S310). 일 예로, 상기 코스트는 템플릿(template)을 기반으로 계산될 수 있다. 즉, 상기 코스트는 템플릿 정합(template matching) 방법을 통하여 도출될 수 있다.
도 4는 상기 템플릿 정합 방법을 통하여 상기 현재 블록의 MVP 후보에 대한 코스트를 도출하는 일 예를 나타낸다.
도 4를 참조하면 상기 현재 블록의 주변 샘플들의 샘플값들과 상기 MVP 후보가 가리키는 후보 블록의 주변 샘플들의 샘플값들을 기반으로 상기 MVP 후보에 대한 코스트가 도출될 수 있다. 도 4를 참조하면 상기 현재 블록의 상기 주변 샘플들은 상기 현재 블록에서 참조될 수 있는(causal) 좌측 주변 샘플들 및 상측 주변 샘플들을 포함할 수 있다. 또한, 도 4를 참조하면 상기 현재 블록의 임의의 주변 영역이 상기 현재 블록의 템플릿(template)으로 설정될 수 있고, 참조 픽처 상의 상기 MVP 후보가 가리키는 후보 블록의 템플릿을 이용하여 상기 MVP 후보의 코스트가 도출될 수 있다. 여기서, 상기 MVP 후보에 대한 상기 후보 블록의 템플릿은 상기 현재 블록의 템플릿과 동일한 사이즈를 가질 수 있다. 또한, 상기 현재 블록의 상기 좌측 주변 샘플들 및 상기 상측 주변 샘플들은 상기 현재 블록의 디코딩 시점에 이미 디코딩되어 있을 수 있고, 따라서 디코딩 장치에서의 움직임 추정 과정에 사용될 수 있으므로 상기 좌측 주변 샘플들 및 상기 상측 주변 샘플들은 상기 현재 블록의 템플릿에 포함될 수 있다. 즉, 상기 현재 블록의 템플릿은 상기 좌측 주변 샘플들 및 상기 상측 주변 샘플들을 포함하는 특정 영역일 수 있다. 여기서, 상기 코스트는 상기 현재 블록의 템플릿과 상기 후보 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합으로 도출될 수 있다. 예를 들어, 상기 코스트는 다음과 같은 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000001
여기서, i, j는 블록의 템플릿 내 샘플의 위치 (i, j)를 나타내고, Costdistortion은 상기 코스트, Tempref는 상기 후보 블록의 템플릿의 샘플값, Tempcur는 상기 현재 블록의 템플릿의 샘플값을 나타낸다. 상기 후보 블록의 템플릿 및 상기 현재 블록의 템플릿 사이의 대응하는 샘플들 간의 차이를 누적할 수 있고, 상기 차이의 누적은 상기 MVP 후보에 대한 코스트로 사용될 수 있다.
인코딩 장치/디코딩 장치는 상기 MVP 후보 리스트의 MVP 후보들에 대한 코스트들을 기반으로 MVP 후보들을 재정렬(reordering)할 수 있다(S320). 예를 들어, 인코딩 장치/디코딩 장치는 코스트가 작은 순서로 상기 MVP 후보들을 재정렬할 수 있다. 또는, 다른 예로, 인코딩 장치/디코딩 장치는 코스트가 가장 작은 상기 MVP 후보를 첫번째 순서로 재정렬할 수 있다. 여기서, 상기 MVP 후보는 AMVP 후보라고 불릴 수도 있다.
인코딩 장치/디코딩 장치는 상기 MVP 후보 리스트의 재정렬된 MVP 후보에 대한 리파인(refine) MVP 후보를 도출할 수 있다(S330). 상기 재정렬된 MVP 후보가 복수인 경우, 재정렬된 순서로 리파인(refine) MVP 후보가 도출될 수 있다. 예를 들어, 상기 리파인 MVP 후보는 상기 재정렬된 MVP 후보의 움직임 벡터를 리파인하여 도출될 수 있다. 구체적으로, 인코딩 장치/디코딩 장치는 상기 재정렬된 MVP 후보가 가리키는 후보 블록의 임의의 주변 영역에서 포함된 참조 블록들의 템플릿들 중 상기 현재 블록의 템플릿과의 코스트가 작은 템플릿을 도출할 수 있다. 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 움직임 벡터를 리파인 움직임 벡터로 도출할 수 있다. 즉, 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 수정된(modified) 움직임 벡터를 상기 리파인 MVP 후보로 도출할 수 있다. 인코딩 장치/디코딩 장치는 상기 MVP 후보 리스트 내 상기 리파인 MVP 후보의 순서를 상기 재정렬된 MVP 후보의 순서의 앞으로 도출할 수 있다. 즉, 인코딩 장치/디코딩 장치는 상기 리파인 MVP 후보에 대한 인덱스의 값을 상기 재정렬된 MVP 후보에 대한 인덱스의 값보다 작은 값으로 할당할 수 있다.
인코딩 장치/디코딩 장치는 MVP 후보들 및 리파인 MVP 후보 중 특정 개수의 후보를 선택하여 수정된(modified) MVP 후보 리스트를 도출할 수 있다(S340). 예를 들어, 5개의 MVP 후보가 도출되고, 1개의 리파인 MVP 후보가 도출된 경우, 인코딩 장치/디코딩 장치는 상기 6개의 후보들 중 2개의 후보를 선택할 수 있고, 상기 2개의 후보를 기반으로 상기 수정된 MVP 후보 리스트를 도출할 수 있다. 또한, 인코딩 장치는 상기 선택된 후보들에 대한 정보를 시그널링할 수 있다.
한편, 상기 현재 블록의 MVP 후보를 구성하는 방법은 후술하는 내용과 같을 수 있다.
예를 들어, 현재 블록에 대한 MVP 후보로 구성될 수 있는 움직임 정보의 종류 및 체크 순서는 다음의 표와 같이 도출될 수 있다.
Figure PCTKR2018014822-appb-T000001
상술한 표 1과 같이 머지 모드와의 통일성을 위하여 머지 모드와 동일한 위치의 주변 블록들이 체크될 수 있고, 상기 주변 블록들을 체크하는 순서도 동일하게 설정될 수 있다. 단, 머지 모드와 달리 AMVP 모드는 MVD가 시그널링 되므로 서브 블록 단위의 움직임 벡터를 포함하는 MVP 후보를 구성하는 것은 적합하지 않을 수 있다. 이에, 표 1에 도시된 것과 같이 서브 블록 단위의 움직임 벡터를 포함하는 ATMVP 및 STMVP 는 상기 현재 블록의 MVP 후보로 고려되지 않을 수 있다. 또한, Combined bi-pred 후보는 L0 움직임 벡터 및 L1 움직임 벡터를 조합하여 생성되므로, L0 예측 및 L1 예측마다 다른 MVP를 유도하는 AMVP 모드에는 적합하지 않을 수 있다. 따라서, 상기 Combined bi-pred 후보는 MVP 후보로 고려되지 않을 수 있다. 여기서, 상기 L0 예측은 L0 움직임 정보를 기반으로 수행되는 단예측(uni-prediction)을 나타낼 수 있고, 상기 L1 예측은 L1 움직임 정보를 기반으로 수행되는 단예측을 나타낼 수 있다.
A1 은 상기 현재 블록의 좌측 주변 블록의 움직임 벡터를 나타내고, B1 은 상기 현재 블록의 상측 주변 블록의 움직임 벡터를 나타내고, B0 은 상기 현재 블록의 우상측 주변 블록의 움직임 벡터를 나타내고, A0 은 상기 현재 블록의 좌하측 주변 블록의 움직임 벡터를 나타내고, ATMVP 는 상기 현재 블록의 특정 주변 블록의 움직임 정보가 가리키는 동일 위치 블록의 움직임 벡터를 나타내고, STMVP 는 상기 현재 블록의 공간적 주변 블록의 움직임 정보와 시간적 주변 블록의 움직임 정보를 기반으로 도출된 움직임 정보를 나타내고, B2 은 상기 현재 블록의 좌상측 주변 블록의 움직임 정보를 나타내고, TMVP 는 상기 현재 블록의 시간적 주변 블록의 움직임 벡터를 나타내고, Combined 는 상기 현재 블록의 주변 블록의 움직임 정보를 조합하여 도출된 움직임 정보를 나타내고, Zero 는 값이 0인 움직임 벡터를 나타낸다.
한편, 상기 현재 블록의 사이즈가 WxH 이고, 현재 블록의 좌상단(top-left) 샘플 포지션의 x성분이 0 및 y성분이 0인 경우, 상기 좌측 주변 블록은 (-1, H-1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 상측 주변 블록은 (W-1, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 우상측 주변 블록은 (W, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌하측 주변 블록은 (-1, H) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌상측 주변 블록은 (-1, -1) 좌표의 좌상단 샘플을 포함하는 블록일 수 있다.
상술한 내용과 같이 머지 후보 리스트의 구성 순서와 같이 상기 MVP 후보 리스트를 구성하는 방안이 제안될 수 있다.
상기 MVP 후보 리스트를 구성하는 기존의 방법의 경우, 상기 A0 및 상기 A1 중 하나를 상기 현재 블록의 MVP 후보로 도출될 수 있고, 상기 B0, 상기 B1 및 상기 B2 중 하나를 상기 현재 블록의 MVP 후보로 도출될 수 있다.
도 5는 상기 A0 및 상기 A1을 기반으로 상기 MVP 후보 리스트의 MVP 후보를 도출하는 일 예를 나타낸다. 인코딩 장치/디코딩 장치는 현재 블록의 좌측 및 좌하측에 위치하는 주변 블록 A0, 주변 블록 A1 의 움직임 벡터들 중 하나의 MVP 후보를 선택할 수 있다. 도 5를 참조하면 인코딩 장치/디코딩 장치는 주변 블록 A0 의 움직임 벡터를 체크할 수 있다(S500). 예를 들어, 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 참조 픽처가 동일하고, 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 상기 참조 픽처가 동일한 참조 픽처 리스트에 포함되면 상기 주변 블록 A0의 움직임 벡터를 MVP 후보로 도출할 수 있다. 또한, 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처가 포함된 참조 픽처 리스트에 대하여 상기 주변 블록 A0 이 가용(available)하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 참조 픽처가 동일하고, 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 상기 참조 픽처가 다른 참조 픽처 리스트에 포함되면 상기 주변 블록 A0의 움직임 벡터를 MVP 후보로 도출할 수 있다. 즉, 상기 인코딩 장치/디코딩 장치는 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 참조 픽처가 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처와 동일한 참조 픽처 리스트에 포함되고, 동일한 픽처인 경우, 상기 주변 블록 A0 의 움직임 벡터를 상기 MVP 후보로 도출할 수 있다. 또한, 상기 인코딩 장치/디코딩 장치는 상기 주변 블록 A0 의 참조 픽처 인덱스가 가리키는 참조 픽처가 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처와 동일한 참조 픽처 리스트에 포함되지 않고 다른 참조 픽처 리스트에 포함되더라도, 동일한 픽처인 경우, 상기 주변 블록 A0 의 움직임 벡터를 상기 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 A0가 가용하지 않은지 판단할 수 있다(S510). 상술한 주변 블록 A0 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A0가 가용하지 않다고 판단할 수 있다.
상기 주변 블록 A0가 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 주변 블록 A1 의 움직임 벡터를 체크할 수 있다(S520). 인코딩 장치/디코딩 장치는 상기 주변 블록 A0 에 대한 체크 과정과 동일한 체크 과정을 상기 주변 블록 A1 에 대하여 수행할 수 있다. 예를 들어, 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 참조 픽처가 동일하고, 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 상기 참조 픽처가 동일한 참조 픽처 리스트에 포함되면 상기 주변 블록 A1의 움직임 벡터를 MVP 후보로 도출할 수 있다. 또한, 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처가 포함된 참조 픽처 리스트에 대하여 상기 주변 블록 A1 이 가용(available)하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 참조 픽처가 동일하고, 상기 현재 블록의 참조 픽처 인덱스와 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 상기 참조 픽처가 다른 참조 픽처 리스트에 포함되면 상기 주변 블록 A0의 움직임 벡터를 MVP 후보로 도출할 수 있다. 즉, 상기 인코딩 장치/디코딩 장치는 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 참조 픽처가 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처와 동일한 참조 픽처 리스트에 포함되고, 동일한 픽처인 경우, 상기 주변 블록 A1 의 움직임 벡터를 상기 MVP 후보로 도출할 수 있다. 또한, 상기 인코딩 장치/디코딩 장치는 상기 주변 블록 A1 의 참조 픽처 인덱스가 가리키는 참조 픽처가 상기 현재 블록의 참조 픽처 인덱스가 가리키는 참조 픽처와 동일한 참조 픽처 리스트에 포함되지 않고 다른 참조 픽처 리스트에 포함되더라도, 동일한 픽처인 경우, 상기 주변 블록 A1 의 움직임 벡터를 상기 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 A1 이 가용하지 않은지 판단할 수 있다(S530). 상술한 주변 블록 A1 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A1이 가용하지 않다고 판단할 수 있다.
상기 주변 블록 A1이 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A0 의 움직임 벡터를 스케일링(scaling)하여 움직임 벡터 scaledA0 를 도출할 수 있고, 상기 움직임 벡터 scaledA0 를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S540). 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처와 다른 참조 픽처에 대한 움직임 벡터 A0 를 스케일링할 수 있고, 스케일링된 움직임 벡터 scaledA0 를 상기 MVP 후보로 도출할 수 있다.
한편, 상기 움직임 벡터 scaledA0 가 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A1 의 움직임 벡터를 스케일링하여 움직임 벡터 scaledA1 를 도출할 수 있고, 상기 움직임 벡터 scaledA1 를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S550). 인코딩 장치/디코딩 장치는 상기 현재 블록의 참조 픽처와 다른 참조 픽처에 대한 움직임 벡터 A1를 스케일링할 수 있고, 스케일링된 움직임 벡터 scaledA1를 상기 MVP 후보로 도출할 수 있다.
한편, 상기 주변 블록 A0 및 상기 주변 블록 A1 에 대한 움직임 벡터들을 기반으로 상기 MVP 후보를 도출하는 방안과 동일한 과정이 상기 주변 블록 B0, 상기 주변 블록 B1 및 상기 주변 블록 B2 에 대한 움직임 벡터들에 대하여 수행될 수 있다. 예를 들어, 상기 주변 블록 B0, 상기 주변 블록 B1 및 상기 주변 블록 B2 순서로 체크될 수 있고, 상기 주변 블록 B0, 상기 주변 블록 B1 및 상기 주변 블록 B2 이 가용하지 않은 경우, 움직임 벡터 scaledB0, 움직임 벡터 scaledB1 및 움직임 벡터 scaledB2 순서로 체크될 수 있다.
도 6은 기존의 순서를 통하여 상기 MVP 후보 리스트를 구성하는 일 예를 나타낸다. 도 6을 참조하면 상기 A0 및 상기 A1 중 하나를 상기 현재 블록의 MVP 후보로 도출될 수 있고, 상기 B0, 상기 B1 및 상기 B2 중 하나를 상기 현재 블록의 MVP 후보로 도출될 수 있다. 상기 A0 및 상기 A1을 기반으로 MVP 후보를 도출하는 순서는 다음과 같을 수 있다.
구체적으로, 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제1 움직임 정보가 존재하는 경우, 상기 제1 움직임 정보에 포함된 제1 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제2 움직임 정보가 존재하는 경우, 상기 제2 움직임 정보에 포함된 제2 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보 및 상기 제2 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제3 움직임 정보가 존재하는 경우, 상기 제3 움직임 정보에 포함된 제3 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보 및 상기 제3 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제4 움직임 정보가 존재하는 경우, 상기 제4 움직임 정보에 포함된 제4 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보 및 상기 제4 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제5 움직임 정보가 존재하는 경우, 상기 제5 움직임 정보에 포함된 제5 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보 및 상기 제5 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제6 움직임 정보가 존재하는 경우, 상기 제6 움직임 정보에 포함된 제6 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보 및 상기 제6 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제7 움직임 정보가 존재하는 경우, 상기 제7 움직임 정보에 포함된 제7 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보 및 상기 제7 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제8 움직임 정보가 존재하는 경우, 상기 제8 움직임 정보에 포함된 제8 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
한편, 상기 B0, B1 및 상기 B2를 기반으로 MVP 후보를 도출하는 순서는 다음과 같을 수 있다.
구체적으로, 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제1 움직임 정보가 존재하는 경우, 상기 제1 움직임 정보에 포함된 제1 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제2 움직임 정보가 존재하는 경우, 상기 제2 움직임 정보에 포함된 제2 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보 및 상기 제2 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제3 움직임 정보가 존재하는 경우, 상기 제3 움직임 정보에 포함된 제3 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보 및 상기 제3 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제4 움직임 정보가 존재하는 경우, 상기 제4 움직임 정보에 포함된 제4 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보 및 상기 제4 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제5 움직임 정보가 존재하는 경우, 상기 제5 움직임 정보에 포함된 제5 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보 및 상기 제5 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제6 움직임 정보가 존재하는 경우, 상기 제6 움직임 정보에 포함된 제6 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보 및 상기 제6 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제7 움직임 정보가 존재하는 경우, 상기 제7 움직임 정보에 포함된 제7 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보 및 상기 제7 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제8 움직임 정보가 존재하는 경우, 상기 제8 움직임 정보에 포함된 제8 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보, 상기 제7 움직임 정보 및 상기 제8 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제9 움직임 정보가 존재하는 경우, 상기 제9 움직임 정보에 포함된 제9 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보, 상기 제7 움직임 정보, 상기 제8 움직임 정보 및 상기 제9 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제10 움직임 정보가 존재하는 경우, 상기 제10 움직임 정보에 포함된 제10 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보, 상기 제7 움직임 정보, 상기 제8 움직임 정보, 상기 제9 움직임 정보 및 상기 제10 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제11 움직임 정보가 존재하는 경우, 상기 제11 움직임 정보에 포함된 제11 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
상기 제1 움직임 정보, 상기 제2 움직임 정보, 상기 제3 움직임 정보, 상기 제4 움직임 정보, 상기 제5 움직임 정보, 상기 제6 움직임 정보, 상기 제7 움직임 정보, 상기 제8 움직임 정보, 상기 제9 움직임 정보, 상기 제10 움직임 정보 및 상기 제11 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처가 아닌 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제12 움직임 정보가 존재하는 경우, 상기 제12 움직임 정보에 포함된 제12 움직임 벡터가 상기 현재 블록의 MVP 후보로 도출될 수 있다.
한편, 본 발명에서 제안하는 MVP 후보 리스트 구성 방안은 최대 2개가 아닌 최대 5개의 MVP 후보들을 포함할 수 있는바, 상기 A0 및 상기 A1 에서 하나의 MVP 후보를 도출하고, 상기 B0, 상기 B1 및 상기 B2 를 기반으로 하나의 MVP 후보를 도출하는 기존 구성 방안의 변경이 필요하다.
도 7은 현재 블록의 주변 블록들을 기반으로 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 7을 참조하면 인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 A1을 체크할 수 있다(S700). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 A1의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 A1 이 가용하지 않은지 판단할 수 있다(S705). 상술한 주변 블록 A1 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A1이 가용하지 않다고 판단할 수 있다. 상기 주변 블록 A1의 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A1이 가용하지 않다고 판단할 수 있다.
상기 주변 블록 A1이 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 특정 참조 픽처 이외의 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제3 움직임 정보에 포함된 제3 움직임 벡터를 스케일링할 수 있고, 스케일링된 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S710). 여기서, 상기 스케일링된 움직임 벡터는 scaled A1으로 나타낼 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B1을 체크할 수 있다(S715). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B1의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 B1 이 가용하지 않은지 판단할 수 있다(S720). 상술한 주변 블록 B1 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B1이 가용하지 않다고 판단할 수 있다. 상기 주변 블록 B1의 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B1이 가용하지 않다고 판단할 수 있다.
상기 주변 블록 B1이 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 특정 참조 픽처 이외의 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제3 움직임 정보에 포함된 제3 움직임 벡터를 스케일링할 수 있고, 스케일링된 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S725). 여기서, 상기 스케일링된 움직임 벡터는 scaled B1으로 나타낼 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B0을 체크할 수 있다(S730). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B0의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 B0 가 가용하지 않은지 판단할 수 있다(S735). 상술한 주변 블록 B0 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B0이 가용하지 않다고 판단할 수 있다. 상기 주변 블록 B0의 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B0이 가용하지 않다고 판단할 수 있다.
상기 주변 블록 B0이 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 특정 참조 픽처 이외의 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제3 움직임 정보에 포함된 제3 움직임 벡터를 스케일링할 수 있고, 스케일링된 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S740). 여기서, 상기 스케일링된 움직임 벡터는 scaled B0 로 나타낼 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 A0을 체크할 수 있다(S745). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 A0의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 A0 가 가용하지 않은지 판단할 수 있다(S750). 상술한 주변 블록 A0 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A0이 가용하지 않다고 판단할 수 있다. 상기 주변 블록 A0의 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A0이 가용하지 않다고 판단할 수 있다.
상기 주변 블록 A0이 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 특정 참조 픽처 이외의 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제3 움직임 정보에 포함된 제3 움직임 벡터를 스케일링할 수 있고, 스케일링된 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S755). 여기서, 상기 스케일링된 움직임 벡터는 scaled A0 로 나타낼 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B2를 체크할 수 있다(S760). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B2의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 상기 주변 블록 B2 가 가용하지 않은지 판단할 수 있다(S765). 상술한 주변 블록 B2 에 대한 체크 과정을 통하여 상기 MVP 후보가 도출되지 않은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B2가 가용하지 않다고 판단할 수 있다. 상기 주변 블록 B2의 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B2가 가용하지 않다고 판단할 수 있다.
상기 주변 블록 B2가 가용하지 않은 경우, 인코딩 장치/디코딩 장치는 상기 특정 참조 픽처 이외의 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제3 움직임 정보에 포함된 제3 움직임 벡터를 스케일링할 수 있고, 스케일링된 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다(S770). 여기서, 상기 스케일링된 움직임 벡터는 scaled B2 로 나타낼 수 있다.
한편, 상기 MVP 후보 리스트를 구성하기 위하여 MVP 후보를 도출하는 순서는 변경될 수도 있다. 예를 들어, 인코딩 장치/디코딩 장치는 상기 현재 블록의 공간적 주변 블록들을 상기 주변 블록 A1, 상기 주변 블록 B1, 상기 주변 블록 B0, 상기 주변 블록 A0, 상기 주변 블록 B2 순서로 체크하여 MVP 후보를 도출할 수 있고, 상기 도출된 MVP 후보의 개수가 최대 개수(예를 들어, 5개)보다 작은 경우, scaled A1, scaled B1, scaled B0, scaled A0, scaled B2 순으로 추가하여 최대 개수의 MVP 후보들을 포함하는 MVP 후보 리스트를 구성할 수 있다. 여기서, 상기 scaled A1는 상기 주변 블록 A1 의 움직임 벡터를 스케일링하여 도출된 움직임 벡터, 상기 scaled B1는 상기 주변 블록 B1 의 움직임 벡터를 스케일링하여 도출된 움직임 벡터, 상기 scaled B0는 상기 주변 블록 B0 의 움직임 벡터를 스케일링하여 도출된 움직임 벡터, 상기 scaled A0는 상기 주변 블록 A0 의 움직임 벡터를 스케일링하여 도출된 움직임 벡터, 상기 scaled B2는 상기 주변 블록 B2 의 움직임 벡터를 스케일링하여 도출된 움직임 벡터를 나타낼 수 있다.
도 8은 현재 블록의 주변 블록들을 기반으로 MVP 후보 리스트를 구성하는 일 예를 나타낸다.
도 8을 참조하면 인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 A1을 체크할 수 있다(S800). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 A1의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A1의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B1을 체크할 수 있다(S805). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B1의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B1의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B0을 체크할 수 있다(S810). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B0의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B0의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 A0을 체크할 수 있다(S815). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 A0의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 A0의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 현재 블록의 주변 블록 B2를 체크할 수 있다(S820). 예를 들어, 상기 현재 블록에 대한 참조 픽처 인덱스가 가리키는 참조 픽처가 특정 참조 픽처 리스트에 포함된 특정 참조 픽처인 경우에, 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제1 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제1 움직임 정보에 포함된 제1 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
상기 주변 블록 B2의 상기 제1 움직임 정보가 존재하지 않고, 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처를 가리키는 참조 픽처 인덱스를 포함하는 상기 주변 블록 B2의 제2 움직임 정보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 제2 움직임 정보에 포함된 제2 움직임 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있다.
인코딩 장치/디코딩 장치는 도출된 MVP 후보의 개수가 5개보다 작은지 판단할 수 있다(S825). 상기 도출된 MVP 후보의 개수가 5개인 경우, 인코딩 장치/디코딩 장치는 상기 도출된 MVP 후보를 포함하는 MVP 후보 리스트를 구성할 수 있고, 추가적인 MVP 후보를 더 도출하지 않을 수 있다.
상기 도출된 MVP 후보의 개수가 5개보다 작은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A1 의 움직임 벡터를 스케일링할 수 있고, 스케일링된 벡터를 체크할 수 있다(S830). 예를 들어, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있고, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출하지 않을 수 있다. 상기 스케일링된 벡터는 scaled A1 이라고 나타낼 수 있다.
인코딩 장치/디코딩 장치는 도출된 MVP 후보의 개수가 5개보다 작은지 판단할 수 있다(S835). 상기 도출된 MVP 후보의 개수가 5개인 경우, 인코딩 장치/디코딩 장치는 상기 도출된 MVP 후보를 포함하는 MVP 후보 리스트를 구성할 수 있고, 추가적인 MVP 후보를 더 도출하지 않을 수 있다.
상기 도출된 MVP 후보의 개수가 5개보다 작은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B1 의 움직임 벡터를 스케일링할 수 있고, 스케일링된 벡터를 체크할 수 있다(S840). 예를 들어, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있고, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출하지 않을 수 있다. 상기 스케일링된 벡터는 scaled B1 이라고 나타낼 수 있다.
인코딩 장치/디코딩 장치는 도출된 MVP 후보의 개수가 5개보다 작은지 판단할 수 있다(S845). 상기 도출된 MVP 후보의 개수가 5개인 경우, 인코딩 장치/디코딩 장치는 상기 도출된 MVP 후보를 포함하는 MVP 후보 리스트를 구성할 수 있고, 추가적인 MVP 후보를 더 도출하지 않을 수 있다.
상기 도출된 MVP 후보의 개수가 5개보다 작은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B0 의 움직임 벡터를 스케일링할 수 있고, 스케일링된 벡터를 체크할 수 있다(S850). 예를 들어, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있고, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출하지 않을 수 있다. 상기 스케일링된 벡터는 scaled B0 라고 나타낼 수 있다.
인코딩 장치/디코딩 장치는 도출된 MVP 후보의 개수가 5개보다 작은지 판단할 수 있다(S855). 상기 도출된 MVP 후보의 개수가 5개인 경우, 인코딩 장치/디코딩 장치는 상기 도출된 MVP 후보를 포함하는 MVP 후보 리스트를 구성할 수 있고, 추가적인 MVP 후보를 더 도출하지 않을 수 있다.
상기 도출된 MVP 후보의 개수가 5개보다 작은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 A0 의 움직임 벡터를 스케일링할 수 있고, 스케일링된 벡터를 체크할 수 있다(S860). 예를 들어, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있고, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출하지 않을 수 있다. 상기 스케일링된 벡터는 scaled A0 라고 나타낼 수 있다.
인코딩 장치/디코딩 장치는 도출된 MVP 후보의 개수가 5개보다 작은지 판단할 수 있다(S865). 상기 도출된 MVP 후보의 개수가 5개인 경우, 인코딩 장치/디코딩 장치는 상기 도출된 MVP 후보를 포함하는 MVP 후보 리스트를 구성할 수 있고, 추가적인 MVP 후보를 더 도출하지 않을 수 있다.
상기 도출된 MVP 후보의 개수가 5개보다 작은 경우, 인코딩 장치/디코딩 장치는 상기 주변 블록 B2 의 움직임 벡터를 스케일링할 수 있고, 스케일링된 벡터를 체크할 수 있다(S870). 예를 들어, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하지 않는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출할 수 있고, 상기 스케일링된 벡터와 동일한 MVP 후보가 존재하는 경우, 인코딩 장치/디코딩 장치는 상기 스케일링된 벡터를 상기 현재 블록의 MVP 후보로 도출하지 않을 수 있다. 상기 스케일링된 벡터는 scaled B2 라고 나타낼 수 있다.
한편, 상기 구성된 MVP 후보 리스트에 포함된 MVP 후보들 중 하나의 후보를 나타내는 MVP 인덱스가 시그널링될 수 있고, 따라서, 시그널링 오버헤드(signaling overhead)없이 중복되지 않는 다양한 MVP 후보들이 MVP 후보 리스트에 추가될 수 있도록 중복 체크 과정이 필요하다. 따라서, 예를 들어, 제1 MVP 후보와 제2 MVP 후보가 동일한 경우, 즉, 상기 제1 MVP 후보와 상기 제2 MVP 후보가 동일한 움직임 벡터인 경우, 중복 체크 과정을 통하여 상기 제1 MVP 후보와 상기 제2 MVP 후보 중 상기 MVP 후보 리스트 순서 상 나중 순서의 MVP 후보가 제거될 수 있다.
예를 들어, 상기 MVP 후보 리스트가 다음과 같이 5개의 공간적 MVP 후보 및/또는 시간적 MVP 후보인 {C0, C1, C2, C3, C4} 로 구성되는 경우, 각 MVP 후보를 도출하는 단계에서 중복 체크 과정이 수행될 수 있다. 여기서, 상기 공간적 MVP 후보는 현재 블록의 공간적 주변 블록의 움직임 벡터를 기반으로 도출된 MVP 후보를 나타낼 수 있고, 상기 시간적 MVP 후보는 상기 현재 블록의 시간적 주변 블록의 움직임 벡터를 기반으로 도출된 MVP 후보를 나타낼 수 있다.
먼저, 상기 C0 이 상기 현재 블록의 MVP 후보로 도출될 수 있다. 다음으로, 상기 C1 이 가용한지 판단될 수 있다. 상기 C1 이 가용한 경우, 상기 C0 및 상기 C1 에 대한 중복 체크가 수행될 수 있다. 예를 들어, 상기 C1 이 상기 C0 와 동일한 경우, 즉, 상기 C1 이 상기 C0 와 동일한 움직임 벡터인 경우, 상기 C1 은 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 상기 C1 이 상기 C0 와 동일하지 않은 경우, 즉, 상기 C1 이 상기 C0 와 동일한 움직임 벡터가 아닌 경우, 상기 C1 은 상기 현재 블록의 MVP 후보로 도출될 수 있다.
다음으로, 상기 C2 가 가용한지 판단될 수 있다. 상기 C2 가 가용한 경우, 상기 C0 및 상기 C2 에 대한 중복 체크와 상기 C1 및 상기 C2 에 대한 중복 체크가 수행될 수 있다. 예를 들어, 상기 C2 가 상기 C0 와 동일한 경우, 즉, 상기 C2가 상기 C0 와 동일한 움직임 벡터인 경우, 상기 C2 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C2 가 상기 C1 와 동일한 경우, 즉, 상기 C2가 상기 C1 와 동일한 움직임 벡터인 경우, 상기 C2 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 상기 C2 가 상기 C0 및 상기 C0 와 동일하지 않은 경우, 즉, 상기 C2 가 상기 C0 및 상기 C1와 동일한 움직임 벡터가 아닌 경우, 상기 C2 는 상기 현재 블록의 MVP 후보로 도출될 수 있다.
다음으로, 상기 C3 가 가용한지 판단될 수 있다. 상기 C3 가 가용한 경우, 상기 C0 및 상기 C3 에 대한 중복 체크, 상기 C1 및 상기 C3 에 대한 중복 체크 및 상기 C2 및 상기 C3 에 대한 중복 체크가 수행될 수 있다. 예를 들어, 상기 C3 가 상기 C0 와 동일한 경우, 즉, 상기 C3가 상기 C0 와 동일한 움직임 벡터인 경우, 상기 C3 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C3 가 상기 C1 와 동일한 경우, 즉, 상기 C3가 상기 C1 와 동일한 움직임 벡터인 경우, 상기 C3 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C3 가 상기 C2 와 동일한 경우, 즉, 상기 C3가 상기 C2 와 동일한 움직임 벡터인 경우, 상기 C3 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 상기 C3 가 상기 C0, 상기 C1 및 상기 C2 와 동일하지 않은 경우, 즉, 상기 C3 가 상기 C0, 상기 C1 및 상기 C2와 동일한 움직임 벡터가 아닌 경우, 상기 C3 는 상기 현재 블록의 MVP 후보로 도출될 수 있다.
다음으로, 상기 C4 가 가용한지 판단될 수 있다. 상기 C4 가 가용한 경우, 상기 C0 및 상기 C4 에 대한 중복 체크, 상기 C1 및 상기 C4 에 대한 중복 체크, 상기 C2 및 상기 C4 에 대한 중복 체크 및 상기 C3 및 상기 C4 에 대한 중복 체크가 수행될 수 있다. 예를 들어, 상기 C4 가 상기 C0 와 동일한 경우, 즉, 상기 C4가 상기 C0 와 동일한 움직임 벡터인 경우, 상기 C4 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C4 가 상기 C1 와 동일한 경우, 즉, 상기 C4가 상기 C1 와 동일한 움직임 벡터인 경우, 상기 C4 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C4 가 상기 C2 와 동일한 경우, 즉, 상기 C4가 상기 C2 와 동일한 움직임 벡터인 경우, 상기 C4 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 또한, 상기 C4 가 상기 C3 와 동일한 경우, 즉, 상기 C4가 상기 C3 와 동일한 움직임 벡터인 경우, 상기 C4 는 상기 현재 블록의 MVP 후보로 도출되지 않을 수 있다. 상기 C4 가 상기 C0, 상기 C1, 상기 C2 및 상기 C3 와 동일하지 않은 경우, 즉, 상기 C4 가 상기 C0, 상기 C1, 상기 C2 및 상기 C3와 동일한 움직임 벡터가 아닌 경우, 상기 C4 는 상기 현재 블록의 MVP 후보로 도출될 수 있다.
한편, 상기 현재 블록에 대하여 AMVR(Adaptive Motion Vector Resolution) 툴(tool)이 적용되는 경우, MVP 후보를 라운딩(rounding)한 뒤, 라운딩된 움직임 벡터를 기준으로 중복 체크가 수행될 수 있다. 또한, 상기 현재 블록에 대하여 상기 AMVR 툴이 적용되더라도, MVP 후보에 대한 중복 체크는 상기 MVP 후보의 라운딩되지 않은 움직임 벡터를 기준으로 수행될 수도 있다. 한편, 상기 라운딩된 움직임 벡터, 중복 체크 과정을 통하여 제거된 움직임 벡터, 또는 중복 체크 과정을 통하여 제거된 라운딩된 움직임 벡터는 ALR(AMVP candidate List Refinement)을 위한 후보로 저장될 수 있다.
상술한 내용과 같이 MVP 후보 리스트가 구성된 경우, ALR 을 통하여 상기 MVP 후보 리스트에 대한 리오더링(reordering) 및/또는 리파인먼트(refinement) 과정이 수행되어 수정된(modified) MVP 후보 리스트가 도출될 수 있다. 예를 들어, 현재 블록의 임의의 주변 영역, 상기 현재 블록의 템플릿이 가용한 경우, 상기 ALR 을 통하여 상기 MVP 후보 리스트에 대한 리오더링 및/또는 리파인먼트 과정이 수행될 수 있다. 구체적으로, 인코딩 장치/디코딩 장치는 상기 현재 블록의 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출할 수 있고, 상기 코스트들을 기반으로 상기 MVP 후보들을 재정렬하는 과정 및/또는 상기 MVP 후보들 중 특정 MVP 후보에 대한 리파인 MVP 후보를 도출하는 과정을 수행하여 수정된 MVP 후보 리스트를 도출할 수 있다. 한편, 상기 현재 블록의 템플릿이 가용하지 않은 경우, 상기 MVP 후보 리스트에 대한 리오더링 및/또는 리파인먼트 과정은 수행되지 않을 수 있다. 이 경우, 재정렬되지 않은 순서로 상기 MVP 후보들을 포함하는 상기 MVP 후보 리스트에 대한 MVP 인덱스가 시그널링될 수 있다. 여기서, 상기 MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 또한, 상기 MVP 후보의 템플릿은 상기 MVP 후보가 가리키는 참조 블록의 템플릿을 나타낼 수 있고, 상기 현재 블록의 템플릿과 동일한 사이즈의 영역일 수 있다.
상기 리오더링 및/또는 리파인먼트를 수행하여 상기 수정된 MVP 후보 리스트가 도출된 경우, 상기 수정된 MVP 후보 리스트에 대하여 중복된 움직임 벡터를 나타내는 MVP 후보를 제거하는 과정이 수행될 수 있다. 예를 들어, 인코딩 장치/디코딩 장치는 동일한 움직임 벡터를 나타내는 MVP 후보가 있는지 체크할 수 있고, 동일한 움직임 정보를 나타내는 MVP 후보들이 있는 경우, 상기 MVP 후보들 중 가장 앞선 순서의 MVP 후보를 제외한 MVP 후보를 상기 수정된 MVP 후보 리스트에서 제거할 수 있다. 동일한 움직임 정보를 나타내는 MVP 후보가 있는지 여부를 체크하는 과정은 프루닝 체크(pruning check) 라고 나타낼 수 있다. 한편, 상기 프루닝 체크는 재정렬된 MVP 후보에 대해서만 수행될 수도 있다. 즉, 상기 MVP 후보 리스트의 MVP 후보들에 대한 재정렬 과정이 수행된 경우, 재정렬된 MVP 후보의 움직임 벡터에 대해서만 동일한 움직임 벡터를 나타내는 MVP 후보가 있는지 판단될 수 있다. 이를 통하여, 상기 프루닝 체크 과정은 상기 재정렬된 MVP 후보와 상기 재정렬된 MVP 후보보다 앞선 순서의 MVP 후보와 비교하는 과정만이 수행될 수 있고, 계산 복잡도가 줄어드는 장점이 있다. 또한, 상기 리파인먼트 과정으로 도출된 리파인 MVP 후보의 움직임 벡터에 대해서만 동일한 움직임 벡터를 나타내는 MVP 후보가 있는지 판단될 수 있다. 또한, 상기 영 벡터(zero vector)를 나타내는 MVP 후보에 대해서만 동일한 움직임 벡터를 나타내는 MVP 후보가 있는지 판단될 수도 있다. 이를 통하여 코딩 효율을 향상시킬 수 있다.
한편, 리파인 MVP 후보가 도출된 경우, 후술하는 내용과 같이 수정된 MVP 후보 리스트가 구성될 수도 있다.
도 9는 리파인 MVP 후보를 포함하는 수정된 MVP 후보 리스트를 구성하는 일 예를 나타낸다. 리파인 MVP 후보의 선택률은 리파인 MVP 후보의 위치에 따라 달라질 수 있으므로, 상기 리파인 MVP 후보의 순서에 따라 다른 수정된 MVP 후보 리스트 구성 방법이 고려될 수 있다.
인코딩 장치/디코딩 장치는 상기 리파인 MVP 후보가 재정렬된 순서상 첫번째 순서의 MVP 후보인지 판단할 수 있다(S900). 상기 리파인 MVP 후보가 첫번째 순서의 MVP 후보인 경우, 인코딩 장치/디코딩 장치는 상기 리파인 MVP 후보를 상기 첫번째 순서(S910), 이외의 MVP 후보들을 기존 MVP 후보 리스트의 순서로 재정렬하여 수정된 MVP 후보 리스트를 구성할 수 있다(S920). 상기 리파인 MVP 후보가 첫번째 순서의 MVP 후보가 아닌 경우, 인코딩 장치/디코딩 장치는 수정된 MVP 후보 리스트를 유지할 수 있다(S930).
한편, 상술한 실시예와 다른 수정된 MVP 후보 리스트를 구성하는 방안이 제안될 수 있다. 예를 들어, 도 9에 도시된 것과 같이 리파인 MVP 후보의 순서를 기반으로 수정된 MVP 리스트 구성을 달리하는 방안이 제안될 수도 있으나, 템플릿을 기반으로 도출된 코스트를 특정 임계값과 비교하여 코스트가 상기 특정 임계값보다 작은 MVP 후보는 재정렬된 순서를 유지하고, 코스트가 상기 특정 임계값보다 큰 MVP 후보는 기존 MVP 후보 리스트에서의 순서를 유지하도록 수정된 MVP 후보 리스트를 구성하는 방안이 제안될 수 있다. 또한, 특정 조건에 따라 재정렬 방법을 달리하는 방안이 제안될 수 있으며, 항상 동일한 재정렬 방법을 적용하는 방안도 제안될 수 있다.
한편, 상기 현재 블록의 템플릿과 MVP 후보에 대한 참조 블록의 템플릿을 기반으로 상기 MVP 후보의 코스트를 계산하는 과정은 다음과 같이 후술한다.
예를 들어, 상기 현재 블록의 템플릿과 참조 픽처 상의 상기 MVP 후보가 가리키는 참조 블록의 템플릿을 이용하여 상기 MVP 후보의 코스트가 도출될 수 있고, 상기 코스트는 상기 현재 블록의 템플릿과 상기 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Differences, SAD)으로 도출될 수 있다. 상기 현재 블록과 상기 참조 블록의 인접 영역 유사도를 기반으로 움직임 정보의 정확도가 예측될 수 있다.
도 10은 템플릿을 기반으로 MVP 후보의 코스트를 도출하는 일 예를 나타낸다.
도 10을 참조하면 상기 현재 블록의 상기 템플릿은 상기 현재 블록의 좌측 주변 영역 및/또는 상측 주변 영역을 포함할 수 있고, 상기 참조 블록의 상기 템플릿은 상기 현재 블록의 템플릿과 대응하는 영역일 수 있고, 상기 참조 블록의 상기 템플릿은 상기 참조 블록의 좌측 주변 영역 및/또는 상측 주변 영역을 포함할 수 있다. 상기 현재 블록의 좌측 주변 영역 및/또는 상측 주변 영역이 가용한 경우, 각 주변 영역에 대해 SAD로 상기 MVP 후보의 상기 코스트가 계산될 수 있다. 즉, 예를 들어, 상기 현재 블록의 좌측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 좌측 주변 영역과의 SAD, 상기 현재 블록의 상측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 상측 주변 영역과의 SAD로 상기 코스트가 계산될 수 있다. 여기서, 상기 현재 블록의 상기 템플릿에 포함되는 상기 상측 주변 영역은 상기 현재 블록의 상측 템플릿이라고 나타낼 수 있고, 상기 현재 블록의 상기 템플릿에 포함되는 상기 좌측 주변 영역은 상기 현재 블록의 좌측 템플릿이라고 나타낼 수 있다. 또한, 상기 참조 블록의 상기 템플릿에 포함되는 상기 상측 주변 영역은 상기 참조 블록의 상측 템플릿이라고 나타낼 수 있고, 상기 참조 블록의 상기 템플릿에 포함되는 상기 좌측 주변 영역은 상기 참조 블록의 좌측 템플릿이라고 나타낼 수 있다.
한편, 인터 예측에 대한 움직임 정보는 상술한 바와 같이 쌍예측 움직임 정보 또는 단예측 움직임 정보일 수 있다. 여기서, 상기 쌍예측 움직임 정보는 L0 참조 픽처 인덱스 및 L0 움직임 벡터(L0 움직임 정보), L1 참조 픽처 인덱스 및 L1 움직임 벡터(L1 움직임 정보)를 포함할 수 있고, 상기 단예측 움직임 정보는 L0 참조 픽처 인덱스 및 L0 움직임 벡터(L0 움직임 정보)를 포함할 수 있고, 또는 L1 참조 픽처 인덱스 및 L1 움직임 벡터(L1 움직임 정보)를 포함할 수 있다. 상기 L0은 참조 픽처 리스트 L0(List 0)를 나타내고, 상기 L1은 참조 픽처 리스트 L1(List 1)를 나타낸다.
상기 MVP 후보는 L0 움직임 벡터를 나타낼 수 있고, 또는, L1 움직임 벡터를 나타낼 수 있다.
상기 MVP 후보가 L0 움직임 벡터를 나타내는 경우, 상기 MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보가 가리키는 L0 참조 블록의 템플릿과의 SAD 로 도출될 수 있다.
구체적으로, 상기 MVP 후보의 코스트는 상기 현재 블록의 상기 상측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 상측 주변 영역과의 코스트L0_A 와 상기 현재 블록의 상기 좌측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 좌측 주변 영역과의 코스트L0_L의 합으로 도출될 수 있다. 상기 코스트L0_A 는 상기 현재 블록의 상기 상측 주변 영역과 상기 참조 블록의 상기 상측 주변 영역과의 SAD 일 수 있고, 상기 코스트L0_L 는 상기 현재 블록의 상기 좌측 주변 영역과 상기 참조 블록의 상기 좌측 주변 영역과의 SAD 일 수 있다.
상기 MVP 후보의 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000002
여기서 costL0 는 상기 MVP 후보의 상기 코스트를 나타내고, costL0_A 는 상기 MVP 후보의 코스트L0_A 를 나타내고, costL0_L 는 상기 MVP 후보의 코스트L0_L 를 나타낸다.
또한, 상기 MVP 후보가 L1 움직임 벡터를 나타내는 경우, 상기 MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보가 가리키는 L1 참조 블록의 템플릿과의 SAD 로 도출될 수 있다.
구체적으로, 상기 MVP 후보의 코스트는 상기 현재 블록의 상기 상측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 상측 주변 영역과의 코스트L1_A 와 상기 현재 블록의 상기 좌측 주변 영역과 상기 MVP 후보가 가리키는 참조 블록의 좌측 주변 영역과의 코스트L1_L의 합으로 도출될 수 있다. 상기 코스트L1_A 는 상기 현재 블록의 상기 상측 주변 영역과 상기 참조 블록의 상기 상측 주변 영역과의 SAD 일 수 있고, 상기 코스트L1_L 는 상기 현재 블록의 상기 좌측 주변 영역과 상기 참조 블록의 상기 좌측 주변 영역과의 SAD 일 수 있다.
상기 MVP 후보의 코스트L1는 다음의 수학식을 기반으로 도출될 수 있다.
여기서 costL1 는 상기 MVP 후보의 상기 코스트L1 를 나타내고, costL1_A 는 상기 MVP 후보의 코스트L1_A 를 나타내고, costL1_L 는 상기 MVP 후보의 코스트L1_L 를 나타낸다.
한편, L0 움직임 정보 및 L1 움직임 정보를 포함하는 쌍예측 움직임 정보의 경우, 상기 쌍예측 움직임 정보의 코스트는 코스트L0 및 코스트L1의 평균으로 계산될 수 있다. 여기서, 상기 코스트L0는 상기 현재 블록의 템플릿과 상기 쌍예측 움직임 정보의 L0 움직임 정보가 가리키는 참조 블록의 템플릿과의 SAD 로 도출될 수 있고, 상기 코스트L1는 상기 현재 블록의 템플릿과 상기 쌍예측 움직임 정보의 L1 움직임 정보가 가리키는 참조 블록의 템플릿과의 SAD 로 도출될 수 있다.
상기 쌍예측 움직임 정보의 코스트 는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000004
여기서 costBi 는 상기 쌍예측 움직임 정보의 상기 코스트를 나타내고, costL0 는 상기 쌍예측 움직임 정보의 상기 코스트L1 를 나타내고, costL1 는 상기 쌍예측 움직임 정보의 상기 코스트L1 를 나타낸다.
한편, 템플릿의 가용 여부는 다음과 같은 조건을 기반으로 판단될 수 있다.
- 실제 샘플이 존재하는지 여부
- 슬라이스 혹은 타일 경계 여부
- 인트라 모드 적용 여부
즉, 상기 템플릿에 포함되는 샘플이 존재하는지 여부를 기반으로 상기 템플릿의 가용 여부가 판단될 수 있다. 또한, 상기 템플릿이 슬라이스 혹은 타일 경계에 인접한 영역인지 여부를 기반으로 상기 템플릿의 가용 여부가 판단될 수 있다. 또한, 상기 템플릿이 인트라 모드를 기반으로 디코딩된 영역인지 여부를 기반으로 상기 템플릿의 가용 여부가 판단될 수 있다.
상술한 내용과 같이 템플릿을 기반으로 상기 MVP 후보에 대한 코스트를 도출하는 경우, 상기 주변 블록의 위치에 따라 상기 MVP 후보의 코스트가 달라질 수 있다. 이에, 본 발명은 위치에 따라 코스트가 크게 차이 나는 경우를 방지하고, 코스트 도출 방안을 보다 개선하는 방안을 아래와 같이 제안한다.
예를 들어, 좌측 주변 블록의 움직임 벡터의 좌측 템플릿에 대한 코스트는 다른 MVP 후보의 좌측 템플릿에 대한 코스트보다 작게 도출될 수 있다. 구체적으로, 상기 좌측 주변 블록의 움직임 벡터의 좌측 템플릿에 대한 코스트는 상기 좌측 주변 블록의 움직임 벡터가 가리키는 참조 블록의 좌측 템플릿과 상기 현재 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다. 따라서, 상기 좌측 템플릿은 상기 현재 블록의 좌측 주변 영역이므로 상기 좌측 주변 블록의 복원 블록을 나타낼 수 있고, 상기 참조 블록은 상기 좌측 주변 블록의 움직임 벡터를 기반으로 도출된 참조 블록이므로, 상기 좌측 주변 블록의 움직임 벡터의 상기 좌측 템플릿에 대한 코스트는 복원 블록과 참조 블록과의 디스토션(distortion)을 의미할 수 있고, 상기 좌측 주변 블록의 움직임 벡터의 상기 좌측 템플릿에 대한 코스트는 다른 MVP 후보의 좌측 템플릿에 대한 코스트보다 작게 도출될 수 있다.
또한, 상측 주변 블록의 움직임 벡터의 상측 템플릿에 대한 코스트는 다른 MVP 후보의 상측 템플릿에 대한 코스트보다 작게 도출될 수 있다. 구체적으로, 상기 상측 주변 블록의 움직임 벡터의 상측 템플릿에 대한 코스트는 상기 상측 주변 블록의 움직임 벡터가 가리키는 참조 블록의 상측 템플릿과 상기 현재 블록의 상측 템플릿과의 SAD 로 도출될 수 있다. 따라서, 상기 상측 템플릿은 상기 현재 블록의 상측 주변 영역이므로 상기 상측 주변 블록의 복원 블록을 나타낼 수 있고, 상기 참조 블록은 상기 상측 주변 블록의 움직임 벡터를 기반으로 도출된 참조 블록이므로, 상기 상측 주변 블록의 움직임 벡터의 상기 상측 템플릿에 대한 코스트는 복원 블록과 참조 블록과의 디스토션(distortion)을 의미할 수 있고, 상기 상측 주변 블록의 움직임 벡터의 상기 상측 템플릿에 대한 코스트는 다른 MVP 후보의 좌측 템플릿에 대한 코스트보다 작게 도출될 수 있다.
상술한 템플릿의 위치 및 사이즈에 따라서 코스트가 달라지는 현상은 현재 블록이 비정방형 블록인 경우에 더 심화될 수 있다.
이를 개선하기 위하여 좌측 템플릿 및 상측 템플릿 각각의 코스트를 노말라이제이션(normalization)하여 템플릿 사이즈에 따른 영향을 줄이는 방안이 제안될 수 있다.
예를 들어, 현재 블록의 사이즈가 width x height이고 템플릿 사이즈가 2인 경우, 좌측 템플릿의 사이즈는 (2 x height), 상측 템플릿의 사이즈는 (width x 2) 일 수 있다. 이 경우, 노말라이제이션된 상기 좌측 템플릿의 코스트 및 상기 상측 템플릿의 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000005
여기서, costL'는 노말라이제이션된 상기 좌측 템플릿의 코스트를 나타내고, costA'는 노말라이제이션된 상기 상측 템플릿의 코스트를 나타내고, costL 는 상기 좌측 템플릿의 코스트를 나타내고, costA 는 상기 상측 템플릿의 코스트를 나타내고, width 는 상기 현재 블록의 폭을 나타내고, height 는 상기 현재 블록의 높이를 나타낸다.
한편, 상기 템플릿의 사이즈는 2로 기설정될 수 있다. 또는, 상기 템플릿의 사이즈는 후술하는 실시예들과 같이 변경될 수 있다.
일 예로, 상기 템플릿의 사이즈는 현재 블록의 사이즈를 기반으로 도출될 수도 있다. 예를 들어, 상기 현재 블록의 사이즈가 16x16 사이즈보다 작은 경우, 상기 템플릿의 사이즈는 2로 도출될 수 있고, 상기 현재 블록의 사이즈가 16x16 사이즈보다 크거나 같은 경우, 상기 템플릿의 사이즈는 4로 도출될 수 있다.
상기 템플릿의 사이즈가 도출된 경우, 상기 MVP 후보에 대한 템플릿은 (-n, 0) 의 좌상단 샘플을 포함하고, nxH 사이즈를 갖는 좌측 주변 영역(좌측 템플릿)과, (0, -n) 의 좌상단 샘플을 포함하고, Wxn 사이즈를 갖는 상측 주변 영역(상측 템플릿)을 포함할 수 있다. 여기서, n 은 상기 템플릿의 사이즈를 나타낸다.
한편, 상술한 MVP 후보 리스트를 도출하고 상기 MVP 후보 리스트를 기반으로 현재 블록의 MVP 를 도출하는 실시예들은 현재 블록의 루마 블록의 템플릿만이 고려될 수 있다. 하지만, 도출된 MVP 는 상기 현재 블록의 루마 성분뿐만 아니라 크로마 성분의 움직임 보상(motion compensation) 에 사용될 수 있고, 따라서, 상술한 수학식 5를 기반으로 도출되는 코스트를 사용하여 상기 MVP 를 도출하는 경우, 상기 MVP는 상기 현재 블록의 루마 성분 및 크로마 성분의 움직임 벡터 도출에 대하여 정확하지 않을 수 있다. 이에, 본 발명은 후술하는 내용과 같이 MVP 후보에 대한 코스트를 도출하는 방안을 제안한다.
예를 들어, 현재 블록의 루마 블록의 사이즈가 WLxHL이고, 상기 현재 블록의 크로마 블록의 사이즈가 WCxHC이고, 템플릿 사이즈가 2인 경우, 상기 현재 블록의 좌측 템플릿의 수정된(modified) 코스트 및 상기 현재 블록의 상측 템플릿의 수정된 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000006
여기서, costA(LX) 는 현재 블록의 루마 블록의 상측 템플릿 및 크로마 블록의 상측 템플릿에 대한 수정된 코스트를 나타내고, costL(LX)는 현재 블록의 루마 블록의 좌측 템플릿 및 크로마 블록의 좌측 템플릿에 대한 수정된 코스트를 나타내고, costA(LX, L) 은 상기 현재 블록의 루마 블록의 상측 템플릿의 코스트를 나타내고, costL(LX, L) 은 상기 현재 블록의 루마 블록의 좌측 템플릿의 코스트를 나타내고, costA(LX, C) 은 상기 현재 블록의 크로마 블록의 상측 템플릿의 코스트를 나타내고, costL(LX, C) 은 상기 현재 블록의 크로마 블록의 좌측 템플릿의 코스트를 나타낸다. 또한, WL 는 상기 현재 블록의 상기 루마 블록의 폭을 나타내고, HL 는 상기 현재 블록의 상기 루마 블록의 높이를 나타내고, WC 는 상기 현재 블록의 상기 크로마 블록의 폭을 나타내고, HC 는 상기 현재 블록의 상기 크로마 블록의 높이를 나타낸다. 또한, w 는 가중 계수(weighting factor)를 나타낸다. 상기 루마 블록에 대한 가중 계수가 상기 크로마 블록에 대한 가중 계수보다 크게 설정될 수 있다. 즉, w 가 (1-w) 보다 크게 설정될 수 있는바, 상기 w 가 0.5 보다 큰 값으로 설정될 수 있다. 또한, 상기 가중 계수는 상기 현재 블록을 기반으로 도출될 수 있다. 즉, 상기 가중 계수는 블록 단위로 설정될 수 있다. 또는, 상기 가중 계수는 슬라이스 단위로 기설정될 수 있고, 상기 가중 계수를 기반으로 상기 MVP 후보에 대한 코스트가 도출될 수 있다. 한편, 일 예로, 상기 루마 블록 및 상기 크로마 블록에 대한 라인 버퍼(line buffer)는 각각 2와 1로 정의될 수 있다. 상기 루마 블록 및 상기 크로마 블록에 대한 라인 버퍼는 다른 값으로 정의될 수도 있고, 상기 루마 블록 및 상기 크로마 블록의 사이즈를 기반으로 노말라이제이션된 값이 사용될 수도 있다.
한편, 상기 현재 블록에 국지적 조도 보상(location illumination compensation, LIC)이 적용되는 경우, IC_SAD(Illumination Compensation_SAD) 가 도출되므로 상기 MVP 후보에 대한 코스트 계산 방법은 변경될 수 있다. 상기 IC_SAD 는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000007
Figure PCTKR2018014822-appb-M000008
여기서, Cur 은 현재 블록의 템플릿 내 샘플값을 나타내고, Ref 은 참조 블록의 템플릿 내 샘플값을 나타내고, W 는 상기 현재 블록의 폭을 나타내고, H는 상기 현재 블록의 높이를 나타낸다.
한편, 상기 LIC 에 대한 구체적인 설명은 다음과 같을 수 있다.
영상 내에 광원이나 그림자가 존재하는 경우, 그 영향을 받는 영역에 국지적(local) 조도 변화가 발생한다. 이 경우 블록 내 객체에 대한 예측을 수행함에 있어서, 현재 픽처의 현재 블록과 참조 픽처의 참조 블록 간의 조도의 차이로 인하여 예측의 성능이 감소된다. 이는 비디오 인코딩/디코딩 과정에서 사용되는 일반적인 움직임 추정(estimation)/보상(compensation) 알고리즘에 따르면 이러한 국지적 조도 변화를 보상하지 못하기 때문이다. 반면에, 이러한 국지적 조도 변화를 보상하는 경우, 보다 정확한 예측을 수행할 수 있다.
구체적으로, 조도 보상을 적용하여 보상된 참조 블록을 기반으로 현재 블록을 예측하여 예측의 효율을 높일 수 있으며, 이 경우 예측된 현재 블록과 원본 블록 간의 레지듀얼이 감소되어, 레지듀얼 신호에 할당되는 데이터가 줄어들고 코딩 효율이 향상될 수 있다. 이와 같이 참조 블록에 조도를 보상하여 예측의 효율을 높이는 방법은 국지적 조도 보상(location illumination compensation, LIC)라고 불릴 수 있다. LIC는 IC(illumination compensation)와 혼용될 수도 있다. 상기 IC_SAD 는 상기 조도 보상을 위한 값을 나타낼 수 있다. 즉, 상기 LIC 가 현재 블록에 적용되는 경우, 상기 IC_SAD 를 기반으로 상기 보상된 참조 블록을 도출될 수 있다. 예를 들어, 상기 보상된 참조 블록의 참조 샘플값은 상기 참조 블록의 참조 샘플값에 상기 IC_SAD 를 더한 값으로 도출될 수 있다.
한편, LIC를 위한 부가 정보로서, LIC 의 적용 여부를 나타내기 위한 LIC 플래그가 사용될 수 있다. 예를 들어, 상기 LIC 플래그의 값이 1 인 경우(즉, 상기 LIC 플래그의 값이 '참(true)'인 경우), 상기 LIC 플래그는 현재 블록에 LIC 가 적용됨을 나타낼 수 있고, 상기 LIC 플래그의 값이 0 인 경우(즉, 상기 LIC 플래그의 값이 '거짓(false)'인 경우), 상기 LIC 플래그는 현재 블록에 LIC 가 적용되지 않음을 나타낼 수 있다.
LIC 의 효율을 높이기 위하여는, LIC 를 위한 부가 정보를 최소화하면서 예측 성능을 높이는 것이 중요하다. 예를 들어, 부가 정보를 최소화하기 위하여 특정 사이즈의 CU나 2Nx2N의 파티션 타입을 갖는 PU에 대하여 제한적으로 적용하는 것과 같이 블록 사이즈 또는 파티션 타입을 고려하여 LIC 적용 여부를 결정할 수도 있다. 또한, 상술한 바와 같이 QTBT 구조가 사용되는 경우, CU, PU, TU의 구분 없이 다양한 사이즈의 CU가 사용될 수 있음에 따라, 해당 구조에 적합하도록 LIC 를 적용하여 예측의 정확도를 높일 수 있다.
한편, 상기 IC_SAD은 상기 현재 블록의 템플릿과 MVP 후보가 가리키는 참조 블록의 템플릿을 기반으로 도출되는바, 상기 IC_SAD 가 상기 MVP 후보에 대한 코스트로 사용될 수 있다. 예를 들어, 상기 LIC 플래그의 값이 '참(true)'인 경우, 즉, 상기 LIC 플래그가 상기 현재 블록에 LIC 가 적용됨을 나타내는 경우, 상기 현재 블록의 루마 블록에 대한 상기 MVP 후보의 코스트는 상기 IC_SAD로 도출될 수 있고, 상기 현재 블록의 크로마 블록에 대한 상기 MVP 후보의 코스트는 상기 현재 블록의 상기 크로마 블록의 템플릿과 상기 참조 블록의 크로마 블록의 템플릿과의 SAD로 도출될 수 있다. 또한, 상기 LIC 플래그의 값이 '거짓(false)'인 경우, 즉, 상기 LIC 플래그가 상기 현재 블록에 LIC 가 적용되지 않음을 나타내는 경우, 상기 현재 블록의 루마 블록에 대한 상기 MVP 후보의 코스트는 상기 현재 블록의 상기 루마 블록의 템플릿과 상기 참조 블록의 루마 블록의 템플릿과의 SAD로 도출될 수 있고, 상기 현재 블록의 크로마 블록에 대한 상기 MVP 후보의 코스트는 상기 현재 블록의 상기 크로마 블록의 템플릿과 상기 참조 블록의 크로마 블록의 템플릿과의 SAD로 도출될 수 있다. 상술한 실시예는 일 예로서, 상기 크로마 블록이 고려되는지 여부에 따라서 상기 IC_SAD 가 사용되는 방안은 다양하게 변경될 수 있다. 예를 들어, 상기 가중 계수가 상기 LIC 플래그의 값을 기반으로 도출될 수 있다.
한편, 복잡성을 줄이기 위해 루마 블록과 크로마 블록을 모두 고려한 코스트 도출 방안은 상기 리오더링 과정에 적용되고, 리파인먼트 과정에는 적용되지 않을 수 있다. 즉, 상기 현재 블록의 루마 블록에 대한 상기 MVP 후보의 코스트와 상기 현재 블록의 크로마 블록에 대한 상기 MVP 후보의 코스트를 도출하는 방안은 상기 리오더링 과정에 적용될 수 있고, 상기 리파인먼트 과정은 상기 현재 블록에 대한 MVP 후보의 코스트를 기반으로 수행될 수 있다. 상기 현재 블록에 대한 MVP 후보의 코스트는 상기 루마 블록에 대한 상기 MVP 후보의 코스트를 나타낼 수 있다. 또한, 반대의 경우도 가능할 수 있다. 또한, 상술한 방안은 DMVR(Decoder side Motion Vector Refinement, DMVR)에 의한 코스트 또는 양방향 정합(Bi-lateral matching)에 의한 코스트에도 사용될 수 있다.
한편, 상기 MVP 후보 리스트에 대한 리파인먼트 과정은 넓은 영역에 대한 메모리가 액세스(access)되어야 한다. 즉, 상기 리파인먼트 과정을 수행하기 위하여 많은 하드웨어 자원(hardware resources)가 필요할 수 있다. 이에, 본 발명은 참조 픽처에 대한 제한된 액세스(restricted access)를 기반으로 수행되는 리파인먼트 과정을 제안한다.
도 11은 현재 블록과 L0 참조 블록에 대한 코스트L0 와 상기 현재 블록과 L1 참조 블록에 대한 코스트L1을 도출하는 일 예를 나타낸다.
도 11을 참조하면 상기 현재 블록과 상기 L0 참조 블록에 대한 상기 코스트L0는 상기 현재 블록의 템플릿과 상기 L0 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 L0 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 L0 참조 블록은 L0 움직임 벡터를 나타내는 MVP 후보가 가리키는 참조 블록일 수 있다.
여기서, 상기 현재 블록의 템플릿은 상측 템플릿 및 좌측 템플릿을 포함할 수 있고, 상기 코스트L0는 상측 코스트L0 및 좌측 코스트L0의 합으로 도출될 수 있다. 상기 상측 코스트L0는 상기 현재 블록의 상측 템플릿과 상기 L0 참조 블록의 상측 템플릿과의 SAD 로 도출될 수 있고, 상기 좌측 코스트L0는 상기 현재 블록의 좌측 템플릿과 상기 L0 참조 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다.
또한, 도 11을 참조하면 상기 현재 블록과 상기 L1 참조 블록에 대한 상기 코스트L1은 상기 현재 블록의 템플릿과 상기 L1 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 L1 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 L1 참조 블록은 L1 움직임 벡터를 나타내는 MVP 후보가 가리키는 참조 블록일 수 있다.
여기서, 상기 현재 블록의 템플릿은 상측 템플릿 및 좌측 템플릿을 포함할 수 있고, 상기 코스트L1은 상측 코스트L1 및 좌측 코스트L1의 합으로 도출될 수 있다. 상기 상측 코스트L1은 상기 현재 블록의 상측 템플릿과 상기 L1 참조 블록의 상측 템플릿과의 SAD 로 도출될 수 있고, 상기 좌측 코스트L1은 상기 현재 블록의 좌측 템플릿과 상기 L0 참조 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다.
상기 코스트L0 및 상기 코스트L1이 도출된 경우, 상기 상기 코스트L0 및 상기 코스트L1을 기반으로 다음과 같이 제한된(restricted) 리파인먼트 과정이 수행될 수 있다.
도 12는 상기 코스트L0 및 상기 코스트L1 를 기반으로 수행되는 제한된(restricted) 리파인먼트의 일 예를 나타낸다. 도 12를 참조하면 인코딩 장치/디코딩 장치는 상기 현재 블록과 상기 L0 참조 블록에 대한 상기 코스트L0 를 도출한다(S1200). 상기 현재 블록과 상기 L0 참조 블록에 대한 상기 코스트L0는 상기 현재 블록의 템플릿과 상기 L0 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 L0 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 L0 참조 블록은 L0 움직임 벡터를 나타내는 MVP 후보가 가리키는 참조 블록일 수 있다.
인코딩 장치/디코딩 장치는 상기 현재 블록과 상기 L1 참조 블록에 대한 상기 코스트L1 를 도출한다(S1210). 상기 현재 블록과 상기 L1 참조 블록에 대한 상기 코스트L1은 상기 현재 블록의 템플릿과 상기 L1 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 L1 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 L1 참조 블록은 L1 움직임 벡터를 나타내는 MVP 후보가 가리키는 참조 블록일 수 있다.
인코딩 장치/디코딩 장치는 상기 코스트L1 이 상기 코스트L0 보다 큰지 판단할 수 있다(S1220).
상기 코스트L1 이 상기 코스트L0 보다 큰 경우, 인코딩 장치/디코딩 장치는 상기 L1 움직임 벡터를 나타내는 MVP 후보에 대한 리파인(refine) MVP 후보를 도출할 수 있다(S1230). 예를 들어, 인코딩 장치/디코딩 장치는 상기 L1 움직임 벡터를 나타내는 MVP 후보가 가리키는 상기 L1 참조 블록의 임의의 주변 영역에 포함된 참조 블록들의 템플릿들 중 상기 현재 블록의 템플릿과의 코스트가 작은 템플릿을 도출할 수 있다. 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 움직임 벡터를 리파인 움직임 벡터로 도출할 수 있다. 즉, 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 리파인 움직임 벡터를 상기 리파인 MVP 후보로 도출할 수 있다.
상기 코스트L1 이 상기 코스트L0 보다 크지 않은 경우, 인코딩 장치/디코딩 장치는 상기 L0 움직임 벡터를 나타내는 MVP 후보에 대한 리파인(refine) MVP 후보를 도출할 수 있다(S1240). 예를 들어, 인코딩 장치/디코딩 장치는 상기 L0 움직임 벡터를 나타내는 MVP 후보가 가리키는 상기 L0 참조 블록의 임의의 주변 영역에 포함된 참조 블록들의 템플릿들 중 상기 현재 블록의 템플릿과의 코스트가 작은 템플릿을 도출할 수 있다. 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 움직임 벡터를 리파인 움직임 벡터로 도출할 수 있다. 즉, 인코딩 장치/디코딩 장치는 상기 도출된 템플릿의 참조 블록을 가리키는 리파인 움직임 벡터를 상기 리파인 MVP 후보로 도출할 수 있다.
도 12를 참조하면 L0 예측 및 L1 예측 중 하나의 예측에 대한 참조 픽처만 상기 리파인먼트 과정에 사용될 수 있고, 이를 통하여 상기 리파인먼트 과정을 위한 메모리 액세스를 줄일 수 있다. 여기서, L0 예측은 참조 픽처 리스트 L0 에 포함된 참조 픽처를 기반으로 수행되는 인터 예측을 나타낼 수 있고, L1 예측은 참조 픽처 리스트 L1 에 포함된 참조 픽처를 기반으로 수행되는 인터 예측을 나타낼 수 있다. 또한, 별도의 조건 없이 기설정된 하나의 특정 참조 픽처 리스트에 대한 리파인먼트 과정이 수행될 수도 있다. 한편, 상술한 제한된(restricted) 리파인먼트 과정은 DMVR 에도 적용될 수 있고, 상기 DMVR 에 대한 메모리 액세스를 줄이는데 효과적일 수 있다.
도 13은 본 발명에 따른 인코딩 장치에 의한 비디오 인코딩 방법을 개략적으로 나타낸다. 도 13에서 개시된 방법은 도 1에서 개시된 인코딩 장치에 의하여 수행될 수 있다. 구체적으로 예를 들어, 도 13의 S1300 내지 S1350은 상기 인코딩 장치의 예측부에 의하여 수행될 수 있고, S1360은 상기 인코딩 장치의 엔트로피 인코딩부에 의하여 수행될 수 있다.
인코딩 장치는 현재 블록의 주변 블록을 기반으로 MVP 후보 리스트를 구성한다(S1300). 여기서, 상기 주변 블록은 상기 현재 블록의 좌측 주변 블록, 상측 주변 블록, 우상측 주변 블록, 좌하측 주변 블록 및 좌상측 주변 블록을 포함할 수 있다. 또한, 상기 주변 블록은 상기 현재 블록의 우하측 위치 또는 중심 위치에 대응하는 참조 픽처 내 위치를 포함하는 동일 위치 블록을 포함할 수도 있다. 상기 현재 블록의 사이즈가 WxH 이고, 상기 현재 블록의 좌상단(top-left) 샘플 포지션의 x성분이 0 및 y성분이 0인 경우, 상기 좌측 주변 블록은 (-1, H-1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 상측 주변 블록은 (W-1, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 우상측 주변 블록은 (W, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌하측 주변 블록은 (-1, H) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌상측 주변 블록은 (-1, -1) 좌표의 좌상단 샘플을 포함하는 블록일 수 있다.
예를 들어, 인코딩 장치는 상기 현재 블록의 좌측 주변 블록의 움직임 벡터, 상측 주변 블록의 움직임 벡터, 우상측 주변 블록의 움직임 벡터, 좌하측 주변 블록의 움직임 벡터, 좌상측 주변 블록의 움직임 벡터 순서로 유효성을 판단할 수 있고, 유효한 움직임 벡터를 MVP 후보로 상기 MVP 후보 리스트에 순차적으로 추가할 수 있다.
상기 주변 블록의 움직임 벡터에 대한 유효성은 다음과 같이 판단될 수 있다. 구체적으로, 상기 주변 블록의 움직임 벡터가 제1 움직임 벡터, 제2 움직임 벡터에 해당되는지 여부가 순차적으로 판단될 수 있고, 상기 주변 블록의 상기 움직임 벡터가 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 아닌 경우, 상기 주변 블록의 상기 움직임 벡터가 유효하지 않다고 판단될 수 있다. 여기서, 상기 제1 움직임 벡터는 특정 참조 픽처 리스트에 포함된 특정 참조 픽처에 대한 움직임 벡터이고, 상기 제2 움직임 벡터는 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처에 대한 움직임 벡터일 수 있다. 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처는 상기 현재 블록의 참조 픽처일 수 있다. 한편, 상기 주변 블록의 상기 움직임 벡터가 유효하지 않다고 판단된 경우, 상기 움직임 벡터를 스케일링될 수 있고, 스케일링된 움직임 벡터가 상기 MVP 후보로 상기 MVP 후보 리스트에 추가될 수도 있다.
또한, 인코딩 장치는 상기 주변 블록을 기반으로 최대 개수의 MVP 후보들을 포함한 MVP 후보 리스트를 구성할 수 있다. 예를 들어, 상기 MVP 후보 리스트에 포함된 상기 MVP 후보들의 최대 개수는 5개일 수 있다.
상기 주변 블록을 기반으로 도출된 상기 MVP 후보들의 개수가 상기 최대 개수보다 작은 경우, 인코딩 장치는 상기 현재 블록의 좌측 주변 블록의 스케일링된 움직임 벡터, 상측 주변 블록의 스케일링된 움직임 벡터, 우상측 주변 블록의 스케일링된 움직임 벡터, 좌하측 주변 블록의 스케일링된 움직임 벡터, 좌상측 주변 블록의 스케일링된 움직임 벡터를 기반으로 최대 개수의 MVP 후보들을 포함한 MVP 후보 리스트를 구성할 수 있다. 최대 개수의 MVP 후보들이 구성되도록 상기 좌측 주변 블록의 스케일링된 움직임 벡터, 상기 상측 주변 블록의 스케일링된 움직임 벡터, 상기 우상측 주변 블록의 스케일링된 움직임 벡터, 상기 좌하측 주변 블록의 스케일링된 움직임 벡터, 상기 좌상측 주변 블록의 스케일링된 움직임 벡터 순서로 상기 MVP 후보 리스트에 순차적으로 추가될 수 있다.
한편, 인코딩 장치는 상기 현재 블록에 스킵(skip) 모드, 머지(merge) 모드, 및 AMVP(adaptive motion vector prediction) 모드 중 어느 하나의 모드가 적용되는지 결정할 수 있고, 상기 현재 블록의 예측 모드 정보를 생성할 수 있다. 상기 예측 모드 정보는 상기 현재 블록에 스킵(skip) 모드, 머지(merge) 모드, 및 AMVP(adaptive motion vector prediction) 모드 중 어느 하나의 모드가 적용되는지 나타낼 수 있다. 또한, 상기 현재 블록의 인터 예측에 대한 정보는 상기 예측 모드 정보를 포함할 수 있다.
인코딩 장치는 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출한다(S1310). 인코딩 장치는 상기 MVP 후보들에 대한 코스트들을 도출할 수 있다.
예를 들어, MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보에 대한 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 상기 참조 블록은 상기 MVP 후보가 가리키는 참조 블록을 나타낼 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 코스트는 상술한 수학식 1을 기반으로 도출될 수 있다.
여기서, 상기 현재 블록의 템플릿은 상측 템플릿 및 좌측 템플릿을 포함할 수 있고, 상기 코스트는 상측 코스트 및 좌측 코스트의 합으로 도출될 수 있다. 상기 상측 코스트는 상기 현재 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 상측 템플릿과의 SAD 로 도출될 수 있고, 상기 좌측 코스트는 상기 현재 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다. 한편, 상기 현재 블록의 사이즈가 WxH 이고, 상기 현재 블록의 좌상단(top-left) 샘플 포지션의 x성분이 0 및 y성분이 0인 경우, 상기 현재 블록의 템플릿은 (-n, 0) 좌표의 좌상단 샘플을 포함하고, nxH 사이즈를 갖는 상기 좌측 템플릿과, (0, -n) 의 좌상단 샘플을 포함하고, Wxn 사이즈를 갖는 상기 상측 템플릿으로 도출될 수 있다. 여기서, 상기 n은 상기 템플릿에 대한 사이즈 정보가 나타내는 값을 나타낼 수 있다. 인코딩 장치는 상기 템플릿에 대한 사이즈를 결정할 수 있고, 상기 템플릿에 대한 사이즈 정보를 생성할 수 있다. 상기 인터 예측에 대한 정보는 상기 템플릿에 대한 사이즈 정보를 포함할 수 있다.
또는, 상기 상측 코스트는 상기 현재 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 상측 템플릿과의 SAD 를 상기 상측 템플릿의 사이즈로 노말라이제이션(normalization) 한 값으로 도출될 수 있고, 상기 좌측 코스트는 상기 현재 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 좌측 템플릿과의 SAD 를 상기 좌측 템플릿의 사이즈로 노말라이제이션(normalization) 한 값으로 도출될 수 있다. 상기 좌측 코스트 및 상기 상측 코스트는 상술한 수학식 5를 기반으로 도출될 수 있다.
또한, 다른 예로, MVP 후보의 코스트는 상기 MVP 후보의 상측 코스트 및 상기 MVP 후보의 좌측 코스트의 합으로 도출될 수 있고, 상기 MVP 후보의 상측 코스트는 상기 MVP 후보의 상측 루마 코스트와 상기 MVP 후보의 상측 크로마 코스트를 기반으로 도출될 수 있고, 상기 MVP 후보의 좌측 코스트는 상기 MVP 후보의 좌측 루마 코스트와 상기 MVP 후보의 좌측 크로마 코스트를 기반으로 도출될 수 있다.
상기 MVP 후보의 상기 상측 루마 코스트는 상기 현재 블록의 루마 블록의 상측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 상측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있고, 상기 MVP 후보의 상기 상측 크로마 코스트는 상기 현재 블록의 크로마 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 상측 템플릿과의 SAD 로 도출될 수 있다. 구체적으로, 상기 MVP 후보의 상기 상측 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000009
여기서, costA(LX) 는 상기 MVP 후보의 상기 상측 코스트를 나타낼 수 있고, costA(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 상측 코스트를 나타낼 수 있고, costA(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 상측 코스트를 나타낼 수 있고, WL 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타낼 수 있고, WC 는 상기 현재 블록의 상기 크로마 블록의 폭을 나타낼 수 있고, w 는 가중 계수(weighting factor)를 나타낼 수 있다. 한편, 예를 들어, 상기 가중 계수는 0.5 이상이고 1 이하인 값으로 설정될 수 있다.
또한, 상기 MVP 후보의 상기 좌측 루마 코스트는 상기 현재 블록의 루마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있고, 상기 MVP 후보의 상기 좌측 크로마 코스트는 상기 현재 블록의 크로마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다. 구체적으로, 상기 MVP 후보의 상기 좌측 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000010
여기서, costL(LX) 는 상기 MVP 후보의 상기 좌측 코스트를 나타내고, costL(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 좌측 코스트를 나타낼 수 있고, costL(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 좌측 코스트를 나타낼 수 있고, HL 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타낼 수 있고, HC 는 상기 현재 블록의 상기 크로마 블록의 높이를 나타낼 수 있고, w 는 가중 계수(weighting factor)를 나타낼 수 있다. 한편, 예를 들어, 상기 가중 계수는 0.5 이상이고 1 이하인 값으로 설정될 수 있다.
또한, 상기 현재 블록에 LIC(location illumination compensation)가 적용되는 경우, 상기 루마 코스트는 IC_SAD 로 도출될 수 있다. 상기 현재 블록에 상기 LIC 가 적용되지 않는 경우, 상기 루마 코스트는 상술한 수학식 1을 기반으로 도출될 수 있다.
여기서, 상기 IC_SAD는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000011
Figure PCTKR2018014822-appb-I000001
여기서, Cur 는 상기 현재 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타낼 수 있고, Ref 는 상기 MVP 후보에 대한 참조 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타낼 수 있고, W 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타낼 수 있고, H 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타낼 수 있다. 한편, 상기 크로마 코스트는 상기 IC_SAD 로 도출될 수 있다. 또는, 상기 크로마 코스트가 상기 루마 코스트와 다른 값으로 도출될 수 있다. 상기 크로마 코스트는 상술한 수학식 1을 기반으로 도출될 수도 있다. 한편, 인코딩 장치는 상기 현재 블록의 상기 LIC 적용 여부를 나타내는 LIC 플래그를 생성할 수 있다. 예를 들어, 상기 LIC 플래그의 값이 1인 경우, 상기 LIC 플래그는 상기 현재 블록에 상기 LIC 가 적용됨을 나타낼 수 있고, 상기 LIC 플래그의 값이 0인 경우, 상기 LIC 플래그는 상기 현재 블록에 상기 LIC 가 적용되지 않음을 나타낼 수 있다.
인코딩 장치는 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출한다(S1320).
예를 들어, 인코딩 장치는 상기 MVP 후보들을 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
또는, 인코딩 장치는 상기 MVP 후보들을 코스트가 작은 순으로 재정렬하여 수정된 MVP 후보 리스트를 도출할 수 있다. 또는, 인코딩 장치는 상기 MVP 후보 리스트의 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
한편, MVP 후보에 대한 코스트는 루마 코스트 및 크로마 코스트를 포함할 수 있고, 상기 루마 코스트 및 상기 크로마 코스트가 다른 값으로 도출될 수 있다. 이 경우, 상기 루마 코스트를 기반으로 상기 현재 블록의 루마 블록에 대한 수정된 MVP 후보 리스트가 도출될 수 있고, 상기 크로마 코스트를 기반으로 상기 현재 블록의 크로마 블록에 대한 수정된 MVP 후보 리스트가 도출될 수 있다.
구체적으로, 인코딩 장치는 상기 현재 블록의 루마 블록에 대한 MVP 후보 리스트에 포함된 MVP 후보들을 루마 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 루마 블록에 대한 상기 수정된 MVP 후보 리스트를 도출할 수 있다. 또한, 인코딩 장치는 상기 현재 블록의 크로마 블록에 대한 MVP 후보 리스트에 포함된 MVP 후보들을 크로마 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 크로마 블록에 대한 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
한편, 상기 MVP 후보들이 재정렬된 순서로 상기 특정 MVP 후보로 도출될 수 있다. 또는, 상기 MVP 후보들 중 코스트가 가장 작은 MVP 후보가 상기 특정 MVP 후보로 도출될 수 있다.
구체적으로, 상기 리파인 MVP 후보는 다음과 같이 도출될 수 있다.
일 예로, 인코딩 장치는 탐색 범위 내 참조 블록들의 템플릿들 중 상기 현재 블록의 템플릿과의 코스트가 가장 작은 템플릿을 도출할 수 있고, 상기 도출된 템플릿의 참조 블록을 가리키는 움직임 벡터를 상기 리파인 MVP 후보로 도출할 수 있다. 여기서, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 1 인티저 펠(integer pel) 범위일 수 있다. 또는, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 2 인티저 펠 범위일 수 있다. 또는, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 하프 인티저 펠 범위일 수 있다. 또한, 상술한 예시들 이외의 범위로 상기 탐색 범위가 설정될 수도 있다.
인코딩 장치는 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다. 예를 들어, 상기 리파인 MVP 후보는 상기 특정 MVP 후보에 선행하는 순서로 상기 수정된 MVP 후보 리스트에 추가될 수 있다. 한편, 상기 수정된 MVP 후보 리스트에 상기 리파인 MVP 후보가 추가된 경우, 상기 수정된 MVP 후보 리스트의 MVP 후보들은 재정렬될 수도 있다. 예를 들어, 상기 리파인 MVP 후보가 상기 수정된 MVP 후보 리스트의 첫번째 순서의 MVP 후보인 경우, 상기 리파인 MVP 후보 이외의 MVP 후보들은 상기 MVP 후보 리스트의 순서로 재정렬될 수 있다.
한편, 인코딩 장치는 상기 수정된 MVP 후보 리스트의 MVP 후보가 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 상기 MVP 후보가 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는 경우, 상기 MVP 후보는 상기 수정된 MVP 후보 리스트에서 제거될 수 있다. 인코딩 장치는 상기 수정된 MVP 후보 리스트의 모든 MVP 후보들에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 또는, 인코딩 장치는 상기 리파인 MVP 후보에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 또는, 인코딩 장치는 재정렬된 MVP 후보에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 여기서, 상기 재정렬된 MVP 후보는 상기 MVP 후보 리스트에서의 순서와 상기 재정렬된 MVP 후보 리스트에서의 순서가 다른 MVP 후보일 수 있다.
인코딩 장치는 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출한다(S1330). 인코딩 장치는 상기 수정된 MVP 후보 리스트의 MVP 후보들 중 하나의 MVP 후보를 선택할 수 있고, 상기 선택된 MVP 후보가 나타내는 움직임 벡터를 상기 현재 블록의 상기 MVP로 도출할 수 있다. 인코딩 장치는 상기 수정된 MVP 후보 리스트에 포함된 MVP 후보들 중 상기 선택된 MVP 후보를 가리키는 MVP 인덱스(MVP index)를 생성할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVP 인덱스를 포함할 수 있다.
인코딩 장치는 상기 현재 블록의 상기 MVP 를 기반으로 상기 현재 블록의 움직임 벡터를 도출한다(S1340). 인코딩 장치는 상기 현재 블록의 움직임 벡터를 도출할 수 있고, 상기 MVP 를 기반으로 상기 현재 블록의 MVD(motion vector difference)를 생성할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVD를 포함할 수 있다. 인코딩 장치는 상기 MVP와 상기 MVD의 가산을 통해 상기 현재 블록의 상기 움직임 벡터를 도출할 수 있다.
인코딩 장치는 상기 현재 블록의 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행한다(S1350). 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측 블록이 도출될 수 있고, 상기 예측 블록을 기반으로 복원 블록이 도출될 수 있다. 구체적으로, 인코딩 장치는 상기 움직임 벡터를 기반으로 상기 현재 블록의 참조 픽처 내 참조 블록을 도출할 수 있다. 인코딩 장치는 특정 참조 픽처 리스트에 포함된 특정 참조 픽처를 상기 현재 블록의 참조 픽처로 도출할 수 있고, 상기 참조 픽처 내 상기 움직임 벡터가 가리키는 블록을 상기 현재 블록의 참조 블록으로 도출할 수 있다. 인코딩 장치는 상기 참조 블록을 기반으로 예측 샘플을 생성할 수 있다. 인코딩 장치는 상기 현재 블록의 참조 픽처를 가리키는 참조 픽처 인덱스를 생성할 수 있다. 상기 현재 블록의 인터 예측에 대한 정보는 상기 참조 픽처 인덱스를 포함할 수 있다.
또한, 인코딩 장치는 원본 샘플과 상기 생성된 예측 샘플을 기반으로 레지듀얼(residual) 샘플을 생성할 수 있다. 인코딩 장치는 상기 레지듀얼 샘플을 기반으로 상기 레지듀얼에 관한 정보를 생성할 수 있다. 상기 레지듀얼에 관한 정보는 상기 레지듀얼 샘플에 관한 변환 계수들을 포함할 수 있다. 인코딩 장치는 상기 예측 샘플과 상기 레지듀얼 샘플을 기반으로 상기 복원 샘플을 도출할 수 있다. 즉, 인코딩 장치는 상기 예측 샘플과 상기 레지듀얼 샘플을 더하여 상기 복원 샘플을 도출할 수 있다. 또한, 인코딩 장치는 상기 레지듀얼에 관한 정보를 인코딩하여 비트스트림 형태로 출력할 수 있다. 상기 비트스트림은 네트워크 또는 저장매체를 통하여 디코딩 장치로 전송될 수 있다.
인코딩 장치는 상기 현재 블록의 인터 예측에 대한 정보를 인코딩한다(S1360). 상기 현재 블록에 AMVP 모드가 적용된 경우, 인코딩 장치는 상기 현재 블록의 MVP를 도출하기 위하여 선택된 MVP 후보를 가리키는 MVP 인덱스를 생성할 수 있다. 인코딩 장치는 상기 MVP 인덱스를 인코딩하여 출력할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVP 인덱스를 포함할 수 있다. 또한, 인코딩 장치는 상기 현재 블록의 참조 픽처 인덱스를 생성할 수 있고, 상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스를 포함할 수 있다. 또한, 인코딩 장치는 상기 현재 블록의 MVD를 생성할 수 있고, 상기 인터 예측에 대한 정보는 상기 MVD를 포함할 수 있다. 상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스를 포함할 수 있다. 또한, 인코딩 장치는 상기 현재 블록의 LIC 플래그를 생성할 수 있고, 상기 인터 예측에 대한 정보는 상기 LIC 플래그를 포함할 수 있다.
또한, 인코딩 장치는 상기 레지듀얼 샘플을 기반으로 상기 레지듀얼에 관한 정보를 생성할 수 있다. 상기 레지듀얼에 관한 정보는 상기 레지듀얼 샘플에 관한 변환 계수들을 포함할 수 있다. 인코딩 장치는 상기 레지듀얼에 관한 정보를 인코딩하여 비트스트림 형태로 출력할 수 있다. 상기 비트스트림은 네트워크 또는 저장매체를 통하여 디코딩 장치로 전송될 수 있다.
도 14는 본 발명에 따른 영상 인코딩 방법을 수행하는 인코딩 장치를 개략적으로 나타낸다. 도 13에서 개시된 방법은 도 14에서 개시된 인코딩 장치에 의하여 수행될 수 있다. 구체적으로 예를 들어, 도 14의 상기 인코딩 장치의 예측부는 도 13의 S1300 내지 S1350을 수행할 수 있고, 상기 인코딩 장치의 엔트로피 인코딩부는 도 13의 S1360을 수행할 수 있다.
도 15는 본 발명에 따른 디코딩 장치에 의한 영상 디코딩 방법을 개략적으로 나타낸다. 도 15에서 개시된 방법은 도 2에서 개시된 디코딩 장치에 의하여 수행될 수 있다. 구체적으로 예를 들어, 도 15의 S1500 은 상기 디코딩 장치의 엔트로피 디코딩부에 의하여 수행될 수 있고, S1510 내지 S1560은 상기 디코딩 장치의 예측부에 의하여 수행될 수 있다.
디코딩 장치는 비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득한다(S1500). 디코딩 장치는 비트스트림을 통하여 상기 현재 블록의 인터 예측에 대한 정보를 획득할 수 있다. 상기 인터 예측에 대한 정보는 상기 현재 블록에 스킵(skip) 모드, 머지(merge) 모드, 및 AMVP(adaptive motion vector prediction) 모드 중 어느 하나의 모드가 적용되는지 나타내는 예측 모드 정보를 포함할 수 있다. 상기 현재 블록에 AMVP 모드가 적용되는 경우, 디코딩 장치는 상기 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성할 수 있고, 상기 MVP 후보 리스트에 포함된 MVP 후보들 중 하나의 MVP 후보를 가리키는 MVP 인덱스(merge index)를 획득할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVP 인덱스를 포함할 수 있다. 또한, 상기 인터 예측에 대한 정보는 움직임 벡터 차분(motion vector difference, MVD)를 포함할 수 있다. 또한, 상기 인터 예측에 대한 정보는 상기 현재 블록의 참조 픽처 인덱스를 포함할 수 있다. 상기 참조 픽처 인덱스는 특정 참조 픽처 리스트에 포함된 특정 참조 픽처를 가리킬 수 있고, 상기 특정 참조 픽처는 상기 현재 블록의 참조 픽처로 도출될 수 있다. 여기서, 상기 특정 참조 픽처 리스트는 참조 픽처 리스트 L0(List 0) 또는 참조 픽처 리스트 L1(List 1) 일 수 있다.
디코딩 장치는 현재 블록의 주변 블록을 기반으로 MVP 후보 리스트를 구성한다(S1510). 여기서, 상기 주변 블록은 상기 현재 블록의 좌측 주변 블록, 상측 주변 블록, 우상측 주변 블록, 좌하측 주변 블록 및 좌상측 주변 블록을 포함할 수 있다. 또한, 상기 주변 블록은 상기 현재 블록의 우하측 위치 또는 중심 위치에 대응하는 참조 픽처 내 위치를 포함하는 동일 위치 블록을 포함할 수도 있다. 상기 현재 블록의 사이즈가 WxH 이고, 상기 현재 블록의 좌상단(top-left) 샘플 포지션의 x성분이 0 및 y성분이 0인 경우, 상기 좌측 주변 블록은 (-1, H-1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 상측 주변 블록은 (W-1, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 우상측 주변 블록은 (W, -1) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌하측 주변 블록은 (-1, H) 좌표의 좌상단 샘플을 포함하는 블록이고, 상기 좌상측 주변 블록은 (-1, -1) 좌표의 좌상단 샘플을 포함하는 블록일 수 있다.
예를 들어, 디코딩 장치는 상기 현재 블록의 좌측 주변 블록의 움직임 벡터, 상측 주변 블록의 움직임 벡터, 우상측 주변 블록의 움직임 벡터, 좌하측 주변 블록의 움직임 벡터, 좌상측 주변 블록의 움직임 벡터 순서로 유효성을 판단할 수 있고, 유효한 움직임 벡터를 MVP 후보로 상기 MVP 후보 리스트에 순차적으로 추가할 수 있다.
상기 주변 블록의 움직임 벡터에 대한 유효성은 다음과 같이 판단될 수 있다. 구체적으로, 상기 주변 블록의 움직임 벡터가 제1 움직임 벡터, 제2 움직임 벡터에 해당되는지 여부가 순차적으로 판단될 수 있고, 상기 주변 블록의 상기 움직임 벡터가 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 아닌 경우, 상기 주변 블록의 상기 움직임 벡터가 유효하지 않다고 판단될 수 있다. 여기서, 상기 제1 움직임 벡터는 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처에 대한 움직임 벡터이고, 상기 제2 움직임 벡터는 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처에 대한 움직임 벡터일 수 있다. 한편, 상기 주변 블록의 상기 움직임 벡터가 유효하지 않다고 판단된 경우, 상기 움직임 벡터를 스케일링될 수 있고, 스케일링된 움직임 벡터가 상기 MVP 후보로 상기 MVP 후보 리스트에 추가될 수도 있다.
또한, 디코딩 장치는 상기 주변 블록을 기반으로 최대 개수의 MVP 후보들을 포함한 MVP 후보 리스트를 구성할 수 있다. 예를 들어, 상기 MVP 후보 리스트에 포함된 상기 MVP 후보들의 최대 개수는 5개일 수 있다.
상기 주변 블록을 기반으로 도출된 상기 MVP 후보들의 개수가 상기 최대 개수보다 작은 경우, 디코딩 장치는 상기 현재 블록의 좌측 주변 블록의 스케일링된 움직임 벡터, 상측 주변 블록의 스케일링된 움직임 벡터, 우상측 주변 블록의 스케일링된 움직임 벡터, 좌하측 주변 블록의 스케일링된 움직임 벡터, 좌상측 주변 블록의 스케일링된 움직임 벡터를 기반으로 최대 개수의 MVP 후보들을 포함한 MVP 후보 리스트를 구성할 수 있다. 최대 개수의 MVP 후보들이 구성되도록 상기 좌측 주변 블록의 스케일링된 움직임 벡터, 상기 상측 주변 블록의 스케일링된 움직임 벡터, 상기 우상측 주변 블록의 스케일링된 움직임 벡터, 상기 좌하측 주변 블록의 스케일링된 움직임 벡터, 상기 좌상측 주변 블록의 스케일링된 움직임 벡터 순서로 상기 MVP 후보 리스트에 순차적으로 추가될 수 있다.
디코딩 장치는 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출한다(S1520). 디코딩 장치는 상기 MVP 후보들에 대한 코스트들을 도출할 수 있다.
예를 들어, MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보에 대한 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있다. 상기 참조 블록은 상기 MVP 후보가 가리키는 참조 블록을 나타낼 수 있다. 즉, 상기 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 템플릿의 대응하는 샘플들간 차이의 절대값의 합(Sum of Absolute Difference, SAD)으로 도출될 수 있다. 상기 코스트는 상술한 수학식 1을 기반으로 도출될 수 있다.
여기서, 상기 현재 블록의 템플릿은 상측 템플릿 및 좌측 템플릿을 포함할 수 있고, 상기 코스트는 상측 코스트 및 좌측 코스트의 합으로 도출될 수 있다. 상기 상측 코스트는 상기 현재 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 상측 템플릿과의 SAD 로 도출될 수 있고, 상기 좌측 코스트는 상기 현재 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다. 한편, 상기 현재 블록의 사이즈가 WxH 이고, 상기 현재 블록의 좌상단(top-left) 샘플 포지션의 x성분이 0 및 y성분이 0인 경우, 상기 현재 블록의 템플릿은 (-n, 0) 좌표의 좌상단 샘플을 포함하고, nxH 사이즈를 갖는 상기 좌측 템플릿과, (0, -n) 의 좌상단 샘플을 포함하고, Wxn 사이즈를 갖는 상기 상측 템플릿으로 도출될 수 있다. 여기서, 상기 n은 상기 템플릿에 대한 사이즈 정보가 나타내는 값을 나타낼 수 있다. 디코딩 장치는 비트스트림을 통하여 상기 템플릿에 대한 사이즈 정보를 획득할 수 있다. 예를 들어, 상기 인터 예측에 대한 정보는 상기 사이즈 정보를 포함할 수 있다.
또는, 상기 상측 코스트는 상기 현재 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 상측 템플릿과의 SAD 를 상기 상측 템플릿의 사이즈로 노말라이제이션(normalization) 한 값으로 도출될 수 있고, 상기 좌측 코스트는 상기 현재 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 좌측 템플릿과의 SAD 를 상기 좌측 템플릿의 사이즈로 노말라이제이션(normalization) 한 값으로 도출될 수 있다. 상기 좌측 코스트 및 상기 상측 코스트는 상술한 수학식 5를 기반으로 도출될 수 있다.
또한, 다른 예로, MVP 후보의 코스트는 상기 MVP 후보의 상측 코스트 및 상기 MVP 후보의 좌측 코스트의 합으로 도출될 수 있고, 상기 MVP 후보의 상측 코스트는 상기 MVP 후보의 상측 루마 코스트와 상기 MVP 후보의 상측 크로마 코스트를 기반으로 도출될 수 있고, 상기 MVP 후보의 좌측 코스트는 상기 MVP 후보의 좌측 루마 코스트와 상기 MVP 후보의 좌측 크로마 코스트를 기반으로 도출될 수 있다.
상기 MVP 후보의 상기 상측 루마 코스트는 상기 현재 블록의 루마 블록의 상측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 상측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있고, 상기 MVP 후보의 상기 상측 크로마 코스트는 상기 현재 블록의 크로마 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 상측 템플릿과의 SAD 로 도출될 수 있다. 구체적으로, 상기 MVP 후보의 상기 상측 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000012
여기서, costA(LX) 는 상기 MVP 후보의 상기 상측 코스트를 나타낼 수 있고, costA(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 상측 코스트를 나타낼 수 있고, costA(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 상측 코스트를 나타낼 수 있고, WL 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타낼 수 있고, WC 는 상기 현재 블록의 상기 크로마 블록의 폭을 나타낼 수 있고, w 는 가중 계수(weighting factor)를 나타낼 수 있다. 한편, 예를 들어, 상기 가중 계수는 0.5 이상이고 1 이하인 값으로 설정될 수 있다.
또한, 상기 MVP 후보의 상기 좌측 루마 코스트는 상기 현재 블록의 루마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출될 수 있고, 상기 MVP 후보의 상기 좌측 크로마 코스트는 상기 현재 블록의 크로마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD 로 도출될 수 있다. 구체적으로, 상기 MVP 후보의 상기 좌측 코스트는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000013
여기서, costL(LX) 는 상기 MVP 후보의 상기 좌측 코스트를 나타내고, costL(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 좌측 코스트를 나타낼 수 있고, costL(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 좌측 코스트를 나타낼 수 있고, HL 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타낼 수 있고, HC 는 상기 현재 블록의 상기 크로마 블록의 높이를 나타낼 수 있고, w 는 가중 계수(weighting factor)를 나타낼 수 있다. 한편, 예를 들어, 상기 가중 계수는 0.5 이상이고 1 이하인 값으로 설정될 수 있다.
또한, 상기 인터 예측에 대한 정보는 LIC 플래그를 포함할 수 있고, MVP 후보의 코스트는 루마 코스트 및 크로마 코스트를 포함할 수 있다. 상기 LIC 플래그의 값이 1인 경우, 상기 루마 코스트는 IC_SAD 로 도출될 수 있다. 상기 LIC 플래그의 값이 0인 경우, 상기 루마 코스트는 상술한 수학식 1을 기반으로 도출될 수 있다.
여기서, 상기 IC_SAD는 다음의 수학식을 기반으로 도출될 수 있다.
Figure PCTKR2018014822-appb-M000014
Figure PCTKR2018014822-appb-I000002
여기서, Cur 는 상기 현재 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타낼 수 있고, Ref 는 상기 MVP 후보에 대한 참조 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타낼 수 있고, W 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타낼 수 있고, H 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타낼 수 있다. 한편, 상기 크로마 코스트는 상기 IC_SAD 로 도출될 수 있다. 또는, 상기 크로마 코스트가 상기 루마 코스트와 다른 값으로 도출될 수 있다. 상기 크로마 코스트는 상술한 수학식 1을 기반으로 도출될 수도 있다.
디코딩 장치는 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출한다(S1530).
예를 들어, 디코딩 장치는 상기 MVP 후보들을 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
또는, 디코딩 장치는 상기 MVP 후보들을 코스트가 작은 순으로 재정렬하여 수정된 MVP 후보 리스트를 도출할 수 있다. 또는, 디코딩 장치는 상기 MVP 후보 리스트의 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
한편, MVP 후보에 대한 코스트는 루마 코스트 및 크로마 코스트를 포함할 수 있고, 상기 루마 코스트 및 상기 크로마 코스트가 다른 값으로 도출될 수 있다. 이 경우, 상기 루마 코스트를 기반으로 상기 현재 블록의 루마 블록에 대한 수정된 MVP 후보 리스트가 도출될 수 있고, 상기 크로마 코스트를 기반으로 상기 현재 블록의 크로마 블록에 대한 수정된 MVP 후보 리스트가 도출될 수 있다.
구체적으로, 디코딩 장치는 상기 현재 블록의 루마 블록에 대한 MVP 후보 리스트에 포함된 MVP 후보들을 루마 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 루마 블록에 대한 상기 수정된 MVP 후보 리스트를 도출할 수 있다. 또한, 디코딩 장치는 상기 현재 블록의 크로마 블록에 대한 MVP 후보 리스트에 포함된 MVP 후보들을 크로마 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출할 수 있고, 상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출할 수 있고, 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 크로마 블록에 대한 상기 수정된 MVP 후보 리스트를 도출할 수 있다.
한편, 상기 MVP 후보들이 재정렬된 순서로 상기 특정 MVP 후보로 도출될 수 있다. 또는, 상기 MVP 후보들 중 코스트가 가장 작은 MVP 후보가 상기 특정 MVP 후보로 도출될 수 있다.
구체적으로, 상기 리파인 MVP 후보는 다음과 같이 도출될 수 있다.
일 예로, 디코딩 장치는 탐색 범위 내 참조 블록들의 템플릿들 중 상기 현재 블록의 템플릿과의 코스트가 가장 작은 템플릿을 도출할 수 있고, 상기 도출된 템플릿의 참조 블록을 가리키는 움직임 벡터를 상기 리파인 MVP 후보로 도출할 수 있다. 여기서, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 1 인티저 펠(integer pel) 범위일 수 있다. 또는, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 2 인티저 펠 범위일 수 있다. 또는, 상기 탐색 범위는 상기 특정 MVP 후보가 가리키는 위치 주변의 하프 인티저 펠 범위일 수 있다. 또한, 상술한 예시들 이외의 범위로 상기 탐색 범위가 설정될 수도 있다.
디코딩 장치는 상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출할 수 있다. 예를 들어, 상기 리파인 MVP 후보는 상기 특정 MVP 후보에 선행하는 순서로 상기 수정된 MVP 후보 리스트에 추가될 수 있다. 한편, 상기 수정된 MVP 후보 리스트에 상기 리파인 MVP 후보가 추가된 경우, 상기 수정된 MVP 후보 리스트의 MVP 후보들은 재정렬될 수도 있다. 예를 들어, 상기 리파인 MVP 후보가 상기 수정된 MVP 후보 리스트의 첫번째 순서의 MVP 후보인 경우, 상기 리파인 MVP 후보 이외의 MVP 후보들은 상기 MVP 후보 리스트의 순서로 재정렬될 수 있다.
한편, 디코딩 장치는 상기 수정된 MVP 후보 리스트의 MVP 후보가 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 상기 MVP 후보가 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는 경우, 상기 MVP 후보는 상기 수정된 MVP 후보 리스트에서 제거될 수 있다. 디코딩 장치는 상기 수정된 MVP 후보 리스트의 모든 MVP 후보들에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 또는, 디코딩 장치는 상기 리파인 MVP 후보에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 또는, 디코딩 장치는 재정렬된 MVP 후보에 대하여 앞선 순서의 MVP 후보와 동일한 움직임 벡터를 나타내는지 여부를 판단할 수 있다. 여기서, 상기 재정렬된 MVP 후보는 상기 MVP 후보 리스트에서의 순서와 상기 재정렬된 MVP 후보 리스트에서의 순서가 다른 MVP 후보일 수 있다.
디코딩 장치는 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출한다(S1540). 디코딩 장치는 상기 수정된 MVP 후보 리스트의 MVP 후보들 중 하나의 MVP 후보를 선택할 수 있고, 상기 선택된 MVP 후보가 나타내는 움직임 벡터를 상기 현재 블록의 MVP로 도출할 수 있다. 구체적으로, 예를 들어, 디코딩 장치는 비트스트림을 통하여 상기 수정된 MVP 후보 리스트에 포함된 MVP 후보들 중 하나의 MVP 후보를 가리키는 MVP 인덱스(MVP index)를 획득할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVP 인덱스를 포함할 수 있다. 디코딩 장치는 상기 수정된 MVP 후보 리스트의 MVP 후보들 중 상기 MVP 인덱스가 가리키는 MVP 후보의 움직임 벡터를 상기 현재 블록의 MVP 로 도출할 수 있다.
디코딩 장치는 상기 현재 블록의 상기 MVP 및 MVD(motion vector difference)를 기반으로 상기 현재 블록의 움직임 벡터를 도출한다(S1550). 디코딩 장치는 비트스트림을 통하여 상기 현재 블록의 상기 MVD를 획득할 수 있다. 상기 인터 예측에 대한 정보는 상기 MVD를 포함할 수 있다. 디코딩 장치는 상기 MVP와 상기 MVD의 가산을 통해 상기 현재 블록의 상기 움직임 벡터를 도출할 수 있다.
디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행한다(S1560). 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측 블록이 도출될 수 있고, 상기 예측 블록을 기반으로 복원 블록이 도출될 수 있다. 구체적으로, 디코딩 장치는 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 참조 픽처 내 참조 블록을 도출할 수 있다. 디코딩 장치는 상기 참조 픽처 인덱스가 가리키는 특정 참조 픽처 리스트에 포함된 특정 참조 픽처를 상기 현재 블록의 참조 픽처로 도출할 수 있고, 상기 참조 픽처 내 상기 움직임 벡터가 가리키는 블록을 상기 현재 블록의 참조 블록으로 도출할 수 있다. 디코딩 장치는 상기 참조 블록을 기반으로 예측 샘플을 생성할 수 있고, 예측 모드에 따라 상기 예측 샘플을 바로 복원 샘플로 이용할 수도 있고, 또는 상기 예측 샘플에 레지듀얼 샘플을 더하여 복원 샘플을 생성할 수도 있다. 디코딩 장치는 상기 현재 블록에 대한 레지듀얼 샘플이 존재하는 경우, 상기 비트스트림으로부터 상기 현재 블록에 대한 레지듀얼에 관한 정보를 획득할 수 있다. 상기 레지듀얼에 관한 정보는 상기 레지듀얼 샘플에 관한 변환 계수를 포함할 수 있다. 디코딩 장치는 상기 레지듀얼 정보를 기반으로 상기 현재 블록에 대한 상기 레지듀얼 샘플(또는 레지듀얼 샘플 어레이)을 도출할 수 있다. 디코딩 장치는 상기 예측 샘플과 상기 레지듀얼 샘플을 기반으로 복원 샘플을 생성할 수 있고, 상기 복원 샘플을 기반으로 복원 블록 또는 복원 픽처를 도출할 수 있다. 이후 디코딩 장치는 필요에 따라 주관적/객관적 화질을 향상시키기 위하여 디블록킹 필터링 및/또는 SAO 절차와 같은 인루프 필터링 절차를 상기 복원 픽처에 적용할 수 있음은 상술한 바와 같다.
도 16은 본 발명에 따른 영상 디코딩 방법을 수행하는 디코딩 장치를 개략적으로 나타낸다. 도 15에서 개시된 방법은 도 16에서 개시된 디코딩 장치에 의하여 수행될 수 있다. 구체적으로 예를 들어, 도 16의 상기 디코딩 장치의 엔트로피 디코딩부는 도 15의 S1500을 수행할 수 있고, 도 16의 상기 디코딩 장치의 예측부는 도 15의 S1510 내지 S1560을 수행할 수 있다.
상술한 본 발명에 따르면 주변 블록들을 기반으로 다양한 MVP 후보를 포함한 MVP 후보 리스트를 도출할 수 있고, 이를 통하여, 예측 정확도를 향상시키고 MVD 의 전송을 위한 비트량을 감소시키고 전반적인 코딩 효율을 향상시킬 수 있다.
또한, 본 발명에 따르면 코스트를 고려하여 현재 블록에 대한 최적의 MVP 후보가 작은 값의 MVP 인덱스로 나타내는 순서로 재정렬될 수 있고, 이를 통하여, 예측을 위한 비트량을 감소시키고 전반적인 코딩 효율을 향상시킬 수 있다.
또한, 본 발명에 따르면 현재 블록의 루마 성분 및 크로마 성분을 고려한 코스트를 도출하고, 상기 코스트를 기반으로 현재 블록에 대한 최적의 MVP 후보 리스트를 구성할 수 있고, 이를 통하여, 루마 성분 및 크로마 성분의 예측 정확도 및 효율을 향상시키고 전반적인 코딩 효율을 향상시킬 수 있다.
또한, 본 발명에 따르면 현재 블록의 MVP 후보를 기반으로 최적의 MVP 후보인 리파인 MVP 후보를 도출할 수 있고, 이를 통하여, 예측 정확도 및 효율을 향상시킬 수 있고 전반적인 코딩 효율을 향상시킬 수 있다.
상술한 실시예에서, 방법들은 일련의 단계 또는 블록으로써 순서도를 기초로 설명되고 있지만, 본 발명은 단계들의 순서에 한정되는 것은 아니며, 어떤 단계는 상술한 바와 다른 단계와 다른 순서로 또는 동시에 발생할 수 있다. 또한, 당업자라면 순서도에 나타내어진 단계들이 배타적이지 않고, 다른 단계가 포함되거나 순서도의 하나 또는 그 이상의 단계가 본 발명의 범위에 영향을 미치지 않고 삭제될 수 있음을 이해할 수 있을 것이다.
상술한 본 발명에 따른 방법은 소프트웨어 형태로 구현될 수 있으며, 본 발명에 따른 인코딩 장치 및/또는 디코딩 장치는 예를 들어 TV, 컴퓨터, 스마트폰, 셋톱박스, 디스플레이 장치 등의 영상 처리를 수행하는 장치에 포함될 수 있다.
본 발명에서 실시예들이 소프트웨어로 구현될 때, 상술한 방법은 상술한 기능을 수행하는 모듈(과정, 기능 등)로 구현될 수 있다. 모듈은 메모리에 저장되고, 프로세서에 의해 실행될 수 있다. 메모리는 프로세서 내부 또는 외부에 있을 수 있고, 잘 알려진 다양한 수단으로 프로세서와 연결될 수 있다. 프로세서는 ASIC(application-specific integrated circuit), 다른 칩셋, 논리 회로 및/또는 데이터 처리 장치를 포함할 수 있다. 메모리는 ROM(read-only memory), RAM(random access memory), 플래쉬 메모리, 메모리 카드, 저장 매체 및/또는 다른 저장 장치를 포함할 수 있다. 즉, 본 발명에서 설명한 실시예들은 프로세서, 마이크로 프로세서, 컨트롤러 또는 칩 상에서 구현되어 수행될 수 있다. 예를 들어, 각 도면에서 도시한 기능 유닛들은 컴퓨터, 프로세서, 마이크로 프로세서, 컨트롤러 또는 칩 상에서 구현되어 수행될 수 있다.
또한, 본 발명이 적용되는 디코딩 장치 및 인코딩 장치는 멀티미디어 방송 송수신 장치, 모바일 통신 단말, 홈 시네마 비디오 장치, 디지털 시네마 비디오 장치, 감시용 카메라, 비디오 대화 장치, 비디오 통신과 같은 실시간 통신 장치, 모바일 스트리밍 장치, 저장 매체, 캠코더, 주문형 비디오(VoD) 서비스 제공 장치, OTT 비디오(Over the top video) 장치, 인터넷 스트리밍 서비스 제공 장치, 3차원(3D) 비디오 장치, 화상 전화 비디오 장치, 및 의료용 비디오 장치 등에 포함될 수 있으며, 비디오 신호 또는 데이터 신호를 처리하기 위해 사용될 수 있다. 예를 들어, OTT 비디오(Over the top video) 장치로는 게임 콘솔, 블루레이 플레이어, 인터넷 접속 TV, 홈시어터 시스템, 스마트폰, 태블릿 PC, DVR(Digital Video Recoder) 등을 포함할 수 있다.
또한, 본 발명이 적용되는 처리 방법은 컴퓨터로 실행되는 프로그램의 형태로 생산될 수 있으며, 컴퓨터가 판독할 수 있는 기록 매체에 저장될 수 있다. 본 발명에 따른 데이터 구조를 가지는 멀티미디어 데이터도 또한 컴퓨터가 판독할 수 있는 기록 매체에 저장될 수 있다. 상기 컴퓨터가 판독할 수 있는 기록 매체는 컴퓨터로 읽을 수 있는 데이터가 저장되는 모든 종류의 저장 장치 및 분산 저장 장치를 포함한다. 상기 컴퓨터가 판독할 수 있는 기록 매체는, 예를 들어, 블루레이 디스크(BD), 범용 직렬 버스(USB), ROM, PROM, EPROM, EEPROM, RAM, CD-ROM, 자기 테이프, 플로피 디스크 및 광학적 데이터 저장 장치를 포함할 수 있다. 또한, 상기 컴퓨터가 판독할 수 있는 기록 매체는 반송파(예를 들어, 인터넷을 통한 전송)의 형태로 구현된 미디어를 포함한다. 또한, 인코딩 방법으로 생성된 비트스트림이 컴퓨터가 판독할 수 있는 기록 매체에 저장되거나 유무선 통신 네트워크를 통해 전송될 수 있다. 또한, 본 발명의 실시예는 프로그램 코드에 의한 컴퓨터 프로그램 제품으로 구현될 수 있고, 상기 프로그램 코드는 본 발명의 실시예에 의해 컴퓨터에서 수행될 수 있다. 상기 프로그램 코드는 컴퓨터에 의해 판독 가능한 캐리어 상에 저장될 수 있다.
또한, 본 발명이 적용되는 컨텐츠 스트리밍 시스템은 크게 인코딩 서버, 스트리밍 서버, 웹 서버, 미디어 저장소, 사용자 장치 및 멀티미디어 입력 장치를 포함할 수 있다.
상기 인코딩 서버는 스마트폰, 카메라, 캠코더 등과 같은 멀티미디어 입력 장치들로부터 입력된 컨텐츠를 디지털 데이터로 압축하여 비트스트림을 생성하고 이를 상기 스트리밍 서버로 전송하는 역할을 한다. 다른 예로, 스마트폰, 카메라, 캠코더 등과 같은 멀티미디어 입력 장치들이 비트스트림을 직접 생성하는 경우, 상기 인코딩 서버는 생략될 수 있다. 상기 비트스트림은 본 발명이 적용되는 인코딩 방법 또는 비트스트림 생성 방법에 의해 생성될 수 있고, 상기 스트리밍 서버는 상기 비트스트림을 전송 또는 수신하는 과정에서 일시적으로 상기 비트스트림을 저장할 수 있다.
상기 스트리밍 서버는 웹 서버를 통한 사용자 요청에 기초하여 멀티미디어 데이터를 사용자 장치에 전송하고, 상기 웹 서버는 사용자에게 어떠한 서비스가 있는지를 알려주는 매개체 역할을 한다. 사용자가 상기 웹 서버에 원하는 서비스를 요청하면, 상기 웹 서버는 이를 스트리밍 서버에 전달하고, 상기 스트리밍 서버는 사용자에게 멀티미디어 데이터를 전송한다. 이때, 상기 컨텐츠 스트리밍 시스템은 별도의 제어 서버를 포함할 수 있고, 이 경우 상기 제어 서버는 상기 컨텐츠 스트리밍 시스템 내 각 장치 간 명령/응답을 제어하는 역할을 한다.
상기 스트리밍 서버는 미디어 저장소 및/또는 인코딩 서버로부터 컨텐츠를 수신할 수 있다. 예를 들어, 상기 인코딩 서버로부터 컨텐츠를 수신하게 되는 경우, 상기 컨텐츠를 실시간으로 수신할 수 있다. 이 경우, 원활한 스트리밍 서비스를 제공하기 위하여 상기 스트리밍 서버는 상기 비트스트림을 일정 시간동안 저장할 수 있다.
상기 사용자 장치의 예로는, 휴대폰, 스마트 폰(smart phone), 노트북 컴퓨터(laptop computer), 디지털방송용 단말기, PDA(personal digital assistants), PMP(portable multimedia player), 네비게이션, 슬레이트 PC(slate PC), 태블릿 PC(tablet PC), 울트라북(ultrabook), 웨어러블 디바이스(wearable device, 예를 들어, 워치형 단말기 (smartwatch), 글래스형 단말기 (smart glass), HMD(head mounted display)), 디지털 TV, 데스크탑 컴퓨터, 디지털 사이니지 등이 있을 수 있다. 상기 컨텐츠 스트리밍 시스템 내 각 서버들은 분산 서버로 운영될 수 있으며, 이 경우 각 서버에서 수신하는 데이터는 분산 처리될 수 있다.

Claims (17)

  1. 디코딩 장치에 의하여 수행되는 영상 디코딩 방법에 있어서,
    비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득하는 단계;
    상기 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하는 단계;
    상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하는 단계;
    상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하는 단계;
    상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하는 단계;
    상기 현재 블록의 상기 MVP 및 MVD(motion vector difference)를 기반으로 상기 현재 블록의 움직임 벡터를 도출하는 단계; 및
    상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 단계를 포함하되,
    상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스 및 상기 MVD를 포함하는 것을 특징으로 하는 영상 디코딩 방법.
  2. 제1항에 있어서,
    상기 주변 블록은 상기 현재 블록의 좌측 주변 블록, 상기 현재 블록의 상측 주변 블록, 상기 현재 블록의 우상측 주변 블록, 상기 현재 블록의 좌하측 주변 블록 및 상기 현재 블록의 좌상측 주변 블록을 포함하는 것을 특징으로 하는 영상 디코딩 방법.
  3. 제2항에 있어서,
    상기 현재 블록의 상기 주변 블록을 기반으로 상기 MVP 후보 리스트를 구성하는 단계는,
    상기 현재 블록의 좌측 주변 블록의 움직임 벡터, 상측 주변 블록의 움직임 벡터, 우상측 주변 블록의 움직임 벡터, 좌하측 주변 블록의 움직임 벡터, 좌상측 주변 블록의 움직임 벡터 순서로 유효성을 판단하는 단계; 및
    유효한 움직임 벡터를 MVP 후보로 상기 MVP 후보 리스트에 순차적으로 추가하는 단계를 포함하는 것을 특징으로 하는 영상 디코딩 방법.
  4. 제3항에 있어서,
    상기 참조 픽처 인덱스는 특정 참조 픽처 리스트에 포함된 특정 참조 픽처를 가리키고,
    상기 주변 블록의 움직임 벡터가 제1 움직임 벡터, 제2 움직임 벡터에 해당되는지 여부가 순차적으로 판단되고,
    상기 주변 블록의 상기 움직임 벡터가 상기 제1 움직임 벡터 및 상기 제2 움직임 벡터가 아닌 경우, 상기 주변 블록의 상기 움직임 벡터가 유효하지 않다고 판단되되,
    상기 제1 움직임 벡터는 상기 특정 참조 픽처 리스트에 포함된 상기 특정 참조 픽처에 대한 움직임 벡터이고,
    상기 제2 움직임 벡터는 상기 특정 참조 픽처 리스트가 아닌 참조 픽처 리스트에 포함된 상기 특정 참조 픽처에 대한 움직임 벡터인 것을 특징으로 하는 영상 디코딩 방법.
  5. 제2항에 있어서,
    상기 MVP 후보 리스트에 포함된 상기 MVP 후보들의 최대 개수는 5개인 것을 특징으로 하는 영상 디코딩 방법.
  6. 제1항에 있어서,
    MVP 후보의 코스트는 상기 현재 블록의 템플릿과 상기 MVP 후보에 대한 참조 블록의 템플릿과의 SAD(Sum of Absolute Difference) 로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  7. 제6항에 있어서,
    상기 현재 블록의 상기 템플릿은 상측 템플릿 및 좌측 템플릿을 포함하고,
    상기 코스트는 상측 코스트 및 좌측 코스트의 합으로 도출되고,
    상기 상측 코스트는 상기 현재 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 상측 템플릿과의 SAD 로 도출되고,
    상기 좌측 코스트는 상기 현재 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 좌측 템플릿과의 SAD 로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  8. 제1항에 있어서,
    MVP 후보의 코스트는 상기 MVP 후보의 상측 코스트 및 상기 MVP 후보의 좌측 코스트의 합으로 도출되고,
    상기 MVP 후보의 상측 코스트는 상기 MVP 후보의 상측 루마 코스트와 상기 MVP 후보의 상측 크로마 코스트를 기반으로 도출되고,
    상기 MVP 후보의 좌측 코스트는 상기 MVP 후보의 좌측 루마 코스트와 상기 MVP 후보의 좌측 크로마 코스트를 기반으로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  9. 제8항에 있어서,
    상기 MVP 후보의 상기 상측 루마 코스트는 상기 현재 블록의 루마 블록의 상측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 상측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출되고,
    상기 MVP 후보의 상기 상측 크로마 코스트는 상기 현재 블록의 크로마 블록의 상측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 상측 템플릿과의 SAD 로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  10. 제9항에 있어서,
    상기 MVP 후보의 상기 상측 코스트는 다음의 수학식을 기반으로 도출되고,
    Figure PCTKR2018014822-appb-I000003
    여기서, costA(LX) 는 상기 MVP 후보의 상기 상측 코스트를 나타내고, costA(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 상측 코스트를 나타내고, costA(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 상측 코스트를 나타내고, WL 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타내고, WC 는 상기 현재 블록의 상기 크로마 블록의 폭을 나타내고, w 는 가중 계수(weighting factor)를 나타내는 것을 특징으로 하는 영상 디코딩 방법.
  11. 제8항에 있어서,
    상기 MVP 후보의 상기 좌측 루마 코스트는 상기 현재 블록의 루마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD(Sum of Absolute Difference) 로 도출되고,
    상기 MVP 후보의 상기 좌측 크로마 코스트는 상기 현재 블록의 크로마 블록의 좌측 템플릿과 상기 MVP 후보에 대한 상기 참조 블록의 크로마 블록의 좌측 템플릿과의 SAD 로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  12. 제11항에 있어서,
    상기 MVP 후보의 상기 좌측 코스트는 다음의 수학식을 기반으로 도출되고,
    Figure PCTKR2018014822-appb-I000004
    여기서, costL(LX) 는 상기 MVP 후보의 상기 좌측 코스트를 나타내고, costL(LX, L) 는 상기 현재 블록의 상기 루마 블록의 상기 좌측 코스트를 나타내고, costL(LX, C) 는 상기 현재 블록의 상기 크로마 블록의 상기 좌측 코스트를 나타내고, HL 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타내고, HC 는 상기 현재 블록의 상기 크로마 블록의 높이를 나타내고, w 는 가중 계수(weighting factor)를 나타내는 것을 특징으로 하는 영상 디코딩 방법.
  13. 제1항에 있어서
    상기 인터 예측에 대한 정보는 LIC 플래그를 포함하고,
    MVP 후보의 코스트는 루마 코스트 및 크로마 코스트를 포함하고,
    상기 LIC 플래그의 값이 1인 경우, 상기 루마 코스트는 IC_SAD 로 도출되는 것을 특징으로 하는 영상 디코딩 방법.
  14. 제13항에 있어서,
    상기 IC_SAD는 다음의 수학식을 기반으로 도출되고,
    Figure PCTKR2018014822-appb-I000005
    Figure PCTKR2018014822-appb-I000006
    여기서, Cur 는 상기 현재 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타내고, Ref 는 상기 MVP 후보에 대한 참조 블록의 루마 블록의 템플릿에 포함된 복원 샘플을 나타내고, W 는 상기 현재 블록의 상기 루마 블록의 폭(width)을 나타내고, H 는 상기 현재 블록의 상기 루마 블록의 높이(height)를 나타내는 것을 특징으로 하는 영상 디코딩 방법.
  15. 제1항에 있어서,
    상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하는 단계는,
    상기 MVP 후보들을 코스트가 작은 순으로 재정렬하여 재정렬된 MVP 후보 리스트를 도출하는 단계;
    상기 MVP 후보들 중 특정 MVP 후보를 기반으로 리파인 MVP 후보를 도출하는 단계;
    상기 리파인 MVP 후보를 상기 재정렬된 MVP 후보 리스트에 추가하여 상기 수정된 MVP 후보 리스트를 도출하는 단계를 포함하는 것을 특징으로 하는 영상 디코딩 방법.
  16. 영상 디코딩을 수행하는 디코딩 장치에 있어서,
    비트스트림을 통하여 현재 블록의 인터 예측에 대한 정보를 획득하는 엔트로피 디코딩부; 및
    상기 현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하고, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하고, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하고, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하고, 상기 현재 블록의 상기 MVP 및 MVD(motion vector difference)를 기반으로 상기 현재 블록의 움직임 벡터를 도출하고, 상기 현재 블록의 참조 픽처 인덱스 및 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 예측부를 포함하되,
    상기 인터 예측에 대한 정보는 상기 참조 픽처 인덱스 및 상기 MVD를 포함하는 것을 특징으로 하는 디코딩 장치.
  17. 영상 인코딩을 수행하는 인코딩 장치에 있어서,
    현재 블록의 주변 블록을 기반으로 MVP(motion vector predictor) 후보 리스트를 구성하고, 상기 MVP 후보 리스트에 포함된 MVP 후보들에 대한 코스트들을 도출하고, 상기 MVP 후보들에 대한 상기 코스트들을 기반으로 수정된 MVP 후보 리스트를 도출하고, 상기 수정된 MVP 후보 리스트를 기반으로 상기 현재 블록의 MVP를 도출하고, 상기 현재 블록의 상기 MVP 를 기반으로 상기 현재 블록의 움직임 벡터를 도출하고, 상기 현재 블록의 상기 움직임 벡터를 기반으로 상기 현재 블록의 예측을 수행하는 예측부; 및
    상기 현재 블록의 인터 예측에 대한 정보를 인코딩하는 엔트로피 인코딩부를 포함하되,
    상기 인터 예측에 대한 정보는 상기 현재 블록의 참조 픽처를 가리키는 참조 픽처 인덱스 및 MVD(motion vector difference)를 포함하는 것을 특징으로 하는 인코딩 장치.
PCT/KR2018/014822 2017-11-30 2018-11-28 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치 WO2019107916A1 (ko)

Priority Applications (2)

Application Number Priority Date Filing Date Title
KR1020207015435A KR102387363B1 (ko) 2017-11-30 2018-11-28 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치
US16/767,925 US11057640B2 (en) 2017-11-30 2018-11-28 Image decoding method and apparatus based on inter-prediction in image coding system

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
US201762593161P 2017-11-30 2017-11-30
US62/593,161 2017-11-30
KR20180037579 2018-03-30
KR10-2018-0037579 2018-03-30

Publications (1)

Publication Number Publication Date
WO2019107916A1 true WO2019107916A1 (ko) 2019-06-06

Family

ID=66665126

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/KR2018/014822 WO2019107916A1 (ko) 2017-11-30 2018-11-28 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치

Country Status (3)

Country Link
US (1) US11057640B2 (ko)
KR (1) KR102387363B1 (ko)
WO (1) WO2019107916A1 (ko)

Families Citing this family (36)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7088606B2 (ja) 2018-04-02 2022-06-21 エスゼット ディージェイアイ テクノロジー カンパニー リミテッド 動画処理方法、画像処理装置、プログラム、符号化デバイス、及び復号化デバイス
KR102605638B1 (ko) 2018-06-07 2023-11-22 베이징 바이트댄스 네트워크 테크놀로지 컴퍼니, 리미티드 부분 코스트 계산
TWI719525B (zh) 2018-06-29 2021-02-21 大陸商北京字節跳動網絡技術有限公司 Lut與amvp之間的交互
CN110662053B (zh) 2018-06-29 2022-03-25 北京字节跳动网络技术有限公司 使用查找表的视频处理方法、装置和存储介质
GB2588531B (en) 2018-06-29 2023-02-01 Beijing Bytedance Network Tech Co Ltd Concept of using one or multiple look up tables to store motion information of previously coded in order and use them to code following blocks
JP7256265B2 (ja) * 2018-06-29 2023-04-11 北京字節跳動網絡技術有限公司 ルックアップテーブルの更新:fifo、制限されたfifo
KR102646649B1 (ko) 2018-06-29 2024-03-13 베이징 바이트댄스 네트워크 테크놀로지 컴퍼니, 리미티드 Lut에서의 모션 후보들의 검사 순서
JP7460617B2 (ja) 2018-06-29 2024-04-02 北京字節跳動網絡技術有限公司 Lut更新条件
BR112020024142A2 (pt) 2018-06-29 2021-03-02 Beijing Bytedance Network Technology Co., Ltd. método para processamento de vídeo, aparelho para codificação de dados de vídeo, meio de armazenamento e meio de gravação legíveis por computador não transitório
CN110662056B (zh) 2018-06-29 2022-06-07 北京字节跳动网络技术有限公司 哪个查找表需要更新或不更新
GB2589241B (en) 2018-07-02 2023-06-07 Beijing Bytedance Network Tech Co Ltd Update of look-up tables
TWI719519B (zh) 2018-07-02 2021-02-21 大陸商北京字節跳動網絡技術有限公司 對於dmvr的塊尺寸限制
TW202025760A (zh) 2018-09-12 2020-07-01 大陸商北京字節跳動網絡技術有限公司 要檢查多少個hmvp候選
CN111083492B (zh) 2018-10-22 2024-01-12 北京字节跳动网络技术有限公司 双向光流中的梯度计算
WO2020084476A1 (en) 2018-10-22 2020-04-30 Beijing Bytedance Network Technology Co., Ltd. Sub-block based prediction
KR20240007302A (ko) 2018-11-12 2024-01-16 베이징 바이트댄스 네트워크 테크놀로지 컴퍼니, 리미티드 인터 및 인트라 통합 예측의 단순화
CN117319644A (zh) 2018-11-20 2023-12-29 北京字节跳动网络技术有限公司 基于部分位置的差计算
WO2020103870A1 (en) * 2018-11-20 2020-05-28 Beijing Bytedance Network Technology Co., Ltd. Inter prediction with refinement in video processing
KR102648159B1 (ko) 2019-01-10 2024-03-18 베이징 바이트댄스 네트워크 테크놀로지 컴퍼니, 리미티드 Lut 업데이트의 호출
WO2020143824A1 (en) 2019-01-13 2020-07-16 Beijing Bytedance Network Technology Co., Ltd. Interaction between lut and shared merge list
WO2020147773A1 (en) 2019-01-16 2020-07-23 Beijing Bytedance Network Technology Co., Ltd. Inserting order of motion candidates in lut
JP2022521554A (ja) 2019-03-06 2022-04-08 北京字節跳動網絡技術有限公司 変換された片予測候補の利用
WO2020192611A1 (en) 2019-03-22 2020-10-01 Beijing Bytedance Network Technology Co., Ltd. Interaction between merge list construction and other tools
KR20230169434A (ko) 2019-04-02 2023-12-15 베이징 바이트댄스 네트워크 테크놀로지 컴퍼니, 리미티드 디코더 측 움직임 벡터 유도
CN113079372B (zh) * 2021-06-07 2021-08-06 腾讯科技(深圳)有限公司 帧间预测的编码方法、装置、设备及可读存储介质
CN116830581A (zh) * 2021-09-15 2023-09-29 腾讯美国有限责任公司 用于运动矢量差的经改进的信令方法和装置
US20230104476A1 (en) * 2021-10-05 2023-04-06 Tencent America LLC Grouping based adaptive reordering of merge candidate
WO2023098899A1 (en) * 2021-12-03 2023-06-08 Beijing Bytedance Network Technology Co., Ltd. Method, apparatus, and medium for video processing
WO2023132556A1 (ko) * 2022-01-04 2023-07-13 엘지전자 주식회사 영상 인코딩/디코딩 방법 및 장치, 그리고 비트스트림을 저장한 기록 매체
WO2023194599A1 (en) * 2022-04-08 2023-10-12 Interdigital Ce Patent Holdings, Sas Memory bandwidth constrained template-based operations
GB2617568A (en) * 2022-04-11 2023-10-18 Canon Kk Video coding and decoding
WO2023200246A1 (ko) * 2022-04-12 2023-10-19 엘지전자 주식회사 영상 부호화/복호화 방법, 비트스트림을 전송하는 방법 및 비트스트림을 저장한 기록 매체
WO2023200243A1 (ko) * 2022-04-12 2023-10-19 엘지전자 주식회사 Mvd 부호 예측에 기반한 영상 부호화/복호화 방법, 장치 및 비트스트림을 저장하는 기록 매체
WO2024010338A1 (ko) * 2022-07-05 2024-01-11 한국전자통신연구원 영상 부호화/복호화를 위한 방법, 장치 및 기록 매체
WO2024072195A1 (ko) * 2022-09-28 2024-04-04 엘지전자 주식회사 영상 인코딩/디코딩 방법 및 장치, 그리고 비트스트림을 저장한 기록 매체
WO2024088048A1 (en) * 2022-10-26 2024-05-02 Mediatek Inc. Method and apparatus of sign prediction for block vector difference in intra block copy

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160366415A1 (en) * 2015-06-09 2016-12-15 Qualcomm Incorporated Systems and methods of determining illumination compensation parameters for video coding
US20170111654A1 (en) * 2011-03-21 2017-04-20 Lg Electronics Inc. Method for selecting motion vector predictor and device using same
KR20170075784A (ko) * 2014-12-09 2017-07-03 미디어텍 인크. 비디오 코딩에서 움직임 벡터 예측자 또는 합병 후보를 도출하는 방법
KR20170102844A (ko) * 2012-10-12 2017-09-12 한국전자통신연구원 영상의 부호화/복호화 방법 및 이를 이용하는 장치
WO2017157281A1 (en) * 2016-03-16 2017-09-21 Mediatek Inc. Method and apparatus of pattern-based motion vector derivation for video coding

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9544592B2 (en) * 2012-02-10 2017-01-10 Texas Instruments Incorporated Methods and systems for encoding pictures associated with video data
EP3139605A4 (en) 2014-04-28 2017-05-17 Panasonic Intellectual Property Corporation of America Encoding method, decoding method, encoding apparatus, and decoding apparatus
US10951912B2 (en) * 2016-10-05 2021-03-16 Qualcomm Incorporated Systems and methods for adaptive selection of weights for video coding
CN117528108A (zh) * 2016-11-28 2024-02-06 英迪股份有限公司 图像编码方法、图像解码方法及用于传送比特流的方法
US10911761B2 (en) * 2016-12-27 2021-02-02 Mediatek Inc. Method and apparatus of bilateral template MV refinement for video coding
EP3343924A1 (en) * 2017-01-03 2018-07-04 Thomson Licensing Method and apparatus for encoding and decoding motion information
EP3343925A1 (en) * 2017-01-03 2018-07-04 Thomson Licensing Method and apparatus for encoding and decoding motion information
CN110574377B (zh) * 2017-05-10 2021-12-28 联发科技股份有限公司 用于视频编解码的重新排序运动向量预测候选集的方法及装置
US10602180B2 (en) * 2017-06-13 2020-03-24 Qualcomm Incorporated Motion vector prediction

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170111654A1 (en) * 2011-03-21 2017-04-20 Lg Electronics Inc. Method for selecting motion vector predictor and device using same
KR20170102844A (ko) * 2012-10-12 2017-09-12 한국전자통신연구원 영상의 부호화/복호화 방법 및 이를 이용하는 장치
KR20170075784A (ko) * 2014-12-09 2017-07-03 미디어텍 인크. 비디오 코딩에서 움직임 벡터 예측자 또는 합병 후보를 도출하는 방법
US20160366415A1 (en) * 2015-06-09 2016-12-15 Qualcomm Incorporated Systems and methods of determining illumination compensation parameters for video coding
WO2017157281A1 (en) * 2016-03-16 2017-09-21 Mediatek Inc. Method and apparatus of pattern-based motion vector derivation for video coding

Also Published As

Publication number Publication date
US20200296414A1 (en) 2020-09-17
KR20200066737A (ko) 2020-06-10
US11057640B2 (en) 2021-07-06
KR102387363B1 (ko) 2022-04-18

Similar Documents

Publication Publication Date Title
WO2019107916A1 (ko) 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치
WO2019103564A1 (ko) 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치
WO2020171444A1 (ko) Dmvr 기반의 인터 예측 방법 및 장치
WO2019117640A1 (ko) 영상 코딩 시스템에서 인터 예측에 따른 영상 디코딩 방법 및 장치
WO2020004990A1 (ko) 인터 예측 모드 기반 영상 처리 방법 및 이를 위한 장치
WO2018226066A1 (ko) 영상 코딩 시스템에서 어파인 예측에 따른 영상 디코딩 방법 및 장치
WO2020184848A1 (ko) Dmvr 기반의 인터 예측 방법 및 장치
WO2020055107A1 (ko) 영상 코딩 시스템에서 어파인 mvp 후보 리스트를 사용하는 어파인 움직임 예측에 기반한 영상 디코딩 방법 및 장치
WO2019194514A1 (ko) 인터 예측 모드 기반 영상 처리 방법 및 이를 위한 장치
WO2020055161A1 (ko) 영상 코딩 시스템에서 서브 블록 단위의 움직임 예측에 기반한 영상 디코딩 방법 및 장치
WO2020184847A1 (ko) Dmvr 및 bdof 기반의 인터 예측 방법 및 장치
WO2020013569A1 (ko) 영상 코딩 시스템에서 어파인 움직임 예측에 기반한 영상 디코딩 방법 및 장치
WO2019216714A1 (ko) 인터 예측 모드 기반 영상 처리 방법 및 이를 위한 장치
WO2021172914A1 (ko) 레지듀얼 코딩에 대한 영상 디코딩 방법 및 그 장치
WO2020262931A1 (ko) 비디오/영상 코딩 시스템에서 머지 데이터 신택스의 시그널링 방법 및 장치
WO2021040410A1 (ko) 레지듀얼 코딩에 대한 영상 디코딩 방법 및 그 장치
WO2020251257A1 (ko) 예측 샘플을 생성하기 위한 가중치 인덱스 정보를 도출하는 영상 디코딩 방법 및 그 장치
WO2020262930A1 (ko) 머지 데이터 신택스에서 중복적인 신택스의 제거 방법 및 장치
WO2020032609A1 (ko) 영상 코딩 시스템에서 어파인 머지 후보 리스트를 사용하는 어파인 움직임 예측에 기반한 영상 디코딩 방법 및 장치
WO2020050695A1 (ko) 영상 코딩 시스템에서 머지 후보 리스트를 사용하는 움직임 예측에 기반한 영상 디코딩 방법 및 장치
WO2020009447A1 (ko) 인터 예측 모드 기반 영상 처리 방법 및 이를 위한 장치
WO2021141227A1 (ko) 영상 디코딩 방법 및 그 장치
WO2020262902A1 (ko) 쌍 예측을 적용하는 영상 디코딩 방법 및 그 장치
WO2021006697A1 (ko) 레지듀얼 코딩에 대한 영상 디코딩 방법 및 그 장치
WO2020256487A1 (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: 18884641

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 20207015435

Country of ref document: KR

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18884641

Country of ref document: EP

Kind code of ref document: A1