Changeset 2227 for GTP/trunk/Lib
- Timestamp:
- 03/11/07 02:17:58 (18 years ago)
- Location:
- GTP/trunk/Lib/Vis/Preprocessing
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/Preprocessing/scripts/preprocess_visibility_internal.sh
r2211 r2227 14 14 15 15 NUM_SAMPLE_RAYS=200000000 16 #NUM_SAMPLE_RAYS=5000000016 NUM_SAMPLE_RAYS=50000000 17 17 18 18 $PREPROCESSOR -total_samples=$NUM_SAMPLE_RAYS \ -
GTP/trunk/Lib/Vis/Preprocessing/src/BvHierarchy.cpp
r2224 r2227 634 634 635 635 636 static float AvgRaysPerObject(const int pvs, const int nRays) 637 { 638 return (float)nRays / ((float)pvs + Limits::Small); 639 } 640 641 636 642 void BvHierarchy::EvalSubdivisionCandidate(BvhSubdivisionCandidate &splitCandidate, 637 643 const bool computeSplitPlane, … … 689 695 // avg contribution of a ray to a pvs 690 696 const float pvs = (float)CountViewCells(*tData.mSampledObjects); 691 const float avgRayContri = AvgRayContribution((int)pvs, tData.mNumRays); 697 //const float avgRayContri = AvgRayContribution((int)pvs, tData.mNumRays); 698 const float avgRaysPerObject = AvgRaysPerObject((int)pvs, tData.mNumRays); 692 699 693 700 // high avg ray contri, the result is influenced by undersampling 694 splitCandidate.SetAvgRay Contribution(avgRayContri);701 splitCandidate.SetAvgRaysPerObject(avgRaysPerObject); 695 702 const float viewSpaceVol = GetViewSpaceVolume(); 696 703 … … 699 706 const float parentVol = tData.mCorrectedVolume * oldRatio; 700 707 708 //cout << "h " << avgRaysPerObject << " "; 701 709 // this leaf is a pvs entry in all the view cells 702 710 // that see one of the objects. … … 708 716 709 717 splitCandidate.mCorrectedFrontVolume = 710 mHierarchyManager->EvalCorrectedPvs(splitCandidate.mVolumeFrontViewCells, parentVol, avgRay Contri);718 mHierarchyManager->EvalCorrectedPvs(splitCandidate.mVolumeFrontViewCells, parentVol, avgRaysPerObject); 711 719 712 720 splitCandidate.mCorrectedBackVolume = 713 mHierarchyManager->EvalCorrectedPvs(splitCandidate.mVolumeBackViewCells, parentVol, avgRay Contri);721 mHierarchyManager->EvalCorrectedPvs(splitCandidate.mVolumeBackViewCells, parentVol, avgRaysPerObject); 714 722 715 723 const float relfrontCost = splitCandidate.mCorrectedFrontVolume * … … 727 735 // increase in pvs entries 728 736 const int pvsEntriesIncr = EvalPvsEntriesIncr(splitCandidate, 729 avgRay Contri,737 avgRaysPerObject, 730 738 (int)pvs, 731 739 splitCandidate.mNumFrontViewCells, … … 737 745 { 738 746 cout << "bvh volume cost" 739 << " avg ray contri: " << avgRayContri<< " ratio: " << oldRatio747 << " avg rays per object: " << avgRaysPerObject << " ratio: " << oldRatio 740 748 << " parent: " << parentVol << " old vol: " << oldVolume 741 749 << " frontvol: " << splitCandidate.mVolumeFrontViewCells << " corr. " << splitCandidate.mCorrectedFrontVolume … … 766 774 767 775 int BvHierarchy::EvalPvsEntriesIncr(BvhSubdivisionCandidate &splitCandidate, 768 const float avgRay Contri,776 const float avgRaysPerObjects, 769 777 const int numParentViewCells, 770 778 const int numFrontViewCells, … … 780 788 781 789 splitCandidate.mCorrectedFrontPvs = 782 mHierarchyManager->EvalCorrectedPvs((float)frontViewCells, parentPvs, avgRay Contri);790 mHierarchyManager->EvalCorrectedPvs((float)frontViewCells, parentPvs, avgRaysPerObjects); 783 791 splitCandidate.mCorrectedBackPvs = 784 mHierarchyManager->EvalCorrectedPvs((float)backViewCells, parentPvs, avgRay Contri);792 mHierarchyManager->EvalCorrectedPvs((float)backViewCells, parentPvs, avgRaysPerObjects); 785 793 786 794 if (0) 787 795 cout << "bvh pvs" 788 << " avg ray contri: " << avgRay Contri<< " ratio: " << oldPvsRatio796 << " avg ray contri: " << avgRaysPerObjects << " ratio: " << oldPvsRatio 789 797 << " parent: " << parentPvs << " " << " old vol: " << oldPvsSize 790 798 << " frontpvs: " << frontViewCells << " corr. " << splitCandidate.mCorrectedFrontPvs … … 1014 1022 #endif 1015 1023 1016 #if 11017 1024 1018 1025 float BvHierarchy::EvalSah(const BvhTraversalData &tData, … … 1111 1118 ar = rbox.SurfaceArea(); 1112 1119 1120 #if BOUND_RENDERCOST 1113 1121 const float sum = noValidSplit ? 1e25f : objectsLeft * al + objectsRight * ar; 1114 1122 #else 1123 const float rcLeft = std::max(objectsLeft, MIN_RENDERCOST); 1124 const float rcRight = std::max(objectsRight, MIN_RENDERCOST); 1125 1126 const float sum = noValidSplit ? 1e25f : objectsLeft * al + objectsRight * ar; 1127 1128 #endif 1115 1129 /*cout << "pos=" << (*cit).mPos << "\t q=(" << objectsLeft << "," << objectsRight <<")\t r=(" 1116 1130 << lbox.SurfaceArea() << "," << rbox.SurfaceArea() << ")" << endl; … … 1153 1167 } 1154 1168 1155 #else 1156 1157 float BvHierarchy::EvalSah (const BvhTraversalData &tData,1158 1159 1160 1169 1170 1171 float BvHierarchy::EvalSahWithTigherBbox(const BvhTraversalData &tData, 1172 const int axis, 1173 ObjectContainer &objectsFront, 1174 ObjectContainer &objectsBack) 1161 1175 { 1162 1176 // go through the lists, count the number of objects left and right … … 1294 1308 } 1295 1309 1296 #endif1297 1310 1298 1311 static bool PrepareOutput(const int axis, … … 1423 1436 const bool noValidSplit = (nObjectsRight <= Limits::Small); 1424 1437 1438 #if BOUND_RENDERCOST 1425 1439 // the heuristics 1426 1440 const float sum = noValidSplit ? 1427 1441 1e25f : volLeft * (float)nObjectsLeft + volRight * (float)nObjectsRight; 1428 1442 #else 1443 const float rcLeft = max(nObjectsLeft, MIN_RENDERCOST); 1444 const float rcRight = max(nObjectsRight, MIN_RENDERCOST); 1445 1446 // the heuristics 1447 const float sum = noValidSplit ? 1448 1e25f : volLeft * (float)rcLeft + volRight * (float)rcRight; 1449 1450 #endif 1451 1429 1452 #ifdef GTP_DEBUG 1430 1453 if (printStats) … … 1842 1865 float BvHierarchy::EvalAbsCost(const ObjectContainer &objects) 1843 1866 { 1867 float result; 1844 1868 #if USE_BETTER_RENDERCOST_EST 1845 1869 ObjectContainer::const_iterator oit, oit_end = objects.end(); … … 1847 1871 for (oit = objects.begin(); oit != oit_end; ++ oit) 1848 1872 { 1849 objRenderCost += ViewCellsManager::GetRendercost(*oit);1873 result += ViewCellsManager::GetRendercost(*oit); 1850 1874 } 1851 1875 #else 1852 re turn(float)objects.size();1876 result = (float)objects.size(); 1853 1877 #endif 1878 1879 #if BOUND_RENDERCOST 1880 result = max(result, MIN_RENDERCOST); 1881 #endif 1882 1883 return result; 1854 1884 } 1855 1885 … … 1875 1905 /////////////// 1876 1906 //-- render cost heuristics 1907 1877 1908 const float objRenderCost = EvalAbsCost(objects); 1878 1909 -
GTP/trunk/Lib/Vis/Preprocessing/src/BvHierarchy.h
r2224 r2227 14 14 #include "IntersectableWrapper.h" 15 15 #include "HierarchyManager.h" 16 #include " PerfTimer.h"16 #include "Timer/PerfTimer.h" 17 17 18 18 … … 736 736 ObjectContainer &objectsBack); 737 737 738 float EvalSahWithTigherBbox(const BvhTraversalData &tData, 739 const int axis, 740 ObjectContainer &objectsFront, 741 ObjectContainer &objectsBack); 738 742 739 743 /** Evaluates render cost of the bv induced by these objects … … 910 914 */ 911 915 int EvalPvsEntriesIncr(BvhSubdivisionCandidate &splitCandidate, 912 const float avgRayContri,916 const float raysPerObjects, 913 917 const int numParentViewCells, 914 918 const int numFrontViewCells, -
GTP/trunk/Lib/Vis/Preprocessing/src/Environment.cpp
r2130 r2227 2775 2775 "true"); 2776 2776 2777 RegisterOption("Hierarchy.Construction.maxAvgRay Contri",2778 optFloat, 2779 "hierarchy_construction_max_avg_ray contri=",2780 " 99999.0");2781 2782 RegisterOption("Hierarchy.Construction.minAvgRay Contri",2783 optFloat, 2784 "hierarchy_construction_min_avg_ray contri=",2785 " 99990.0");2777 RegisterOption("Hierarchy.Construction.maxAvgRaysPerObject", 2778 optFloat, 2779 "hierarchy_construction_max_avg_rays_per_object=", 2780 "2"); 2781 2782 RegisterOption("Hierarchy.Construction.minAvgRaysPerObject", 2783 optFloat, 2784 "hierarchy_construction_min_avg_rays_per_object=", 2785 "1"); 2786 2786 2787 2787 RegisterOption("Hierarchy.useTraversalTree", -
GTP/trunk/Lib/Vis/Preprocessing/src/Halton.cpp
r2105 r2227 1 1 #include "Halton.h" 2 #include "PerfTimer.h" 2 #include "Timer/PerfTimer.h" 3 3 4 4 5 #define PREGENERATE_HALTON 0 -
GTP/trunk/Lib/Vis/Preprocessing/src/HierarchyManager.cpp
r2224 r2227 155 155 156 156 Environment::GetSingleton()->GetFloatValue( 157 "Hierarchy.Construction.maxAvgRay Contri", mMaxAvgRayContri);157 "Hierarchy.Construction.maxAvgRaysPerObject", mMaxAvgRaysPerObject); 158 158 159 159 Environment::GetSingleton()->GetFloatValue( 160 "Hierarchy.Construction.minAvgRay Contri", mMinAvgRayContri);160 "Hierarchy.Construction.minAvgRaysPerObject", mMinAvgRaysPerObject); 161 161 162 162 Environment::GetSingleton()->GetBoolValue( … … 177 177 Debug << "max steps of same kind: " << mMaxStepsOfSameType << endl; 178 178 Debug << "max repairs: " << mMaxRepairs << endl; 179 Debug << "max avg ray contribution: " << mMaxAvgRayContri << endl; 179 Debug << "max avg rays per object: " << mMaxAvgRaysPerObject << endl; 180 Debug << "mín avg rays per object: " << mMinAvgRaysPerObject << endl; 180 181 181 182 // for comparing it with byte - value … … 830 831 float HierarchyManager::EvalCorrectedPvs(const float childPvs, 831 832 const float totalPvs, 832 const float avgRay Contri) const833 const float avgRaysPerObjects) const 833 834 { 834 835 // assume pvs sampled sufficiently => take child pvs 835 if (avgRay Contri < mMinAvgRayContri)836 if (avgRaysPerObjects > mMaxAvgRaysPerObject) 836 837 { 837 838 return childPvs; 838 839 } 839 840 840 // assume pvs not sampled sufficiently => take total pvs 841 if (avgRayContri >= mMaxAvgRayContri) 842 { 841 else if (avgRaysPerObjects <= mMinAvgRaysPerObject) 842 { 843 cout << "b ";// << avgRaysPerObjects << " "; 843 844 return totalPvs; 844 845 } 845 846 846 const float alpha = (mMaxAvgRayContri - avgRayContri) / 847 (mMaxAvgRayContri - mMinAvgRayContri); 848 849 const float beta = (1.0f - alpha) * (totalPvs - childPvs); 847 const float alpha = (mMaxAvgRaysPerObject - avgRaysPerObjects) / 848 (mMaxAvgRaysPerObject - mMinAvgRaysPerObject); 849 850 /// rays per object == max threshold => alpha == 0 => newPvs is childPvs 851 /// rays per object == min threshold => alpha == 1 => newPvs is totalPvs 852 853 const float beta = alpha * (totalPvs - childPvs); 850 854 #if 1 851 855 const float newPvs = childPvs + beta; … … 853 857 const float newPvs = alpha * childPvs + (1.0f - alpha) * totalPvs; 854 858 #endif 855 cout <<"a";859 cout << "c ";// << avgRaysPerObjects << " "; 856 860 //cout << "alpha " << alpha << " beta: " << beta << " child: " << childPvs << " parent: " << totalPvs << endl; 857 861 858 862 if ((newPvs < childPvs - Limits::Small) || (newPvs > totalPvs + Limits::Small)) 859 cout << "Error!! " << newPvs << endl; 863 cout << "Error! " << newPvs << " smaller than child pvs or larger than parent pvs" << endl; 864 860 865 return newPvs; 861 866 } … … 892 897 } 893 898 894 cout << sc->Type() << " ";895 896 899 ///////////// 897 900 // update stats … … 907 910 float mem = (float)ObjectPvs::GetEntrySizeByte() * pvsEntriesIncr; 908 911 912 #if USE_AVGRAYCONTRI 909 913 // high avg ray contri, the result is influenced by undersampling 910 914 // => decrease priority 911 if (0 && USE_AVGRAYCONTRI && (sc->GetAvgRayContribution() > mMaxAvgRayContri)) 915 916 if (sc->GetAvgRayContribution() > mMaxAvgRayContri) 912 917 { 913 918 const float factor = 1.0f + sc->GetAvgRayContribution() - mMaxAvgRayContri; … … 916 921 mem *= factor; 917 922 } 918 923 #endif 924 919 925 mHierarchyStats.mMemory += mem; 920 926 mHierarchyStats.mRenderCostDecrease = sc->GetRenderCostDecrease(); … … 1148 1154 1149 1155 SubdivisionCandidate *sc = NextSubdivisionCandidate(splitQueue); 1156 1157 const bool success = ApplySubdivisionCandidate(sc, splitQueue, dirtyCandidates); 1158 1159 if (success) 1160 { 1161 //sc->CollectDirtyCandidates(dirtyCandidates, true); 1162 //if (steps % 10 == 0) 1163 cout << sc->Type() << " "; 1150 1164 1151 const bool success = ApplySubdivisionCandidate(sc, splitQueue, dirtyCandidates);1152 1153 if (success)1154 {1155 //sc->CollectDirtyCandidates(dirtyCandidates, true);1156 1165 ++ steps; 1157 1166 } … … 1490 1499 SubdivisionCandidateContainer::const_iterator sit, sit_end = dirtyList.end(); 1491 1500 1492 for (sit = dirtyList.begin(); sit != sit_end; ++ sit) 1501 int i = 0; 1502 for (sit = dirtyList.begin(); sit != sit_end; ++ sit, ++ i) 1493 1503 { 1494 1504 // only repair a certain number of candidates … … 1507 1517 1508 1518 ++ repaired; 1509 cout << "."; 1519 //if (i % 10 == 0) 1520 cout << "."; 1510 1521 1511 1522 #ifdef GTP_DEBUG … … 2360 2371 { 2361 2372 ++ subStats.mViewSpaceSplits; 2362 cout << "v";2373 //cout << "v"; 2363 2374 //cout << "vsp t: " << timeStamp << " rc: " << rcDecr << " pvs: " << entriesIncr << endl; 2364 2375 } … … 2366 2377 { 2367 2378 ++ subStats.mObjectSpaceSplits; 2368 cout << "o";2379 //cout << "o"; 2369 2380 //"osp t: " << timeStamp << " rc: " << rcDecr << " pvs: " << entriesIncr << endl; 2370 2381 } -
GTP/trunk/Lib/Vis/Preprocessing/src/HierarchyManager.h
r2224 r2227 47 47 48 48 #define COUNT_ORIGIN_OBJECTS 1 49 #define USE_AVGRAYCONTRI 1 49 #define USE_AVGRAYCONTRI 0 50 51 #define BOUND_RENDERCOST 0 52 53 static const float MIN_RENDERCOST = 100.0f; 54 50 55 51 56 … … 308 313 float EvalCorrectedPvs(const float pvsFront, 309 314 const float totalPvs, 310 const float avgRayContri) const;315 const float raysPerObjects) const; 311 316 312 317 … … 607 612 float mInitialRenderCost; 608 613 609 float mMaxAvgRayContri; 610 611 float mMinAvgRayContri; 614 //float mMaxAvgRayContri; 615 //float mMinAvgRayContri; 616 617 float mMaxAvgRaysPerObject; 618 float mMinAvgRaysPerObject; 612 619 613 620 // quick hack: -
GTP/trunk/Lib/Vis/Preprocessing/src/SamplingStrategy.cpp
r2210 r2227 7 7 #include "RssTree.h" 8 8 #include "Mutation.h" 9 #include " PerfTimer.h"9 #include "Timer/PerfTimer.h" 10 10 11 11 -
GTP/trunk/Lib/Vis/Preprocessing/src/SubdivisionCandidate.h
r2224 r2227 40 40 /** Evaluate this candidate and put results into queue for further traversal. 41 41 */ 42 virtual bool Apply(SplitQueue &splitQueue, bool terminationCriteriaMet, SubdivisionCandidateContainer &dirtyList) = 0; 42 virtual bool Apply(SplitQueue &splitQueue, 43 bool terminationCriteriaMet, 44 SubdivisionCandidateContainer &dirtyList) = 0; 43 45 44 46 /** Returns true of the global termination criteria of this split were met, … … 74 76 } 75 77 78 /** The average ray contribution of this candidate . 79 This is somewhat of a confidence value into the computed values. If 80 it is high, there is likely to be a lot of undersampling. 81 */ 82 inline void SetAvgRaysPerObject(const float raysPerObject) 83 { 84 mAvgRaysPerObject = raysPerObject; 85 86 } 76 87 inline float GetAvgRayContribution() const 77 88 { 78 89 return mAvgRayContribution; 90 } 91 92 /** Returns average rays per object. 93 */ 94 float GetAvgRaysPerObject() const 95 { 96 return (float)mAvgRaysPerObject; 79 97 } 80 98 … … 165 183 float mAvgRayContribution; 166 184 185 /// the average ray contribution of this candidate 186 float mAvgRaysPerObject; 187 167 188 int mMailbox; 168 189 -
GTP/trunk/Lib/Vis/Preprocessing/src/ViewCell.cpp
r2210 r2227 1766 1766 float ViewCellsTree::GetPvsCostForLeafStorage(ViewCell *vc) const 1767 1767 { 1768 // pvs is al ways stored directly inleaves1768 // pvs is already stored in the leaves 1769 1769 if (vc->IsLeaf()) 1770 1770 { … … 1772 1772 } 1773 1773 1774 ///////////////////////////////// 1775 1774 1776 // interior nodes: pvs is either stored as a 1775 1777 // scalar or has to be reconstructed from the leaves … … 1958 1960 //////////////////////////////////////////////// 1959 1961 //-- for interiors, pvs can be stored using different methods 1960 //1961 1962 1962 1963 switch (mViewCellsStorage) -
GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp
r2224 r2227 24 24 #include "SamplingStrategy.h" 25 25 #include "SceneGraph.h" 26 #include " PerfTimer.h"26 #include "Timer/PerfTimer.h" 27 27 28 28 … … 2517 2517 s<<"#AVG_REL_PVS_INCREASE\n"<<pvsStat.avgRelPvsIncrease<<endl; 2518 2518 s<<"#DEV_REL_PVS_INCREASE\n"<<pvsStat.devRelPvsIncrease<<endl; 2519 s<<"#MEM ROY\n"<<pvsStat.mem<<endl;2519 s<<"#MEMORY\n"<<pvsStat.mem<<endl; 2520 2520 2521 2521 s<<"#CONTRIBUTING_RAYS\n"<<mSamplesStat.mContributingRays<<endl; … … 6019 6019 6020 6020 ResetViewCells(); 6021 Debug << "\nView cells after construction:\n" << mCurrentViewCellsStats << endl;6021 //Debug << "\nView cells after construction:\n" << mCurrentViewCellsStats << endl; 6022 6022 6023 6023 ////////////// -
GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.h
r2224 r2227 127 127 128 128 float mem; 129 float renderCostRatio; 129 130 }; 130 131 -
GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsParserXerces.h
r2176 r2227 10 10 #include <hash_map> 11 11 12 #include " PerfTimer.h"12 #include "Timer/PerfTimer.h" 13 13 14 14 namespace GtpVisibilityPreprocessor { -
GTP/trunk/Lib/Vis/Preprocessing/src/VspTree.cpp
r2210 r2227 559 559 || (data.mPvs <= mTermMinPvs) 560 560 || (data.mProbability <= mTermMinProbability) 561 //|| (data.GetAvgRayContribution() > mTermMaxRayContribution)562 561 || (data.mDepth >= mTermMaxDepth) 563 562 ); … … 811 810 812 811 splitCandidate.SetAvgRayContribution(avgRayContri); 813 812 813 const float avgRaysPerObject = 814 (float)splitCandidate.mParentData.mRays->size() / ((float)pvs + Limits::Small); 815 816 splitCandidate.SetAvgRayContribution(avgRayContri); 817 splitCandidate.SetAvgRaysPerObject(avgRaysPerObject); 818 814 819 // compute global decrease in render cost 815 820 float oldRenderCost; … … 875 880 mHierarchyManager->EvalCorrectedPvs(fPvsSize, 876 881 correctedOldPvs, 877 splitCandidate.GetAvgRay Contribution());882 splitCandidate.GetAvgRaysPerObject()); 878 883 splitCandidate.mCorrectedBackPvs = 879 884 mHierarchyManager->EvalCorrectedPvs(bPvsSize, 880 885 correctedOldPvs, 881 splitCandidate.GetAvgRay Contribution());886 splitCandidate.GetAvgRaysPerObject()); 882 887 883 888 splitCandidate.mFrontPvs = fPvsSize; … … 1536 1541 1537 1542 const AxisAlignedPlane &candidatePlane = sc.mSplitPlane; 1538 const float avgRayContri = sc.GetAvgRayContribution(); 1543 //const float avgRayContri = sc.GetAvgRayContribution(); 1544 const float avgRaysPerObject = sc.GetAvgRaysPerObject(); 1539 1545 1540 1546 ////////////////////////////////////////////// … … 1563 1569 // and back pvs with respect to the classification 1564 1570 UpdateContributionsToPvs(*ray, true, cf, pvsFront, pvsBack, totalPvs); 1571 1565 1572 #if COUNT_ORIGIN_OBJECTS 1566 1573 UpdateContributionsToPvs(*ray, false, cf, pvsFront, pvsBack, totalPvs); … … 1585 1592 //-- evaluate render cost heuristics 1586 1593 1587 const float oldRenderCostRatio = (tData.mRenderCost > 0)? 1588 (totalPvs / tData.mRenderCost) : 1; 1594 const float oldRenderCostRatio = (tData.mRenderCost > 0)? (totalPvs / tData.mRenderCost) : 1; 1589 1595 1590 1596 const float penaltyOld = tData.mCorrectedRenderCost * oldRenderCostRatio; 1591 1597 1592 sc.mCorrectedFrontRenderCost = mHierarchyManager->EvalCorrectedPvs(pvsFront, penaltyOld, avgRay Contri);1593 sc.mCorrectedBackRenderCost = mHierarchyManager->EvalCorrectedPvs(pvsBack, penaltyOld, avgRay Contri);1598 sc.mCorrectedFrontRenderCost = mHierarchyManager->EvalCorrectedPvs(pvsFront, penaltyOld, avgRaysPerObject); 1599 sc.mCorrectedBackRenderCost = mHierarchyManager->EvalCorrectedPvs(pvsBack, penaltyOld, avgRaysPerObject); 1594 1600 1595 1601 sc.mFrontRenderCost = pvsFront; … … 1608 1614 if (0) 1609 1615 cout << "vsp render cost" 1610 << " avg ray contri: " << avgRayContri<< " ratio: " << oldRenderCostRatio1616 << " avg rays per object: " << avgRaysPerObject << " ratio: " << oldRenderCostRatio 1611 1617 << " parent: " << penaltyOld << " " << " old vol: " << totalPvs 1612 1618 << " front cost: " << sc.mCorrectedFrontRenderCost << " corr. " << sc.mCorrectedFrontRenderCost -
GTP/trunk/Lib/Vis/Preprocessing/src/VspTree.h
r2224 r2227 12 12 #include "SubdivisionCandidate.h" 13 13 #include "HierarchyManager.h" 14 #include " PerfTimer.h"14 #include "Timer/PerfTimer.h" 15 15 16 16 … … 393 393 394 394 395 /** Returns average rays per object. 396 */ 397 float GetAvgRaysPerObject() const 398 { 399 return (float)mRays->size() / ((float)mPvs + Limits::Small); 400 } 401 395 402 VspTraversalData(): 396 403 mNode(NULL),
Note: See TracChangeset
for help on using the changeset viewer.