F_VN_CreateBandrejectGaussianFilter

F_VN_CreateBandrejectGaussianFilter 1:

Creates a bandreject Gaussian filter, which can be applied to a frequency domain image by element-wise multiplication.

Syntax

Definition:

FUNCTION F_VN_CreateBandrejectGaussianFilter : HRESULT
VAR_INPUT
    ipFilter         : Reference To ITcVnImage;
    nWidth           : UDINT;
    nHeight          : UDINT;
    bDoublePrecision : BOOL;
    bOriginAtCenter  : BOOL;
    fCutoffDistance  : LREAL;
    fBandWidth       : LREAL;
    hrPrev           : HRESULT;
END_VAR

F_VN_CreateBandrejectGaussianFilter 2: Inputs

Name

Type

Description

ipFilter

Reference To ITcVnImage

Returns the created filter (1 channel of type REAL or LREAL, depending on bDoublePrecision. Non-zero interface pointers are reused.).

nWidth

UDINT

Filter width (even, >= 2, must match the width of the image it is applied to)

nHeight

UDINT

Filter height (even, >= 2, must match the height of the image it is applied to)

bDoublePrecision

BOOL

If true, the filter is generated with double precision (LREAL) instead of single precision (REAL).

bOriginAtCenter

BOOL

If true, the filter origin is shifted to the image center.

fCutoffDistance

LREAL

The cutoff distance of the Gaussian filter (> 0).

fBandWidth

LREAL

The band width of the Gaussian filter (> 0).

hrPrev

HRESULT

HRESULT indicating the result of previous operations (If SUCCEEDED(hrPrev) equals false, no operation is executed.)

F_VN_CreateBandrejectGaussianFilter 3: Return value

HRESULT

Required License

TC3 Vision Base

System Requirements

Development environment

Target platform

PLC libraries to include

TwinCAT V3.1. 4024.44 or later

PC or CX (x64) with PL50, e.g. Intel 4-core Atom CPU

Tc3_Vision