Last change
on this file since 4629 was
4588,
checked in by patrick, 20 years ago
|
orxonox/trunk: now drawing o-boundingbox as a polygon, seems to be one minor accuracy problem
|
File size:
1.0 KB
|
Line | |
---|
1 | /*! |
---|
2 | \file obb.h |
---|
3 | \brief Definition of an OBB (object Oriented Bounding Box) |
---|
4 | |
---|
5 | */ |
---|
6 | |
---|
7 | #ifndef _OBB_H |
---|
8 | #define _OBB_H |
---|
9 | |
---|
10 | #include "base_object.h" |
---|
11 | #include "bounding_volume.h" |
---|
12 | |
---|
13 | template<class T> class tList; |
---|
14 | |
---|
15 | //! A class representing an extended bounding volume tree: an obb tree |
---|
16 | class OBB : public BoundingVolume { |
---|
17 | |
---|
18 | public: |
---|
19 | OBB(); |
---|
20 | virtual ~OBB(); |
---|
21 | |
---|
22 | |
---|
23 | inline Vector** getAxis () const { return this->axis; } |
---|
24 | inline const float* getHalfLength() const { return this->halfLength; } |
---|
25 | |
---|
26 | virtual void mergeWith(const BoundingVolume &bv); |
---|
27 | |
---|
28 | virtual void drawBV(int currentDepth, const int depth) const; |
---|
29 | virtual void drawBVPolygon(int currentDepth, const int depth) const; |
---|
30 | virtual void drawBVBlended(int currentDepth, const int depth) const; |
---|
31 | |
---|
32 | |
---|
33 | public: |
---|
34 | Vector** axis; //!< Axes of oriented box [x,y,z] |
---|
35 | float* halfLength; //!< Half lengths of the box along the axis |
---|
36 | float covarianceMatrix[3][3]; //!< the covariance matrix |
---|
37 | |
---|
38 | }; |
---|
39 | |
---|
40 | #endif /* _OBB_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.