Patent ID: 8731246

Claim:
A motion vector detection device, comprising: a processor; and a memory containing a program, the program, when executed, causing the processor to function as: a matching error calculation part that calculates a plurality of matching errors between a focus block in a current frame and each of a plurality of reference blocks in a reference frame; a least matching error calculation part that calculates a least matching error from among the plurality of matching errors; a threshold calculation part that calculates a threshold value that increases as a variation of the plurality of matching errors becomes greater; a correction vector calculation part that calculates a correction vector from motion vectors detected in the other focus blocks from which motion vectors were detected prior to the focus block of the current frame; and a motion vector determination part that determines, as a motion vector for the focus block, a relative position vector in a block in which the relative position vector with respect to the focus block is the closest to the correction vector, the block being selected from among the reference blocks in which a difference between the plurality of matching errors and the least matching error is within the threshold value, wherein the matching error calculation part calculates each of the plurality of matching errors as follows: D ⁡ ( u ) = ∑ x ∈ B ⁢  I ref ⁡ ( x + u ) - I src ⁡ ( x )  where D(u) represents a matching error with respect to motion vector u, I ref represents the current frame, I src , represents the reference frame, B represents a set of position vectors indicating pixel positions in the focus blocks and x represents an element of the set of B.