AssetBase

Engine/source/assets/assetBase.h

More...

Public Types

enum
AssetErrCode {
  Failed 
  Ok 
  NotLoaded 
  BadFileReference 
  InvalidFormat 
  DependencyNotFound 
  FileTooLarge 
  UsingFallback 
  Extended 
}

Private Types

Parent 

Public Friends

Public Static Attributes

mErrCodeStrings [AssetErrCode::Extended+1]

Public Static Functions

Public Functions

addAssetDependencyField(const char * pFieldName, const char * pAssetId)
copyTo(SimObject * object)

Copy SimObject to another SimObject (Originally designed for T2D).

Declare Console Object.

expandAssetFilePath(const char * pAssetFilePath)

Expanding/Collapsing asset paths is only available once registered with the asset manager.

bool
bool
setAssetAutoUnload(const bool autoUnload)
setAssetCategory(const char * pAssetCategory)
setAssetDescription(const char * pAssetDescription)
setAssetInternal(const bool assetInternal)
setAssetName(const char * pAssetName)

Asset configuration.

Protected Static Functions

const char *
getAssetAutoUnload(void * obj, const char * data)
const char *
getAssetCategory(void * obj, const char * data)
const char *
getAssetDescription(void * obj, const char * data)
const char *
getAssetInternal(void * obj, const char * data)
const char *
getAssetName(void * obj, const char * data)
const char *
getAssetPrivate(void * obj, const char * data)
bool
setAssetAutoUnload(void * obj, const char * array, const char * data)
bool
setAssetCategory(void * obj, const char * array, const char * data)
bool
setAssetDescription(void * obj, const char * array, const char * data)
bool
setAssetInternal(void * obj, const char * array, const char * data)
bool
setAssetName(void * obj, const char * array, const char * data)
bool
bool
bool
bool

Private Functions

setOwned(AssetManager * pAssetManager, AssetDefinition * pAssetDefinition)

Set asset manager ownership.

Detailed Description

Public Types

AssetErrCode

Enumerator

Failed
Ok
NotLoaded
BadFileReference
InvalidFormat
DependencyNotFound
FileTooLarge
UsingFallback
Extended

Private Types

typedef SimObject Parent 

Public Friends

Protected Attributes

U32 mAcquireReferenceCount 
bool mAssetInitialized 
AssetDefinition * mpAssetDefinition 
AssetManager * mpOwningAssetManager 

Public Static Attributes

const String mErrCodeStrings [AssetErrCode::Extended+1]

Public Static Functions

getAssetErrstrn(U32 errCode)

initPersistFields()

Engine.

Public Functions

AssetBase()

~AssetBase()

addAssetDependencyField(const char * pFieldName, const char * pAssetId)

clearAssetDependencyFields(const char * pFieldName)

collapseAssetFilePath(const char * pAssetFilePath)

copyTo(SimObject * object)

Reimplemented from: SimObject

Reimplemented by: CppAsset, CubemapAsset, ExampleAsset, GameObjectAsset, GUIAsset, ImageAsset, LevelAsset, MaterialAsset, ParticleAsset, PostEffectAsset, ScriptAsset, ShapeAnimationAsset, ShapeAsset, SoundAsset, StateMachineAsset, TerrainAsset, TerrainMaterialAsset

DECLARE_CONOBJECT(AssetBase )

Declare Console Object.

expandAssetFilePath(const char * pAssetFilePath)

Expanding/Collapsing asset paths is only available once registered with the asset manager.

getAcquiredReferenceCount(void )

getAssetAutoUnload(void )

getAssetCategory(void )

getAssetDependencyFieldCount(const char * pFieldName)

getAssetDescription(void )

getAssetId(void )

getAssetInternal(void )

getAssetName(void )

getAssetPrivate(void )

getAssetType(void )

getOwned(void )

isAssetValid(void )

refreshAsset(void )

saveAsset()

setAssetAutoUnload(const bool autoUnload)

setAssetCategory(const char * pAssetCategory)

setAssetDescription(const char * pAssetDescription)

setAssetInternal(const bool assetInternal)

setAssetName(const char * pAssetName)

Asset configuration.

Protected Functions

initializeAsset(void )

Reimplemented by: MaterialAsset, PostEffectAsset, ShapeAsset, TerrainAsset, TerrainMaterialAsset, CppAsset, CubemapAsset, ExampleAsset, GameObjectAsset, GUIAsset, ImageAsset, LevelAsset, ParticleAsset, ScriptAsset, ShapeAnimationAsset, SoundAsset, StateMachineAsset

onAssetRefresh(void )

Reimplemented by: CppAsset, CubemapAsset, ExampleAsset, GameObjectAsset, GUIAsset, ImageAsset, LevelAsset, MaterialAsset, ParticleAsset, PostEffectAsset, ScriptAsset, ShapeAnimationAsset, ShapeAsset, SoundAsset, StateMachineAsset, TerrainAsset, TerrainMaterialAsset

Protected Static Functions

getAssetAutoUnload(void * obj, const char * data)

getAssetCategory(void * obj, const char * data)

getAssetDescription(void * obj, const char * data)

getAssetInternal(void * obj, const char * data)

getAssetName(void * obj, const char * data)

getAssetPrivate(void * obj, const char * data)

setAssetAutoUnload(void * obj, const char * array, const char * data)

setAssetCategory(void * obj, const char * array, const char * data)

setAssetDescription(void * obj, const char * array, const char * data)

setAssetInternal(void * obj, const char * array, const char * data)

setAssetName(void * obj, const char * array, const char * data)

writeAssetAutoUnload(void * obj, StringTableEntry pFieldName)

writeAssetCategory(void * obj, StringTableEntry pFieldName)

writeAssetDescription(void * obj, StringTableEntry pFieldName)

writeAssetInternal(void * obj, StringTableEntry pFieldName)

writeAssetName(void * obj, StringTableEntry pFieldName)

Private Functions

acquireAssetReference(void )

releaseAssetReference(void )

setOwned(AssetManager * pAssetManager, AssetDefinition * pAssetDefinition)

Set asset manager ownership.