When the x component of the second motion vector 2204 is obtainable, the y component of the second motion vector 2204 is obtained from the y component of the first motion vector 2202. On the other hand, when the y component of the second motion vector 2204 is obtainable, the x component of the second motion vector 2204 is obtained from the x and y components of the first motion vector 2202 and the y component of the second motion vector 2204. Equations 6 and 7 below respectively represent methods of determining the y and x components of the second motion vector 2204.
In Equations 6 and 7, x denotes a horizontal component of a motion vector and y denotes a vertical component of the motion vector. MV0 denotes the first motion vector 2202, MV1 denotes the second motion vector 2204, and MV2 denotes the third motion vector 2206. w denotes the width of the current block 2200 and h denotes the height of the current block 2200. MV1[y]=MV0[y]??[Equation 6] MV1[x]=√{square root over (w2?(MV1[y]?MV0[y])2)}+MV0[x]?w??[Equation 7]
According to Equation 6, when only the x component of the second motion vector 2204 is obtainable, the processor 1710 determines the y component of the second motion vector 2204 to be the same as the y component of the first motion vector 2202.