VCreateCalibration Statement

Applies To
Vision Calibration

Description
VCreateCalibration creates a vision calibration at runtime.

Usage

VCreateCalibration   CameraNumber, CalibrationName, [CopyCalibName]
CameraNumber
Numerical expression containing a camera number to be used for new calibration.
CalibrationName
String expression containing the new calibration name
CopyCalibName
String expression containing the calibration name to copy from (optional)

Remarks
Here are the basic steps to create a runtime calibration:

  1. Execute VCreateCalibration.
  2. Use VSet to set CameraOrientation and TargetSequence properties. Set other properties as necessary.
  3. If the camera is not standalone, you must create a point file for the calibration with the same name. Alternatively, you can call VCalPoints and teach the calibration points.
  4. Execute VCal to run the calibration.
  5. Set the Calibration property for one or more sequences that will use the new calibration.
  6. Execute VSave to save the changes.

To make changes to the vision configuration permanent, you must call VSave.

Example

Function CreateCal
    String cal$

    cal$ = "mycal"
    VCreateCalibration 1, cal$
    VSet cal$.CameraOrientation, VISION_CAMORIENT_MOBILEJ2
    VSet cal$.TargetSequence, "calSeq"
    VCalPoints cal$
    VCal cal$
    VSave
Fend

See Also
VCreateObject Statement, VCreateSequence Statement, VSave Statement