Skip to content

bgsegm_createBackgroundSubtractorMOG

bgsegmfunctionOpenCV 5.0.0
import { bgsegm_createBackgroundSubtractorMOG } from '@banou/opencv-wasm'

Use after await initOpenCV(). See the initialization and named imports guide.

ARGUMENTShistory, nmixtures, backgroundRatio, noiseSigma
FUNCTIONbgsegm_createBackgroundSubtractorMOG
RETURN TYPEbgsegm_BackgroundSubtractorMOG | null
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Creates mixture-of-gaussian background subtractor

bgsegm_createBackgroundSubtractorMOG(history: number, nmixtures: number, backgroundRatio: number, noiseSigma: number): bgsegm_BackgroundSubtractorMOG | null;
5 available overloads
bgsegm_createBackgroundSubtractorMOG(): bgsegm_BackgroundSubtractorMOG | null;
bgsegm_createBackgroundSubtractorMOG(history: number): bgsegm_BackgroundSubtractorMOG | null;
bgsegm_createBackgroundSubtractorMOG(history: number, nmixtures: number): bgsegm_BackgroundSubtractorMOG | null;
bgsegm_createBackgroundSubtractorMOG(history: number, nmixtures: number, backgroundRatio: number): bgsegm_BackgroundSubtractorMOG | null;
bgsegm_createBackgroundSubtractorMOG(history: number, nmixtures: number, backgroundRatio: number, noiseSigma: number): bgsegm_BackgroundSubtractorMOG | null;
history

Length of the history.

nmixtures

Number of Gaussian mixtures.

backgroundRatio

Background ratio.

noiseSigma

Noise strength (standard deviation of the brightness or each color channel). 0 means some automatic value.

Returns

The bgsegm_BackgroundSubtractorMOG | null result.

These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.