- Timestamp:
- 06/20/05 08:13:57 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/VUT/work/ogre_changes/Plugins/OctreeSceneManager/src/OgreOctree.cpp
r135 r139 36 36 #include <OgreOctree.h> 37 37 #include <OgreOctreeNode.h> 38 #include <OgreLogManager.h> 38 39 39 40 namespace Ogre … … 109 110 mDepth = 0; 110 111 112 _updateBounds(); 111 113 #endif //GTP_VISIBILITY_MODIFIED_OGRE 112 114 mNumNodes = 0; … … 175 177 //mWireBoundingBox->setupBoundingBox(mBox); 176 178 mWireBoundingBox->setupBoundingBox(mWorldAABB); 179 177 180 return mWireBoundingBox; 178 181 } … … 229 232 // Reset bounds first 230 233 mWorldAABB.setNull(); 231 234 232 235 // Update bounds from own attached objects 233 236 NodeList::iterator it, it_end; … … 247 250 for (int k = 0; k < 2; ++k) 248 251 { 249 if (mChildren[i][j][k] != 0)252 if (mChildren[i][j][k]) 250 253 { 251 254 mWorldAABB.merge(mChildren[i][j][k]->_getWorldAABB()); … … 254 257 } 255 258 } 259 // HACK: clamp to bounds 260 AxisAlignedBox box; 261 _getCullBounds(&box); 262 mWorldAABB = mWorldAABB.intersection(box); 263 264 //std::stringstream d; d << "updating box: " << mWorldAABB << ", depth: " << mDepth << "null: " << mBox.isNull(); 265 //LogManager::getSingleton().logMessage(d.str()); 266 256 267 // recursively update parent bounds 257 268 if (mParent)
Note: See TracChangeset
for help on using the changeset viewer.