OpenCV 2.4.2

org.opencv.video
Class BackgroundSubtractor

java.lang.Object
  extended by org.opencv.core.Algorithm
      extended by org.opencv.video.BackgroundSubtractor
Direct Known Subclasses:
BackgroundSubtractorMOG

public class BackgroundSubtractor
extends Algorithm

Base class for background/foreground segmentation.

The class is only used to define the common interface for the whole family of background/foreground segmentation algorithms.

See Also:
org.opencv.video.BackgroundSubtractor : public Algorithm

Field Summary
 
Fields inherited from class org.opencv.core.Algorithm
nativeObj
 
Constructor Summary
protected BackgroundSubtractor(long addr)
           
 
Method Summary
 void apply(Mat image, Mat fgmask)
          Computes a foreground mask.
 void apply(Mat image, Mat fgmask, double learningRate)
          Computes a foreground mask.
protected  void finalize()
           
 
Methods inherited from class org.opencv.core.Algorithm
getBool, getDouble, getInt, getMat, getMatVector, getString, paramHelp, paramType, setBool, setDouble, setInt, setMat, setMatVector, setString
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BackgroundSubtractor

protected BackgroundSubtractor(long addr)
Method Detail

apply

public void apply(Mat image,
                  Mat fgmask)

Computes a foreground mask.

Parameters:
image - Next video frame.
fgmask - The output foreground mask as an 8-bit binary image.
See Also:
org.opencv.video.BackgroundSubtractor.operator()

apply

public void apply(Mat image,
                  Mat fgmask,
                  double learningRate)

Computes a foreground mask.

Parameters:
image - Next video frame.
fgmask - The output foreground mask as an 8-bit binary image.
learningRate - a learningRate
See Also:
org.opencv.video.BackgroundSubtractor.operator()

finalize

protected void finalize()
                 throws java.lang.Throwable
Overrides:
finalize in class Algorithm
Throws:
java.lang.Throwable

Official OpenCV 2.4 Documentation