Encoder and decoder for deriving the motion vector of the current block and performing motion compensation
An encoder includes circuitry and memory. Using the memory, the circuitry, in inter prediction processing: derives a first motion vector of a current block to be processed, using a motion vector of a previous block which has been previously processed; derives a second motion vector of the current block by performing motion estimation in the vicinity of the first motion vector; and generates a prediction image of the current block by performing motion compensation using the second motion vector.
1. A decoding method, comprising:
deriving a first motion vector of a first current block to be processed, using a motion vector of a previous block which has been previously processed;
deriving a second motion vector of the first current block by performing motion estimation in vicinity of a position specified by the first motion vector;
generating a prediction image of the first current block by performing motion compensation using the second motion vector;
deriving a third motion vector of a second current block to be processed after the first current block, using the first motion vector of the first current block, when the second current block is included in a first picture including the first current block;
deriving a third motion vector of the second current block, using the second motion vector of the first current block, when the second current block is included in a second picture different from the first picture;
deriving a fourth motion vector of the second current block by performing motion estimation in vicinity of a position specified by the third motion vector; and
generating a prediction image of the second current block by performing motion compensation using the fourth motion vector,
wherein the deriving the third motion vector includes:
(i) generating a motion vector predictor list indicating a plurality of motion vector predictors using the first motion vector or the second motion vector of the first current block; and
(ii) determining the third motion vector of the second current block based on the plurality of motion vector predictors.
2. An encoder, comprising:
circuitry; and
memory,
wherein, using the memory, the circuitry, in inter prediction processing:
derives a first motion vector of a first current block to be processed, using a motion vector of a previous block which has been previously processed;
derives a second motion vector of the first current block by performing motion estimation in vicinity of a position specified by the first motion vector;
generates a prediction image of the first current block by performing motion compensation using the second motion vector;
derives a third motion vector of a second current block to be processed after the first current block, using the first motion vector of the first current block, when the second current block is included in a first picture including the first current block;
derives a third motion vector of the second current block, using the second motion vector of the first current block, when the second current block is included in a second picture different from the first picture;
derives a fourth motion vector of the second current block by performing motion estimation in vicinity of a position specified by the third motion vector; and
generates a prediction image of the second current block by performing motion compensation using the fourth motion vector, and
wherein in deriving the third motion vector, the circuitry:
(i) generates a motion vector predictor list indicating a plurality of motion vector predictors using the first motion vector or the second motion vector of the first current block; and
(ii) determines the third motion vector of the second current block based on the plurality of motion vector predictors.