LucasKanadeFlow.evaluate

Lucas-Kanade optical flow algorithm implementation.

class LucasKanadeFlow
override
float[2][]
evaluate
(
inout Image f1
,
inout Image f2
,
in float[2][] points
,
in float[2][] searchRegions
,
float[2][] flow = null
,
bool usePrevious = false
)
in { assert (!f1.empty && !f2.empty && f1.size == f2.size && f1.channels == 1 && f1.depth == f2.depth); assert (points.length == searchRegions.length); if (usePrevious) { assert (flow !is null); assert (points.length == flow.length); } }

Parameters

f1
Type: Image

First frame image.

f2
Type: Image

Second frame image.

points
Type: float[2][]

points which are tracked.

searchRegions
Type: float[2][]

search region width and height for each point.

flow
Type: float[2][]

displacement values preallocated array.

usePrevious
Type: bool

if algorithm should continue iterating by using presented values in the flow array, set this to true.

See: dcv.features.corner

Meta