Rev | Line | |
---|
[2197] | 1 | #include "dxstdafx.h" |
---|
| 2 | #include "Occluder.hpp" |
---|
| 3 | |
---|
| 4 | Occluder::Occluder(const Vector& centre, const float hardRadius) |
---|
| 5 | { |
---|
| 6 | this->centre = centre; |
---|
| 7 | this->solidRadius = hardRadius; |
---|
| 8 | |
---|
| 9 | lastTestedRayId = 0; |
---|
| 10 | occluders = NULL; |
---|
| 11 | nOccluders = 0; |
---|
| 12 | |
---|
| 13 | bbox.minPoint.x = centre.x - solidRadius; |
---|
| 14 | bbox.minPoint.y = centre.y - solidRadius; |
---|
| 15 | bbox.minPoint.z = centre.z - solidRadius; |
---|
| 16 | bbox.maxPoint.x = centre.x + solidRadius; |
---|
| 17 | bbox.maxPoint.y = centre.y + solidRadius; |
---|
| 18 | bbox.maxPoint.z = centre.z + solidRadius; |
---|
| 19 | |
---|
| 20 | } |
---|
| 21 | |
---|
| 22 | void Occluder::setupBBox() |
---|
| 23 | { |
---|
| 24 | lastTestedRayId = 0; |
---|
| 25 | occluders = NULL; |
---|
| 26 | nOccluders = 0; |
---|
| 27 | |
---|
| 28 | bbox.minPoint.x = centre.x - solidRadius; |
---|
| 29 | bbox.minPoint.y = centre.y - solidRadius; |
---|
| 30 | bbox.minPoint.z = centre.z - solidRadius; |
---|
| 31 | bbox.maxPoint.x = centre.x + solidRadius; |
---|
| 32 | bbox.maxPoint.y = centre.y + solidRadius; |
---|
| 33 | bbox.maxPoint.z = centre.z + solidRadius; |
---|
| 34 | } |
---|
| 35 | |
---|
| 36 | Occluder::~Occluder(void) |
---|
| 37 | { |
---|
| 38 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.