Changeset 831 for GTP/trunk/Lib/Geom
- Timestamp:
- 04/26/06 18:17:10 (19 years ago)
- Location:
- GTP/trunk/Lib/Geom/shared/GTGeometry
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Geom/shared/GTGeometry/GTGeometry.vcproj
r829 r831 256 256 </File> 257 257 </Filter> 258 <Filter 259 Name="leaves" 260 Filter=""> 261 <File 262 RelativePath=".\src\libs\leaves\activas.cpp"> 263 </File> 264 <File 265 RelativePath=".\src\libs\leaves\Arbol.cpp"> 266 </File> 267 <File 268 RelativePath=".\src\libs\leaves\foliage.cpp"> 269 </File> 270 <File 271 RelativePath=".\src\libs\leaves\Hoja.cpp"> 272 <FileConfiguration 273 Name="Debug|Win32"> 274 <Tool 275 Name="VCCLCompilerTool" 276 ObjectFile="$(IntDir)/$(InputName)1.obj"/> 277 </FileConfiguration> 278 <FileConfiguration 279 Name="Release|Win32"> 280 <Tool 281 Name="VCCLCompilerTool" 282 ObjectFile="$(IntDir)/$(InputName)1.obj"/> 283 </FileConfiguration> 284 </File> 285 <File 286 RelativePath=".\src\libs\leaves\Point3D.cpp"> 287 </File> 288 <File 289 RelativePath=".\src\libs\leaves\VertexData.cpp"> 290 </File> 291 </Filter> 258 292 </Filter> 259 293 <Filter … … 262 296 UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"> 263 297 <File 298 RelativePath=".\src\libs\leaves\activas.h"> 299 </File> 300 <File 264 301 RelativePath=".\src\libs\AdjModel.cxx"> 265 302 </File> … … 274 311 </File> 275 312 <File 313 RelativePath=".\src\libs\leaves\arbol.h"> 314 </File> 315 <File 276 316 RelativePath=".\src\libs\auxiliar.h"> 277 317 </File> … … 283 323 </File> 284 324 <File 325 RelativePath=".\src\libs\leaves\foliage.h"> 326 </File> 327 <File 285 328 RelativePath=".\src\libs\GeoBase.h"> 286 329 </File> … … 334 377 </File> 335 378 <File 379 RelativePath=".\src\libs\leaves\hoja.h"> 380 </File> 381 <File 336 382 RelativePath=".\include\hoja.h"> 337 383 </File> … … 340 386 </File> 341 387 <File 388 RelativePath=".\src\libs\leaves\Point3D.h"> 389 </File> 390 <File 342 391 RelativePath=".\src\libs\detail\policy.h"> 343 392 </File> … … 355 404 </File> 356 405 <File 406 RelativePath=".\src\libs\leaves\tlista.h"> 407 </File> 408 <File 409 RelativePath=".\src\libs\leaves\TMatrix.h"> 410 </File> 411 <File 357 412 RelativePath=".\src\libs\tri_stripper.h"> 413 </File> 414 <File 415 RelativePath=".\src\libs\leaves\Vector.h"> 416 </File> 417 <File 418 RelativePath=".\include\VertexData.h"> 358 419 </File> 359 420 <Filter -
GTP/trunk/Lib/Geom/shared/GTGeometry/include/GeoLodTreeLibrary.h
r829 r831 9 9 #include "GeoLodStripsLibrary.h" 10 10 11 /*class LodStrip;12 11 class Arbol; 13 12 class Foliage; 14 13 class Point3D; 15 */ 14 16 15 namespace Geometry 17 16 { 17 class IndexData; 18 18 class LodTreeLibrary 19 19 { … … 22 22 LodTreeLibrary(LodTreeLibrary*);*/ 23 23 LodTreeLibrary( std::string trunkSimpSeqFile, 24 Geometry::Mesh *treeGeoMesh 25 /*, 24 Geometry::Mesh *treeGeoMesh, 26 25 std::string foliage_verts, 27 26 std::string foliage_leafs, 28 std::string foliage_simpl ,27 std::string foliage_simpl/*, 29 28 uint32 leafSubMeshID, 30 29 CREATEVERTEXDATAFUNC vdfun=NULL, … … 38 37 uint32 MinTrunkLod(void) const; 39 38 uint32 MaxTrunkLod(void) const; 40 /*uint32 GoToFoliageLod(uint32 newlod);39 uint32 GoToFoliageLod(uint32 newlod); 41 40 uint32 MinFoliageLod(void) const; 42 uint32 MaxFoliageLod(void) const; */41 uint32 MaxFoliageLod(void) const; 43 42 44 43 // funciones nuevas propuestas … … 52 51 53 52 // uint32 Get_Foliage_VertexCount(void) const; 54 //uint32 Get_Foliage_MaxIndexCount(void) const;55 //uint32 CurrentLOD_Foliage_IndexCount(void) const;56 /*const IndexData* CurrentLOD_Foliage_Indices(void) const;57 const VertexData* Get_Foliage_VertexData(void) const;53 uint32 Get_Foliage_MaxIndexCount(void) const; 54 uint32 CurrentLOD_Foliage_IndexCount(void) const; 55 const IndexData* CurrentLOD_Foliage_Indices(void) const; 56 /* const VertexData* Get_Foliage_VertexData(void) const; 58 57 */ 59 58 // Geometry::IndexData *trunk_all_indices; … … 65 64 uint32 uniqueID; 66 65 Geometry::LodStripsLibrary *trunk; 67 //Arbol *arbol;68 //Foliage *foliage;66 Arbol *arbol; 67 Foliage *foliage; 69 68 70 69 }; -
GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoLodTreeLibrary.cpp
r829 r831 2 2 #include <assert.h> 3 3 #include "GeoLodTreeLibrary.h" 4 //#include "ArbolesInma/Arbol.h"5 //#include "ArbolesInma/Foliage.h"4 #include "libs/leaves/arbol.h" 5 #include "libs/leaves/Foliage.h" 6 6 7 7 using namespace Geometry; … … 10 10 11 11 Geometry::LodTreeLibrary::LodTreeLibrary(std::string trunkSimpSeqFile, 12 Geometry::Mesh *treeGeoMesh 13 /*, 12 Geometry::Mesh *treeGeoMesh, 14 13 std::string foliage_verts, 15 14 std::string foliage_leafs, 16 std::string foliage_simpl ,15 std::string foliage_simpl/*, 17 16 uint32 leafSubMeshID, 18 17 CREATEVERTEXDATAFUNC vdfun, … … 23 22 24 23 // Cargar el tronco 25 /* trunk=new LodStrip(vdfun,midfun);26 trunk->ED_NUEVA=1;27 trunk->RESVARIABLE=0;28 trunk->MODOTEST=0; //0: No test 1: plano 2: esfera29 trunk->bTextures=0;30 if (trunk->RecuperarModeloEFFICIENT((char*)trunkfile.c_str())==0)31 throw FileNotFound(trunkfile);32 33 // trunk->LodsDisp=(int) (trunk->cVerts.size()*0.99);34 trunk->LodsDisp=(int) (trunk->TOTALCAMBIOS*0.95);35 trunk->CopiarVectors2ArraysNUEVAED();36 trunk->LodActual=0;37 trunk->CalculaNormalesVertice();*/38 39 24 trunk = new LodStripsLibrary(trunkSimpSeqFile,treeGeoMesh); 40 25 41 26 // Cargar la copa del árbol 42 /* arbol = new Arbol(foliage_verts.c_str(),foliage_leafs.c_str(),foliage_simpl.c_str(),vdfun,idfun); 43 foliage = new Foliage(arbol);*/ 44 27 arbol = new Arbol(foliage_verts.c_str(),foliage_leafs.c_str(),foliage_simpl.c_str(),NULL/*vdfun*/,NULL/*idfun*/); 28 foliage = new Foliage(arbol); 45 29 } 46 30 /* … … 66 50 { 67 51 if (trunk) delete trunk; 68 //if (arbol) delete arbol;69 //if (foliage) delete foliage;52 if (arbol) delete arbol; 53 if (foliage) delete foliage; 70 54 /* if (trunk_all_indices) delete trunk_all_indices; 71 55 if (indices_offsets) delete[] indices_offsets; … … 117 101 } 118 102 119 /* 103 120 104 uint32 LodTreeLibrary::GoToFoliageLod(uint32 newlod) 121 105 { … … 174 158 return arbol->nHojas; 175 159 } 176 */ 160 177 161 /*const VertexData* LodTreeLibrary::Get_Trunk_VertexData(void) const 178 162 { … … 191 175 return arbol->vertexdata; 192 176 } 193 177 */ 194 178 const IndexData* LodTreeLibrary::CurrentLOD_Foliage_Indices(void) const 195 179 { 196 180 // return current_foliage_indices; 197 181 return arbol->indexdata; 198 } */182 } 199 183 200 184 … … 203 187 throw Geometry::FileNotFound(text); 204 188 }*/ 205 /* 189 206 190 uint32 LodTreeLibrary::CurrentLOD_Foliage_IndexCount(void) const 207 191 { … … 209 193 return arbol->indexdata->GetNumValidIndices(); 210 194 } 211 195 /* 212 196 uint32 LodTreeLibrary::Get_Trunk_VertexCount(void) const 213 197 { … … 224 208 { 225 209 return arbol->vertexdata->GetNumVertices(); 226 } 210 }*/ 227 211 uint32 LodTreeLibrary::Get_Foliage_MaxIndexCount(void) const 228 212 { 229 213 return arbol->indexdata->GetNumMaxIndices(); 230 214 } 231 */ -
GTP/trunk/Lib/Geom/shared/GTGeometry/src/libs/leaves/Arbol.cpp
r830 r831 1 #include <GL\glut.h>2 1 #include <stdio.h> 3 2 #include <string.h> 4 3 #include <math.h> 5 4 #include "Arbol.h" 6 #include "../defs.h" 7 8 //-------------------------------------------------------------------------------------------------------------------------------- 9 // Void constructor 10 // Parameters --> None 11 //-------------------------------------------------------------------------------------------------------------------------------- 12 /*Arbol::Arbol(void): Vertices(NULL), Hojas(NULL) 13 { 14 cx = cy= cz=0; 15 }*/ 5 16 6 //-------------------------------------------------------------------------------------------------------------------------------- 17 7 // Constructor with the name of a file cotaining the data … … 51 41 52 42 //VERTICES 53 if ((TotVerts=LeeVertices(arbol))==0) 54 if ((nHojas = LeoHojas (hojas))==0) ThrowFileNotFoundError((const char*)hojas);43 if ((TotVerts=LeeVertices(arbol))==0){ printf("File not found '%s'\n",arbol); exit(1); }//ThrowFileNotFoundError((const char*)arbol); 44 if ((nHojas = LeoHojas (hojas))==0) { printf("File not found '%s'\n",hojas); exit(1); }//ThrowFileNotFoundError((const char*)hojas); 55 45 // TotTronco = LeoTronco (tronco); 56 46 // CalculaNormalesVertice(); 57 if ((TotHojas = LeoHojasSimpl(simpli))==0) ThrowFileNotFoundError((const char*)simpli);47 if ((TotHojas = LeoHojasSimpl(simpli))==0){ printf("File not found '%s'\n",simpli); exit(1); }// ThrowFileNotFoundError((const char*)simpli); 58 48 RellenoRaiz(); 59 49
Note: See TracChangeset
for help on using the changeset viewer.