Changeset 1286 for GTP/trunk/Lib/Vis/Preprocessing/src/BvHierarchy.cpp
- Timestamp:
- 08/25/06 18:25:09 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/Preprocessing/src/BvHierarchy.cpp
r1279 r1286 1454 1454 1455 1455 1456 void BvHierarchy::ExportObjects(BvhLeaf *leaf, OUT_STREAM &stream) 1457 { 1458 ObjectContainer::const_iterator oit, oit_end = leaf->mObjects.end(); 1459 for (oit = leaf->mObjects.begin(); oit != oit_end; ++ oit) 1460 { 1461 stream << (*oit)->GetId() << " "; 1462 } 1463 } 1464 1465 1456 1466 void BvHierarchy::ExportNode(BvhNode *node, OUT_STREAM &stream) 1457 1467 { … … 1460 1470 BvhLeaf *leaf = dynamic_cast<BvhLeaf *>(node); 1461 1471 1462 stream << "<Leaf "; 1463 stream << "objects=\""; 1472 stream << "<Leaf" 1473 << " min=\"" << leaf->GetBoundingBox().Min() 1474 << " max=\"" << leaf->GetBoundingBox().Max() 1475 << " objects=\""; 1464 1476 1465 //-- export objects in kd leaves1466 //if (mExportObjects)ExportObjects(leaf, stream);1477 //-- export objects 1478 ExportObjects(leaf, stream); 1467 1479 1468 1480 stream << "\" />" << endl; 1469 //stream << " </Leaf>" << endl;1470 1481 } 1471 1482 else … … 1473 1484 BvhInterior *interior = dynamic_cast<BvhInterior *>(node); 1474 1485 1475 stream << "<Interior box=\"" << interior->GetBoundingBox() << "\">" << endl; 1486 stream << "<Interior" 1487 << " min=\"" << interior->GetBoundingBox().Min() 1488 << " max=\"" << interior->GetBoundingBox().Max() 1489 << "\">" << endl; 1476 1490 1477 1491 ExportNode(interior->GetBack(), stream);
Note: See TracChangeset
for help on using the changeset viewer.