Skip to content

ximgproc_fastGlobalSmootherFilter

Extended image processingfunctionOpenCV 5.0.0
import { ximgproc_fastGlobalSmootherFilter } from '@banou/opencv-wasm'

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

ARGUMENTSguide, src, dst, lambda
FUNCTIONximgproc_fastGlobalSmootherFilter
RETURN TYPEvoid
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Simple one-line Fast Global Smoother filter call. If you have multiple images to filter with the same guide then use FastGlobalSmootherFilter interface to avoid extra computations.

ximgproc_fastGlobalSmootherFilter(guide: Mat, src: Mat, dst: Mat, lambda: number, sigma_color: number, lambda_attenuation: number, num_iter: number): void;
3 available overloads
ximgproc_fastGlobalSmootherFilter(guide: Mat, src: Mat, dst: Mat, lambda: number, sigma_color: number): void;
ximgproc_fastGlobalSmootherFilter(guide: Mat, src: Mat, dst: Mat, lambda: number, sigma_color: number, lambda_attenuation: number): void;
ximgproc_fastGlobalSmootherFilter(guide: Mat, src: Mat, dst: Mat, lambda: number, sigma_color: number, lambda_attenuation: number, num_iter: number): void;
guide

image serving as guide for filtering. It should have 8-bit depth and either 1 or 3 channels.

src

source image for filtering with unsigned 8-bit or signed 16-bit or floating-point 32-bit depth and up to 4 channels.

dst

Output destination, filled by the native operation. destination image.

lambda

parameter defining the amount of regularization

sigma_color

parameter, that is similar to color space sigma in bilateralFilter.

lambda_attenuation

internal parameter, defining how much lambda decreases after each iteration. Normally, it should be 0.25. Setting it to 1.0 may lead to streaking artifacts.

num_iter

number of iterations used for filtering, 3 is usually enough.

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.