Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

Phx::GraphicsEngine::Node Class Reference

A node in the graphics engine scene graph. More...

#include <PhxGraphicsEngine.h>

Inheritance diagram for Phx::GraphicsEngine::Node:

Phx::LockedPtrInterface< Node > List of all members.

Public Member Functions

virtual Ptr< NodenewNode (const String &name="")=0
 Creates a new Node interface that is a sub-node of this interface.
virtual Ptr< PointLightnewPointLight (const String &name="")=0
virtual Ptr< DirectionalLightnewDirectionalLight (const String &name="")=0
virtual Ptr< SpotLightnewSpotLight (const String &name="")=0
virtual Ptr< PointLightnewPointLight (const Ptr< const PointLightDescription > &description, const String &name="")=0
virtual Ptr< DirectionalLightnewDirectionalLight (const Ptr< const DirectionalLightDescription > &description, const String &name="")=0
virtual Ptr< SpotLightnewSpotLight (const Ptr< const SpotLightDescription > &description, const String &name="")=0
virtual Ptr< SkyBoxnewSkyBox (const Ptr< const GeometryDescription > &description, const String &name="")=0
virtual Ptr< BillboardGroupnewBillboardGroup (const Ptr< const BillboardGroupDescription > &description, const String &name="")=0
virtual Ptr< GeometrynewGeometry (const String &name="")=0
 Creates a new Geometry interface attached to this node.
virtual Ptr< GeometrynewGeometry (const Ptr< const GeometryDescription > &description, const String &name="")=0
 Creates a new Geometry interface using the description of geometry given.
virtual Ptr< CameranewCamera (const String &cameraName)=0
 Constructs a new camera attached to this node.
virtual Ptr< TerrainGeometrynewTerrainGeometry (const Ptr< const TerrainGeometryDescription > &description, const String &terrainName)=0
 Creates a new TerrainGeometry attached to this node.
virtual void position (const Vector3 &position)=0
 Sets the position of this node relative to its parent.
virtual void orientation (const Quaternion &orientation)=0
 Sets the orientation of this node relative to its parent.
const Vector3position (void) const
 Returns the position of this node in the parent's coordinate frame.
const Quaternion & orientation (void) const
 Returns the orientation of this node relative to the parent frame.
const String & name (void) const
 Returns the name of this node, which was set when the Node was created.

Protected Member Functions

void setName (const String &name)
void setPosition (const Vector3 &position)
void setOrientation (const Quaternion &orientation)

Detailed Description

A node in the graphics engine scene graph.

The node interface allows the client to manipulate a coordinate frame to which other frames and/or Entity's may be attached.

The scene graph is a hierarchical structure containing the scene elements. Each scene element that has a position/orientation is attached to a Node, which may be embedded within other Nodes. Each Node imparts its translation and rotation to all of its children and sub-nodes.


Member Function Documentation

virtual Ptr<Camera> Phx::GraphicsEngine::Node::newCamera const String &  cameraName  )  [pure virtual]
 

Constructs a new camera attached to this node.

Parameters:
cameraName A name for this camera, used to identify it when selecting views. Unlike the "debugging" names used for nodes and geometry, this name must be globally unique. If you're using the camera along with another game object, use the NamedInterface name of the object the camera is associated with as part of the name -- this will ensure that no other objects (following the same convention) try to use the same name. Obviously, names like "Camera" are not recommended.
Exceptions:
InUseException thrown if the name cameraName is taken by another camera elsewhere in the engine.
RangeException throw if cameraName is "".
Returns:
A new Camera interface to a camera with the given name attached to this node.

virtual Ptr<Geometry> Phx::GraphicsEngine::Node::newGeometry const Ptr< const GeometryDescription > &  description,
const String &  name = ""
[pure virtual]
 

Creates a new Geometry interface using the description of geometry given.

Parameters:
description A GeometryDescription specifying how to configure the interface after creation.
name An optional debuggin name for the Geometry interface. This name need not be unique.
Note:
This interface is safely accessible from multiple concurrent clients.
Returns:
A new Geometry interface to a geometric scene element attached to this Node.

virtual Ptr<Geometry> Phx::GraphicsEngine::Node::newGeometry const String &  name = ""  )  [pure virtual]
 

Creates a new Geometry interface attached to this node.

The client may then set a mesh name in the Geometry interface to load a geometric model and display it with this node.

Parameters:
name An optional debugging name for the Geometry interface. This name need not be unique.
Note:
This interface is safely accessible from multiple concurrent clients.
Returns:
A new Geometry interface to a geometric scene element that will be attached to this Node.

virtual Ptr<Node> Phx::GraphicsEngine::Node::newNode const String &  name = ""  )  [pure virtual]
 

Creates a new Node interface that is a sub-node of this interface.

The returned interface is independent of the parent node. They are associated internally, but the interfaces may be manipulated by different clients safely (though clients should never share a single Node interface!)

Parameters:
name An optional debugging name for the node. Unlike names that certain engines may use internally, this name need not be unique.
Note:
This interface is safely accessible by multiple concurrent clients.

virtual Ptr<TerrainGeometry> Phx::GraphicsEngine::Node::newTerrainGeometry const Ptr< const TerrainGeometryDescription > &  description,
const String &  terrainName
[pure virtual]
 

Creates a new TerrainGeometry attached to this node.

Parameters:
description A TerrainGeometryDescription that describes the terrain geometry to be constructed.
terrainName A debugging name for this geometry.

virtual void Phx::GraphicsEngine::Node::orientation const Quaternion &  orientation  )  [pure virtual]
 

Sets the orientation of this node relative to its parent.

Parameters:
orientation A quaternion expressing a rotation from the parent basis to this node's basis.

virtual void Phx::GraphicsEngine::Node::position const Vector3 position  )  [pure virtual]
 

Sets the position of this node relative to its parent.

Parameters:
position The position of this object relative to its parent position, expressed in the parent's coordinate frame.


The documentation for this class was generated from the following file:
Generated on Mon Jul 10 19:45:29 2006 for Phoenix OSFS by  doxygen 1.4.2