Patent ID: 8179963

Claim:
A coding mode determining apparatus for determining at least one of a plurality of candidate coding modes of an image block, the plurality of coding modes determining at least one of (i) a division method in which the image block is divided into small blocks and (ii) a picture reference direction in motion estimation for the small blocks, the coding mode determining apparatus comprising: a simple motion estimation portion that derives a first coding cost for each of the plurality of coding modes, based on a simple motion estimation for the small blocks, the small motion blocks being partitions of the image block obtained using each of the plurality of coding modes; a coding mode selecting portion that selects a subset of the plurality of coding modes, based on the first coding cost derived for each of the plurality of coding modes by the simple motion estimation portion; a complex motion estimation portion that derives a second coding cost for each of the plurality of coding modes, based on a complex motion estimation for the small blocks obtained using at least a subset of the selected subset of the plurality of coding modes, such that based on a result of the simple motion estimation by the simple motion estimation portion, (i) when the first coding cost of a forward prediction is substantially equal to the first coding cost of a backward prediction, the complex motion estimation portion sets picture reference directions to a forward direction, a backward direction, and a bi-direction, performs the complex motion estimation for the small blocks for the forward direction, the backward direction and the bi-direction, and calculates the second coding cost for the forward direction, the second coding cost for the backward direction, and the second coding cost for the bi-direction, respectively, and (ii) when the first coding cost of the forward prediction differs from the first coding cost of the backward prediction, the complex motion estimation portion selects one of the forward prediction and the backward prediction having a smaller first coding cost, and calculates the second coding cost for the small blocks for one of the forward direction and the backward direction corresponding to the selected one of the forward prediction and the backward prediction; and a coding mode determining portion that determines, from the plurality of coding modes, a coding mode of the image block, the coding mode being determined based on the second coding cost derived for each of the plurality of coding modes by the complex motion estimation portion.