Estimate optical flow
The function estimates optical flow of the input video using the method specified by
the input object opticFlow
. The optical flow is estimated as the
motion between two consecutive video frames. The video frame T at the
given instant tcurrent is referred as current
frame and the video frame T-1 is referred as previous frame. The
initial value of the previous frame at time
tcurrent = 0 is set as a uniform image of
grayscale value 0.
Note
If you specify opticFlow
as
opticalFlowLKDoG
object, then the estimation delays by an
amount relative to the number of video frames. The amount of delay depends on
the value of NumFrames
defined in opticalFlowLKDoG
object. The
optic flow estimated for a video frame at
tcurrent corresponds to the
video frame at time . tcurrent is the
time of the current video frame.