| CPC H04N 19/139 (2014.11) [H04N 19/176 (2014.11); H04N 19/46 (2014.11); H04N 19/513 (2014.11)] | 6 Claims |

|
1. A decoding method of an image, the method comprising:
deriving motion information of a current block based on a merge index and a merge candidate list of the current block, wherein the motion information includes at least one of a motion vector or a reference picture index, and wherein the merge candidate list includes at least one merge candidate; and
performing inter prediction of the current block based on the motion information of the current block,
wherein a maximum number of merge candidates available for the current block is adaptively determined based on a first flag indicating whether to use a motion vector difference value for inter prediction of the current block,
wherein the motion vector of the current block is modified with the motion vector difference value based on the first flag indicating that the motion vector difference value is used for the inter prediction of the current block,
wherein the motion vector difference value is derived based on a merge offset vector,
wherein the merge offset vector is determined based on a length candidate and a direction candidate,
wherein the length candidate is determined based on a first index specifying one of a plurality of length candidates, and the direction candidate is determined based on a second index specifying one of a plurality of direction candidates,
wherein a range of the length candidates is determined differently based on a second flag indicating whether only integer sample precision is used, and
wherein the second flag equal to a first value indicates that only the integer sample precision is used, and the second flag equal to a second value indicates that either fractional or integer sample precision is used.
|