VR-Forces 4.0.4 Class Documentation
Classes | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes
makVrv::DtTexturedPrimitiveStyle Class Reference

A style for rendering a primitive with a single texture applied. More...

Inheritance diagram for makVrv::DtTexturedPrimitiveStyle:
Inheritance graph
[legend]

List of all members.

Classes

struct  TexturedQuadInfo

Public Member Functions

 DtTexturedPrimitiveStyle (DtOverlayResourceProvider &provider, unsigned int vertexCount)
 CTOR.
virtual ~DtTexturedPrimitiveStyle ()
 Virtual DTOR.
virtual void add (unsigned int *indexPtr)
 Add an index pointer to keep up to date.
virtual void remove (unsigned int index)
 Remove an index.
virtual void render (int mode, unsigned int groupCount, bool geocentric, float geocentricAlpha, const double cameraLocation[3]=0, const double positionMatrix[16]=0, int offset=0)
 Render the primitives.
Vertex Attribute Setters and Getters
virtual void set3DVertexPosition (unsigned int index, unsigned int vertex, float x, float y, float z, float w)
 Sets the 3D position of the vertex.
virtual void get3DVertexPosition (unsigned int index, unsigned int vertex, float &x, float &y, float &z, float &w) const
 Gets the 3D position of the vertex.
virtual void set2DVertexPosition (unsigned int index, unsigned int vertex, float x, float y)
 Sets the 2D position (offset) of the vertex.
virtual void get2DVertexPosition (unsigned int index, unsigned int vertex, float &x, float &y) const
 Gets the 2D position (offset) of the vertex.
virtual void set2DOffsetRotation (unsigned int index, unsigned int vertIndex, float angle)
 Sets the rotation of the vertex's 2D offset.
virtual void get2DOffsetRotation (unsigned int index, unsigned int vertIndex, float &angle) const
 Gets the rotation of the vertex's 2D offset.
virtual void setColor (unsigned int index, unsigned int vertex, float r, float g, float b, float a)
 Sets the color of the vertex.
virtual void getColor (unsigned int index, unsigned int vertex, float &r, float &g, float &b, float &a) const
 Gets the color of the vertex.
virtual void setUVCoordinates (unsigned int index, unsigned int vertIndex, float u, float v)
 Sets the UV coordinate.
virtual void getUVCoordinates (unsigned int index, unsigned int vertIndex, float &u, float &v) const
 Gets the UV coordinate.
Primitive Attribute Setters and Getters
virtual void setFillParameters (unsigned int index, void *fill, unsigned int fullStipplePattern[32]=0)
 Sets the fill parameters for the primitive.
virtual void getFillParameters (unsigned int index, void *&fill, unsigned int fullStipplePattern[32]) const
 Gets the fill parameters for the primitive.
virtual void setGroup (unsigned int index, float zFactor)
 Sets the group for the primitive.
virtual float group (unsigned int index) const
 Gets the group for the primitive.

Protected Types

typedef std::vector
< DtOffsetColoredTexturedVertex
TexturedQuadVertexList
typedef std::vector
< TexturedQuadInfo
TexturedQuadInfoList
typedef boost::unordered_map
< void *, std::vector
< unsigned int > > 
TextureIndexMap

Protected Member Functions

virtual float * vertexData () const
 Get the vertex data.
virtual unsigned int vertexDataSize () const
 Get total size of the vertex data in bytes.
void addIndexedTextureCache (unsigned int index, void *textureHandle)
 Adds the given texture handle to the cache (indexed by primitive).
void removeIndexedTextureCache (unsigned int index, void *textureHandle)
 Removes the teexture handle from the cache.

Protected Attributes

DtOverlayResourceProvidermyResourceProvider
TexturedQuadVertexList myTexturedQuadsVertices
TexturedQuadInfoList myTexturedQuads
TextureIndexMap myTextureIndexMap
DtProjected2DTexturedEffectmyEffect

Detailed Description

A style for rendering a primitive with a single texture applied.


Member Typedef Documentation

typedef boost::unordered_map<void*,std::vector<unsigned int> > makVrv::DtTexturedPrimitiveStyle::TextureIndexMap [protected]

Constructor & Destructor Documentation

CTOR.

Virtual DTOR.


Member Function Documentation

virtual void makVrv::DtTexturedPrimitiveStyle::add ( unsigned int *  indexPtr) [virtual]

Add an index pointer to keep up to date.

Reimplemented from makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::remove ( unsigned int  index) [virtual]

Remove an index.

Reimplemented from makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::render ( int  mode,
unsigned int  groupCount,
bool  geocentric,
float  geocentricAlpha,
const double  cameraLocation[3] = 0,
const double  positionMatrix[16] = 0,
int  offset = 0 
) [virtual]

Render the primitives.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::set3DVertexPosition ( unsigned int  index,
unsigned int  vertex,
float  x,
float  y,
float  z,
float  w 
) [virtual]

Sets the 3D position of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::get3DVertexPosition ( unsigned int  index,
unsigned int  vertex,
float &  x,
float &  y,
float &  z,
float &  w 
) const [virtual]

Gets the 3D position of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::set2DVertexPosition ( unsigned int  index,
unsigned int  vertex,
float  x,
float  y 
) [virtual]

Sets the 2D position (offset) of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::get2DVertexPosition ( unsigned int  index,
unsigned int  vertex,
float &  x,
float &  y 
) const [virtual]

Gets the 2D position (offset) of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::set2DOffsetRotation ( unsigned int  index,
unsigned int  vertIndex,
float  angle 
) [virtual]

Sets the rotation of the vertex's 2D offset.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::get2DOffsetRotation ( unsigned int  index,
unsigned int  vertIndex,
float &  angle 
) const [virtual]

Gets the rotation of the vertex's 2D offset.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::setColor ( unsigned int  index,
unsigned int  vertex,
float  r,
float  g,
float  b,
float  a 
) [virtual]

Sets the color of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::getColor ( unsigned int  index,
unsigned int  vertex,
float &  r,
float &  g,
float &  b,
float &  a 
) const [virtual]

Gets the color of the vertex.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::setUVCoordinates ( unsigned int  index,
unsigned int  vertIndex,
float  u,
float  v 
) [virtual]

Sets the UV coordinate.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::getUVCoordinates ( unsigned int  index,
unsigned int  vertIndex,
float &  u,
float &  v 
) const [virtual]

Gets the UV coordinate.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::setFillParameters ( unsigned int  index,
void *  fill,
unsigned int  fullStipplePattern[32] = 0 
) [virtual]

Sets the fill parameters for the primitive.

Parameters:
indexthe index of the primitive to set the fill param for.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::getFillParameters ( unsigned int  index,
void *&  fill,
unsigned int  fullStipplePattern[32] 
) const [virtual]

Gets the fill parameters for the primitive.

Parameters:
indexthe index of the primitive to get the fill param for.

Implements makVrv::DtPrimitiveStyle.

virtual void makVrv::DtTexturedPrimitiveStyle::setGroup ( unsigned int  index,
float  zFactor 
) [virtual]

Sets the group for the primitive.

Parameters:
indexthe index of the primitve to set the group for.

Implements makVrv::DtPrimitiveStyle.

virtual float makVrv::DtTexturedPrimitiveStyle::group ( unsigned int  index) const [virtual]

Gets the group for the primitive.

Parameters:
indexthe index of the primitive to get the group for.

Implements makVrv::DtPrimitiveStyle.

virtual float* makVrv::DtTexturedPrimitiveStyle::vertexData ( ) const [protected, virtual]

Get the vertex data.

Implements makVrv::DtPrimitiveStyle.

virtual unsigned int makVrv::DtTexturedPrimitiveStyle::vertexDataSize ( ) const [protected, virtual]

Get total size of the vertex data in bytes.

Implements makVrv::DtPrimitiveStyle.

void makVrv::DtTexturedPrimitiveStyle::addIndexedTextureCache ( unsigned int  index,
void *  textureHandle 
) [protected]

Adds the given texture handle to the cache (indexed by primitive).

void makVrv::DtTexturedPrimitiveStyle::removeIndexedTextureCache ( unsigned int  index,
void *  textureHandle 
) [protected]

Removes the teexture handle from the cache.


Member Data Documentation


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

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)