- Timestamp:
- 09/01/06 13:48:15 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/OnlineCullingCHC/OGRE/src/OgreKdTree.cpp
r1296 r1312 877 877 unsigned long t1, t2, t3, t4; 878 878 879 m Stats.clear();879 mTreeStats.clear(); 880 880 881 881 // data we want to collect … … 890 890 t3 = timer->getMicroseconds(); // DEBUG 891 891 892 m Stats.mNumSceneNodes = nObjects;892 mTreeStats.mNumSceneNodes = nObjects; 893 893 894 894 assert(! aabb.isNull() && "Teh stubid worldAABB iz NULL ... waht now?"); … … 924 924 mBuildLog->logMessage("Total time: " + StringConverter::toString(t4 - t1) + "µs"); 925 925 mBuildLog->logMessage("Tree Depth: " + StringConverter::toString(mMaxDepth)); 926 mBuildLog->logMessage("Number of Objects: " + StringConverter::toString(m Stats.mNumSceneNodes));927 mBuildLog->logMessage("Number of Leaves: " + StringConverter::toString(m Stats.mNumLeaves));928 mBuildLog->logMessage("Number of Nodes: " + StringConverter::toString(m Stats.mNumNodes));926 mBuildLog->logMessage("Number of Objects: " + StringConverter::toString(mTreeStats.mNumSceneNodes)); 927 mBuildLog->logMessage("Number of Leaves: " + StringConverter::toString(mTreeStats.mNumLeaves)); 928 mBuildLog->logMessage("Number of Nodes: " + StringConverter::toString(mTreeStats.mNumNodes)); 929 929 mBuildLog->logMessage("Total cost: " + StringConverter::toString(calcCost())); 930 930 mBuildLog->logMessage("################################"); … … 1044 1044 } 1045 1045 // update stats 1046 ++ m Stats.mNumNodes;1047 ++ m Stats.mNumLeaves;1046 ++ mTreeStats.mNumNodes; 1047 ++ mTreeStats.mNumLeaves; 1048 1048 // update bounding box 1049 1049 leaf->_updateBounds(false); … … 1128 1128 1129 1129 // update stats 1130 ++ m Stats.mNumNodes;1130 ++ mTreeStats.mNumNodes; 1131 1131 1132 1132 // update bounding box … … 1196 1196 topNode = leaf; 1197 1197 // update stats 1198 ++ m Stats.mNumNodes;1199 ++ m Stats.mNumLeaves;1198 ++ mTreeStats.mNumNodes; 1199 ++ mTreeStats.mNumLeaves; 1200 1200 } 1201 1201 … … 1310 1310 1311 1311 // update stats 1312 ++ m Stats.mNumNodes;1312 ++ mTreeStats.mNumNodes; 1313 1313 } 1314 1314 … … 1399 1399 bool showBoxes, KdTree::NodeList& visibleNodes) 1400 1400 { 1401 // debug1402 //cam->mNumVisQueries = 0;1401 mFrameStats.clear(); 1402 cam->mNumVisQueries = 0; 1403 1403 1404 1404 if (mKdRoot) … … 1406 1406 cam, queue, onlyShadowCasters, showBoxes, visibleNodes); 1407 1407 1408 //mBuildLog->logMessage("Frame # " + StringConverter::toString(Root::getSingleton().getCurrentFrameNumber()) + 1409 // " ," + StringConverter::toString(cam->mNumVisQueries) + " vis queries"); 1408 mFrameStats.mTraversedNodes = cam->mNumVisQueries; 1410 1409 } 1411 1410 … … 1420 1419 if (fullVis || 1421 1420 ((vis = (cam->*getVisibility)(node->mAABB)) != KdTreeCamera::KDNV_NONE)) 1422 //((vis = (cam->*getVisibility)(node->mAABB)) != KdTreeCamera::KDNV_NONE))1423 1421 { 1424 1422 visibleNodes.push_back(node); 1425 1423 1426 1424 bool v = (fullVis || vis == KdTreeCamera::KDNV_FULL); 1425 1427 1426 node->queueVisibleObjects(currentFrame, cam, queue, onlyShadowCasters, showBoxes, v); 1427 1428 if (v || node->isLeaf()) 1429 ++ mFrameStats.mRenderedNodes; 1428 1430 1429 1431 if (!v) … … 1437 1439 cam, queue, onlyShadowCasters, showBoxes, visibleNodes, v); 1438 1440 } 1441 } 1442 else 1443 { 1444 ++ mFrameStats.mFrustumCulledNodes; 1439 1445 } 1440 1446 }
Note: See TracChangeset
for help on using the changeset viewer.