Classes

Vision Connector User Manual

Portfolio
Industrial AI
Product
Vision Connector
Software version
1.2.2
Language
English

PluginLogger class

The SDK provides logging capabilities through the PluginLogger class. The PluginLogger can store registered callbacks with the actual logging implementation. VCA uses this concept to register its own logging logic, but the camera connector can also register its own logging callback if needed. If there is no registered callback then a fallback logger is used which writes to the standard output.

While the PluginLogger provides instance-based macros for the different log levels it is not recommended to use them on their own. Each camera connector has its own PluginLogger instance and its specific log macros. Use these specific macros.

Object and ObjectContainer classes

The SDK contains some utility classes such as the Object and ObjectContainer. These classes provide a generalized way to handle data between the custom camera connector and the VCA application and are not used individually. The Object represents a JSON object.

CameraStatus class

The CameraStatus class extends the ObjectContainer class to handle specific data for the camera status. It is used in the Camera abstract class.

CameraParameter class

The CameraParameter class extends the ObjectContainer class to handle specific data for camera parameters. It is used in the Camera abstract class.

The camera parameter can have the following fields:

name

The name of the parameter

description

Description of the parameter

value

Value of the parameter

min

Minimum value of the parameter (if applicable)

max

Maximum value of the parameter (if applicable)

increment

Expected value increment (if applicable)

symbolics

Predefined value options (if applicable)

type

Type of the parameter

readOnly

Accessibility of the parameter

The camera parameter handles each field as string independent from the original value data type. The original data type is defined by the "type" field:

  • bool

  • int

  • float

  • string

  • enum

CameraParameterStatus class

The CameraParameterStatus class extends the ObjectContainer class to handle specific data for camera parameter changes.

Depending on the success of the parameter change, the status can be either "OK" or "ERROR". If the status is "OK", then the value is the changed parameter value; otherwise, it is the error message.

Image class

The Image class is responsible for managing the image data retrieved from the cameras. VCA supports multipart images. An instance of the Image class consists of no, one or several image parts. By default, the Image instance does not contain any image part. The Image instance does not take over of the ownership of added image parts.

It is also possible to add metadata to each image part and custom fields to the Image instance itself.

CameraException

Custom exception for camera-related errors.