17 void LoadFromFile(
const char* filename,
int nBytesPerPixel = 0);
51 int m_dwTextureFormat;
64 typedef std::map<string, CRegionLayer*> RegionLayer_Map_Type;
66 void SetSize(
float fWidth,
float fHeight);
69 DWORD GetValue(
const string& sLayerName,
float x,
float y);
75 void LoadRegion(
const string& sLayerName,
const char* filename);
83 RegionLayer_Map_Type&
GetLayers() {
return m_layers;}
89 int GetNumOfRegions();
93 void SetCurrentRegionIndex(
int nRegion);
97 int GetCurrentRegionIndex();
102 void SetCurrentRegionName(
const string& name);
105 const string& GetCurrentRegionName();
108 void SetCurrentRegionFilepath(
const string& filename);
111 const string& GetCurrentRegionFilepath();
118 int m_nCurRegionIndex;
121 string m_sCurRegionName;
124 RegionLayer_Map_Type m_layers;
Definition: SceneObject.h:15
void SetFileName(const string &filename)
set the file name.
Definition: TerrainRegions.cpp:140
const string & GetFileName()
get texture file path.
Definition: TerrainRegions.h:29
DWORD GetPixelValue(int x, int y)
get the value in image.
Definition: TerrainRegions.cpp:118
int GetHeight()
pixels columns
Definition: TerrainRegions.h:23
RegionLayer_Map_Type & GetLayers()
get the layers map.
Definition: TerrainRegions.h:83
void LoadFromFile(const char *filename, int nBytesPerPixel=0)
load from an image file.
Definition: TerrainRegions.cpp:44
a single region layer
Definition: TerrainRegions.h:7
the editable terrain regions associated with a terrain tile.
Definition: TerrainRegions.h:57
int GetWidth()
pixels rows
Definition: TerrainRegions.h:26