Home

mlamp

Download project

Visualization Elements

This example shows the use of some visualization elements and events, e.g. working with external pictures
or rotating objects with mouse events.

Product description

To include an external image, an Image Pool object must be added. The included images must use the ID
from the Image Pool for the Static ID property.

Some mouse events are directly supported from the visualization (OnMouseClick, OnMouseDown,
OnMouseLeave, OnMouseEnter, OnMouseUp and OnMouseMove).
Additional ones (double click, dragging) were implemented in the "MouseEvents" program.
This example changes the color of an object when an event occurs.

Another function is the rotation. This function can distinguish between interior and normal rotation.
In both cases the element rotates around the center point of the element. With the interior rotation,
the element additionally rotates itself, whereas with the normal rotation it does not.

More information

Main: Calls the following programs.

MouseEvents: This program implements the double click and dragging for object.
A timer is used for the double click to wait for the second mouse click. To implement the dragging,
a new position for the object is calculated when the mouse is pressed and moving.

Node: This program is responsible for expanding and collapsing the node by a double click.
This is also realized with a timer for the double click.

Rotation: For each degree of a circle the position is calculated.

Visualization: It is important that the time interval for the visualization task is short in
order to get fast feedback from the user interface.

System requirements and restrictions

System requirements and restrictions Info
Programming System CODESYS Development System Version 3.5.14.0 or higher
Runtime System CODESYS Control Version 3.5.14.0
Required Accessories -

Screenshot thumbnail
Screenshot of Visualization