sqrBoxFilter
import { sqrBoxFilter } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Calculates the normalized sum of squares of the pixel values overlapping the filter.
For every pixel (x, y) in the source image, the function calculates the sum of squares of those neighboring
pixel values which overlap the filter placed over the pixel (x, y).
The unnormalized square box filter can be useful in computing local image statistics such as the local variance and standard deviation around the neighborhood of a pixel.
See: boxFilter
sqrBoxFilter(src: Mat, dst: Mat, ddepth: number, ksize: Size, anchor: Point, normalize: boolean, borderType: number): void;4 available overloads
sqrBoxFilter(src: Mat, dst: Mat, ddepth: number, ksize: Size): void;sqrBoxFilter(src: Mat, dst: Mat, ddepth: number, ksize: Size, anchor: Point): void;sqrBoxFilter(src: Mat, dst: Mat, ddepth: number, ksize: Size, anchor: Point, normalize: boolean): void;sqrBoxFilter(src: Mat, dst: Mat, ddepth: number, ksize: Size, anchor: Point, normalize: boolean, borderType: number): void;srcinput image
dstOutput destination, filled by the native operation. output image of the same size and type as src
ddepththe output image depth (-1 to use src.depth())
ksizekernel size
anchorkernel anchor point. The default value of Point(-1, -1) denotes that the anchor is at the kernel center.
normalizeflag, specifying whether the kernel is to be normalized by it's area or not.
borderTypeborder mode used to extrapolate pixels outside of the image, see #BorderTypes. #BORDER_WRAP is not supported.
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.