Skip to content

AffineFeature

Features and matchingclassOpenCV 5.0.0
import { AffineFeature } from '@banou/opencv-wasm'

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

ARGUMENTSConstructor or factory
CLASSAffineFeature
RETURN TYPEOwned native handle
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Native object: release it with using or delete(). Factories can return null; check before calling methods. Inherits Feature2D.

Class for implementing the wrapper which makes detectors and extractors to be affine invariant, described as ASIFT in [YM11] .

Constructors and members

static create

Create an owned AffineFeature instance with the supplied configuration.

Class for implementing the wrapper which makes detectors and extractors to be affine invariant, described as ASIFT in [YM11] .

create(backend: Feature2D | null, maxTilt: number, minTilt: number, tiltStep: number, rotateStepBase: number): AffineFeature | null;
5 available overloads
create(backend: Feature2D | null): AffineFeature | null;
create(backend: Feature2D | null, maxTilt: number): AffineFeature | null;
create(backend: Feature2D | null, maxTilt: number, minTilt: number): AffineFeature | null;
create(backend: Feature2D | null, maxTilt: number, minTilt: number, tiltStep: number): AffineFeature | null;
create(backend: Feature2D | null, maxTilt: number, minTilt: number, tiltStep: number, rotateStepBase: number): AffineFeature | null;
backend

The detector/extractor you want to use as backend.

maxTilt

The highest power index of tilt factor. 5 is used in the paper as tilt sampling range n.

minTilt

The lowest power index of tilt factor. 0 is used in the paper.

tiltStep

Tilt sampling step \delta_t in Algorithm 1 in the paper.

rotateStepBase

Rotation sampling step factor b in Algorithm 1 in the paper.

Returns

The AffineFeature | null result.

clone

Create another handle to the same native object. This retains the object without copying its pixels or algorithm state; dispose both handles separately.

clone(): this;
Returns

The this result.

setViewParams

Set the view params used by this AffineFeature object.

setViewParams(tilts: FloatVector, rolls: FloatVector): void;
tilts

tilts argument (FloatVector).

rolls

rolls argument (FloatVector).

getViewParams

Return the view params configured on this AffineFeature object.

getViewParams(tilts: FloatVector, rolls: FloatVector): void;
tilts

tilts argument (FloatVector).

rolls

rolls argument (FloatVector).

getDefaultName

Returns the algorithm string identifier. This string is used as top level xml/yml node tag when the object is saved to a file or string.

getDefaultName(): string;
Returns

The string 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.