newspeoplefor developersdocumentationdownloads

nSwingShapeNode Class Reference

#include <nswingshapenode.h>

Inheritance diagram for nSwingShapeNode:

nShapeNode nMaterialNode nAbstractShaderNode nTransformNode nSceneNode nRoot nObject nNode nReferenced nSignalEmitter List of all members.

Detailed Description

Extends nShapeNode and provides the rotation matrix needed for the swing and leaves shaders.

(C) 2003 RadonLabs GmbH

Definition at line 17 of file nswingshapenode.h.


Public Member Functions

 nSwingShapeNode ()
 constructor
virtual ~nSwingShapeNode ()
 destructor
virtual bool SaveCmds (nPersistServer *ps)
 save object to persistent stream
virtual bool LoadResources ()
 load resources
virtual void UnloadResources ()
 unload resources
virtual int GetMeshUsage () const
 get the mesh usage flags required by this shape node
virtual bool ApplyShader (nSceneServer *sceneServer)
 perform pre-instancing rendering of shader
virtual bool RenderShader (nSceneServer *sceneServer, nRenderContext *renderContext)
 perform per-instance-rendering of shader
void SetSwingAngle (float f)
 set the max swing angle
float GetSwingAngle () const
 get the swing angle
void SetSwingTime (float t)
 set the swing time period
float GetSwingTime () const
 get the swing time period

Constructor & Destructor Documentation

nSwingShapeNode::nSwingShapeNode  ) 
 

constructor

Definition at line 15 of file nswingshapenode_main.cc.

nSwingShapeNode::~nSwingShapeNode  )  [virtual]
 

destructor

Definition at line 27 of file nswingshapenode_main.cc.


Member Function Documentation

virtual bool nSwingShapeNode::SaveCmds nPersistServer ps  )  [virtual]
 

save object to persistent stream

Reimplemented from nShapeNode.

bool nSwingShapeNode::LoadResources  )  [virtual]
 

load resources

This validates the variable handles for time and wind.

Reimplemented from nShapeNode.

Definition at line 51 of file nswingshapenode_main.cc.

void nSwingShapeNode::UnloadResources  )  [virtual]
 

unload resources

This invalidates the variable handles for time and wind.

Reimplemented from nShapeNode.

Definition at line 67 of file nswingshapenode_main.cc.

int nSwingShapeNode::GetMeshUsage  )  const [virtual]
 

get the mesh usage flags required by this shape node

This method must return the mesh usage flag combination required by this shape node class. Subclasses should override this method based on their requirements.

Returns:
a combination on nMesh2::Usage flags

Reimplemented from nShapeNode.

Definition at line 41 of file nswingshapenode_main.cc.

bool nSwingShapeNode::ApplyShader nSceneServer sceneServer  )  [virtual]
 

perform pre-instancing rendering of shader

Set pre-instancing attribute of shader.

Reimplemented from nMaterialNode.

Definition at line 104 of file nswingshapenode_main.cc.

bool nSwingShapeNode::RenderShader nSceneServer sceneServer,
nRenderContext renderContext
[virtual]
 

perform per-instance-rendering of shader

Set per-instance-attribute of shader.

Reimplemented from nMaterialNode.

Definition at line 134 of file nswingshapenode_main.cc.

void nSwingShapeNode::SetSwingAngle float  f  )  [inline]
 

set the max swing angle

Definition at line 60 of file nswingshapenode.h.

float nSwingShapeNode::GetSwingAngle  )  const [inline]
 

get the swing angle

Definition at line 70 of file nswingshapenode.h.

void nSwingShapeNode::SetSwingTime float  t  )  [inline]
 

set the swing time period

Definition at line 80 of file nswingshapenode.h.

float nSwingShapeNode::GetSwingTime  )  const [inline]
 

get the swing time period

Definition at line 90 of file nswingshapenode.h.


The documentation for this class was generated from the following files:

Copyright © 1999-2005 by the contributing authors. Ideas, requests, problems: Send feedback.