Skip to content

ft_inpaint

fuzzyfunctionOpenCV 5.0.0
import { ft_inpaint } from '@banou/opencv-wasm'

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

ARGUMENTSimage, mask, output, radius
FUNCTIONft_inpaint
RETURN TYPEvoid
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Image inpainting

Note: The algorithms are described in paper [Perf]:rec.

ft_inpaint(image: Mat, mask: Mat, output: Mat, radius: number, function_: number, algorithm: number): void;
image

Input image.

mask

Mask used for unwanted area marking.

output

Output destination, filled by the native operation. Output 32-bit image.

radius

Radius of the basic function.

function_

Function type could be one of the following:

  • ft::LINEAR Linear basic function.
algorithm

Algorithm could be one of the following:

  • ft::ONE_STEP One step algorithm.
  • ft::MULTI_STEP This algorithm automaticaly increases radius of the basic function.
  • ft::ITERATIVE Iterative algorithm running in more steps using partial computations.

This function provides inpainting technique based on the fuzzy mathematic.

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.