2.5 The Scene Tree
As seen in the previous section, to access to the Scene Tree Window you can either choose Scene Tree in the Tools menu, or use the mouse pointer to double-click on an object. The scene tree contains the information that describes a simulated world, including robots and environment, and its graphical representation. The scene tree of Webots is structured like a VRML97 file. It is composed of a list of nodes, each containing fields. Fields can contain values (text strings, numerical values) or other nodes.
This section describes the user interface of the Scene Tree, gives an overview of the VRML97 nodes and Webots nodes.

Figure 2.3: Scene Tree Window
2.5.1 Buttons of the Scene Tree Window
Nodes can be expanded with a double-click. When a field is selected, its value can be edited at the bottom of the Scene Tree. All changes will be immediately reflected in the 3D window. The following buttons are available to edit the world:
Cut: Cuts the selected object.
Copy: Copies the selected object.
Paste: Pastes the copied or cut object.
Note that the first three nodes of the Scene Tree (WorldInfo, Viewpoint, and Background) cannot be cut, copied or pasted. One single instance of each of these nodes must be present in every Webots world, and in that precise order.
Delete: Deletes the selected object.
Reset to default: Resets a field to its default value.
Transform: Allows you to change the type of some nodes.
New node: Adds a new node or object.
For nodes, this triggers a dialog that will let you choose a node type from a list.
The new node is created with default values that can be modified afterwards.
You can only insert a node suitable for the corresponding field.
Export: Exports a node into an ascii file.
Exported nodes can then be imported in other worlds.
Import: Imports a previously exported node into the scene tree.
Help: Context sensitive help for the currently selected node.
|
|