Skip to content
Almar Klein edited this page Jun 1, 2017 · 3 revisions

Inherits from BaseObject.

A Wobject (world object) is a visual element that is drawn in 3D world coordinates (in the scene). Wobjects can be children of other wobjects or of an Axes object (which is the wibject that represents the scene).

To each wobject, several transformations can be applied, which are also applied to its children. This way complex models can be build. For example, in a robot arm the fingers would be children of the hand, so that when the hand moves or rotates, the fingers move along automatically. The fingers can then also be moved without affecting the hand or other fingers.

The transformations are represented by Transform_* objects in the list named "transformations". The transformations are applied in the order as they appear in the list.

The Wobject class implements the following properties:
transformations

The Wobject class implements the following methods:
Draw, GetAxes, TransformPoint

Properties

Get the list of transformations of this wobject. These can be Transform_Translate, Transform_Scale, or Transform_Rotate instances.

Methods

Calls Draw on the axes that contains this object.

Get the axes in which this wobject resides.

Note that this is not necesarily an Axes instance (like the line objects in the Legend wibject).

Transform a point in the local coordinate system of this wobject to the coordinate system of the given baseWobject (which should be a parent of this wobject), or to the global (Axes) coordinate system if not given.

This is done by taking into account the transformations applied to this wobject and its parent wobjects.

If baseWobject is the current wobject itself, only the tranformations of this wobject are applied.

Clone this wiki locally