org.opencv.video

## Class BackgroundSubtractor

- java.lang.Object
- - org.opencv.core.Algorithm
  - - org.opencv.video.BackgroundSubtractor

- Direct Known Subclasses:
    BackgroundSubtractorKNN, BackgroundSubtractorMOG2

      public class BackgroundSubtractor
      extends Algorithm

- - ### Field Summary

    - ### Fields inherited from class org.opencv.core.Algorithm

      `nativeObj`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `BackgroundSubtractor(long addr)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `apply(Mat image, Mat fgmask)`
    `void` | `apply(Mat image, Mat fgmask, double learningRate)`
    `protected void` | `finalize()`
    `void` | `getBackgroundImage(Mat backgroundImage)`

    - ### Methods inherited from class org.opencv.core.Algorithm

      `clear, getDefaultName, save`

    - ### 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,
                            double learningRate)

    - #### apply

          public void apply(Mat image,
                            Mat fgmask)

    - #### getBackgroundImage

          public void getBackgroundImage(Mat backgroundImage)

    - #### finalize

          protected void finalize()
                           throws java.lang.Throwable

      Overrides:
        `finalize` in class `Algorithm`
      Throws:
        `java.lang.Throwable`