User Objects

<< Click to Display Table of Contents >>

Navigation:  Image Manager > CVB Technology > Non-destructive Overlays >

User Objects

 

User objects are custom overlay objects designed by the application developer.

Any overlay object can be described by a list of vertices defining the corner points in x,y coordinates, for example a line has two vertices, a triangle has three, but a rectangle and a bitmap graphic have only two, top left and bottom right.

The number of vertices, the vertices as a list of points, and a callback function (This is not required when using the Display control) are passed to the Display control.

Whenever the overlay has to be redrawn, Common Vision Blox invokes the user's callback function (Or the UserPaint event when using the Display control) which is given the position of the vertices (in window coordinates) and a device context (DC) as drawing parameters.

Users can therefore draw any overlay that can be described as a list of points into the DC.

The User Object overlay is not available under Visual Basic because the language does not support pointers to variable-length lists.

 

Please see Object ID's for further information on assigning user object ID's.

 

 

Properties, Events and Methods of the Display control regarding User Objects

 

The example VCOverlay shows the use of User Objects.

 

Properties

 

Methods

AddUserObject or AddUserObjectNET

GetUserObjectPosition

HasUserObject

RemoveUserObject

RemoveAllUserObjects

RemoveAllOverlays

 

Events

UserPaint

UserObjectClick

UserObjectDraged

UserObjectDrag

 

 

UserObjects