A tilemap is a (rectangular) array of index to tile definitions. More...
#include <OSDLTileMap.h>
Public Member Functions | |
TileMap (TileCount width, TileCount height, Ceylan::System::File &mapFile) | |
Constructs a new tilemap with specified dimensions, the map itself being read from specified file. | |
virtual | ~TileMap () throw () |
Virtual destructor. | |
virtual const std::string | toString (Ceylan::VerbosityLevels level=Ceylan::high) const |
Returns an user-friendly description of the state of this object. | |
Protected Attributes | |
TileCount | _width |
The width, in tiles, of this rectangular tile map. | |
TileCount | _height |
The height, in tiles, of this rectangular tile map. | |
TileNumber | _size |
Number of tile index for this map. | |
TileIndex * | _map |
The internal tile map (1D array of tile index). | |
Private Member Functions | |
TileMap (const TileMap &source) | |
Copy constructor made private to ensure that it will never be called. | |
TileMap & | operator= (const TileMap &source) |
Assignment operator made private to ensure that it will never be called. |
A tilemap is a (rectangular) array of index to tile definitions.
Definition at line 126 of file OSDLTileMap.h.
Constructs a new tilemap with specified dimensions, the map itself being read from specified file.
width | the width, in tiles, of the map. | |
height | the height, in tiles, of the map. | |
mapFile | a file whose read pointer is set at the beginning of a serialized tile map of the specified dimensions. Ownership is not taken, after this constructor the file read pointer will just be advanced just after the read tilemap. |
TileMapException | if the operation failed, including if the appropriate data could not be read from file. |
Definition at line 71 of file OSDLTileMap.cc.
TileMap::~TileMap | ( | ) | throw () [virtual] |
OSDL::Rendering::TileMap::TileMap | ( | const TileMap & | source | ) | [private] |
Copy constructor made private to ensure that it will never be called.
The compiler should complain whenever this undefined constructor is called, implicitly or not.
Assignment operator made private to ensure that it will never be called.
The compiler should complain whenever this undefined operator is called, implicitly or not.
const string TileMap::toString | ( | Ceylan::VerbosityLevels | level = Ceylan::high |
) | const [virtual] |
Returns an user-friendly description of the state of this object.
level | the requested verbosity level. |
Definition at line 114 of file OSDLTileMap.cc.
TileCount OSDL::Rendering::TileMap::_height [protected] |
The height, in tiles, of this rectangular tile map.
Definition at line 193 of file OSDLTileMap.h.
Referenced by toString().
TileIndex* OSDL::Rendering::TileMap::_map [protected] |
The internal tile map (1D array of tile index).
Definition at line 206 of file OSDLTileMap.h.
Referenced by TileMap(), and ~TileMap().
TileNumber OSDL::Rendering::TileMap::_size [protected] |
Number of tile index for this map.
Definition at line 202 of file OSDLTileMap.h.
Referenced by TileMap().
TileCount OSDL::Rendering::TileMap::_width [protected] |
The width, in tiles, of this rectangular tile map.
Definition at line 189 of file OSDLTileMap.h.
Referenced by toString().