HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GU_KDOPTree.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  */
7 
8 #ifndef __GU_KDOPTree_h__
9 #define __GU_KDOPTree_h__
10 
11 #include "GU_API.h"
12 #include <BV/BV_KDOPTree.h>
13 
14 class GU_Detail;
15 
16 /// This is a simple extension to BV_KDOPTree that includes debug output
17 /// capability.
18 template <int K>
19 class GU_API GU_KDOPTree : public BV_KDOPTree<K>
20 {
21 public:
23 
24  GU_KDOPTree();
25  GU_KDOPTree(const GU_KDOPTree &);
26 
28 
29  /// Create a GU_Detail showing the KDOPs at each level of the
30  /// hierarchy.
31  ///
32  /// If the depth parameter is non-negative, then only leaves
33  /// at the given depth level are included.
34  /// If the onlyLeaf parameter is non-negative, then only boxes containing
35  /// that primitive are included.
36  void createDebugTree(GU_Detail &gdp,
37  int depth = -1,
38  int prim = -1) const;
39 private:
40  static bool outputTree(GU_Detail &gdp, const BV_KDOPNode<K> &node,
41  int onlyDepth, int onlyLeaf, int depth);
42  static void outputNode(GU_Detail &gdp, const BV_KDOPNode<K> &node);
43 };
44 
49 
50 #endif
GLint GLint GLsizei GLsizei GLsizei depth
Definition: glcorearb.h:475
#define GU_API
Definition: GU_API.h:11
GU_KDOPTree< 26 > GU_26DOPTree
Definition: GU_KDOPTree.h:48
BV_KDOPTree< K > BaseClass
Definition: GU_KDOPTree.h:22
GU_KDOPTree< 6 > GU_AABBTree
Definition: GU_KDOPTree.h:45
GU_KDOPTree< 18 > GU_18DOPTree
Definition: GU_KDOPTree.h:47
A single node of a BV_KDOPTree.
Definition: BV_KDOPTree.h:22
BV_KDOPTree & operator=(const BV_KDOPTree &)
GU_KDOPTree< 14 > GU_14DOPTree
Definition: GU_KDOPTree.h:46