Changed AssetType underlying type
Added mesh name to mesh asset object Added in static token for LoadGLTF function Fixed warning in GetTypeFromExtension
This commit is contained in:
parent
a907c7c575
commit
78a20173e0
|
@ -18,6 +18,8 @@ namespace SHADE
|
||||||
|
|
||||||
SHMeshAssetHeader header;
|
SHMeshAssetHeader header;
|
||||||
|
|
||||||
|
std::string meshName;
|
||||||
|
|
||||||
std::vector<SHVec3> vertexPosition;
|
std::vector<SHVec3> vertexPosition;
|
||||||
std::vector<SHVec2> texCoords;
|
std::vector<SHVec2> texCoords;
|
||||||
std::vector<SHVec3> vertexTangent;
|
std::vector<SHVec3> vertexTangent;
|
||||||
|
|
|
@ -40,10 +40,10 @@ typedef FMOD::Sound* SHSound;
|
||||||
#define ASSET_META_VER "1.0"
|
#define ASSET_META_VER "1.0"
|
||||||
|
|
||||||
// Asset type enum
|
// Asset type enum
|
||||||
enum class AssetType : int
|
enum class AssetType : uint8_t
|
||||||
{
|
{
|
||||||
INVALID = -1,
|
INVALID = 0,
|
||||||
AUDIO = 0,
|
AUDIO = 1,
|
||||||
SHADER,
|
SHADER,
|
||||||
MATERIAL,
|
MATERIAL,
|
||||||
IMAGE,
|
IMAGE,
|
||||||
|
@ -52,7 +52,8 @@ enum class AssetType : int
|
||||||
SCRIPT,
|
SCRIPT,
|
||||||
SCENE,
|
SCENE,
|
||||||
PREFAB,
|
PREFAB,
|
||||||
AUDIO_WAV
|
AUDIO_WAV,
|
||||||
|
DDS
|
||||||
};
|
};
|
||||||
|
|
||||||
//Directory
|
//Directory
|
||||||
|
|
|
@ -30,7 +30,7 @@ namespace SHADE
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* \brief Static function to generate resource ID.
|
* \brief Static function to generate resource ID.
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
static AssetID GenerateAssetID() noexcept;
|
static AssetID GenerateAssetID(AssetType type) noexcept;
|
||||||
|
|
||||||
static AssetPath GenerateLocalPath(AssetPath path) noexcept;
|
static AssetPath GenerateLocalPath(AssetPath path) noexcept;
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ namespace SHADE
|
||||||
static bool IsRecognised(char const*) noexcept;
|
static bool IsRecognised(char const*) noexcept;
|
||||||
|
|
||||||
// Specialised load calls
|
// Specialised load calls
|
||||||
void LoadGLTF(SHAsset asset) noexcept;
|
static void LoadGLTF(SHAsset asset) noexcept;
|
||||||
|
|
||||||
static FMOD::System* audioSystem;
|
static FMOD::System* audioSystem;
|
||||||
static std::unordered_map<AssetID,SHSound>* audioSoundList;
|
static std::unordered_map<AssetID,SHSound>* audioSoundList;
|
||||||
|
|
|
@ -42,6 +42,8 @@ namespace SHADE
|
||||||
return static_cast<AssetType>(i);
|
return static_cast<AssetType>(i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return AssetType::INVALID;
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
|
|
Loading…
Reference in New Issue