ProcUnit::TransformXY

Performs coordinates transformation

int TransformXY(
   int  imageNo,
   int  mode,
   double       srcX,
   double       srcY,
   double       *destX,
   double       *destY,
);

Parameters
imageNo
Image number
mode
Transformation mode
0:After transform → Before transform
1:Before transform → After transform
10:Picture element → Calibration
srcX
Coordinate X value before transformation
srcY
Coordinate Y value before transformation
*destX
Pointer to coordinate X value after transformation
*destY
Pointer to coordinate Y value after transformation

Return Value
Returns 0 when performs coordinates transformation succeeded.
Otherwise returns a non-zero value.

Description
Performs coordinates transformation.

Example
    int Sample::TransformXY(ProcUnit *ptrProcUnit, int imageNo, int mode, double srcX, double srcY, double *destX, double *destY)
    {

        // Get the pointer to the inner processing unit

        ProcUnit *ptrInnerUnit = ptrProcUnit->GetInnerUnit(0);

        // Performs coordinates transformation

        ptrInnerUnit->TransformXY(imageNo, mode, srcX, srcY, destX, destY);
    }