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 new calibration name.
CopyCalibName
Optional. String expression containing the name of copy source calibration

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 using the same name, or call VCalPoints to teach 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