X3D grouping and transforms

The educational technology and digital learning wiki
Jump to navigation Jump to search

Draft

This article or section is currently under construction

In principle, someone is working on it and there should be a better version in a not so distant future.
If you want to modify this page, please discuss it with the person working on it (see the "history")

Introduction

Grouping nodes organize objects in an X3D world in various ways. There existe several grouping nodes that have different functions.

  • Group and StaticGroup collect related nodes together. This way one can reuse it as a whole
  • Transform is probably the most important node. It controls position, orientation and scale of its children
  • Inline loads other X3D scenes
  • LOD (level of detail) provides different levels of geometry quality according to the user's viewpoint
  • Switch can be animated to select different children, one (or none) at a time
  • Anchor allows to define URL links to another X3D scene or other page in a web browser
  • Billboard allows to create a group whose geometry always faces the user
  • Collision provides collision detection properties between child geometry and the camera.

Inlining other scenes

The Inline node allows to loads another X3D world within the current scene.

The supported formats depend on the user's X3D browser: XML encoded .x3d, ClassicVRML encoding .x3dv, compressed binary .x3db, sometimes VRML97 .wrl

  • Inlined scene must be positioned, rotated and scaled to match the local frame of coordinates
  • The local reference frame is determined by the parent's Transformation node hierarchy, i.e. where it is loaded.
  • Also, the user's viewpoint does not change automatically to the loaded Inline scene's default Viewpoint

The Inline node takes the following Fields (and some more). The url attribute is mandatory of course, all the others are optional.

url 'list of URLs'
is one or more quoted strings that all point to the same object in one or more locations. Each address is retrieved and evaluated, in order, until the desired Inline file is successfully retrieved. Relative addresses work both on localhost or server. Absolute addresses provide a reliable backup
bboxCenter "0 0 0"
Bounding box center: position offset from origin of local coordinate system.
bboxSize "-1 -1 -1"
the bounding box size is automatically calculated, but it can be specified as an optimization or constraint.

Grouping

The Group node collects nodes together with related purpose. Often such nodes are close to each other spatially.

If a DEF is provided, the group can be re-USEd.


Credits and Copyright modificiation