|
CeresEngine 0.2.0
A game development framework
|
Primary class used to implement parsers and imports for common file formats to engine resources. More...
#include <CeresEngine/Resource/Importer/ResourceImporter.hpp>
Public Types | |
| enum class | SupportStatus { Supported , Generic , Unsupported } |
| An enumeration that contains the possible importer support status. More... | |
Public Member Functions | |
| ResourceImporter (ResourceManager &resourceManager) | |
| Creates a new resource importer. | |
| virtual | ~ResourceImporter ()=default |
| Destroys the resource importer. | |
| virtual Async< ImportedResources > | import (const ResourceURL &url, const ResourceImportOptions &options)=0 |
| Imports a resource from a URL. | |
| virtual Async< SupportStatus > | supports (const ResourceURL &url)=0 |
| Checks if the import supports the given resource. | |
Protected Attributes | |
| ResourceManager & | mResourceManager |
| The owning resource manager. | |
| URLSession & | mURLSession |
| The URL session to be used to load resources. | |
| ExecutionContext & | mExecutionContext |
| The execution context to perform asynchronous resource operations on. | |
Primary class used to implement parsers and imports for common file formats to engine resources.
An enumeration that contains the possible importer support status.
|
explicit |
Creates a new resource importer.
| resourceManager | The owning resource manager. |
|
virtualdefault |
Destroys the resource importer.
|
pure virtual |
Imports a resource from a URL.
| url | The URL to import the resource from. |
Implemented in CeresEngine::TResourceImporter< T, O >, CeresEngine::TResourceImporter< AudioClip, AudioClipImportOptions >, CeresEngine::TResourceImporter< AudioStream, AudioStreamImportOptions >, CeresEngine::TResourceImporter< Font, FontImportOptions >, CeresEngine::TResourceImporter< MaterialImporter, MaterialImportOptions >, CeresEngine::TResourceImporter< Mesh, MeshImportOptions >, CeresEngine::TResourceImporter< Scene, SceneImportOptions >, CeresEngine::TResourceImporter< ShaderImporter, ShaderImportOptions >, and CeresEngine::TResourceImporter< Texture, TextureImportOptions >.
|
pure virtual |
Checks if the import supports the given resource.
| url | The URL to import the resource from. |
Implemented in CeresEngine::OggVorbisClipImporter, CeresEngine::MTLMaterialImporter, CeresEngine::OBJMeshImporter, CeresEngine::GLTFSceneImporter, CeresEngine::OBJSceneImporter, CeresEngine::StbiTextureImporter, CeresEngine::ShaderImporterImpl, and CeresEngine::DefaultFontImporter.
|
protected |
The execution context to perform asynchronous resource operations on.
|
protected |
The owning resource manager.
Can be used to import/load dependent resources.
|
protected |
The URL session to be used to load resources.