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

nvsg::SkinnedTriangles Class Reference

GeoSet for animated Triangles. More...

#include <SkinnedTriangles.h>

Inheritance diagram for nvsg::SkinnedTriangles:

Inheritance graph
[legend]
Collaboration diagram for nvsg::SkinnedTriangles:

Collaboration graph
[legend]
List of all members.

Public Member Functions

virtual NVSG_API const SkinnedTrianglesclone (void) const
 Get a clone of this SkinnedTriangles object.
virtual NVSG_API bool isDataShared (void) const
 Determine whether the data of this object is shared.
virtual NVSG_API DataID getDataID (void) const
 Get the DataID of the data of this object.
virtual NVSG_API size_t getNumberOfFrames (void) const
 Get the number of animation frames that are part of this SkinnedTriangles.
NVSG_API size_t getNumberOfSkins (void) const
 Get number of skins.
NVSG_API const SkingetSkins (void) const
 Get the skins.
NVSG_API void setAnimationFrame (size_t frame, bool bCalculateTangentSpace)
 Calculate vertices and normals depending on the animation frame.
NVSG_API void setNormals (const nvmath::Vec3f *pNor, size_t numNor)
 Overwrite of Triangles::setNormals.
NVSG_API void setNormals (size_t pos, const nvmath::Vec3f *pNor, size_t numNor)
 Overwrite of Triangles::setNormals.
NVSG_API void setSkins (const Skin *pSkins, size_t numSkins)
 Set the skins.
NVSG_API void setSkins (size_t pos, const Skin *pSkins, size_t numSkins)
 Set skins.

Static Public Member Functions

static NVSG_API const SkinnedTrianglescreate (void)
 Create a SkinnedTriangles.
static NVSG_API const SkinnedTrianglescreateFromBase (const Triangles &rhs)
 Create a SkinnedTriangles by copying from a Triangles.

Protected Member Functions

NVSG_API SkinnedTriangles (void)
 Constructor.
NVSG_API SkinnedTriangles (const Triangles &rhs)
 Partial Constructor.
NVSG_API SkinnedTriangles (const SkinnedTriangles &rhs)
 Copy Constructor.
virtual NVSG_API ~SkinnedTriangles (void)
 Protected destructor to prevent explicit creation on stack.

Detailed Description

GeoSet for animated Triangles.

This class has additional information to calculate the vertices and normals of a Triangles depending on the animation step.


Constructor & Destructor Documentation

NVSG_API nvsg::SkinnedTriangles::SkinnedTriangles void   )  [protected]
 

Constructor.

NVSG_API nvsg::SkinnedTriangles::SkinnedTriangles const Triangles rhs  )  [protected]
 

Partial Constructor.

NVSG_API nvsg::SkinnedTriangles::SkinnedTriangles const SkinnedTriangles rhs  )  [protected]
 

Copy Constructor.

virtual NVSG_API nvsg::SkinnedTriangles::~SkinnedTriangles void   )  [protected, virtual]
 

Protected destructor to prevent explicit creation on stack.


Member Function Documentation

static NVSG_API const SkinnedTriangles* nvsg::SkinnedTriangles::create void   )  [static]
 

Create a SkinnedTriangles.

Returns:
a constant pointer to a SkinnedTriangles.

Reimplemented from nvsg::Triangles.

static NVSG_API const SkinnedTriangles* nvsg::SkinnedTriangles::createFromBase const Triangles rhs  )  [static]
 

Create a SkinnedTriangles by copying from a Triangles.

Returns:
a constant pointer to a SkinnedTriangles.

virtual NVSG_API const SkinnedTriangles* nvsg::SkinnedTriangles::clone void   )  const [virtual]
 

Get a clone of this SkinnedTriangles object.

Returns:
a constant pointer to a SkinnedTriangles.

Reimplemented from nvsg::Triangles.

virtual NVSG_API bool nvsg::SkinnedTriangles::isDataShared void   )  const [virtual]
 

Determine whether the data of this object is shared.

Returns:
true if the object's data is shared, otherwise false.

Reimplemented from nvsg::Triangles.

virtual NVSG_API DataID nvsg::SkinnedTriangles::getDataID void   )  const [virtual]
 

Get the DataID of the data of this object.

Returns:
DataID of the object's data.

Reimplemented from nvsg::Triangles.

virtual NVSG_API size_t nvsg::SkinnedTriangles::getNumberOfFrames void   )  const [virtual]
 

Get the number of animation frames that are part of this SkinnedTriangles.

Returns:
The number of animation frames if there is an animation attached, otherwise zero.

Reimplemented from nvsg::Drawable.

size_t nvsg::SkinnedTriangles::getNumberOfSkins void   )  const [inline]
 

Get number of skins.

In addition to vertices, normals, and so on, a SkinnedTriangles contains so-called "skins". A skin is the information where one vertex and its normal can be calculated from, depending on the animation frame.

const Skin * nvsg::SkinnedTriangles::getSkins void   )  const [inline]
 

Get the skins.

Returns:
A constant pointer to the skins

NVSG_API void nvsg::SkinnedTriangles::setAnimationFrame size_t  frame,
bool  bCalculateTangentSpace
 

Calculate vertices and normals depending on the animation frame.

SkinnedTriangles contain animation information on each vertex. When the animation frame is set, the vertices and normals are recalculated. If bCalculateTangentSpace is true, tangents and binormals are also recalculated.

Parameters:
frame  animation frame to set
bCalculateTangentSpace  if true, recalculate tangents and binormals

NVSG_API void nvsg::SkinnedTriangles::setNormals const nvmath::Vec3f pNor,
size_t  numNor
 

Overwrite of Triangles::setNormals.

Sets the normals in the skins and then calls to Triangles::setNormals.

Parameters:
pNor  normals to set
numNor  number of normals

Reimplemented from nvsg::GeoSet.

NVSG_API void nvsg::SkinnedTriangles::setNormals size_t  pos,
const nvmath::Vec3f pNor,
size_t  numNor
 

Overwrite of Triangles::setNormals.

Sets the normals in the skins and then calls to Triangles::setNormals.

Parameters:
pNor  normals to set
numNor  number of normals

Reimplemented from nvsg::GeoSet.

NVSG_API void nvsg::SkinnedTriangles::setSkins const Skin pSkins,
size_t  numSkins
 

Set the skins.

A Skin contains the information how a vertex and a normal is calculated for each animation step.

Parameters:
pSkins  skins to set
numSkins  number of skins

NVSG_API void nvsg::SkinnedTriangles::setSkins size_t  pos,
const Skin pSkins,
size_t  numSkins
 

Set skins.

Copies /a numSkins skins pointed to by /a pSkins, starting at position /a pos inside the range of pre-existing skins.

Pre-existing skins in the range [pos, pos + numSkins) will be replaced. Pre-existing skins outside this range remain untouched.

If you specify -1 for pos or if pos specifies the number of skins currently stored, the skins pointed to by pSkins will be appended to the pre-existing faces.

If you not specify -1 for pos or pos neither specifies the number of skins currently stored nor does it specify a valid position inside the range of pre-existing skins, the behaviour is undefined!


The documentation for this class was generated from the following file:
Generated on Tue Mar 1 13:20:56 2005 for NVSGSDK by NVIDIA