source: GTP/trunk/Lib/Vis/OnlineCullingCHC/include/CoherentHierarchicalCullingManager2.h @ 2455

Revision 2455, 1.7 KB checked in by mattausch, 17 years ago (diff)
RevLine 
[2360]1#ifndef _CoherentHierarchicalCullingManager2_H__
2#define _CoherentHierarchicalCullingManager2_H__
3
4#include "CullingManager.h"
5#include "HierarchyInterface.h"
6
7
8namespace GtpVisibility
9{
10
[2455]11/** Renders the scene with the coherent hierarchical culling algorithm with
12        some additional features
[2360]13*/
[2455]14class CoherentHierarchicalCullingManager2: public CullingManager
[2360]15{
16public:
17        CoherentHierarchicalCullingManager2();
[2455]18
[2360]19        /** Constructor taking the assumed visibility into account, i.e., the estimation
20                for how many frames the current visibility is considered to be valid
21        */
22        CoherentHierarchicalCullingManager2(const unsigned int assumedVisibility);
23
[2455]24        /** The main render routine.
25        */
[2360]26        void RenderScene();
[2455]27
[2360]28        /** Sets assumed visibility (i.e., an estimation for
29                how many frames the visibility is considered to be valid).
30                @param assumedVisibility indicates for how many frames the
31                same visibility is be assumed.
32                if 0, the visibility is tested deterministically for each frame.
33        */
34        void SetAssumedVisibility(const unsigned int assumedVisibility);
35
36protected:
[2455]37
[2360]38        /** Decides if node is considered to be visible depeding on the
39                assumed visibility factor.
40                @returns if node is considered to be visible
41        */
42        bool DecideVisible(HierarchyNode *node) const;
43
44        /** Skip query for this node.
45        */
46        void SkipQuery(HierarchyNode *node) const;
47
48        /** number of steps the visibility is assumed to be valid.
49        */
50        unsigned int mAssumedVisibility;
51
52        /** Threshold for rand function to return positive result with respect to
53                mAssumedVisibility.
54        */
55        int mThreshold;
56};
57
58} // namespace GtpVisibility
59
60#endif // CoherentHierarchicalCullingManager2_H
Note: See TracBrowser for help on using the repository browser.