source:
orxonox.OLD/trunk/src/lib/collision_detection/bounding_volume.h
@
6224
Last change on this file since 6224 was 6022, checked in by bensch, 19 years ago | |
---|---|
File size: 1.2 KB |
Rev | Line | |
---|---|---|
[4588] | 1 | /*! |
[5039] | 2 | * @file bounding_volume.h |
[4836] | 3 | * Definition of a bounding volume for collision detection algorithms |
[4510] | 4 | |
[4616] | 5 | */ |
[4510] | 6 | |
[4511] | 7 | #ifndef _BOUNDING_VOLUME_H |
8 | #define _BOUNDING_VOLUME_H | |
[4510] | 9 | |
10 | #include "base_object.h" | |
[6022] | 11 | #include "model.h" |
[4510] | 12 | |
[4520] | 13 | class Vector; |
[4541] | 14 | template<class T> class tList; |
[4510] | 15 | |
[4541] | 16 | |
[4511] | 17 | //! An abstract class representing a bounding volume |
18 | class BoundingVolume : public BaseObject { | |
[4510] | 19 | |
[4616] | 20 | public: |
21 | BoundingVolume(); | |
22 | virtual ~BoundingVolume(); | |
[4510] | 23 | |
[4616] | 24 | inline const Vector* getCenter() const { return this->center; } |
[4510] | 25 | |
[5688] | 26 | const sVec3D* getVertices() const { return this->vertices; } |
[5279] | 27 | virtual void mergeWith(const BoundingVolume &bv) = 0; |
[4520] | 28 | |
[5279] | 29 | virtual void drawBV(int currentDepth, int drawMode) const = 0; |
[4521] | 30 | |
[4525] | 31 | |
[4635] | 32 | |
[4616] | 33 | public: |
34 | Vector* center; //!< Center point of box | |
[4510] | 35 | |
[5688] | 36 | const sVec3D* vertices; //!< if CD_STORE_VERTICES enabled, this is the place, where the vert. will be sotred |
[4616] | 37 | int numOfVertices; //!< number of vertices in the vertices buffer |
[4814] | 38 | bool bOrigVertices; //!< is true if the vertices pointer points to the original model data - only important for deleting |
[4510] | 39 | }; |
40 | ||
[4511] | 41 | #endif /* _BOUNDING_VOLUME_H */ |
Note: See TracBrowser
for help on using the repository browser.