00001 #ifndef INCLUDED_TEXTURE_HASH 00002 #define INCLUDED_TEXTURE_HASH 00003 00004 #ifndef INCLUDED_TAPESTRY 00005 # include "Tapestry.h" 00006 #endif 00007 00008 class TileHash { 00009 public: 00010 TileHash(void); 00011 00012 private: 00013 TilePtr *table; 00014 int hashSize; 00015 int tableSize; 00016 00017 public: 00018 void clear(void); 00019 int hash(uint32 data); 00020 int put(uint32 *addr, TilePtr tile); 00021 TilePtr get(uint32 *addr); 00022 void remove(uint32 *addr); 00023 }; 00024 00025 typedef TileHash* TileHashPtr; 00026 00027 #endif 00028 00029 const int GLOBAL_TEXTURE_HASH = 0; 00030 const int GLOBAL_TILE_LIST = 1;