Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 1, 2006, 9:08:19 PM (19 years ago)
Author:
bottac
Message:

Experimental lightmapping. Screenshots: http://people.ee.ethz.ch/~bottac/lightmap_test/

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/bsp_model/src/lib/graphics/importer/bsp_file.h

    r7410 r7465  
    8888  int lm_index;         //!< Lightmap index.
    8989  int lm_start [ 2 ];   //!< Corner of this face's lightmap image in lightmap.
    90   int lm_size[ 2 ];     //!< Size of this face's lightmap image in lightmap.
     90  int lm_size [ 2 ];     //!< Size of this face's lightmap image in lightmap.
    9191  float lm_origin [ 3 ] ;    //!<  World space origin of lightmap.
    9292  float lm_vecs [ 2 ][ 3 ];  //!< World space lightmap s and t unit vectors.
     
    123123AMat;
    124124
     125typedef struct
     126{
     127  unsigned char map [128][128][3];
     128}
     129lightmap;
     130
    125131class BspFile
    126132{
     
    153159  char* visData;             //!<
    154160  char* textures;            //!<
    155   char* patchVertice;
     161  char* patchVertice;        //!<
    156162  char* patchIndexes;
    157163  char* patchTrianglesPerRow;
    158  
    159  
     164  lightmap* lightMaps;       //!< Buffer to store lightmap-images
     165
     166
    160167  int** patchRowIndexes;
    161168  VertexArrayModel** VertexArrayModels;
     
    173180  int numPatches;
    174181  int numBrushSides;
     182  int numLightMaps;
    175183
    176184  BspTreeNode* build_tree_rec( int i );
     185  unsigned int loadLightMapToGL(lightmap&);
    177186  AMat* Materials;
     187  unsigned int* glLightMapTextures;
     188  unsigned int whiteLightMap;
     189  unsigned char whiteTexture[3];
    178190  SDL_Surface* testSurf;
    179191
Note: See TracChangeset for help on using the changeset viewer.