Handle all loading of assets.
More...
|
| ~this () |
| Destroy assets stored in memory when the ResourceManager is destroyed.
|
|
|
static ResourceManager * | GetInstance () |
| Return a static instance of ResourceManager for global use.
|
|
static SDL_Texture * | LoadTexture (SDL_Renderer *renderer, string filename) |
| Load an image texture from a file path.
|
|
static TTF_Font * | LoadFont (string fontPath, int fontSize) |
| Load a font from a file path.
|
|
static ref Random | GetRNG () |
| Load a randomness generator.
|
|
Handle all loading of assets.
◆ GetInstance()
◆ GetRNG()
static ref Random ResourceManager::GetRNG |
( |
| ) |
|
|
inlinestatic |
Load a randomness generator.
- Returns
- the randomness generator.
◆ LoadFont()
static TTF_Font * ResourceManager::LoadFont |
( |
string | fontPath, |
|
|
int | fontSize ) |
|
inlinestatic |
Load a font from a file path.
- Parameters
-
fontPath | the file path to the .ttf file. |
fontSize | the font size to load. |
- Returns
- a loaded SDL font pointer.
◆ LoadTexture()
static SDL_Texture * ResourceManager::LoadTexture |
( |
SDL_Renderer * | renderer, |
|
|
string | filename ) |
|
inlinestatic |
Load an image texture from a file path.
- Parameters
-
renderer | the SDL renderer. |
filename | the file path to the .bmp file. |
- Returns
- a loaded SDL texture pointer.
The documentation for this struct was generated from the following file:
- Engine/source/resourcemanager.d