source: trunk/VUT/Ogre/include/OgreBspHierarchyInterface.h @ 345

Revision 345, 1.6 KB checked in by mattausch, 19 years ago (diff)

fixed bug in chc when traversing node two times because of priority queue. left debug info in there

Line 
1#ifndef _BspHierarchyInterface_H__
2#define _BspHierarchyInterface_H__
3
4#include "OgrePlatformHierarchyInterface.h"
5
6namespace Ogre {
7/**
8        This class implements the hierarchy interface for the Ogre bsp hierarchy.
9*/
10class BspHierarchyInterface : public PlatformHierarchyInterface
11{
12public:
13        BspHierarchyInterface(SceneManager *sm, RenderSystem *rsys);
14
15        /** Gets the given option for the scene traverser.
16            @remarks
17                See setOption
18        */
19        //bool getOption( const String &, void * );
20        //bool getOptionKeys( StringVector &refKeys );
21        void PullUpVisibility(GtpVisibility::HierarchyNode *node) const;
22        /** Traverses given node.
23                @param node current node
24                @remark pushes children on the distance queue
25        */
26        void TraverseNode(GtpVisibility::HierarchyNode *node);
27        void RenderNode(GtpVisibility::HierarchyNode *node);
28        bool IsLeaf(GtpVisibility::HierarchyNode *node) const;
29        bool HasGeometry(GtpVisibility::HierarchyNode *node) const;
30        float GetSquaredDistance(GtpVisibility::HierarchyNode *node) const;
31       
32        void SetNodeVisible(GtpVisibility::HierarchyNode *node, const bool visible) const;
33        void SetLastVisited(GtpVisibility::HierarchyNode *node,
34                                                const unsigned int frameId) const;
35
36        bool IsNodeVisible(GtpVisibility::HierarchyNode *node) const;
37        unsigned int LastVisited(GtpVisibility::HierarchyNode *node) const;
38
39protected:
40        /** Returns pointer to the bounding box of the node.
41                @param node current hierarchy node
42                @returns bounding box of current node
43        */
44        AxisAlignedBox *GetBoundingBox(GtpVisibility::HierarchyNode *node);
45};
46} // namespace Ogre
47
48#endif // BspHierarchyInterface_H
Note: See TracBrowser for help on using the repository browser.