Changeset 1321 for GTP/trunk/App/Demos/Geom/Demo_LodTrees
- Timestamp:
- 09/04/06 15:35:59 (18 years ago)
- Location:
- GTP/trunk/App/Demos/Geom/Demo_LodTrees
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Geom/Demo_LodTrees/Demo_LodTrees.vcproj
r1092 r1321 48 48 Name="VCPostBuildEventTool" 49 49 CommandLine="xcopy /Y ..\OgreStuff\bin\Debug\*.dll build\Debug 50 xcopy /Y ..\OgreStuff\bin\Debug\*.cfg build\Debug 51 "/> 50 xcopy /Y ..\OgreStuff\bin\Debug\*.cfg build\Debug"/> 52 51 <Tool 53 52 Name="VCPreBuildEventTool"/> … … 101 100 Name="VCPostBuildEventTool" 102 101 CommandLine="xcopy /Y ..\OgreStuff\bin\Release\*.dll build\Release 103 xcopy /Y ..\OgreStuff\bin\Release\*.cfg build\Release 104 "/> 102 xcopy /Y ..\OgreStuff\bin\Release\*.cfg build\Release"/> 105 103 <Tool 106 104 Name="VCPreBuildEventTool"/> -
GTP/trunk/App/Demos/Geom/Demo_LodTrees/main.cpp
r1307 r1321 281 281 { 282 282 bool istrunk = myTrees->GetLeavesSubMesh()!=submesh; 283 int indices_to_render = 0;284 283 if (istrunk) 285 {286 284 entity->getSubEntity(submesh)->setMaterialName("Examples/Populifolia/trunk"); 287 indices_to_render = myTrees->GetValidTrunkIndexCount(submesh);288 }289 285 else 290 {291 286 entity->getSubEntity(submesh)->setMaterialName("Examples/Populifolia/leaf"); 292 indices_to_render = myTrees->CurrentLOD_Foliage_IndexCount();293 }294 295 Ogre::RenderOperation mRenderOp;296 ogreMesh->getSubMesh(submesh)->_getRenderOperation(mRenderOp,0);297 298 mRenderOp.indexData->indexBuffer = Ogre::HardwareBufferManager::getSingleton().createIndexBuffer(299 Ogre::HardwareIndexBuffer::IT_32BIT, // type of index300 indices_to_render, // number of indexes301 Ogre::HardwareBuffer::HBU_DISCARDABLE , // usage302 false); // no shadow buffer303 287 } 304 288
Note: See TracChangeset
for help on using the changeset viewer.