VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
trpgwGeomHelper Class Reference

Public Types

enum  { UseDouble, UseFloat }

Public Member Functions

 trpgwGeomHelper (void)
virtual ~trpgwGeomHelper (void)
 trpgwGeomHelper (trpgWriteBuffer *, int dataType=UseDouble)
void init (trpgWriteBuffer *, int dataType=UseDouble)
virtual void SetMode (int)
virtual void Reset (void)
 Takes a trpgGeometry primitive type (triangle by default)
virtual void StartPolygon (void)
 Start/End polygon definition.
virtual void EndPolygon (void)
virtual void ResetPolygon (void)
virtual void SetColor (trpgColor &)
 If you change your mind about the current poly.
virtual void SetTexCoord (trpg2dPoint &)
virtual void AddTexCoord (trpg2dPoint &)
virtual void SetNormal (trpg3dPoint &)
 for multiple textures
virtual void SetMaterial (int32)
virtual void AddMaterial (int32)
virtual void AddVertex (trpg3dPoint &)
 for multiple textures
virtual void FlushGeom (void)
 Dump whatever we're doing and move on.
virtual void GetZMinMax (double &min, double &max)
 Get the Min and Max Z values.
trpgwGeomStatsGetStats (void)
 Get statistics for whatever we built.

Protected Member Functions

virtual void Optimize (void)
virtual void ResetTri (void)
 Reset Triangle arrays.

Protected Attributes

int mode
int dataType
trpgWriteBufferbuf
trpgGeometry strips
 Collections of geometry.
trpgGeometry fans
trpgGeometry bags
std::vector< int32matTri
 Temporary data arrays for triangles/quads.
std::vector< trpg2dPointtex
std::vector< trpg3dPointnorm
std::vector< trpg3dPointvert
std::vector< int32matPoly
 Data arrays for a polygon.
std::vector< trpg2dPointpolyTex
std::vector< trpg3dPointpolyNorm
std::vector< trpg3dPointpolyVert
std::vector< trpg2dPointtmpTex
 Single points.
trpg3dPoint tmpNorm
trpgColor tmpCol
trpgwGeomStats stats
 Geometry status built up as we go.
double zmin
 Keeps track of min and max z values.
double zmax

Member Enumeration Documentation

anonymous enum
Enumerator:
UseDouble 
UseFloat 

Constructor & Destructor Documentation

trpgwGeomHelper::trpgwGeomHelper ( void  )
virtual trpgwGeomHelper::~trpgwGeomHelper ( void  )
virtual
trpgwGeomHelper::trpgwGeomHelper ( trpgWriteBuffer ,
int  dataType = UseDouble 
)

Member Function Documentation

void trpgwGeomHelper::init ( trpgWriteBuffer ,
int  dataType = UseDouble 
)
virtual void trpgwGeomHelper::SetMode ( int  )
virtual
virtual void trpgwGeomHelper::Reset ( void  )
virtual

Takes a trpgGeometry primitive type (triangle by default)

virtual void trpgwGeomHelper::StartPolygon ( void  )
virtual

Start/End polygon definition.

virtual void trpgwGeomHelper::EndPolygon ( void  )
virtual
virtual void trpgwGeomHelper::ResetPolygon ( void  )
virtual
virtual void trpgwGeomHelper::SetColor ( trpgColor )
virtual

If you change your mind about the current poly.

Set the current state Note: Currently you must set all of these

virtual void trpgwGeomHelper::SetTexCoord ( trpg2dPoint )
virtual
virtual void trpgwGeomHelper::AddTexCoord ( trpg2dPoint )
virtual
virtual void trpgwGeomHelper::SetNormal ( trpg3dPoint )
virtual

for multiple textures

virtual void trpgwGeomHelper::SetMaterial ( int32  )
virtual
virtual void trpgwGeomHelper::AddMaterial ( int32  )
virtual
virtual void trpgwGeomHelper::AddVertex ( trpg3dPoint )
virtual

for multiple textures

Pull the state info together and add a vertex

virtual void trpgwGeomHelper::FlushGeom ( void  )
virtual

Dump whatever we're doing and move on.

virtual void trpgwGeomHelper::GetZMinMax ( double &  min,
double &  max 
)
virtual

Get the Min and Max Z values.

trpgwGeomStats* trpgwGeomHelper::GetStats ( void  )
inline

Get statistics for whatever we built.

virtual void trpgwGeomHelper::Optimize ( void  )
protectedvirtual
virtual void trpgwGeomHelper::ResetTri ( void  )
protectedvirtual

Reset Triangle arrays.

Member Data Documentation

int trpgwGeomHelper::mode
protected
int trpgwGeomHelper::dataType
protected
trpgWriteBuffer* trpgwGeomHelper::buf
protected
trpgGeometry trpgwGeomHelper::strips
protected

Collections of geometry.

trpgGeometry trpgwGeomHelper::fans
protected
trpgGeometry trpgwGeomHelper::bags
protected
std::vector<int32> trpgwGeomHelper::matTri
protected

Temporary data arrays for triangles/quads.

std::vector<trpg2dPoint> trpgwGeomHelper::tex
protected
std::vector<trpg3dPoint> trpgwGeomHelper::norm
protected
std::vector<trpg3dPoint> trpgwGeomHelper::vert
protected
std::vector<int32> trpgwGeomHelper::matPoly
protected

Data arrays for a polygon.

std::vector<trpg2dPoint> trpgwGeomHelper::polyTex
protected
std::vector<trpg3dPoint> trpgwGeomHelper::polyNorm
protected
std::vector<trpg3dPoint> trpgwGeomHelper::polyVert
protected
std::vector<trpg2dPoint> trpgwGeomHelper::tmpTex
protected

Single points.

trpg3dPoint trpgwGeomHelper::tmpNorm
protected
trpgColor trpgwGeomHelper::tmpCol
protected
trpgwGeomStats trpgwGeomHelper::stats
protected

Geometry status built up as we go.

double trpgwGeomHelper::zmin
protected

Keeps track of min and max z values.

double trpgwGeomHelper::zmax
protected

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

Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)