[1317] | 1 | /*
|
---|
| 2 | -----------------------------------------------------------------------------
|
---|
| 3 | This source file is part of the GameTools Project
|
---|
| 4 | http://www.gametools.org
|
---|
| 5 |
|
---|
| 6 | Author: Martin Szydlowski
|
---|
| 7 | -----------------------------------------------------------------------------
|
---|
| 8 | */
|
---|
| 9 |
|
---|
[1318] | 10 | #ifndef _OgreBvHierarchySceneNode_H__
|
---|
| 11 | #define _OgreBvHierarchySceneNode_H__
|
---|
[1317] | 12 |
|
---|
| 13 | #include <OgreSceneNode.h>
|
---|
[1320] | 14 | #include "OgreBvhRenderable.h"
|
---|
[1317] | 15 |
|
---|
| 16 | namespace Ogre
|
---|
| 17 | {
|
---|
| 18 |
|
---|
[1320] | 19 | class BvHierarchySceneNode : public SceneNode, public BvhRenderable
|
---|
[1317] | 20 | {
|
---|
| 21 | public:
|
---|
[1320] | 22 | BvHierarchySceneNode(SceneManager *creator):
|
---|
[1317] | 23 | SceneNode(creator) {};
|
---|
| 24 |
|
---|
[2292] | 25 | BvHierarchySceneNode(SceneManager *creator, const String& name):
|
---|
[1317] | 26 | SceneNode(creator, name) {};
|
---|
| 27 |
|
---|
[2292] | 28 | ~BvHierarchySceneNode() {};
|
---|
[1317] | 29 |
|
---|
[2292] | 30 | // gather info for kd-tree creation
|
---|
| 31 | virtual void computeScene(BvhPlaneEventList& events, AxisAlignedBox& aabb,
|
---|
| 32 | int& nObjects,
|
---|
| 33 | bool includeChildren = true);
|
---|
[1317] | 34 |
|
---|
[2292] | 35 | // add all contained objects to render queue
|
---|
| 36 | virtual void queueObjects(Camera* cam, RenderQueue* queue, bool onlyShadowCasters);
|
---|
[1317] | 37 |
|
---|
[2292] | 38 | // place all entities in geometry queue (for CHC)
|
---|
| 39 | virtual void getGeometryList(GeometryVector *geometryList);
|
---|
[1317] | 40 |
|
---|
[2292] | 41 | // return a bounding box enclosing all objects
|
---|
| 42 | virtual AxisAlignedBox getBoundingBox(void) const;
|
---|
[1317] | 43 |
|
---|
[2292] | 44 | // DEBUG
|
---|
| 45 | String dumpToString(void);
|
---|
| 46 |
|
---|
[1317] | 47 | protected:
|
---|
| 48 | virtual void _updateBounds(void);
|
---|
| 49 |
|
---|
| 50 | typedef std::set<String> StringSet;
|
---|
| 51 |
|
---|
| 52 | static StringSet& getExcludedMovables(void);
|
---|
| 53 | };
|
---|
| 54 |
|
---|
| 55 | } // namespace Ogre
|
---|
| 56 |
|
---|
[1318] | 57 | #endif // _OgreBvHierarchySceneNode_H__
|
---|