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 |
|
---|
10 | #ifndef _OgreBvHierarchySceneNode_H__
|
---|
11 | #define _OgreBvHierarchySceneNode_H__
|
---|
12 |
|
---|
13 | #include <OgreSceneNode.h>
|
---|
14 | #include "OgreBvhRenderable.h"
|
---|
15 |
|
---|
16 | namespace Ogre
|
---|
17 | {
|
---|
18 |
|
---|
19 | class BvHierarchySceneNode : public SceneNode, public BvhRenderable
|
---|
20 | {
|
---|
21 | public:
|
---|
22 | BvHierarchySceneNode(SceneManager *creator):
|
---|
23 | SceneNode(creator) {};
|
---|
24 |
|
---|
25 | BvHierarchySceneNode(SceneManager *creator, const String& name):
|
---|
26 | SceneNode(creator, name) {};
|
---|
27 |
|
---|
28 | ~BvHierarchySceneNode() {};
|
---|
29 |
|
---|
30 | // gather info for kd-tree creation
|
---|
31 | virtual void computeScene(BvhPlaneEventList& events, AxisAlignedBox& aabb,
|
---|
32 | int& nObjects,
|
---|
33 | bool includeChildren = true);
|
---|
34 |
|
---|
35 | // add all contained objects to render queue
|
---|
36 | virtual void queueObjects(Camera* cam, RenderQueue* queue, bool onlyShadowCasters);
|
---|
37 |
|
---|
38 | // place all entities in geometry queue (for CHC)
|
---|
39 | virtual void getGeometryList(GeometryVector *geometryList);
|
---|
40 |
|
---|
41 | // return a bounding box enclosing all objects
|
---|
42 | virtual AxisAlignedBox getBoundingBox(void) const;
|
---|
43 |
|
---|
44 | // DEBUG
|
---|
45 | String dumpToString(void);
|
---|
46 |
|
---|
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 |
|
---|
57 | #endif // _OgreBvHierarchySceneNode_H__
|
---|