# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NL3D::CTessFace Class Reference

A Landscape Triangle. More...

#include <tessellation.h>

Inheritance diagram for NL3D::CTessFace

Inheritance graph
[legend]
Collaboration diagram for NL3D::CTessFace:

Collaboration graph
[legend]
List of all members.

Public Methods

 CTessFace ()
 ~CTessFace ()
bool isLeaf () const
bool isRectangular () const
bool hasVertex (CTessVertex *v) const
bool hasEdge (CTessVertex *v0, CTessVertex *v1) const
void changeNeighbor (CTessFace *from, CTessFace *to)
void computeTileMaterial ()
void releaseTileMaterial ()
void updateErrorMetric ()
void split (bool propagateSplit=true)
bool merge ()
void refine ()
void unbind (CPatch *except[4])
void forceMerge ()
bool updateBindEdge (CTessFace *&edgeFace, bool &splitWanted)
void updateBind ()
void updateBindAndSplit ()
void forceMergeAtTileLevel ()
void deleteTileUvs ()
void recreateTileUvs ()

Public Attributes

uint8 TileId
CTileMaterialTileMaterial
CTileFaceTileFaces [NL3D_MAX_TILE_FACE]
sint ProjectedSizeDate
float Size
CVector Center
float ProjectedSize
float ErrorMetric
CTessFarVertexFVBase
CTessFarVertexFVLeft
CTessFarVertexFVRight
float TileDistFar = CTessFace::TileDistNear+20
float TileDistFarSqr = sqr(CTessFace::TileDistFar)
float Far1Dist = 400
geometric tesselation.
CPatchPatch
CTessVertexVBase
CTessVertexVLeft
CTessVertexVRight
CTessFace* FBase
CTessFace * FLeft
CTessFace * FRight
CTessFace* Father
CTessFace * SonLeft
CTessFace * SonRight
CParamCoord PVBase
CParamCoord PVLeft
CParamCoord PVRight
uint8 Level
bool NeedCompute
bool RecursMarkCanMerge
bool RecursMarkForceMerge

Static Public Attributes

sint CurrentDate = 0
CVector RefineCenter = CVector::Null
float RefineThreshold = 0.001f
float OORefineThreshold = 1.0f / CTessFace::RefineThreshold
float ChildrenStartComputeLimit = 1.9f
float SelfEndComputeLimit = 2.1f
float TileDistNear = 50
float TileDistNearSqr = sqr(CTessFace::TileDistNear)
float OOTileDistDeltaSqr = 1.0f / (CTessFace::TileDistFarSqr - CTessFace::TileDistNearSqr)
sint TileMaxSubdivision = 0
NLMISC::CBSphere TileFarSphere
NLMISC::CBSphere TileNearSphere
float TilePixelSize = 128
float Far0Dist = 200
float FarTransition = 10
CVertexBufferCurrentFarVB = NULL
CVertexBufferCurrentTileVB = NULL
sint CurrentFarIndex = 1
sint CurrentTileIndex = 1
CTessFace MultipleBindFace

Private Types

enum  TTileUvId {
  IdUvBase = 0,
  IdUvLeft,
  IdUvRight
}

Private Methods

void allocTileUv (TTileUvId id)
void deleteTileUv (TTileUvId id)
void copyTileUv (TTileUvId id, CTessFace *srcFace, TTileUvId srcId)
void heritTileUv (CTessFace *baseFace)
void buildTileFaces ()
void deleteTileFaces ()
bool emptyTileFaces ()
void computeTileErrorMetric ()
bool canMerge (bool testEm)
void splitRectangular (bool propagateSplit)
void doMerge ()
void heritTileMaterial ()
void initTileUvRGBA (sint pass, bool alpha, CParamCoord pointCoord, CParamCoord middleCoord, CUV &uv)
void initTileUvLightmap (CParamCoord pointCoord, CParamCoord middleCoord, CUV &uv)
void updateNearFarVertices ()

Static Private Methods

bool sameTile (const CTessFace *a, const CTessFace *b)
bool exceptPatch (CPatch *p, CPatch *except[4])

Static Private Attributes

CTessFace CantMergeFace

Detailed Description

A Landscape Triangle.

Author(s):
Lionel Berenguier , Nevrax France
Date:
2000

Definition at line 199 of file tessellation.h.


Member Enumeration Documentation

enum NL3D::CTessFace::TTileUvId [private]
 

Enumeration values:
IdUvBase  
IdUvLeft  
IdUvRight  

Definition at line 361 of file tessellation.h.


Constructor & Destructor Documentation

NL3D::CTessFace::CTessFace ( )
 

Definition at line 112 of file tessellation.cpp.

NL3D::CTessFace::~CTessFace ( )
 

Definition at line 145 of file tessellation.cpp.


Member Function Documentation

void NL3D::CTessFace::allocTileUv ( TTileUvId id ) [private]
 

Definition at line 266 of file tessellation.cpp.

void NL3D::CTessFace::buildTileFaces ( ) [private]
 

Definition at line 367 of file tessellation.cpp.

bool NL3D::CTessFace::canMerge ( bool testEm ) [private]
 

Definition at line 1227 of file tessellation.cpp.

void NL3D::CTessFace::changeNeighbor ( CTessFace * from,
CTessFace * to ) [inline]
 

Definition at line 260 of file tessellation.h.

void NL3D::CTessFace::computeTileErrorMetric ( ) [private]
 

Definition at line 166 of file tessellation.cpp.

void NL3D::CTessFace::computeTileMaterial ( )
 

Definition at line 510 of file tessellation.cpp.

void NL3D::CTessFace::copyTileUv ( TTileUvId dstId,
CTessFace * srcFace,
TTileUvId srcId ) [private]
 

Definition at line 311 of file tessellation.cpp.

void NL3D::CTessFace::deleteTileFaces ( ) [private]
 

Definition at line 384 of file tessellation.cpp.

void NL3D::CTessFace::deleteTileUv ( TTileUvId id ) [private]
 

Definition at line 288 of file tessellation.cpp.

void NL3D::CTessFace::deleteTileUvs ( )
 

Definition at line 2175 of file tessellation.cpp.

void NL3D::CTessFace::doMerge ( ) [private]
 

Definition at line 1282 of file tessellation.cpp.

bool NL3D::CTessFace::emptyTileFaces ( ) [private]
 

Definition at line 405 of file tessellation.cpp.

bool NL3D::CTessFace::exceptPatch ( CPatch * p,
CPatch * except[4] ) [static, private]
 

Definition at line 1615 of file tessellation.cpp.

void NL3D::CTessFace::forceMerge ( )
 

Definition at line 1753 of file tessellation.cpp.

void NL3D::CTessFace::forceMergeAtTileLevel ( )
 

Definition at line 1789 of file tessellation.cpp.

bool NL3D::CTessFace::hasEdge ( CTessVertex * v0,
CTessVertex * v1 ) const [inline]
 

Definition at line 259 of file tessellation.h.

bool NL3D::CTessFace::hasVertex ( CTessVertex * v ) const [inline]
 

Definition at line 258 of file tessellation.h.

void NL3D::CTessFace::heritTileMaterial ( ) [private]
 

Definition at line 2259 of file tessellation.cpp.

void NL3D::CTessFace::heritTileUv ( CTessFace * baseFace ) [private]
 

Definition at line 347 of file tessellation.cpp.

void NL3D::CTessFace::initTileUvLightmap ( CParamCoord pointCoord,
CParamCoord middle,
CUV & uv ) [private]
 

Definition at line 490 of file tessellation.cpp.

void NL3D::CTessFace::initTileUvRGBA ( sint pass,
bool alpha,
CParamCoord pointCoord,
CParamCoord middle,
CUV & uv ) [private]
 

Definition at line 421 of file tessellation.cpp.

bool NL3D::CTessFace::isLeaf ( ) const [inline]
 

Definition at line 256 of file tessellation.h.

bool NL3D::CTessFace::isRectangular ( ) const
 

Definition at line 2160 of file tessellation.cpp.

bool NL3D::CTessFace::merge ( )
 

Definition at line 1418 of file tessellation.cpp.

void NL3D::CTessFace::recreateTileUvs ( )
 

Definition at line 2223 of file tessellation.cpp.

void NL3D::CTessFace::refine ( )
 

Definition at line 1439 of file tessellation.cpp.

void NL3D::CTessFace::releaseTileMaterial ( )
 

Definition at line 646 of file tessellation.cpp.

bool NL3D::CTessFace::sameTile ( const CTessFace * a,
const CTessFace * b ) [inline, static, private]
 

Definition at line 353 of file tessellation.h.

void NL3D::CTessFace::split ( bool propagateSplit = true )
 

Definition at line 1008 of file tessellation.cpp.

void NL3D::CTessFace::splitRectangular ( bool propagateSplit ) [private]
 

Definition at line 712 of file tessellation.cpp.

void NL3D::CTessFace::unbind ( CPatch * except[4] )
 

Definition at line 1628 of file tessellation.cpp.

void NL3D::CTessFace::updateBind ( )
 

Definition at line 2125 of file tessellation.cpp.

void NL3D::CTessFace::updateBindAndSplit ( )
 

Definition at line 1908 of file tessellation.cpp.

bool NL3D::CTessFace::updateBindEdge ( CTessFace *& edgeFace,
bool & splitWanted )
 

Definition at line 1809 of file tessellation.cpp.

void NL3D::CTessFace::updateErrorMetric ( )
 

Definition at line 213 of file tessellation.cpp.

void NL3D::CTessFace::updateNearFarVertices ( ) [private]
 

Definition at line 684 of file tessellation.cpp.


Member Data Documentation

CTessFace NL3D::CTessFace::CantMergeFace [static, private]
 

Definition at line 107 of file tessellation.cpp.

CVector NL3D::CTessFace::Center
 

Definition at line 239 of file tessellation.h.

float NL3D::CTessFace::ChildrenStartComputeLimit = 1.9f [static]
 

Definition at line 84 of file tessellation.cpp.

sint NL3D::CTessFace::CurrentDate = 0 [static]
 

Definition at line 79 of file tessellation.cpp.

sint NL3D::CTessFace::CurrentFarIndex = 1 [static]
 

Definition at line 102 of file tessellation.cpp.

CVertexBuffer * NL3D::CTessFace::CurrentFarVB = NULL [static]
 

Definition at line 101 of file tessellation.cpp.

sint NL3D::CTessFace::CurrentTileIndex = 1 [static]
 

Definition at line 104 of file tessellation.cpp.

CVertexBuffer * NL3D::CTessFace::CurrentTileVB = NULL [static]
 

Definition at line 103 of file tessellation.cpp.

float NL3D::CTessFace::ErrorMetric
 

Definition at line 241 of file tessellation.h.

CTessFace * NL3D::CTessFace::FBase
 

Definition at line 208 of file tessellation.h.

CTessFace * NL3D::CTessFace::FLeft
 

Definition at line 208 of file tessellation.h.

CTessFace * NL3D::CTessFace::FRight
 

Definition at line 208 of file tessellation.h.

CTessFarVertex * NL3D::CTessFace::FVBase
 

Definition at line 246 of file tessellation.h.

CTessFarVertex * NL3D::CTessFace::FVLeft
 

Definition at line 246 of file tessellation.h.

CTessFarVertex * NL3D::CTessFace::FVRight
 

Definition at line 246 of file tessellation.h.

float NL3D::CTessFace::Far0Dist = 200 [static]
 

Definition at line 98 of file tessellation.cpp.

float NL3D::CTessFace::Far1Dist = 400
 

Definition at line 99 of file tessellation.cpp.

float NL3D::CTessFace::FarTransition = 10 [static]
 

Definition at line 100 of file tessellation.cpp.

CTessFace * NL3D::CTessFace::Father
 

Definition at line 209 of file tessellation.h.

uint8 NL3D::CTessFace::Level
 

Definition at line 213 of file tessellation.h.

CTessFace NL3D::CTessFace::MultipleBindFace [static]
 

Definition at line 108 of file tessellation.cpp.

bool NL3D::CTessFace::NeedCompute
 

Definition at line 215 of file tessellation.h.

float NL3D::CTessFace::OORefineThreshold = 1.0f / CTessFace::RefineThreshold [static]
 

Definition at line 82 of file tessellation.cpp.

float NL3D::CTessFace::OOTileDistDeltaSqr = 1.0f / (CTessFace::TileDistFarSqr - CTessFace::TileDistNearSqr) [static]
 

Definition at line 91 of file tessellation.cpp.

CParamCoord NL3D::CTessFace::PVBase
 

Definition at line 211 of file tessellation.h.

CParamCoord NL3D::CTessFace::PVLeft
 

Definition at line 211 of file tessellation.h.

CParamCoord NL3D::CTessFace::PVRight
 

Definition at line 211 of file tessellation.h.

CPatch * NL3D::CTessFace::Patch
 

Definition at line 206 of file tessellation.h.

float NL3D::CTessFace::ProjectedSize
 

Definition at line 240 of file tessellation.h.

sint NL3D::CTessFace::ProjectedSizeDate
 

Definition at line 237 of file tessellation.h.

bool NL3D::CTessFace::RecursMarkCanMerge
 

Definition at line 217 of file tessellation.h.

bool NL3D::CTessFace::RecursMarkForceMerge
 

Definition at line 218 of file tessellation.h.

CVector NL3D::CTessFace::RefineCenter = CVector::Null [static]
 

Definition at line 80 of file tessellation.cpp.

float NL3D::CTessFace::RefineThreshold = 0.001f [static]
 

Definition at line 81 of file tessellation.cpp.

float NL3D::CTessFace::SelfEndComputeLimit = 2.1f [static]
 

Definition at line 85 of file tessellation.cpp.

float NL3D::CTessFace::Size
 

Definition at line 238 of file tessellation.h.

CTessFace * NL3D::CTessFace::SonLeft
 

Definition at line 209 of file tessellation.h.

CTessFace * NL3D::CTessFace::SonRight
 

Definition at line 209 of file tessellation.h.

float NL3D::CTessFace::TileDistFar = CTessFace::TileDistNear+20
 

Definition at line 88 of file tessellation.cpp.

float NL3D::CTessFace::TileDistFarSqr = sqr(CTessFace::TileDistFar)
 

Definition at line 90 of file tessellation.cpp.

float NL3D::CTessFace::TileDistNear = 50 [static]
 

Definition at line 87 of file tessellation.cpp.

float NL3D::CTessFace::TileDistNearSqr = sqr(CTessFace::TileDistNear) [static]
 

Definition at line 89 of file tessellation.cpp.

CTileFace * NL3D::CTessFace::TileFaces[NL3D_MAX_TILE_FACE]
 

Definition at line 229 of file tessellation.h.

CBSphere NL3D::CTessFace::TileFarSphere [static]
 

Definition at line 93 of file tessellation.cpp.

uint8 NL3D::CTessFace::TileId
 

Definition at line 225 of file tessellation.h.

CTileMaterial * NL3D::CTessFace::TileMaterial
 

Definition at line 227 of file tessellation.h.

sint NL3D::CTessFace::TileMaxSubdivision = 0 [static]
 

Definition at line 92 of file tessellation.cpp.

CBSphere NL3D::CTessFace::TileNearSphere [static]
 

Definition at line 94 of file tessellation.cpp.

float NL3D::CTessFace::TilePixelSize = 128 [static]
 

Definition at line 95 of file tessellation.cpp.

CTessVertex * NL3D::CTessFace::VBase
 

Definition at line 207 of file tessellation.h.

CTessVertex * NL3D::CTessFace::VLeft
 

Definition at line 207 of file tessellation.h.

CTessVertex * NL3D::CTessFace::VRight
 

Definition at line 207 of file tessellation.h.


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