PutLabel

Write a label (text on unified background) into an image.

Syntax

Definition:

HRESULT PutLabel(
    HRESULT            hrPrev,
    PCCH               sText,
    ITcVnImage*        ipDestImage,
    ULONG              nX,
    ULONG              nY,
    double             fFontScale,
    ULONG              nThickness = 1,
    ETcVnFontType      eFontType = FT_HERSHEY_SIMPLEX,
    TcVnVector4_LREAL& aFontColor = {0, 0, 0, 0},
    TcVnVector4_LREAL& aBackgroundColor = {255, 255, 255, 255},
    ETcVnLineType      eLineType = LT_4_CONNECTED
)

Parameters

Name

Type

Default

Description

hrPrev

HRESULT

 

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

sText

PCCH

 

Text

ipDestImage

ITcVnImage*

 

Destination image

nX

ULONG

 

x coordinate (bottom left)

nY

ULONG

 

y coordinate (bottom left)

fFontScale

double

 

Scaling factor

nThickness

ULONG

1

Line thickness

eFontType

ETcVnFontType

FT_HERSHEY_SIMPLEX

Font type

aFontColor

TcVnVector4_LREAL&

{0, 0, 0, 0}

Font color

aBackgroundColor

TcVnVector4_LREAL&

{255, 255, 255, 255}

Background color

eLineType

ETcVnLineType

LT_4_CONNECTED

Line type

PutLabel 1: 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