Please enable JavaScript to view this site.

Adds a new volatile element to the 3D scene.

Syntax

bool add_item(const string &in type, const string &in name, const string &in init='')

type

Element type (see table of element types)

name

Element name

init

Element initialization values (optional).

Element initialization values consist of a set of properties to be assigned directly to the element being created, with the following format:

[<name1>=<value1>[;<name2>=<value2>[; ......]]]

where <nameX> is the name of the property and <valueX> is the value for the property.

Result

Returns true if element added, false otherwise

Notes

The element name must be unique.

The element is created and displayed immediately, unless you initially set the "visible" property to false.

New elements and their variables will be operational, if valid, only after a restart of the data monitor, such as with a call to the restart_monitor() method.

Example of use:

bool execute(pan3d::object @panel)

{

  ...

  ; Add box item, not visible to positioned at X=200 Y=100 Z=-50

  panel.add_item(pan3d::item_box, "obj1""visible=false;posX=200;posY=100;posZ=-50");

  ; Add cone item, rotating on Z according to RR(10)

  panel.add_item(pan3d::item_cone, "obj2""posA=rr(10)");

  ...

  restart_monitor();

}

 

  

Keyboard Navigation

F7 for caret browsing
Hold ALT and press letter

This Info: ALT+q
Page Header: ALT+h
Topic Header: ALT+t
Topic Body: ALT+b
Contents: ALT+c
Search: ALT+s
Exit Menu/Up: ESC