Vegastrike 0.5.1 rc1  1.0
Original sources for Vegastrike Evolved
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
BVTCache Struct Reference

#include <OPC_TreeCollider.h>

Inheritance diagram for BVTCache:
Pair

Public Member Functions

 BVTCache ()
 Constructor. More...
 
void ResetCache ()
 
void ResetCountDown ()
 
- Public Member Functions inherited from Pair
inline_ Pair ()
 
inline_ Pair (udword i0, udword i1)
 

Public Attributes

const ModelModel0
 Model for first object. More...
 
const ModelModel1
 Model for second object. More...
 
- Public Attributes inherited from Pair
udword id0
 First index of the pair. More...
 
udword id1
 Second index of the pair. More...
 

Detailed Description

This structure holds cached information used by the algorithm. Two model pointers and two colliding primitives are cached. Model pointers are assigned to their respective meshes, and the pair of colliding primitives is used for temporal coherence. That is, in case temporal coherence is enabled, those two primitives are tested for overlap before everything else. If they still collide, we're done before even entering the recursive collision code.

Definition at line 29 of file OPC_TreeCollider.h.

Constructor & Destructor Documentation

BVTCache::BVTCache ( )
inline

Constructor.

Definition at line 32 of file OPC_TreeCollider.h.

33  {
34  ResetCache();
36  }

Member Function Documentation

void BVTCache::ResetCache ( )
inline

Definition at line 38 of file OPC_TreeCollider.h.

References f, and null.

39  {
40  Model0 = null;
41  Model1 = null;
42  id0 = 0;
43  id1 = 1;
44 #ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE !
45  HullTest = true;
46  SepVector.pid = 0;
47  SepVector.qid = 0;
48  SepVector.SV = Point(1.0f, 0.0f, 0.0f);
49 #endif // __MESHMERIZER_H__
50  }
void BVTCache::ResetCountDown ( )
inline

Definition at line 52 of file OPC_TreeCollider.h.

53  {
54 #ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE !
55  CountDown = 50;
56 #endif // __MESHMERIZER_H__
57  }

Member Data Documentation

const Model* BVTCache::Model0

Model for first object.

Definition at line 59 of file OPC_TreeCollider.h.

const Model* BVTCache::Model1

Model for second object.

Definition at line 60 of file OPC_TreeCollider.h.


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