CERN Accelerating science

This website is no longer maintained. Its content may be obsolete. Please visit http://home.cern/ for current CERN information.

Up

VRML 2.0

VRML 2.0 Nodes

The following VRML 2.0 nodes are supported. For additional information, see the end of this topic.

SoVRMLAnchor Group node with URL hyperlink

SoVRMLAppearance Specifies a material node and texture node

SoVRMLAudioClip* Audio data node

SoVRMLBackground* Color backdrop node

SoVRMLBillboard Grouping node that modifies its coordinate system so that its local Z-axis always points at the viewer

SoVRMLBox Box shape node

SoVRMLCollision+ Grouping node that controls collision detection

SoVRMLColor Specifies RGB colors to be used in the fields of another node

SoVRMLColorInterpolator Interpolates among a set of color values

SoVRMLCone Cone shape node

SoVRMLCoordinate Coordinate node

SoVRMLCoordinateInterpolator Interpolates among a set of coordinate values

SoVRMLCylinder Cylinder shape node

SoVRMLCylinderSensor* Maps pointing device motion onto a cylinder

SoVRMLDirectionalLight Node representing a directional light source

SoVRMLElevationGrid Specifies a uniform rectangular grid of varying height in the XZ plane

SoVRMLExtrusion Specifies geometric shapes based on a 2D cross section along a 3D spine

SoVRMLFog* Simulates fog.

SoVRMLFontStyle Specifies font size, family, style, etc.

SoVRMLGeometry Abstract base class for all geometry nodes

SoVRMLGridShape Abstract base class for the SoVRMLElevationGrid node

SoVRMLGroup Group node

SoVRMLImageTexture Texture map node

SoVRMLIndexedFaceSet Indexed polygonal face shape node

SoVRMLIndexedLine Abstract base class for the SoVRMLIndexLineSet node

SoVRMLIndexedLineSet Indexed polyline shape node

SoVRMLIndexedShape Abstract base class for SoVRMLIndexedFaceSet

SoVRMLInline Grouping node that refers to children through a URL

SoVRMLLight Abstract base class for all VRML 2.0 light nodes

SoVRMLLOD Distance-based level-of-detail switching group node

SoVRMLMaterial Surface material definition node

SoVRMLMovieTexture* Texture and sound node

SoVRMLNavigationInfo+ Describes physical characteristics of viewer and viewing model

SoVRMLNormal Node that defines surface normals for shapes

SoVRMLNormalInterpolator Interpolates among a set of normals

SoVRMLOrientationInterpolator Interpolates among a set of rotation values

SoVRMLParent Abstract base class for all VRML grouping nodes that have children

SoVRMLPixelTexture Texture node

SoVRMLPlaneSensor* Maps pointing device motion onto a plane

SoVRMLPointLight Node representing a point light source

SoVRMLPointSet Point set shape node

SoVRMLPositionInterpolator Interpolates among a set of position values

SoVRMLProximitySensor Generates events when the user moves into, out of, or within a specified region of space

SoVRMLScalarInterpolator Interpolates among a set of float values

SoVRMLScript* Used to program behavior in a scene

SoVRMLShape Defines a shape by specifying its appearance and geometry

SoVRMLSound* Specifies position and spatial representation of a sound

SoVRMLSphere Sphere shape node

SoVRMLSphereSensor* Maps pointing device motion onto a sphere

SoVRMLSpotLight Node representing a spotlight source

SoVRMLSwitch Group node that traverses one chosen child

SoVRMLText Text shape node

SoVRMLTextureCoordinate Texture coordinate node

SoVRMLTextureTransform Defines a 2D transformation

SoVRMLTimeSensor Generates events as time passes

SoVRMLTouchSensor Detects when the user has pointed at a specific piece of geometry

SoVRMLTransform Grouping node that defines a coordinate system for its children

SoVRMLVertexLine Abstract base class for SoVRMLIndexedLineSet

SoVRMLVertexPoint Abstract base class for the SoVRMLPointSet node

SoVRMLVertexShape Abstract base class for the SoVRMLIndexedFaceSet node

SoVRMLViewpoint Specifies position from which the user might view the scene

SoVRMLVisibilitySensor* Detects visibility changes of a rectangular box

SoVRMLWorldInfo Contains information about the world

* Action not implemented for this node.

+ Action partially implemented for this node.

Additional VRML Classes

The following classes provide additional support for VRML.

SoVRMLEXTERNPROTODef Contains the internal definition of an externprototype

SoVRMLEXTERNPROTOField Contains the internal definition for one of an externprototype?s fields, exposedFields, eventIns or eventOuts

SoVRMLEXTERNPROTOFieldList Maintains a list of pointers to the field definitions of an externprototype

SoVRMLEXTERNPROTOInstance Instance of an externprototype

SoVRMLPROTODef Contains the internal definition of a prototype

SoVRMLPROTOField Contains the internal definition for one of a prototype?s fields, exposedFields, eventIns or eventOuts

SoVRMLPROTOFieldList Maintains a list of pointers to the field definitions of a prototype

SoVRMLPROTOInstance Instance of a prototype

Additional Information

Routes

Routes are Inventor field-to-field connections. When Open Inventor reads a VRML 2.0 file, it automatically creates the connections specified by the Route statements, if any. When Open Inventor writes a file with a VRML 2.0 header, it automatically generates Route statements for any field-to-field connections that exist. An application can create field-to-field connections in the usual way (field->connectFrom) or by using SoDB::createRoute.

Writing a VRML 2.0 File

To have Open Inventor write a VRML 2.0 file, set the file header to the standard VRML 2.0 header, i.e., ?#VRML V2.0 utf8? using the setHeaderString method on SoOutput. NOTE: Setting the file header to the VRML 2.0 file header does not cause Open Inventor to convert non-VRML 2.0 nodes into VRML 2.0 nodes. If you need to convert nodes to VRML 2.0, use the utility program ivtovrml.

Open Inventor uses the file header to determine how node (class) names should be handled when reading or writing a file. If the file header is an Open Inventor header, e.g. "#Inventor V2.1 ascii", then all nodes will be read (and written) using their internal class names. This means that VRML 2.0 nodes will be written as (for example) "VRMLTransform", to ensure that they do not conflict with pre-existing Inventor node class names. It also means that "Transform" will be read as an SoTransform node, while "VRMLTransform" will be read as an SoVRMLTransform node. If the file header is "#VRML V2.0 utf8", then VRML 2.0 nodes are written without the "VRML" prefix and "Transform" will be read as an SoVRMLTransform node. An SoTransform node will be written as ?SoTransform?.