diff options
| author | assiduous <assiduous@diligentgraphics.com> | 2020-03-28 03:06:49 +0000 |
|---|---|---|
| committer | assiduous <assiduous@diligentgraphics.com> | 2020-03-28 03:06:49 +0000 |
| commit | df0d5b264107cade5aba9f90cb42e7df5e3c70a6 (patch) | |
| tree | 057b86a6ec50fe83467680468822db255c4e62b8 /AssetLoader/src/GLTFLoader.cpp | |
| parent | Enabled format validation on linux (diff) | |
| download | DiligentTools-df0d5b264107cade5aba9f90cb42e7df5e3c70a6.tar.gz DiligentTools-df0d5b264107cade5aba9f90cb42e7df5e3c70a6.zip | |
GLTF Loader: enabled two-sided materials
Diffstat (limited to 'AssetLoader/src/GLTFLoader.cpp')
| -rw-r--r-- | AssetLoader/src/GLTFLoader.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/AssetLoader/src/GLTFLoader.cpp b/AssetLoader/src/GLTFLoader.cpp index cf454bd..df3cead 100644 --- a/AssetLoader/src/GLTFLoader.cpp +++ b/AssetLoader/src/GLTFLoader.cpp @@ -715,6 +715,14 @@ void Model::LoadMaterials(const tinygltf::Model& gltf_model) } } + { + auto double_sided_it = gltf_mat.additionalValues.find("doubleSided"); + if (double_sided_it != gltf_mat.additionalValues.end()) + { + Mat.DoubleSided = double_sided_it->second.bool_value; + } + } + // Extensions // @TODO: Find out if there is a nicer way of reading these properties with recent tinygltf headers { |
