http://www.emgu.com
Calculates optical flow for overlapped blocks block_size.width * 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)

Namespace: Emgu.CV
Assembly: Emgu.CV (in Emgu.CV.dll) Version: 2.4.0.1717 (2.4.0.1717)

Syntax

C#
public static void cvCalcOpticalFlowBM(
	IntPtr prev,
	IntPtr curr,
	Size blockSize,
	Size shiftSize,
	Size maxRange,
	bool usePrevious,
	IntPtr velx,
	IntPtr vely
)
Visual Basic
Public Shared Sub cvCalcOpticalFlowBM ( _
	prev As IntPtr, _
	curr As IntPtr, _
	blockSize As Size, _
	shiftSize As Size, _
	maxRange As Size, _
	usePrevious As Boolean, _
	velx As IntPtr, _
	vely As IntPtr _
)
Visual C++
public:
static void cvCalcOpticalFlowBM(
	IntPtr prev, 
	IntPtr curr, 
	Size blockSize, 
	Size shiftSize, 
	Size maxRange, 
	bool usePrevious, 
	IntPtr velx, 
	IntPtr vely
)

Parameters

prev
Type: System..::..IntPtr
First image, 8-bit, single-channel.
curr
Type: System..::..IntPtr
Second image, 8-bit, single-channel.
blockSize
Type: System.Drawing..::..Size
Size of basic blocks that are compared.
shiftSize
Type: System.Drawing..::..Size
Block coordinate increments.
maxRange
Type: System.Drawing..::..Size
Size of the scanned neighborhood in pixels around block.
usePrevious
Type: System..::..Boolean
Uses previous (input) velocity field.
velx
Type: System..::..IntPtr
Horizontal component of the optical flow of floor((prev->width - block_size.width)/shiftSize.width) x floor((prev->height - block_size.height)/shiftSize.height) size, 32-bit floating-point, single-channel.
vely
Type: System..::..IntPtr
Vertical component of the optical flow of the same size velx, 32-bit floating-point, single-channel.

See Also