A C++ Tileset container.
More...
#include <tileset.hpp>
A C++ Tileset container.
embed:rst:leading-asterisk
.. versionadded:: 1.19
◆ Tileset() [1/4]
| tcod::Tileset::Tileset |
( |
int | tile_width, |
|
|
int | tile_height ) |
|
inlineexplicit |
Construct a new Tileset object with tiles of the given size.
The tileset will be empty.
- Parameters
-
| tile_width | The width of the tiles of this object in pixels. |
| tile_height | The width of the tiles of this object in pixels. |
◆ Tileset() [2/4]
| tcod::Tileset::Tileset |
( |
const std::array< int, 2 > & | tile_shape | ) |
|
|
inlineexplicit |
Construct a new Tileset object with tiles of the given size.
The tileset will be empty.
- Parameters
-
| tile_shape | The {width, height} of the tiles in pixels. |
◆ Tileset() [3/4]
◆ Tileset() [4/4]
Takes ownership of a raw TCOD_Tileset pointer.
- Parameters
-
| ptr | A pointer which will now be managed by this object. |
◆ get() [1/2]
◆ get() [2/2]
◆ get_tile_height()
| auto tcod::Tileset::get_tile_height |
( |
| ) |
const->int |
|
inlinenodiscardnoexcept |
Get the height of tiles in this Tileset.
- Returns
- int The total height of tiles in pixels.
◆ get_tile_shape()
| auto tcod::Tileset::get_tile_shape |
( |
| ) |
const->std::array< int, 2 > |
|
inlinenodiscardnoexcept |
Get the {width, height} shape of tiles in this Tileset.
- Returns
- std::array<int, 2> The {width, height} of tiles in this Tileset in pixels.
◆ get_tile_width()
| auto tcod::Tileset::get_tile_width |
( |
| ) |
const->int |
|
inlinenodiscardnoexcept |
Get the width of tiles in this Tileset.
- Returns
- int The total width of tiles in pixels.
◆ release()
Release ownership of this Tileset's TCOD_Tileset* and return the pointer.
Using this Tileset afterwards is undefined.
The documentation for this class was generated from the following file:
- C:/Users/4b796/Projects/libtcod/src/libtcod/tileset.hpp