PANDORE Version 6 GREYC-IMAGE

pblockmatching



Motion estimation between 2 images using block matching.



Synopsis

pblockmatching block_size search_size ssd_min [-m mask] [im_in_ref|-] [im_in_dest|-] [im_out_dep|-] [im_in|-] [im_out|-]

Description

pblockmatching builds a new image that contains the motion estimation between 2 images.The output image im_out_dep is a multispectral image containing a motion vector in each point: the first band contains the abscissa, and the second one the ordinate of the motion vector.

The motion estimation method using the "block matching" is to find a matching between each squared block of size block_size in the reference image im_in_ref with the same block in the destination image im_in_dest. The corresponding distination block is searched in a the neigbourhood of size search_size. The matching criteria is the destination block that mimizes the Sum of Square Differences (SSD):

   SSD(u,v) = sum_{(x,y) in Block} [im_in_ref(x,y) - im_in_dest(x+u,y+v)]^2

Parameters

Inputs

Outputs

Result

Return SUCCESS or FAILURE.

Examples

Estimates the motion between an image and its translated:

ptranslation 0 17 tangram.pan tangram1.pan
pblockmatching 16 20 3 tangram.pan tangram1.pan deplacements.pan
pplotquiver 256 256 10 0.5 deplacements.pan out.pan

See Also

Motion

C++ prototype

Errc pblockmatching(const Img2duc &im_in_ref, const Img2duc &im_in_dest, Imx2dsf &im_out_dep, short block_size_x, short search_size, short ssd_min);

Version française

Estimation du mouvement entre deux images par mise en correspondance de blocs.


Authors: G. Née - Y. Pitrey Helpiquet - S. Jéhan Besson