Changeset 3287 for GTP/trunk/App
- Timestamp:
- 01/19/09 20:49:54 (16 years ago)
- Location:
- GTP/trunk/App/Demos/Vis/FriendlyCulling
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/FriendlyCulling/default.env
r3286 r3287 17 17 filename=city 18 18 bvhname=city 19 useLODs= 119 useLODs=0 20 20 # shadow map size 21 21 shadowSize=4096 22 22 # the filenames given to recorded frames (+ number.bmp) 23 23 #recordedFramesSuffix=frames/vienna_frame 24 recordedFramesSuffix= frames_100_pgv/vienna_frame24 recordedFramesSuffix=vienna_frame 25 25 #recordedFramesSuffix=frames_50_spgvu/vienna_frame 26 26 # the filename for the statistics … … 49 49 50 50 #visibilitySolutionInitialState=50000000 51 visibilitySolutionInitialState=100000000 51 #visibilitySolutionInitialState=300000000 52 visibilitySolutionInitialState=500000000 52 53 53 54 … … 99 100 ## window options 100 101 101 winWidth=800102 winHeight=600102 #winWidth=800 103 #winHeight=600 103 104 104 #winWidth=1024105 #winHeight=768105 winWidth=1024 106 winHeight=768 106 107 107 108 useFullScreen=0 … … 127 128 # skylight turbitity 128 129 turbitity=3.0f 130 #turbitity=2.0f 129 131 #sky dome scale factor 130 132 -
GTP/trunk/App/Demos/Vis/FriendlyCulling/plot_friendly
r3276 r3287 7 7 COMMAND3=./ps_memory_plot3 8 8 9 PREFIX=pp_2 9 #PREFIX=pp_2 10 PREFIX=myvienna 10 11 11 12 #FILES="$PREFIX-vfc.log $PREFIX_chc.log $PREFIX-vfc_pvs.log $PREFIX-chc++_b20.log $PREFIX-chc++_pvs_b20.log" … … 14 15 #FILES="$PREFIX-chc++.log $PREFIX-chc++_b20.log" 15 16 #FILES="$PREFIX-chc.log $PREFIX-vfc_pvs.log $PREFIX-vfc_pvs_smaller.log $PREFIX-chc++.log $PREFIX-chc++_pvs.log $PREFIX-chc++_pvs_smaller.log" 16 FILES="$PREFIX-chc.log $PREFIX-vfc_pvs.log $PREFIX-chc++.log $PREFIX-chc++_pvs.log" 17 FILES="$PREFIX-vfc.log $PREFIX-vfc_pvs.log $PREFIX-chc++.log" 18 #FILES="$PREFIX-vfc.log $PREFIX-chc++.log $PREFIX-vfc_pvs.log" 17 19 18 20 echo $FILES -
GTP/trunk/App/Demos/Vis/FriendlyCulling/ps_memory_plot2
r3276 r3287 24 24 #echo set xrange \[4200:4600\] >> $FILE 25 25 #echo set xrange \[100:400\] >> $FILE 26 echo set xrange \[1:500\] >> $FILE 26 echo set xrange \[1600:2100\] >> $FILE 27 #echo set xrange \[3000:3500\] >> $FILE 27 28 #echo set xrange \[1600:2000\] >> $FILE 28 29 # echo set boxwidth 0.4 >> $FILE -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/DeferredRenderer.cpp
r3270 r3287 1358 1358 1359 1359 static char imageName[200]; 1360 sprintf(imageName, "%s_%05d. bmp", mSavedFrameSuffix.c_str(), mSavedFrameNumber);1360 sprintf(imageName, "%s_%05d.tga", mSavedFrameSuffix.c_str(), mSavedFrameNumber); 1361 1361 1362 1362 ILstring fileName = ILstring(imageName); -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/Pvs.h
r3285 r3287 11 11 class Bvh; 12 12 13 #define USE_TIMESTAMPS13 //#define USE_TIMESTAMPS 14 14 15 15 struct PvsEntry -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/SkyPreetham.cpp
r3279 r3287 296 296 ambient *= 1e-1f; 297 297 298 // could be too blueish ... 299 ambient.x *= 1.3f; 300 ambient.y *= 1.2f; 301 ambient.z = max(max(ambient.z, ambient.x), ambient.y); 302 298 303 // simulate the sun intensity by modulating the ambient term. 299 304 ambient *= (10.0f - 9.0f * DotProd(sunDir, Vector3::UNIT_Z())); -
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/chcdemo.cpp
r3286 r3287 386 386 void LoadPompeiiFloor(); 387 387 388 void LoadOrUpdatePVSs(const Vector3 &pos); 389 390 391 388 392 float pvsTotalSamples = .0f; 389 393 float pvsTotalTime = .0f; … … 1214 1218 SetupEyeView(); 1215 1219 1220 1216 1221 // set frame related parameters for GPU programs 1217 1222 GPUProgramParameters::InitFrame(camera, light); … … 1242 1247 glEnableClientState(GL_VERTEX_ARRAY); 1243 1248 1244 if (usePvs) 1245 { 1246 if (!viewCellsTree) 1247 { 1248 LoadVisibilitySolution(); 1249 applicationTimer.Start(); 1250 shotRays = visibilitySolutionInitialState; 1251 } 1252 1253 if (viewCellsTree) LoadPvs(); 1254 } 1249 if (usePvs) LoadOrUpdatePVSs(camera->GetPosition()); 1250 1255 1251 1256 1252 // render with the specified method (forward rendering, forward + depth, deferred) … … 1335 1331 //if (traverser->GetType() == RenderTraverser::CULL_COLLECTOR) 1336 1332 // ((PvsCollectionRenderer *)traverser)->SetViewCell(usePvs ? viewCell : NULL); 1333 1334 //renderState.LockCullFaceEnabled(true); 1337 1335 1338 1336 // actually render the scene geometry using the specified algorithm … … 1805 1803 1806 1804 // hack: load pvs on replay (remove later!) 1807 usePvs = true;1805 //usePvs = true; 1808 1806 } 1809 1807 else … … 2534 2532 renderState.SetUseAlphaToCoverage(false); 2535 2533 2534 const Vector3 lightPos = light->GetDirection() * -1e3f; 2535 if (usePvs) LoadOrUpdatePVSs(lightPos); 2536 2537 2536 2538 // change CHC++ set of renderState variables 2537 2539 // this must be done for each change of camera because … … 2671 2673 2672 2674 2673 void LoadPvs()2675 void UpdatePvs(const Vector3 &pos) 2674 2676 { 2675 2677 viewCell = viewCellsTree->GetViewCell(camera->GetPosition()); … … 2798 2800 staticObjects.push_back(myplane); 2799 2801 } 2802 2803 2804 void LoadOrUpdatePVSs(const Vector3 &pos) 2805 { 2806 if (!viewCellsTree) 2807 { 2808 LoadVisibilitySolution(); 2809 applicationTimer.Start(); 2810 shotRays = visibilitySolutionInitialState; 2811 } 2812 2813 if (viewCellsTree) UpdatePvs(pos); 2814 }
Note: See TracChangeset
for help on using the changeset viewer.