Changeset 1058


Ignore:
Timestamp:
06/26/06 17:36:46 (18 years ago)
Author:
gumbau
Message:

LODs parameters changed to the range 1-0 (max-min)

Location:
GTP/trunk/Lib/Geom/shared
Files:
4 deleted
11 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Geom/shared/GTGeometry/GTGeometry.vcproj

    r1057 r1058  
    263263                                </File> 
    264264                                <File 
    265                                         RelativePath=".\src\libs\leaves\Point3D.cpp"> 
    266                                 </File> 
    267                                 <File 
    268265                                        RelativePath=".\src\libs\leaves\VertexData.cpp"> 
    269266                                </File> 
     
    405402                        </File> 
    406403                        <File 
    407                                 RelativePath=".\include\hoja.h"> 
    408                         </File> 
    409                         <File 
    410404                                RelativePath=".\src\libs\NPrim.h"> 
    411405                        </File> 
    412406                        <File 
    413                                 RelativePath=".\src\libs\leaves\Point3D.h"> 
    414                         </File> 
    415                         <File 
    416407                                RelativePath=".\src\libs\detail\policy.h"> 
    417408                        </File> 
     
    436427                        <File 
    437428                                RelativePath=".\src\libs\tri_stripper.h"> 
    438                         </File> 
    439                         <File 
    440                                 RelativePath=".\src\libs\leaves\Vector.h"> 
    441429                        </File> 
    442430                        <File 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/include/GeoLodObject.h

    r1056 r1058  
    1212                } 
    1313                uint32 GetUniqueID(void) const { return  uniqueID; } 
    14                 virtual uint32 GoToLod(uint32)=0; 
     14                virtual void GoToLod(Real)=0; 
    1515 
    1616        private: 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/include/GeoLodStripsLibrary.h

    r1056 r1058  
    1515#include        "GeoMesh.h" 
    1616#include        <vector> 
    17 #include        <time.h> 
    1817#include        "VertexData.h" 
    1918#include "GeoLodObject.h" 
     
    8079                        //      Structures with the data read from the file 
    8180                        //      We won't work with these structures 
    82                         SmallIntVector                                                                  mFileVertices; 
    83                         std::vector     <LODRegisterType>               mFileChangesLOD; 
    84                         std::vector     <SmallIntVector>                mFileStrips; 
    85                         LongVector                                                                                      mData; 
     81                        SmallIntVector                                  mFileVertices; 
     82                        std::vector     <LODRegisterType>       mFileChangesLOD; 
     83                        std::vector     <SmallIntVector>        mFileStrips; 
     84                        LongVector                                              mData; 
    8685 
    8786                        //      Structures with the data to work with 
     
    105104 
    106105                        //      For the efficient version. 
    107                         SmallInt                                mTotalFaces; 
    108                         SmallInt                                *mCurrentData; 
    109                         SmallInt                                *mStripsChanges; 
     106                        SmallInt        mTotalFaces; 
     107                        SmallInt        *mCurrentData; 
     108                        SmallInt        *mStripsChanges; 
    110109                        LODRegisterType *mCurrentRegLOD; 
    111                         SmallInt                                *mVertex; 
     110                        SmallInt        *mVertex; 
     111 
     112                        SmallInt        minFaces, maxFaces; 
    112113                 
    113114                        //      Changes of Strips in LOD file (p). 
     
    145146                        ~LodStripsLibrary(void); 
    146147 
    147                         /// Copy constructor 
    148                         //LodStripsLibrary(const LodStripsLibrary&); 
    149  
    150                         /// Assignment operator 
    151                         //LodStripsLibrary& operator =(const LodStripsLibrary&); 
    152  
    153148                        /// Returns the highest LOD. 
    154149                        uint32  MaxLod(); 
     
    158153 
    159154                        /// Returns de current LOD and changes to the specified LOD. 
    160                         virtual uint32  GoToLod(uint32); 
     155                        virtual void GoToLod(Real); 
    161156 
    162157                        /// Establishes the new LOD range. 
     
    175170                        /// Returns the number of vertices of the lowest LOD. 
    176171                        uint32  MinVertices(); 
    177  
    178 /*                      //      (New)   Get the number of strips. 
    179                         uint32  GetStripCount() const; 
    180                         uint32  GetIndexCountByStrip(uint32) const;*/ 
    181172        }; 
    182173} 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/include/GeoLodTreeLibrary.h

    r1056 r1058  
    1010#include "GeoLodObject.h" 
    1111 
    12 class Arbol; 
    1312class Foliage; 
    14 class Point3D; 
    1513 
    1614namespace Geometry 
     
    3735 
    3836                // funciones ya descritas en la API 
    39                 uint32 GoToTrunkLod(uint32 newlod); 
     37/*              uint32 GoToTrunkLod(uint32 newlod); 
    4038                uint32 MinTrunkLod(void) const; 
    4139                uint32 MaxTrunkLod(void) const; 
    4240                uint32 GoToFoliageLod(uint32 newlod); 
    4341                uint32 MinFoliageLod(void) const; 
    44                 uint32 MaxFoliageLod(void) const; 
     42                uint32 MaxFoliageLod(void) const;*/ 
     43 
     44                void GoToTrunkLod(Real); 
     45                void GoToFoliageLod(Real); 
    4546 
    4647                // changes the lod of the entire object (trunk and leaves) 
    47                 virtual uint32 GoToLod(uint32); 
     48                virtual void GoToLod(Real); 
    4849 
    4950                // new proposed functions 
     
    6970        private: 
    7071                Geometry::LodStripsLibrary *trunk; 
    71                 Arbol *arbol; 
    7272                Foliage *foliage; 
    7373 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoLodStripsLibrary.cpp

    r1018 r1058  
    3535        //      Loads the Level Of Detail file. 
    3636        LodStripsLibrary::LoadStripMesh((char*)name_of_file,mGeoMesh); 
     37 
     38        GoToLod(0.0f);   
     39        minFaces = 0; 
     40        for (unsigned int strip = 0; strip < mTotalStrips; strip++) 
     41                minFaces += int(mStrips[strip].size() - 2); 
     42 
     43        GoToLod(1.0f); 
     44        maxFaces = 0; 
     45        for (unsigned int strip = 0; strip < mTotalStrips; strip++) 
     46                maxFaces += int(mStrips[strip].size() - 2); 
    3747} 
    3848 
     
    5464//      Go to the level of detail. 
    5565//----------------------------------------------------------------------------- 
    56 uint32 LodStripsLibrary::GoToLod(uint32 newLOD) 
     66void LodStripsLibrary::GoToLod(float lodfactor) 
    5767{ 
    5868        register        int                                                     j; 
     
    7383        uint32                                                                          return_value; 
    7484 
     85        uint32 newLOD = (1.0f-lodfactor) * mLods; 
     86     
    7587        //      Initialize the return value to the current LOD. 
    7688        return_value    =       mCurrentLod; 
     
    225237 
    226238        UpdateDataRetrievalInterface(); 
    227         return  return_value; 
     239//      return  return_value; 
    228240} 
    229241 
     
    270282uint32  LodStripsLibrary::MaxFaces() 
    271283{ 
    272         uint32  number_of_faces; 
     284/*      uint32  number_of_faces; 
    273285 
    274286        uint32  current_lod; 
     
    287299        GoToLod(current_lod); 
    288300 
    289         return  number_of_faces; 
     301        return  number_of_faces;*/ 
     302 
     303        return maxFaces; 
    290304} 
    291305 
     
    295309uint32  LodStripsLibrary::MinFaces() 
    296310{ 
    297         uint32  current_lod; 
     311/*      uint32  current_lod; 
    298312        uint32  number_of_faces; 
    299313 
     
    311325        GoToLod(current_lod); 
    312326 
    313         return  number_of_faces; 
     327        return  number_of_faces;*/ 
     328 
     329        return minFaces; 
    314330} 
    315331 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoLodTreeLibrary.cpp

    r1057 r1058  
    1 //#include "defs.h" 
    21#include <assert.h> 
    32#include "GeoLodTreeLibrary.h" 
     
    109                                                                                 Geometry::Mesh *treeGeoMesh, 
    1110                                                                                 uint32 leafSubMeshID/* 
    12                                                                 std::string foliage_verts,  
    13                                                                 std::string foliage_leafs,  
    14                                                                 std::string foliage_simpl, 
    15                                                            uint32 leafSubMeshID, 
    1611                                                           CREATEVERTEXDATAFUNC vdfun, 
    1712                                                           CREATEINDEXDATAFUNC idfun, 
     
    2217 
    2318        // Cargar la copa del árbol 
    24 //      arbol = new Arbol(foliage_verts.c_str(),foliage_leafs.c_str(),foliage_simpl.c_str(),NULL/*vdfun*/,NULL/*idfun*/); 
    2519        Geometry::SubMesh * leafsSubMesh = &(treeGeoMesh->mSubMesh[leafSubMeshID]); 
    2620        foliage = new Foliage(leafsSubMesh,leafSimpSeqFile.c_str()); 
     21        GoToFoliageLod(1.0f); 
    2722} 
    2823/* 
     
    7772*/ 
    7873 
    79 uint32 LodTreeLibrary::GoToTrunkLod(uint32 newlod) 
    80 { 
    81         return trunk->GoToLod(newlod); 
    82 /*      uint32 previouslod = trunk->LodActual; 
    83         trunk->VerModeloVBO(newlod); 
    84         return previouslod;*/ 
    85 } 
    86  
     74void LodTreeLibrary::GoToTrunkLod(float newlod) 
     75{ 
     76        trunk->GoToLod(newlod); 
     77} 
     78/* 
    8779uint32 LodTreeLibrary::MinTrunkLod(void) const 
    8880{ 
    89 //      return 3; // un polígono: preguntar a francisco 
    90 //      return (trunk->TOTALCAMBIOS*0.95f); 
    9181        return trunk->MinLod(); 
    9282} 
    9383uint32 LodTreeLibrary::MaxTrunkLod(void) const 
    9484{ 
    95 //      return (trunk->cVerts.size()*0.99); 
    96 //      return (trunk->TOTALCAMBIOS*0.95f); 
    97 //      return 0; 
    9885        return trunk->MaxLod(); 
    9986} 
    100  
    101  
    102 uint32 LodTreeLibrary::GoToFoliageLod(uint32 newlod) 
    103 { 
    104         foliage->AjusteHojas(newlod); 
     87*/ 
     88 
     89void LodTreeLibrary::GoToFoliageLod(float newlod) 
     90{ 
     91        uint32 targetLeaves = (1.0f-newlod)*foliage->minLeaves + newlod*foliage->leafCount; 
     92        foliage->CalculateLOD(targetLeaves); 
    10593 
    10694        foliage->indexdata->Begin(); 
    10795        foliage->vertexdata->Begin(); 
    108         int i = foliage->ppio; 
    109         int auxnumhojas = 0; 
     96        int i = foliage->begin; 
     97        int auxnumleaves = 0; 
    11098        while(i!=-1) 
    11199        { 
    112                 auxnumhojas++; 
     100                auxnumleaves++; 
    113101                i=foliage->Acth[i].next; 
    114102        } 
    115103 
    116         assert(auxnumhojas*6<=int(foliage->indexdata->GetNumMaxIndices())); 
    117         foliage->indexdata->SetNumValidIndices(auxnumhojas*6); 
    118         i = foliage->ppio; 
    119         int kkkk=0; 
     104        assert(auxnumleaves*6<=int(foliage->indexdata->GetNumMaxIndices())); 
     105        foliage->indexdata->SetNumValidIndices(auxnumleaves*6); 
     106        i = foliage->begin; 
     107        int index=0; 
    120108        while(i!=-1) 
    121109        { 
     
    126114                v3 = foliage->Leaves[i].vertsLeaf[3]; 
    127115 
    128                 foliage->indexdata->SetIndex(kkkk+0,v0); 
    129                 foliage->indexdata->SetIndex(kkkk+1,v1); 
    130                 foliage->indexdata->SetIndex(kkkk+2,v2); 
    131                 foliage->indexdata->SetIndex(kkkk+3,v2); 
    132                 foliage->indexdata->SetIndex(kkkk+4,v1); 
    133                 foliage->indexdata->SetIndex(kkkk+5,v3); 
     116                foliage->indexdata->SetIndex(index+0,v0); 
     117                foliage->indexdata->SetIndex(index+1,v1); 
     118                foliage->indexdata->SetIndex(index+2,v2); 
     119                foliage->indexdata->SetIndex(index+3,v2); 
     120                foliage->indexdata->SetIndex(index+4,v1); 
     121                foliage->indexdata->SetIndex(index+5,v3); 
    134122 
    135123                foliage->vertexdata->SetVertexTexCoord(v0,0,0); 
     
    138126                foliage->vertexdata->SetVertexTexCoord(v3,1,1);  
    139127 
    140                 kkkk+=6; 
     128                index+=6; 
    141129                i=foliage->Acth[i].next; 
    142130        } 
    143131        foliage->indexdata->End(); 
    144132        foliage->vertexdata->End(); 
    145  
    146         return 0; 
    147 } 
    148  
     133} 
     134/* 
    149135uint32 LodTreeLibrary::MinFoliageLod(void) const 
    150136{ 
    151 //      return arbol->minHojas; 
    152137        return foliage->nHojas; 
    153138} 
    154139uint32 LodTreeLibrary::MaxFoliageLod(void) const 
    155140{ 
    156         //      return arbol->TotHojas; 
    157         //return arbol->nHojas; 
    158141        return foliage->minHojas; 
    159 } 
     142}*/ 
    160143 
    161144/*const VertexData* LodTreeLibrary::Get_Trunk_VertexData(void) const  
     
    165148const MultiIndexData* LodTreeLibrary::CurrentLOD_Trunk_Indices(void) const  
    166149{  
    167 //      return (uint32*)trunk->vStrips[istrip];  
    168 //      return trunk->indices_x_tira[istrip]; 
    169150        return trunk->dataRetrievalInterface; 
    170151} 
     
    178159const IndexData* LodTreeLibrary::CurrentLOD_Foliage_Indices(void) const 
    179160{ 
    180 //      return current_foliage_indices; 
    181161        return foliage->indexdata; 
    182162} 
     
    216196 
    217197// changes the lod of the entire object (trunk and leaves) 
    218 uint32 LodTreeLibrary::GoToLod(uint32 lod) 
    219 { 
    220         return 0; 
    221 } 
     198void LodTreeLibrary::GoToLod(Real lod) 
     199{ 
     200        assert(lod<=1.0f && lod>=0.0f); 
     201        GoToTrunkLod(lod); 
     202        GoToFoliageLod(lod); 
     203} 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/src/libs/leaves/foliage.cpp

    r1057 r1058  
    66 
    77 
    8 /******************************************   PANTALLA **************************************************/ 
    98//-------------------------------------------------------------------------------------------------------------------------------- 
    109// Void constructor 
     
    1716vertexdata(NULL), Leaves(NULL), MinDet(NULL) 
    1817{ 
    19         cx = cy= cz= 0; 
    20         ppio= final = -1; 
     18        begin = final = -1; 
    2119 
    2220        ReadVertices(leavesSubMesh); 
    2321        ReadLeafs(leavesSubMesh); 
    2422        if (!ReadSimpSeq(simpSeq)) exit(1); 
    25         RellenoRaiz(); 
    26         CalculaTexCoordsYNorms(); 
    27  
    28  
    29         // esto no sé si devería haber akí 
     23        FillRoot(); 
     24        CalculateTexCoordsAndNorms(); 
     25 
    3026        indexdata->SetNumValidIndices(0); 
    3127 
    3228        int h=0; 
    3329 
    34  
    35         Acth  = new ActiveLeafNode[nHojas*8]; 
    36  
    37         for ( h=0; h < nHojas; h++) { 
     30        Acth  = new ActiveLeafNode[leafCount*8]; 
     31 
     32        for (h=0; h < leafCount; h++) { 
    3833 
    3934                Acth[h].index = h; 
     
    4641        } 
    4742                                 
    48         ppio = 0; 
    49         final = nHojas-1; 
    50         nhactivas = nHojas; 
    51  
    52 } 
    53  
    54 /* 
    55 //-------------------------------------------------------------------------------------------------------------------------------- 
    56 // Constructor with the name of a file cotaining the data 
    57 //-------------------------------------------------------------------------------------------------------------------------------- 
    58 Foliage::Foliage ( Arbol *Arbol1) 
    59 { 
    60         int h=0; 
    61  
    62  
    63         MiArbol = Arbol1; 
    64  
    65         Acth  = new Activas[(MiArbol->nHojas)*8]; 
    66  
    67         for ( h=0; h < MiArbol->nHojas; h++) { 
    68  
    69                 Acth[h].indice = h; 
    70                 if ( h != 0) 
    71                 { 
    72                         Acth[h].prev = (h-1); 
    73                         Acth[h-1].next = h; 
    74                 } 
    75  
    76         } 
    77                                  
    78         ppio = 0; 
    79         final = (MiArbol->nHojas)-1; 
    80         nhactivas = MiArbol->nHojas; 
    81  
    82  
    83  
    84 }*/ 
     43        begin = 0; 
     44        final = leafCount-1; 
     45        active_leaf_count = leafCount; 
     46} 
    8547 
    8648//-------------------------------------------------------------------------------------------------------------------------------- 
     
    9557        delete Acth; 
    9658} 
    97 // 
    98  
    99 //-------------------------------------------------------------------------------------------------------------------------------- 
    100 // Dibuja una hoja 
    101 //-------------------------------------------------------------------------------------------------------------------------------- 
    102                                 /* 
    103 void Foliage::Dibuja_Hoja ( Hoja &aHoja) 
    104 { 
    105          
    106         float a,b,c; 
    107  
    108         glBegin (GL_TRIANGLE_STRIP); 
    109                 glNormal3fv (aHoja.Normal); 
    110                 MiArbol->Vertices[aHoja.vertsLeaf[0]].GetCoordinates (a,b,c); 
    111                 glTexCoord2f ( 0.0, 0.0); 
    112  
    113                 glVertex3f (a,b,c); 
    114  
    115                 MiArbol->Vertices[aHoja.vertsLeaf[1]].GetCoordinates (a,b,c); 
    116                 glTexCoord2f ( 0.0, 1.0); 
    117                 glVertex3f (a,b,c); 
    118          
    119                 MiArbol->Vertices[aHoja.vertsLeaf[2]].GetCoordinates (a,b,c); 
    120                 glTexCoord2f ( 1.0, 0.0); 
    121                 glVertex3f (a,b,c); 
    122  
    123                 MiArbol->Vertices[aHoja.vertsLeaf[3]].GetCoordinates (a,b,c); 
    124                 glTexCoord2f ( 1.0, 1.0); 
    125                 glVertex3f (a,b,c); 
    126  
    127         glEnd (); 
    128  
    129 } 
    130  
    131  
    132 //-------------------------------------------------------------------------------------------------------------------------------- 
    133 // Dibujar todas las hojas activas  
    134 //-------------------------------------------------------------------------------------------------------------------------------- 
    135                                  
    136 int Foliage::DibujarHojas (float frustum[6][4], float zoom) 
    137 { 
    138         int hojactiva, i; 
    139  
    140  
    141         glPolygonMode (GL_FRONT_AND_BACK, GL_FILL); 
    142  
    143         hojactiva = 0; 
    144         glBindTexture (GL_TEXTURE_2D,texName[0]); 
    145         glEnable(GL_ALPHA_TEST); 
    146  
    147         if ( zoom <75.0)  
    148         //if ( false)  
    149         { 
    150                 //calculo el culling de las hojas de minimo detalle 
    151                 Culling (frustum); 
    152                 //printf ( "--------------------------->Entro en culling\n"); 
    153  
    154                 i= ppio;  
    155                 while ( i != -1) 
    156                 {  
    157                         if (MiArbol->Hojas[MiArbol->Hojas[i].raiz].visible == 1) 
    158                         { 
    159                                 hojactiva ++; 
    160                                 Dibuja_Hoja (MiArbol->Hojas[i]); 
    161                         } 
    162                         i = Acth[i].next; 
    163                 } 
    164         } 
    165         else 
    166         { 
    167                 i= ppio;  
    168         while ( i != -1) 
    169                 {  
    170                         hojactiva ++; 
    171                         Dibuja_Hoja (MiArbol->Hojas[i]); 
    172                         i=Acth[i].next; 
    173                 } 
    174  
    175         } 
    176  
    177  
    178  
    179         glDisable(GL_ALPHA_TEST); 
    180  
    181         return ( hojactiva); 
    182  
    183 } 
    184  
    185 //-------------------------------------------------------------------------------------------------------------------------------- 
    186 // Dibujar media copa del arbol  
    187 // si el char c es 'f' dibuja la parte delantera 
    188 // si es 'b' la parte trasera 
    189 //-------------------------------------------------------------------------------------------------------------------------------- 
    190                                  
    191 int Foliage::DibujaMediaCopa (  char c, float rva, float rvb,float rvc, float rvd, float radio) 
    192 { 
    193         int hojactiva, i; 
    194 //      int count, count2; 
    195  
    196         glPolygonMode (GL_FRONT_AND_BACK, GL_FILL); 
    197  
    198         hojactiva = 0; 
    199         glBindTexture (GL_TEXTURE_2D,texName[0]); 
    200         glEnable(GL_ALPHA_TEST); 
    201  
    202         i= ppio;  
    203         if ( c == 'b') 
    204         {//count = 0; 
    205         while ( i != -1) 
    206         {  //count ++; 
    207                         if ( Criterio (MiArbol->Hojas[i],'p', rva,rvb,rvc,rvd, radio) == false) //esta detras del plano 
    208                 { 
    209                         hojactiva ++; 
    210                         Dibuja_Hoja (MiArbol->Hojas[i]); 
    211                         } 
    212                 i = Acth[i].next; 
    213  
    214         } 
    215 //      printf ( " EN LA TRASERA chequeo %i hojas \n", count); 
    216         } 
    217         else 
    218         {// count2 = 0; 
    219  
    220                 while ( i != -1) 
    221                 { //count2++; 
    222                         if ( Criterio (MiArbol->Hojas[i],'p', rva,rvb,rvc,rvd, radio) == true) //esta detras del plano 
    223                 { 
    224                         hojactiva ++; 
    225                         Dibuja_Hoja (MiArbol->Hojas[i]); 
    226                         } 
    227                 i = Acth[i].next; 
    228         } 
    229                 //      printf ( " EN LA DELANTERA chequeo %i hojas \n", count2); 
    230  
    231         } 
    232         glDisable(GL_ALPHA_TEST); 
    233  
    234 //      nhactivas = hojactiva; 
    235  
    236  
    237         return ( hojactiva); 
    238  
    239  
    240  
    241 } 
    242  
    243  
    244  
    245 //------------------------------------------------------------------------------------------------------------------------- 
    246 // dibuja la esfera 
    247 //------------------------------------------------------------------------------------------------------------------------- 
    248  
    249 void Foliage::DibujaEsfera(float r) 
    250 { 
    251  
    252         glPushMatrix(); 
    253                 glTranslated (0.0,MiArbol->cy, 0.0); 
    254                 glColor3f(1.0, 0.0, 0.0); 
    255                 glDisable(GL_LIGHTING); 
    256                 glLineWidth(1.2); 
    257                 glPolygonMode (GL_FRONT_AND_BACK, GL_LINE); 
    258                 glutSolidSphere ( r,20, 20); 
    259                 glEnable(GL_LIGHTING); 
    260                 glColor3f ( 1.0, 1.0, 1.0); 
    261         glPopMatrix(); 
    262  
    263 } 
    264  
    265 /******************************************   CULLING **************************************************/ 
    266 //------------------------------------------------------------------------------------------------------------------------- 
    267 // culling de las hojas de menor detalle 
    268 //------------------------------------------------------------------------------------------------------------------------- 
    269  
    270 void Foliage::Culling (float frustum[6][4]) 
    271 { 
    272         int i, j; 
    273  
    274         i = 0; 
    275         while ( MinDet[i].index != -1) 
    276         { 
    277                 j = MinDet[i].index; 
    278                 if (LeafinFrustum ( j, frustum) == true) { 
    279                 //      printf("dentro %i y el padre es %i\n", j, MiArbol->Hojas[MiArbol->MinDet[i].indice].parent); 
    280                         Leaves[j].visible = 1; 
    281                 } 
    282                 else   
    283                 { 
    284                 //      printf("fuera %i\n", j); 
    285                         Leaves[j].visible = 0; 
    286                 } 
    287  
    288                 i++; 
    289         } 
    290  
    291 } 
    292  
    293  
    294 //------- 
    295 // si está en el frustrum --> true 
    296 //      sino --> false 
    297 //------------ 
    298  
    299  
    300 bool Foliage::LeafinFrustum ( int i, float frustum[6][4]) 
    301 { 
    302         float a,b,c, tmp; 
    303         int j,p; 
    304         Vector v; 
    305  
    306         for (j =0; j<4; j++) 
    307         { 
    308 //              MiArbol->Vertices[MiArbol->Hojas[i].vertsLeaf[j]].GetCoordinates (a,b,c); 
    309                 vertexdata->GetVertexCoord(Leaves[i].vertsLeaf[j],a,b,c); 
    310                 v[0]=a; v[1]=b; v[2]=c; v[3]=1; 
    311  
    312                 //  el punto resultante será 
    313                 v = mat_aux*v; 
    314  
    315                 for( p = 0; p < 5; p++ ) 
    316                 { tmp = float(frustum[p][0] * v[0] + frustum[p][1] * v[1] + frustum[p][2] * v[2] + frustum[p][3]); 
    317                   if ( tmp <= -2.0 )  return false; 
    318                 } 
    319         } 
    320  
    321  
    322         return true; 
    323  
    324 } 
    325  
    32659 
    32760/******************************************   CRITERIO **************************************************/ 
     
    33972 
    34073 
    341 //-------------------------------------------------------------------------------------------------------------------------------- 
    342 // Colapsa dos hojas  
    343 //-------------------------------------------------------------------------------------------------------------------------------- 
    344                                  
    345 void Foliage::ColapsaHoja (  int h,   int& post) 
    346 { 
    347  
    348         //actualizo los punteros del ppio y del final, y post 
    349         while (( ppio == Leaves[h].childLeft) || ( ppio == Leaves[h].childRight)) 
    350                 ppio = Acth[ppio].next; 
    351         while (( final == Leaves[h].childLeft) || ( final == Leaves[h].childRight)) 
    352                  final = Acth[final].prev;  
    353  
    354         while (( post == Leaves[h].childLeft) || ( post == Leaves[h].childRight)) 
    355                  post = Acth[post].next;  
    356  
    357  
    358  
    359         //COLAPSAR = QUITO DOS DE ACTIVOS PONGO UNO A ACTIVO 
    360  
    361         if (Acth[Leaves[h].childLeft].next != -1) 
    362                 Acth[Acth[Leaves[h].childLeft].next].prev = Acth[Leaves[h].childLeft].prev; 
    363         if (Acth[Leaves[h].childLeft].prev != -1) 
    364                 Acth[Acth[Leaves[h].childLeft].prev].next = Acth[Leaves[h].childLeft].next; 
    365  
    366         if (Acth[Leaves[h].childRight].next != -1) 
    367                 Acth[Acth[Leaves[h].childRight].next].prev = Acth[Leaves[h].childRight].prev; 
    368         if (Acth[Leaves[h].childRight].prev != -1) 
    369                 Acth[Acth[Leaves[h].childRight].prev].next = Acth[Leaves[h].childRight].next; 
    370  
    371          
    372         //  desconecto a los hijos 
    373         Acth[Leaves[h].childLeft].prev = -1; 
    374         Acth[Leaves[h].childLeft].next = -1; 
    375         Acth[Leaves[h].childRight].prev = -1; 
    376         Acth[Leaves[h].childRight].next = -1; 
    377  
    378         //añado al final 
    379         Acth[h].prev = final; 
    380         Acth[h].next = -1; 
    381         Acth[final].next = h; 
    382         final = h; 
    383  
    384          
    385 } 
    386  
    387 //-------------------------------------------------------------------------------------------------------------------------------- 
    388 // Splitea una hoja  
    389 //-------------------------------------------------------------------------------------------------------------------------------- 
    390                                  
    391 void Foliage::SplitHoja (int h, int &post) 
    392 { 
    393  
    394         // SPLITEAR: QUITO UNO, PONGO DOS 
    395          
    396         if ( ppio == h) ppio = Acth[h].next; 
    397         if ( final == h) final = Acth[h].prev;  
    398  
    399         // 1 enlazo los hijos  
    400         Acth[Leaves[h].childLeft].next = Leaves[h].childRight; 
    401         Acth[Leaves[h].childRight].prev = Leaves[h].childLeft; 
    402         Acth[Leaves[h].childRight].next = -1; 
    403  
    404         //y desconecto al padre 
    405         if ( Acth[h].prev != -1) 
    406                 Acth[Acth[h].prev].next = Acth[h].next; 
    407         if ( Acth[h].next != -1) 
    408                 Acth[Acth[h].next].prev = Acth[h].prev; 
    409         Acth[h].prev = -1; 
    410         Acth[h].next = -1; 
    411          
    412         //añado al final los hijos  
    413         Acth[Leaves[h].childLeft].prev = final; 
    414         Acth[final].next = Leaves[h].childLeft; 
    415         final = Leaves[h].childRight; 
    416  
    417 } 
    418  
    419  
    420  
    421  
    422  
    423 //------------------------------------------------------------------------------------------- 
    424 // fuerzo a splitear 
    425 // hoja -> es el nodo que cumple la condicion 
    426 // padre -> es el nodo que chequeaba de la lista de activos 
    427 // hpost -> es el nodo siguiente en la lista de activos 
    428 //------------------------------------------------------------------------------------------- 
    429  
    430 bool Foliage::Forzar_Split(int hoja, int padre, int &hpost) 
    431 { 
    432          
    433         int h; 
    434         lista <int> listah; 
    435         bool bien; 
    436  
    437         bien = false; 
    438         h = Leaves[hoja].parent; 
    439         listah.Inserta (h); // Inserta un dato en la lista 
    440  
    441         while ( h != padre) 
    442         { 
    443                 h = Leaves[h].parent; 
    444                 listah.Inserta (h); // Inserta un dato en la lista 
    445         } 
    446  
    447  
    448         while  (listah.NDatos () != 0)  
    449         { 
    450                 h = listah.GetCola ();//coger el padre más alto 
    451                 SplitHoja(h, hpost); 
    452                 listah.Borra(h); 
    453          
    454         } 
    455  
    456         if ( listah.NDatos() == 0) 
    457                 bien = true; 
    458         return (bien); 
    459                  
    460 }                
    461  
    462  
    463  
    464  
    465 /******************************************   RESOLUCIÓN CONSTANTE **************************************************/ 
    466  
    467  
    468 int Foliage::ResolucionC (float dist, float dmax, float dmin) 
    469 { 
    470  
    471         float difdist,  d; 
    472         int difhojas, nhojas; 
    473  
    474         if (( dist > dmin) && (dist <dmax)) 
    475         { 
    476                 difdist = dmax - dmin; 
    477                 difhojas = nHojas - minHojas; 
    478  
    479                 d = dist - dmin; 
    480  
    481                 //regla de 3 
    482  
    483                 nhojas = int(abs(d*difhojas /difdist)); 
    484  
    485                 AjusteHojas ((nHojas)-nhojas); 
    486  
    487         } 
    488         else if (dist > dmax) { 
    489                 AjusteHojas (minHojas); 
    490         } 
    491         else if (dist < dmin) { 
    492                 AjusteHojas (nHojas); 
    493         } 
    494                  
    495         return (nhactivas); 
    496 } 
    497  
    498  
    499  
    500 void Foliage::AjusteHojas( int nhojas) 
    501 { 
    502         if ((nhojas <= nHojas) && (nhojas >= minHojas)) 
    503         { 
    504                 if ( nhojas < nhactivas) { 
    505                         RCecol ( nhactivas - nhojas); 
     74 
     75void Foliage::CalculateLOD(int nleaves) 
     76{ 
     77        if ((nleaves <= leafCount) && (nleaves > minLeaves)) 
     78        { 
     79                if ( nleaves < active_leaf_count) { 
     80                        RCecol (active_leaf_count - nleaves); 
    50681                } 
    50782                else  { 
    508                          RCsplit (nhojas-nhactivas ); 
    509                 } 
    510  
    511                 nhactivas = nhojas; 
    512         //      printf ( "ajusto a %i\n", nhactivas ); 
    513  
     83                         RCsplit (nleaves-active_leaf_count); 
     84                } 
     85 
     86                active_leaf_count = nleaves; 
    51487        } 
    51588 
     
    52497        j = num; 
    52598        h = final+1; 
    526                 while ((h<=TotHojas) && (j>0)) 
     99                while ((h<=leafTotal) && (j>0)) 
    527100                { 
    528                         while (( ppio == Leaves[h].childLeft) || ( ppio == Leaves[h].childRight)) 
    529                                 ppio = Acth[ppio].next; 
     101                        while (( begin == Leaves[h].childLeft) || ( begin == Leaves[h].childRight)) 
     102                                begin = Acth[begin].next; 
    530103 
    531104                        while (( final == Leaves[h].childLeft) || ( final == Leaves[h].childRight)) 
    532105                                final = Acth[final].prev;  
    533  
    534  
    535                         //COLAPSAR = QUITO DOS DE ACTIVOS PONGO UNO A ACTIVO 
    536106 
    537107                        if (Acth[Leaves[h].childLeft].next != -1) 
     
    563133                        //incremento el posible siguiente colapso  
    564134                        h++; 
    565  
    566  
    567                 } 
    568  
    569 } 
    570  
    571 /* 
    572 void Foliage::RCsplit (  int nhojas) 
    573 { 
    574         int i, hpost; 
    575  
    576         i = ppio; 
    577          
    578         while (( i != -1) && (nhojas>0)){ 
    579                 hpost = Acth[i].next; 
    580  
    581                 if (MiArbol->Leaves[i].childLeft != -1){ 
    582                                         SplitHoja(i, hpost); 
    583                                         nhojas --; 
    584  
    585                 } 
    586                  
    587                 i = hpost; 
    588  
    589         } 
    590 } 
    591 */ 
    592  
    593 int Foliage::AnteriorActivo (int h) 
     135                } 
     136} 
     137 
     138int Foliage::PrevActive(int h) 
    594139{ 
    595140        int i; 
    596141 
    597142         
    598         if (ppio > h)  i = -1; 
     143        if (begin > h)  i = -1; 
    599144        else 
    600145        { 
     
    608153} 
    609154 
    610 int Foliage::PosteriorActivo (int h) 
     155int Foliage::NextActive(int h) 
    611156{       int i; 
    612157 
    613158        i = h++; 
    614159         
    615         while ((IsActive(i) == false) || (i> TotHojas)) 
     160        while ((IsActive(i) == false) || (i> leafTotal)) 
    616161                i++; 
    617162 
    618         if (i > TotHojas) i=-1; 
     163        if (i > leafTotal) i=-1; 
    619164 
    620165 
     
    629174        j = num; 
    630175        h = final; 
    631         while ((h > nHojas) &&  (j>0)) 
    632         { 
    633  
     176        while (h>leafCount &&  j>0) 
     177        { 
    634178                ///////////// insertar a los hijos en orden segun su indice 
    635179                //hijo izquierdo 
    636                 ant = AnteriorActivo (Leaves[h].childLeft); 
    637                 post = PosteriorActivo (Leaves[h].childLeft); 
     180                ant = PrevActive(Leaves[h].childLeft); 
     181                post = NextActive(Leaves[h].childLeft); 
    638182 
    639183 
     
    641185                Acth[Leaves[h].childLeft].prev = ant; 
    642186                if (ant != -1) Acth[ant].next = Leaves[h].childLeft; 
    643                         else ppio = Leaves[h].childLeft; 
     187                        else begin = Leaves[h].childLeft; 
    644188                if (post != -1) Acth[post].prev = Leaves[h].childLeft; 
    645189 
    646190                 
    647191                //hijo derecho 
    648                 ant = AnteriorActivo (Leaves[h].childRight); 
    649                 post = PosteriorActivo (Leaves[h].childRight); 
     192                ant = PrevActive(Leaves[h].childRight); 
     193                post = NextActive(Leaves[h].childRight); 
    650194 
    651195 
     
    653197                Acth[Leaves[h].childRight].prev = ant; 
    654198                if (ant != -1)  Acth[ant].next = Leaves[h].childRight; 
    655                                 else ppio = Leaves[h].childRight; 
     199                                else begin = Leaves[h].childRight; 
    656200                if (post != -1) Acth[post].prev = Leaves[h].childRight; 
    657201 
     
    695239        vertexdata->End(); 
    696240 
    697         TotVerts = countv; 
     241        TotalVerts = countv; 
    698242} 
    699243 
     
    746290{ 
    747291        int numtris = int(submesh->mIndexCount / 3); 
    748         nHojas =  numtris / 2; 
    749         for (int h=0; h<nHojas; h++) 
     292        leafCount =  numtris / 2; 
     293        for (int h=0; h<leafCount; h++) 
    750294        { 
    751295                Leaves[h].vertsLeaf[0] = submesh->mIndex[h*6+0]; 
     
    773317        else 
    774318        { 
    775                 tn = nHojas; 
     319                tn = leafCount; 
    776320                while (fgets (linea, 255, fp_simpli) != NULL) 
    777321                { 
     
    779323                                continue; 
    780324                 
    781                         //N 446 Ver 10176 10178 10169 10171  Tv 156 154 E 2 
    782  
    783 //                      sscanf(linea, "%s %lu %s %lu %lu  %lu %lu %s %lu %lu %s %i",  
    784 //                              &str, &tn, &str, &v0, &v1, &v2, &v3, &str, &tv1, &tv2, &str, &e ); 
    785325                        long int triviej00=-1, triviej01=-1; 
    786326                        long int triviej10=-1, triviej11=-1; 
     
    812352        fclose(fp_simpli); 
    813353 
    814         TotHojas=tn; 
     354        leafTotal=tn; 
    815355                 
    816356        return true; 
    817357} 
    818358 
    819 void Foliage::RellenoRaiz (void) 
     359void Foliage::FillRoot(void) 
    820360{ 
    821361        int i,j, k, t, cont; 
     
    826366        cont =-1; 
    827367 
    828         MinDet  = new ActiveLeafNode[nHojas*2]; 
    829          
    830         while (i<TotHojas) 
     368        MinDet  = new ActiveLeafNode[leafCount*2]; 
     369         
     370        while (i<leafTotal) 
    831371        { 
    832372                j=i; 
    833                 while (Leaves[j].parent > -1) j= Leaves[j].parent; 
     373                while (Leaves[j].parent>-1) j=Leaves[j].parent; 
    834374                Leaves[i].root = j; 
    835375 
     
    853393                        } 
    854394 
    855                         if ( esta == false) //añado al final 
     395                        if ( esta == false) 
    856396                        { 
    857397                                cont++; 
     
    860400                } 
    861401 
    862         i++; 
     402                i++; 
    863403        }        
    864404 
    865         minHojas = cont; 
    866  
    867 } 
    868  
    869 void Foliage::CalculaTexCoordsYNorms(void) 
     405        minLeaves = cont; 
     406 
     407} 
     408 
     409void Foliage::CalculateTexCoordsAndNorms(void) 
    870410{        
    871411        vertexdata->Begin(); 
    872         for (int i=0; i<nHojas; i++) 
     412        for (int i=0; i<leafCount; i++) 
    873413        {        
    874414                const float* lanormal = Leaves[i].normal; 
     
    884424                vertexdata->SetVertexNormal(Leaves[i].vertsLeaf[3], lanormal[0], lanormal[1], lanormal[2]); 
    885425                vertexdata->SetVertexTexCoord(Leaves[i].vertsLeaf[3], 1.0f, 0.0f); 
    886  
    887  
    888 /*              MiArbol->Vertices[aHoja.vertsLeaf[1]].GetCoordinates (a,b,c); 
    889                 glTexCoord2f ( 0.0, 1.0); 
    890                 glVertex3f (a,b,c); 
    891          
    892                 MiArbol->Vertices[aHoja.vertsLeaf[2]].GetCoordinates (a,b,c); 
    893                 glTexCoord2f ( 1.0, 0.0); 
    894                 glVertex3f (a,b,c); 
    895  
    896                 MiArbol->Vertices[aHoja.vertsLeaf[3]].GetCoordinates (a,b,c); 
    897                 glTexCoord2f ( 1.0, 1.0); 
    898                 glVertex3f (a,b,c);*/ 
    899426        } 
    900427        vertexdata->End(); 
     
    903430Foliage::Foliage(const Foliage *ar) 
    904431{ 
    905         nHojas=ar->nHojas; 
    906         MinDet  = new ActiveLeafNode[nHojas*2]; 
     432        leafCount = ar->leafCount; 
     433        MinDet = new ActiveLeafNode[leafCount*2]; 
    907434//      for (unsigned int i=0; i<nHojas*2; i++) 
    908435//              MinDet[i]=ar->MinDet[i]; 
    909         memcpy(MinDet,ar->MinDet,sizeof(ActiveLeafNode)*nHojas*2); 
    910         TotHojas=ar->TotHojas; 
    911         cx=ar->cx; 
    912         cy=ar->cy; 
    913         cz=ar->cz; 
    914         rad=ar->rad; 
    915         minHojas=ar->minHojas; 
    916         TotVerts=ar->TotVerts; 
     436        memcpy(MinDet,ar->MinDet,sizeof(ActiveLeafNode)*leafCount*2); 
     437        leafTotal=ar->leafTotal; 
     438        minLeaves=ar->minLeaves; 
     439        TotalVerts=ar->TotalVerts; 
    917440 
    918441        create_vertex_data_func=ar->create_vertex_data_func; 
     
    945468        int h=0; 
    946469 
    947         Acth  = new ActiveLeafNode[nHojas*8]; 
    948  
    949         for ( h=0; h < nHojas; h++) { 
     470        Acth  = new ActiveLeafNode[leafCount*8]; 
     471 
     472        for ( h=0; h < leafCount; h++) { 
    950473 
    951474                Acth[h].index = h; 
     
    958481        } 
    959482                                 
    960         ppio = 0; 
    961         final = nHojas-1; 
    962         nhactivas = nHojas; 
    963  
    964 } 
     483        begin = 0; 
     484        final = leafCount-1; 
     485        active_leaf_count = leafCount; 
     486 
     487} 
  • GTP/trunk/Lib/Geom/shared/GTGeometry/src/libs/leaves/foliage.h

    r1057 r1058  
    44#include "GeoSubMesh.h" 
    55#include "tlista.h" 
    6 #include "TMatrix.h" 
    76#include "VertexData.h" 
    87#include "Leaf.h" 
     
    2423 
    2524                ActiveLeafNode  *Acth; // first active leaf 
    26                 int ppio, final; 
    27                 int nhactivas; 
    28                 TMatrix mat_aux; 
     25                int begin, final; 
     26                int active_leaf_count; 
    2927 
    3028                Foliage (const Geometry::SubMesh *, const char *simpSeq, Geometry::CREATEVERTEXDATAFUNC vdfun=NULL, Geometry::CREATEINDEXDATAFUNC idfun=NULL); 
     
    3230                virtual ~Foliage (void); // Destructor 
    3331                 
    34                 //culling 
    35                 void Culling (float frustum[6][4]); 
    36                 bool LeafinFrustum ( int i, float frustum[6][4]); 
    37  
    38                 bool IsActive( int num) const; 
    39                 int  ResolucionV ( char c, float rva, float rvb,float rvc, float rvd, float radio); 
    40                 void ColapsaHoja (int, int&); 
    41                 void SplitHoja (int, int&); 
    42                 bool Forzar_Split(int, int, int&); 
    43                 int  AnteriorActivo (int h); 
    44                 int  PosteriorActivo (int h); 
    45  
    46  
    47                 // resolucion constante 
    48                 int  ResolucionC (float dist, float dmax, float dmin); 
    49                 void AjusteHojas( int nhojas); 
    50                 void RCecol (  int nhojas); 
    51                 void RCsplit (  int nhojas); 
     32                void CalculateLOD(int nhojas); 
    5233 
    5334                Geometry::VertexData *vertexdata; 
     
    5536 
    5637                Leaf   *Leaves; 
    57                 ActiveLeafNode  *MinDet; // primera hoja activa 
    58                 int nHojas; 
    59                 int TotHojas; 
     38                ActiveLeafNode  *MinDet; // first active leaf 
     39                int leafCount; 
     40                int leafTotal; 
    6041                 
    61                 float cx,cy,cz; //centro de la copa// para los impostores y resolucion variable 
    62                 float rad; //radio de la esfera envolvente 
    63                 int minHojas; 
    64                 int TotVerts; 
     42                int minLeaves; 
     43                int TotalVerts; 
    6544 
    6645        private: 
     
    6847                Geometry::CREATEINDEXDATAFUNC create_index_data_func; 
    6948 
     49                bool IsActive( int num) const; 
     50                int  PrevActive (int h); 
     51                int  NextActive (int h); 
     52 
     53                void RCecol(int nhojas); 
     54                void RCsplit(int nhojas); 
     55 
    7056                void ReadLeafs(const Geometry::SubMesh *); 
    7157                void ReadVertices(const Geometry::SubMesh *); 
    7258                bool ReadSimpSeq(const char*); /// returns true when successful 
    73                 void RellenoRaiz (void); 
     59                void FillRoot(void); 
    7460 
    7561                void GetNormalH (Leaf&); 
    76 //              void GetNormalT(Tronco&); 
    7762 
    7863                void CrossProduct(const float *v1, const float *v2, float *res); 
    7964                void Normalize(const float *v, float *res); 
    8065//              void CalculaNormalesVertice(void); 
    81                 void CalculaTexCoordsYNorms(void); 
     66                void CalculateTexCoordsAndNorms(void); 
    8267 
    8368}; 
  • GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshView.h

    r998 r1058  
    190190 
    191191        //      Change de Level of detail of the object. 
    192         void    GoToLod_LodStrip(unsigned int lod); 
    193         void    GoToLod_LodTree(unsigned int lod); 
     192        void    GoToLod_LodStrip(float lod); 
     193        void    GoToLod_LodTree(float lod); 
    194194         
    195195        // load a image file as a texture 
  • GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshView.cpp

    r1051 r1058  
    11291129//      Change de Level of detail of the object. 
    11301130//--------------------------------------------------------------------------- 
    1131 void    GeoMeshView::GoToLod_LodStrip(unsigned int      lod) 
     1131void    GeoMeshView::GoToLod_LodStrip(float     lod) 
    11321132{ 
    11331133        if (mLodStrip) 
     
    11411141//      Change de Level of detail of the object. 
    11421142//--------------------------------------------------------------------------- 
    1143 void    GeoMeshView::GoToLod_LodTree(unsigned int       lod) 
     1143void    GeoMeshView::GoToLod_LodTree(float      lod) 
    11441144{ 
    11451145        if (mLodTree) 
  • GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp

    r1050 r1058  
    13731373{ 
    13741374        //      Change the lod. 
    1375         geoMeshView->GoToLod_LodStrip((unsigned int)o->value()); 
     1375        geoMeshView->GoToLod_LodStrip((float)o->value()); 
    13761376 
    13771377        //      Refresh data aplication. 
     
    13941394{ 
    13951395        //      Change the lod. 
    1396         geoMeshView->GoToLod_LodTree((unsigned int)o->value()); 
     1396        geoMeshView->GoToLod_LodTree((float)o->value()); 
    13971397 
    13981398        //      Refresh data aplication. 
     
    24012401 
    24022402        //      Sets the slider range. 
    2403         mLodStripSlider->range(lodStripsLib->MinLod(),lodStripsLib->MaxLod()); 
     2403//      mLodStripSlider->range(lodStripsLib->MinLod(),lodStripsLib->MaxLod()); 
     2404        mLodStripSlider->range(0.0f,1.0f); 
    24042405 
    24052406        //      Pass to geomeshview the lod strips object. 
     
    24312432 
    24322433        //      Sets the slider range. 
    2433         mLodStripSlider->range(lodTreeLib->MaxTrunkLod(), lodTreeLib->MinTrunkLod()); 
    2434         mLodTreeSlider->range(lodTreeLib->MaxFoliageLod(), lodTreeLib->MinFoliageLod()); 
     2434//      mLodStripSlider->range(lodTreeLib->MaxTrunkLod(), lodTreeLib->MinTrunkLod()); 
     2435//      mLodTreeSlider->range(lodTreeLib->MaxFoliageLod(), lodTreeLib->MinFoliageLod()); 
     2436        mLodStripSlider->range(0.0f,1.0f); 
     2437        mLodTreeSlider->range(0.0f,1.0f); 
    24352438 
    24362439        //      Pass to geomeshview the lod strips object. 
     
    24382441         
    24392442        //      Puts the slider in the max position. 
    2440         mLodStripSlider->value(lodTreeLib->MinTrunkLod()); 
    2441         mLodTreeSlider->value(lodTreeLib->MinFoliageLod()); 
     2443        mLodStripSlider->value(1.0f); 
     2444        mLodTreeSlider->value(1.0f); 
    24422445} 
    24432446 
Note: See TracChangeset for help on using the changeset viewer.