Click or drag to resize
Accord.NET (logo)

MotionDetectorProcessFrame Method (UnmanagedImage)

Process new video frame.

Namespace:  Accord.Vision.Motion
Assembly:  Accord.Vision (in Accord.Vision.dll) Version: 3.8.0
Syntax
public float ProcessFrame(
	UnmanagedImage videoFrame
)
Request Example View Source

Parameters

videoFrame
Type: Accord.ImagingUnmanagedImage
Video frame to process (detect motion in).

Return Value

Type: Single
Returns amount of motion, which is provided MotionLevel property of the motion detection algorithm in use.
Remarks

The method first of all applies motion detection algorithm to the specified video frame to calculate motion level and motion frame. After this it applies motion processing algorithm (if it was set) to do further post processing, like highlighting motion areas, counting moving objects, etc.

Note Note
In the case if MotionZones property is set, this method will perform motion filtering right after motion algorithm is done and before passing motion frame to motion processing algorithm. The method does filtering right on the motion frame, which is produced by motion detection algorithm. At the same time the method recalculates motion level and returns new value, which takes motion zones into account (but the new value is not set back to motion detection algorithm' MotionLevel property).

See Also