Patent ID: 8477854

Claim:
An encoding method for adaptively carrying out field-based or frame-based encoding processing at a macroblock level with image information as an input, the encoding method comprising: a motion vector information generating step of generating a motion vector information through motion prediction processing; a context model generating step of generating a context model corresponding to a syntax element for carrying out the frame-based or the field-based encoding processing, wherein the context model corresponding to the motion vector information of a current macroblock is generated based on a sum of an absolute value of motion vector information of macroblocks neighboring the current macroblock, and when the current macroblock is subject to the field-based encoding and a neighboring macroblock is subject to frame-based encoding, the motion vector information corresponding to the neighboring macroblock is calculated by converting the vertical component of the motion vector information corresponding to the neighboring macroblock to the equivalent for field-based encoding and is applied to the context model corresponding to the motion vector information of current macroblock; and an encoding step of carrying out the encoding processing using the context model corresponding to the motion vector information of the current macroblock generated in the context model generating step.