Class BackgroundSubtractorExtension
A static class that provide extension methods to backgroundSubtractor
public static class BackgroundSubtractorExtension
- Inheritance
-
BackgroundSubtractorExtension
- Inherited Members
Methods
Apply(IBackgroundSubtractor, IInputArray, IOutputArray, double)
Update the background model
public static void Apply(this IBackgroundSubtractor subtractor, IInputArray image, IOutputArray fgMask, double learningRate = -1)
Parameters
subtractor
IBackgroundSubtractorThe background subtractor
image
IInputArrayThe image that is used to update the background model
fgMask
IOutputArrayThe output foreground mask
learningRate
doubleUse -1 for default
GetBackgroundImage(IBackgroundSubtractor, IOutputArray)
Computes a background image.
public static void GetBackgroundImage(this IBackgroundSubtractor subtractor, IOutputArray backgroundImage)
Parameters
subtractor
IBackgroundSubtractorThe background subtractor
backgroundImage
IOutputArrayThe output background image
Remarks
Sometimes the background image can be very blurry, as it contain the average background statistics.