00001 /* 00002 * PROPRIETARY INFORMATION. This software is proprietary to 00003 * Side Effects Software Inc., and is not to be reproduced, 00004 * transmitted, or disclosed in any way without written permission. 00005 * 00006 * Produced by: 00007 * Jeff Lait 00008 * Side Effects Software Inc 00009 * 123 Front Street West, Suite 1401 00010 * Toronto, Ontario 00011 * Canada M5J 2M2 00012 * 416-504-9876 00013 */ 00014 00015 #ifndef __GU_OBBTree_h__ 00016 #define __GU_OBBTree_h__ 00017 00018 #include "GU_API.h" 00019 #include <BV/BV_OBBTree.h> 00020 00021 class GU_Detail; 00022 class UT_DMatrix4; 00023 00024 /// This is a simple extension to BV_OBBTree that includes debug output 00025 /// capability. 00026 class GU_API GU_OBBTree : public BV_OBBTree 00027 { 00028 public: 00029 typedef BV_OBBTree BaseClass; 00030 00031 GU_OBBTree(); 00032 GU_OBBTree(const GU_OBBTree &); 00033 00034 GU_OBBTree &operator=(const GU_OBBTree &); 00035 00036 /// Create a GU_Detail showing the OBBs at each level of the 00037 /// hierarchy. 00038 /// 00039 /// If the depth parameter is non-negative, then only leaves 00040 /// at the given depth level are included. 00041 /// If the onlyLeaf parameter is non-negative, then only boxes containing 00042 /// that primitive are included. 00043 void createDebugTree(GU_Detail &gdp, 00044 int depth = -1, 00045 int prim = -1) const; 00046 private: 00047 bool outputTree(GU_Detail &gdp, const BV_OBB &node, 00048 const UT_Matrix3 &R, const UT_Vector3 &T, 00049 int onlyDepth, int onlyLeaf, int depth) const; 00050 }; 00051 00052 #endif 00053
1.5.9