Skip to main content

McalTransformResult

BoardSupported
Host SystemYes
V4L2Yes
Clarity UHDYes
Concord PoENo
GenTLYes
GevIQYes
GigE VisionYes
IndioNo
Iris GTXYes
Radient eV-CLYes
Rapixo CLYes
Rapixo CoFYes
Rapixo CXPYes
USB3 VisionYes

Convert a result between its world and pixel value.

Syntax

void McalTransformResult(
AIL_ID CalibrationOrImageId, //in
AIL_INT64 TransformType, //in
AIL_INT64 ResultType, //in
AIL_DOUBLE Result, //in
AIL_DOUBLE * TransformedResultPtr //out
)

Description

This function converts a specific result (a length, area, or angle) from its pixel value to its world value or vice versa. The conversion can be performed according to a camera calibration context, calibrated image, or corrected image. However, since this function uses the average pixel size to perform the conversion, results will be more accurate if you use a corrected image.

Parameters

CalibrationOrImageId (in, AIL_ID)

Specifies the identifier of the camera calibration context, calibrated image, or corrected image. When an image is specified, the transformation uses the camera calibration information associated with this image.

TransformType (in, AIL_INT64)

Specifies whether to perform a pixel-to-world or world-to-pixel conversion. This parameter must be set to one of the following values:

For specifying pixel-to-world or world-to-pixel

ValueDescription
M_PIXEL_TO_WORLDConverts from pixel to world.
M_WORLD_TO_PIXELConverts from world to pixel.

ResultType (in, AIL_INT64)

Specifies the type of result the given input value represents. This parameter must be set to one of the following values:

For specifying the type of result

ValueDescription
M_ANGLERepresents an angle.

An angle interpreted with respect to the pixel coordinate system (M_PIXEL_TO_WORLD) is always measured counter-clockwise. For information on the angle's direction of rotation when interpreting the angle with respect to the relative coordinate system (M_WORLD_TO_PIXEL), see Angle convention in Aurora Imaging Library. | | M_AREA | Represents an area. | | M_LENGTH | Represents a length (for example, the perimeter of an object). | | M_LENGTH_X | Represents a length in the X-direction only. | | M_LENGTH_Y | Represents a length in the Y-direction only. |

Result (in, AIL_DOUBLE)

Specifies the input value.

TransformedResultPtr *(out, AIL_DOUBLE)

Specifies the address in which to place the output value.

Copyright © 2026 Zebra Technologies.