• Roman Donchenko's avatar
    Merge commit '43aec5ad' into merge-2.4 · 2c4bbb31
    Roman Donchenko authored
    Conflicts:
    	cmake/OpenCVConfig.cmake
    	cmake/OpenCVLegacyOptions.cmake
    	modules/contrib/src/retina.cpp
    	modules/gpu/doc/camera_calibration_and_3d_reconstruction.rst
    	modules/gpu/doc/video.rst
    	modules/gpu/src/speckle_filtering.cpp
    	modules/python/src2/cv2.cv.hpp
    	modules/python/test/test2.py
    	samples/python/watershed.py
    2c4bbb31
motion_analysis.rst 3.84 KB

Motion Analysis

CalcOpticalFlowBM

Calculates the optical flow for two images by using the block matching method.

The function calculates the optical flow for overlapped blocks block_size.width x block_size.height pixels each, thus the velocity fields are smaller than the original images. For every block in prev the functions tries to find a similar block in curr in some neighborhood of the original block or shifted by (velx(x0,y0), vely(x0,y0)) block as has been calculated by previous function call (if use_previous=1)

CalcOpticalFlowHS

Calculates the optical flow for two images using Horn-Schunck algorithm.

The function computes the flow for every pixel of the first input image using the Horn and Schunck algorithm [Horn81]_. The function is obsolete. To track sparse features, use :ocv:func:`calcOpticalFlowPyrLK`. To track all the pixels, use :ocv:func:`calcOpticalFlowFarneback`.

CalcOpticalFlowLK

Calculates the optical flow for two images using Lucas-Kanade algorithm.

The function computes the flow for every pixel of the first input image using the Lucas and Kanade algorithm [Lucas81]_. The function is obsolete. To track sparse features, use :ocv:func:`calcOpticalFlowPyrLK`. To track all the pixels, use :ocv:func:`calcOpticalFlowFarneback`.