summaryrefslogtreecommitdiffstats
path: root/AssetLoader/interface
diff options
context:
space:
mode:
authorassiduous <assiduous@diligentgraphics.com>2020-12-14 04:21:57 +0000
committerassiduous <assiduous@diligentgraphics.com>2020-12-14 04:21:57 +0000
commit967f2dc21a045de770cb0e7898ed5fab6a3265fa (patch)
tree7da687bd68f7f8f81309d30586c7f4c05f71ee34 /AssetLoader/interface
parentGLTF resource manager: fixed issue with allocation cache not being protected ... (diff)
downloadDiligentTools-967f2dc21a045de770cb0e7898ed5fab6a3265fa.tar.gz
DiligentTools-967f2dc21a045de770cb0e7898ed5fab6a3265fa.zip
GLTFLoader: added convenience constructor for Model::CreateInfo
Diffstat (limited to 'AssetLoader/interface')
-rw-r--r--AssetLoader/interface/GLTFLoader.hpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/AssetLoader/interface/GLTFLoader.hpp b/AssetLoader/interface/GLTFLoader.hpp
index 91f4aef..05c9c12 100644
--- a/AssetLoader/interface/GLTFLoader.hpp
+++ b/AssetLoader/interface/GLTFLoader.hpp
@@ -352,6 +352,21 @@ struct Model
/// Whether to load animation and initialize skin attributes
/// buffer.
bool LoadAnimationAndSkin = true;
+
+ CreateInfo() = default;
+
+ explicit CreateInfo(const char* _FileName,
+ TextureCacheType* _pTextureCache = nullptr,
+ ResourceCacheUseInfo* _pCacheInfo = nullptr,
+ bool _LoadAnimationAndSkin = true) :
+ // clang-format off
+ FileName {_FileName},
+ pTextureCache {_pTextureCache},
+ pCacheInfo {_pCacheInfo},
+ LoadAnimationAndSkin{_LoadAnimationAndSkin}
+ // clang-format on
+ {
+ }
};
Model(IRenderDevice* pDevice,
IDeviceContext* pContext,