Once a XML component has been defined, it can be used just like any of the built-in scene graph node types. For example, if a XML component named
Gizmo has been defined, an instance of the component can be created by either declaring it in another XML component file:
Or using the
createObject() function to create an roSGNode object:
Each component XML file defines a top-level <component> XML element that may contain an <interface> element, zero or more <script> elements, and zero or more elements defining child Scene Graph nodes.