Handles all resources.
More...
#include <ResourceManager.hpp>
◆ ResourceManager()
◆ ~ResourceManager()
| ResourceManager::~ResourceManager |
( |
| ) |
|
◆ CreateModel()
Create a model if it doesn't already exist.
- Parameters
-
- Returns
- The model instance
◆ CreateScriptFile()
| ScriptFile * ResourceManager::CreateScriptFile |
( |
const std::string & |
name | ) |
|
Create a script file if it doesn't already exist.
- Parameters
-
| name | Name of the script file. |
- Returns
- The ScriptFile instance.
◆ CreateTexture2D()
| Video::Texture2D * ResourceManager::CreateTexture2D |
( |
const char * |
data, |
|
|
int |
dataLength |
|
) |
| |
Create a 2D texture if it doesn't already exist.
- Parameters
-
| data | Image file data. |
| dataLength | Length of the image file data. |
- Returns
- The Texture2D instance
◆ CreateTextureAsset()
| TextureAsset * ResourceManager::CreateTextureAsset |
( |
const std::string & |
name | ) |
|
Create a texture asset if it doesn't already exist.
- Parameters
-
| name | The name of the texture asset. |
- Returns
- The TextureAsset instance
◆ FreeModel()
Free the reference to the model.
- Parameters
-
| model | Model to dereference. |
◆ FreeScriptFile()
| void ResourceManager::FreeScriptFile |
( |
ScriptFile * |
scriptFile | ) |
|
Free the reference to the script file.
Deletes the instance if no more references exist.
- Parameters
-
| scriptFile | ScriptFile to dereference. |
◆ FreeTexture2D()
Free the reference to the 2D texture.
Deletes the instance if no more references exist.
- Parameters
-
| texture | Texture to dereference. |
◆ FreeTextureAsset()
| void ResourceManager::FreeTextureAsset |
( |
TextureAsset * |
textureAsset | ) |
|
Free the reference to the texture asset.
Deletes the instance if no more references exist.
- Parameters
-
| textureAsset | TextureAsset to dereference. |
◆ GetDefaultAlbedo()
Get the default albedo texture.
- Returns
- The default albedo texture.
◆ GetDefaultNormal()
Get the default normal map.
- Returns
- The default normal map.
◆ GetDefaultRoughnessMetallic()
| TextureAsset * ResourceManager::GetDefaultRoughnessMetallic |
( |
| ) |
|
Get the default roughness-metallic texture.
- Returns
- The default roughness-metallic texture.
◆ GetTextureAssetInstanceCount()
| int ResourceManager::GetTextureAssetInstanceCount |
( |
TextureAsset * |
textureAsset | ) |
|
Get the number of instances of a texture asset.
- Parameters
-
| textureAsset | The texture asset to check. |
- Returns
- How many instances of the texture asset currently exist.
◆ Hub
The documentation for this class was generated from the following files: