# CalibrateImage

Associates a calibration with an image. CalibrateImage associates a Calib data structure with an Image data structure, to create a new Image data structure. The resulting data structure can be referenced by other vision tool functions, in order to display their results in the world coordinates defined by the referenced calibration.

For example, a sensor is calibrated using a Calibrate function Functions are tools that are available in Spreadsheet for processing and analyzing acquisitions or other results. You can add functions to your Spreadsheet job to create tool chains and produce results for specific applications.. Next, a CalibrateImage function is inserted, with the Calib parameter set as Cell References to the recently created Calib structure of the Calibrate function. Then, another vision tool, such as DetectBlobs, sets its Image parameter as a cell reference to the CalibrateImage data structure, causing the DetectBlobs coordinate results in the world coordinates of the calibrated image.

Note: The output of any vision tool that reports in real-world coordinates cannot be used as a fixture A fixture is a coordinate location on the image that keeps the tool in the place determined by the fixture. or region input to another vision tool.
Inputs

The CalibrateImage function has the following syntax:

CalibrateImage(Image, Calib)

See the table for a description of the available parameters.

Parameters | Description
Image | This argument must reference a spreadsheet cell that contains a valid Image data structure. This parameter must reference a spreadsheet cell that contains an Image data structure. By default, this parameter references cell A0, the cell containing the Image data structure returned by the AcquireImage function. This parameter can also reference other Image data structures, such as those returned by the Vision Tool Image Functions or Coordinate Transforms Functions.
Calib | This argument must reference a spreadsheet cell that contains a valid Calib data structure or use 0, which is the default value. Tip: You can use 0 as argument to remove the calibration. This is useful when working with already calibrated images. Removing the calibration allows you to directly use output from a 2D tool as input for another 2D tool.

Outputs

Returns | An Image data structure containing the processed image, or #ERR if any of the input parameters are invalid.