24#include "GraphicsApi.h"
29#ifndef DOXYGEN_SHOULD_SKIP_THIS
87 m_texture->setSmooth(smooth);
98 return m_texture !=
nullptr;
135 setMargin({ margin, margin });
163 setSpacing({ spacing, spacing });
239#ifndef DOXYGEN_SHOULD_SKIP_THIS
A texture for colored images.
Definition: Texture.h:313
A tileset.
Definition: Tileset.h:48
void setMargin(int margin)
Set the margin of the tileset.
Definition: Tileset.h:134
void setSpacing(Vector2i spacing)
Set the spacing of the tileset.
void setTexture(Texture &texture)
Change the source texture of the tileset.
void setOffset(Vector2i offset)
Set the offset of the tileset.
Vector2i getTileSize() const
Get the tile size in the tileset.
Definition: Tileset.h:124
RectF computeTextureCoords(int tile) const
Get the texture coordinates for a tile.
Vector2i getOffset() const
Get the offset of the tileset.
Definition: Tileset.h:198
const Texture & getTexture() const
Get the source texture of the tileset.
Definition: Tileset.h:75
Vector2i getMargin() const
Get the margin of the tileset.
Definition: Tileset.h:152
RectF computeTextureCoords(Vector2i coords) const
Get the texture coordinates for a tile.
void setSmooth(bool smooth=true)
Enable or disable the smooth filter on the texture.
Definition: Tileset.h:86
Vector2i getSize() const
Get the size of the tileset.
Definition: Tileset.h:207
void unsetTexture()
Unset the source texture of the tile layer.
void setMargin(Vector2i margin)
Set the margin of the tileset.
Vector2i getSpacing() const
Get the spacing of the tileset.
Definition: Tileset.h:180
bool hasTexture() const
Check if a texture is set.
Definition: Tileset.h:97
void setSpacing(int spacing)
Set the spacing of the tileset.
Definition: Tileset.h:162
void setTileSize(Vector2i tileSize)
Set the tile size in the tileset.
The namespace for gf classes.