Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8320 in orxonox.OLD


Ignore:
Timestamp:
Jun 11, 2006, 8:26:09 PM (18 years ago)
Author:
ponder
Message:

Added a bunch of comments to the terrain_page.h file

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/terrain/src/lib/graphics/importer/terrain/terrain_page.h

    r8319 r8320  
    4444                 */
    4545                TerrainPage( Terrain *_owner, int _xOffset, int _zOffset );
    46                
     46                /**
     47                 * This is used only internally for communication between the TerrainPage and
     48                 * the Terrain class itself.
     49                 */
    4750                inline bool isActive() { return active; }
     51               
     52               
    4853                ~TerrainPage( )
    4954                {
     
    5863                void mimick( int _level ) {}
    5964               
     65                /**
     66                 * Draws a box around the TerrainPage. For debugging purposes.
     67                 */
    6068                void drawBox();
     69               
     70                /**
     71                 * Calculates the smallest fitting axis aligned bounding box for this TerrainPage.
     72                 */
    6173                virtual void calculateBounds();         
     74               
     75               
    6276                /**
    6377                 * Sets the visibility to _flag. If the visibility changed, the vertex and index
     
    6781
    6882                /**
    69                  * If
     83                 * Prepares the page for rendering.
    7084                 */
    7185                void show( );
     86               
     87                /**
     88                 *
     89                 */
    7290                void hide( );
    73                 /**
    74                  *
     91               
     92                /**
     93                 * Updates the tesselation if necessary.
    7594                 */
    7695                void updateTesselation( );
     
    82101               
    83102                /**
    84                  * Returns the curren tween factor. This is a number between 0.0f and 1.0f
     103                 * Returns the curren tween factor. This is a floating point value between 0.0f and 1.0f
    85104                 */
    86105                float getTween() { return 0.0f; }
     
    94113                 */
    95114                int chooseLOD();
     115               
    96116                /**
    97117                 * If the terrain pages tesselation level changed between the last and the
     
    99119                 * return value.
    100120                 */
    101                 bool isDirty() { return true; }
     121                bool isDirty() { return forceTesselation; }
    102122               
    103123                /**
     
    111131                 */
    112132                void calculateError( int _lod );
     133               
     134               
    113135                /**
    114136                 * Tests if the terrain page would cull against the viewing frustum.
    115137                 */
    116138                bool cull( );
    117                
    118                 void calculateMinMax();
    119139               
    120140                /**
     
    127147                        left = _left; right = _right; top = _top; bottom = _bottom;
    128148                }
     149               
     150                /**
     151                 * Sets the position of the TerrainPage. Is this needed?
     152                 */
    129153                inline void setPosition( const Triple& _pos )
    130154                {
     
    139163                void draw( );
    140164               
     165                /**
     166                 * Returns the next active page
     167                 */
    141168                inline pTerrainPage getNext() { return next; }
     169               
     170                /**
     171                 * Returns the previous active page
     172                 */
    142173                inline pTerrainPage getPrevious() { return previous; }                 
     174               
     175                /**
     176                 * Returns the wanted LOD. Make sure you call this method after a call to
     177                 * chooseLOD() or you will get screwed values.
     178                 */
    143179                inline int getWantedLOD() { return wantedLOD; }
     180               
     181                /**
     182                 * Removes the page from the active page list.
     183                 */
    144184                void deactivate();
     185               
     186                /**
     187                 * Inserts the page into the active page list.
     188                 */
    145189                void activate();               
    146190                protected:
     191                       
    147192                       
    148193                        inline void addIndex( unsigned short _index );
Note: See TracChangeset for help on using the changeset viewer.