Changeset 2228 for GTP/trunk/Lib/Vis/Preprocessing/src/HierarchyManager.cpp
- Timestamp:
- 03/11/07 16:14:59 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/Preprocessing/src/HierarchyManager.cpp
r2227 r2228 105 105 Environment::GetSingleton()->GetFloatValue( 106 106 "Hierarchy.Termination.minGlobalCostRatio", mTermMinGlobalCostRatio); 107 108 Environment::GetSingleton()->GetFloatValue("Hierarchy.minRenderCost", mMinRenderCost); 109 107 110 Environment::GetSingleton()->GetIntValue( 108 111 "Hierarchy.Termination.globalCostMissTolerance", mTermGlobalCostMissTolerance); … … 179 182 Debug << "max avg rays per object: " << mMaxAvgRaysPerObject << endl; 180 183 Debug << "mín avg rays per object: " << mMinAvgRaysPerObject << endl; 184 Debug << "mín render cost: " << mMinRenderCost << endl; 181 185 182 186 // for comparing it with byte - value … … 833 837 const float avgRaysPerObjects) const 834 838 { 839 // don't correct pvss 840 if (mMaxAvgRaysPerObject <= mMinAvgRaysPerObject) 841 { 842 return childPvs; 843 } 844 835 845 // assume pvs sampled sufficiently => take child pvs 836 846 if (avgRaysPerObjects > mMaxAvgRaysPerObject) … … 838 848 return childPvs; 839 849 } 840 // assume pvs not sampled sufficiently => take total pvs 841 else if (avgRaysPerObjects <= mMinAvgRaysPerObject) 842 { 843 cout << "b ";// << avgRaysPerObjects << " "; 850 851 // assume pvs not sampled sufficiently => pvs equal to parent pvs 852 // we should not subdivide further from this point 853 if (avgRaysPerObjects <= mMinAvgRaysPerObject) 854 { 855 cout << "t ";// << avgRaysPerObjects << " "; 844 856 return totalPvs; 845 857 } 858 859 /////////// 860 //-- blend pvss 846 861 847 862 const float alpha = (mMaxAvgRaysPerObject - avgRaysPerObjects) / … … 857 872 const float newPvs = alpha * childPvs + (1.0f - alpha) * totalPvs; 858 873 #endif 859 cout << " c";// << avgRaysPerObjects << " ";874 cout << "b ";// << avgRaysPerObjects << " "; 860 875 //cout << "alpha " << alpha << " beta: " << beta << " child: " << childPvs << " parent: " << totalPvs << endl; 861 876 … … 927 942 928 943 mPriority = sc->GetPriority(); 944 945 cout << sc->Type() << " "; 929 946 930 947 ////////// … … 1160 1177 { 1161 1178 //sc->CollectDirtyCandidates(dirtyCandidates, true); 1162 //if (steps % 10 == 0) 1163 cout << sc->Type() << " "; 1179 //if (steps % 10 == 0) cout << sc->Type() << " "; 1164 1180 1165 1181 ++ steps;
Note: See TracChangeset
for help on using the changeset viewer.