OpenCV  2.4.13
Open Source Computer Vision
cv::ocl::MOG2 Class Reference

#include <ocl.hpp>

Inheritance diagram for cv::ocl::MOG2:
cv::ocl::BackgroundSubtractor

Public Member Functions

 MOG2 (int nmixtures=-1)
 the default constructor More...
 
void initialize (Size frameSize, int frameType)
 re-initiaization method More...
 
void operator() (const oclMat &frame, oclMat &fgmask, float learningRate=-1.0f)
 the update operator More...
 
void getBackgroundImage (oclMat &backgroundImage) const
 computes a background image which are the mean of all background gaussians More...
 
void release ()
 releases all inner buffers More...
 
- Public Member Functions inherited from cv::ocl::BackgroundSubtractor
virtual ~BackgroundSubtractor ()
 the virtual destructor More...
 

Public Attributes

int history
 
float varThreshold
 
float backgroundRatio
 
float varThresholdGen
 
float fVarInit
 
float fVarMin
 
float fVarMax
 
float fCT
 
bool bShadowDetection
 
unsigned char nShadowDetection
 
float fTau
 

Detailed Description

The class implements the following algorithm: "Improved adaptive Gausian mixture model for background subtraction" Z.Zivkovic International Conference Pattern Recognition, UK, August, 2004. http://www.zoranz.net/Publications/zivkovic2004ICPR.pdf

Constructor & Destructor Documentation

cv::ocl::MOG2::MOG2 ( int  nmixtures = -1)

the default constructor

Member Function Documentation

void cv::ocl::MOG2::getBackgroundImage ( oclMat backgroundImage) const
virtual

computes a background image which are the mean of all background gaussians

Implements cv::ocl::BackgroundSubtractor.

void cv::ocl::MOG2::initialize ( Size  frameSize,
int  frameType 
)

re-initiaization method

void cv::ocl::MOG2::operator() ( const oclMat frame,
oclMat fgmask,
float  learningRate = -1.0f 
)
virtual

the update operator

Reimplemented from cv::ocl::BackgroundSubtractor.

void cv::ocl::MOG2::release ( )

releases all inner buffers

Member Data Documentation

float cv::ocl::MOG2::backgroundRatio
bool cv::ocl::MOG2::bShadowDetection
float cv::ocl::MOG2::fCT
float cv::ocl::MOG2::fTau
float cv::ocl::MOG2::fVarInit
float cv::ocl::MOG2::fVarMax
float cv::ocl::MOG2::fVarMin
int cv::ocl::MOG2::history
unsigned char cv::ocl::MOG2::nShadowDetection
float cv::ocl::MOG2::varThreshold

here it is the maximum allowed number of mixture components. Actual number is determined dynamically per pixel

float cv::ocl::MOG2::varThresholdGen

The documentation for this class was generated from the following file: