R-Type
Public Member Functions | List of all members
GameEngine::AssetManager Class Reference

Class to manage assets. More...

#include <AssetManager.hpp>

Public Member Functions

 AssetManager ()=default
 Default constructor. More...
 
 ~AssetManager ()=default
 Default destructor. More...
 
void loadTexture (const std::string &filename, Recti area)
 Load a texture from a file. More...
 
void loadFont (const std::string &filename)
 
const TexturegetTexture (const std::string &textureName) const
 Get a texture previously loaded. More...
 
const FontgetFont (const std::string &fontName) const
 

Detailed Description

Class to manage assets.

Constructor & Destructor Documentation

◆ AssetManager()

GameEngine::AssetManager::AssetManager ( )
default

Default constructor.

◆ ~AssetManager()

GameEngine::AssetManager::~AssetManager ( )
default

Default destructor.

Member Function Documentation

◆ getFont()

const Font& GameEngine::AssetManager::getFont ( const std::string &  fontName) const
inline

◆ getTexture()

const Texture& GameEngine::AssetManager::getTexture ( const std::string &  textureName) const
inline

Get a texture previously loaded.

Parameters
textureNamename of the texture
Returns
const reference to the texture

◆ loadFont()

void GameEngine::AssetManager::loadFont ( const std::string &  filename)
inline

◆ loadTexture()

void GameEngine::AssetManager::loadTexture ( const std::string &  filename,
Recti  area 
)
inline

Load a texture from a file.

Parameters
filenamename of the file
areaarea of the texture

The documentation for this class was generated from the following file: