From 26c4505c5355730cd89ed42ce6f29e241b59ac47 Mon Sep 17 00:00:00 2001 From: mosfet80 Date: Thu, 22 Jun 2023 21:41:26 +0200 Subject: [PATCH 01/10] Update run-cmake into sanitizer.yml --- .github/workflows/sanitizer.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sanitizer.yml b/.github/workflows/sanitizer.yml index b23f4520f..41b8468e2 100644 --- a/.github/workflows/sanitizer.yml +++ b/.github/workflows/sanitizer.yml @@ -22,7 +22,7 @@ jobs: CC: clang - name: configure and build - uses: lukka/run-cmake@v3 + uses: lukka/run-cmake@v10 with: cmakeListsOrSettingsJson: CMakeListsTxtAdvanced cmakeListsTxtPath: '${{ github.workspace }}/CMakeLists.txt' @@ -46,7 +46,7 @@ jobs: CC: clang - name: configure and build - uses: lukka/run-cmake@v2 + uses: lukka/run-cmake@v10 with: cmakeListsOrSettingsJson: CMakeListsTxtAdvanced cmakeListsTxtPath: '${{ github.workspace }}/CMakeLists.txt' From 46ea0a7d7c37c4fa7f9b39aca6994e2d5d0afd30 Mon Sep 17 00:00:00 2001 From: mosfet80 Date: Thu, 22 Jun 2023 21:43:52 +0200 Subject: [PATCH 02/10] Update sanitizer.yml --- .github/workflows/sanitizer.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sanitizer.yml b/.github/workflows/sanitizer.yml index 41b8468e2..483ee8fc1 100644 --- a/.github/workflows/sanitizer.yml +++ b/.github/workflows/sanitizer.yml @@ -22,7 +22,7 @@ jobs: CC: clang - name: configure and build - uses: lukka/run-cmake@v10 + uses: lukka/run-cmake@v3 with: cmakeListsOrSettingsJson: CMakeListsTxtAdvanced cmakeListsTxtPath: '${{ github.workspace }}/CMakeLists.txt' @@ -46,7 +46,7 @@ jobs: CC: clang - name: configure and build - uses: lukka/run-cmake@v10 + uses: lukka/run-cmake@v3 with: cmakeListsOrSettingsJson: CMakeListsTxtAdvanced cmakeListsTxtPath: '${{ github.workspace }}/CMakeLists.txt' From 506baa21e68dfe928cecc7f53f4027d94ecd1fb3 Mon Sep 17 00:00:00 2001 From: Marco Feuerstein Date: Tue, 4 Jul 2023 09:25:45 +0200 Subject: [PATCH 03/10] Unify extension check for importers. This enables proper checking for all kinds of extensions (including the ones with multiple dots) for all importers and internal usage. --- code/Common/BaseImporter.cpp | 39 +++++++++++++++++++---------------- code/Common/Importer.cpp | 20 +++--------------- include/assimp/BaseImporter.h | 10 +++++++++ 3 files changed, 34 insertions(+), 35 deletions(-) diff --git a/code/Common/BaseImporter.cpp b/code/Common/BaseImporter.cpp index 87b385268..a37297b9a 100644 --- a/code/Common/BaseImporter.cpp +++ b/code/Common/BaseImporter.cpp @@ -229,27 +229,30 @@ void BaseImporter::GetExtensionList(std::set &extensions) { const char *ext0, const char *ext1, const char *ext2) { - std::string::size_type pos = pFile.find_last_of('.'); - - // no file extension - can't read - if (pos == std::string::npos) { - return false; + std::set extensions; + for (const char* ext : {ext0, ext1, ext2}) { + if (ext == nullptr) continue; + extensions.emplace(ext); } + return HasExtension(pFile, extensions); +} - const char *ext_real = &pFile[pos + 1]; - if (!ASSIMP_stricmp(ext_real, ext0)) { - return true; +// ------------------------------------------------------------------------------------------------ +// Check for file extension +/*static*/ bool BaseImporter::HasExtension(const std::string &pFile, const std::set &extensions) { + // CAUTION: Do not just search for the extension! + // GetExtension() returns the part after the *last* dot, but some extensions + // have dots inside them, e.g. ogre.mesh.xml. Compare the entire end of the + // string. + for (std::set::const_iterator it = extensions.cbegin(); it != extensions.cend(); ++it) { + // Yay for C++<20 not having std::string::ends_with() + const std::string extension = "." + *it; + if (extension.length() > pFile.length()) continue; + // Possible optimization: Fetch the lowercase filename! + if (0 == ASSIMP_stricmp(pFile.c_str() + pFile.length() - extension.length(), extension.c_str())) { + return true; + } } - - // check for other, optional, file extensions - if (ext1 && !ASSIMP_stricmp(ext_real, ext1)) { - return true; - } - - if (ext2 && !ASSIMP_stricmp(ext_real, ext2)) { - return true; - } - return false; } diff --git a/code/Common/Importer.cpp b/code/Common/Importer.cpp index b66059397..bdf64ac8f 100644 --- a/code/Common/Importer.cpp +++ b/code/Common/Importer.cpp @@ -637,24 +637,10 @@ const aiScene* Importer::ReadFile( const char* _pFile, unsigned int pFlags) { std::set extensions; pimpl->mImporter[a]->GetExtensionList(extensions); - // CAUTION: Do not just search for the extension! - // GetExtension() returns the part after the *last* dot, but some extensions have dots - // inside them, e.g. ogre.mesh.xml. Compare the entire end of the string. - for (std::set::const_iterator it = extensions.cbegin(); it != extensions.cend(); ++it) { - - // Yay for C++<20 not having std::string::ends_with() - std::string extension = "." + *it; - if (extension.length() <= pFile.length()) { - // Possible optimization: Fetch the lowercase filename! - if (0 == ASSIMP_stricmp(pFile.c_str() + pFile.length() - extension.length(), extension.c_str())) { - ImporterAndIndex candidate = { pimpl->mImporter[a], a }; - possibleImporters.push_back(candidate); - break; - } - } - + if (BaseImporter::HasExtension(pFile, extensions)) { + ImporterAndIndex candidate = { pimpl->mImporter[a], a }; + possibleImporters.push_back(candidate); } - } // If just one importer supports this extension, pick it and close the case. diff --git a/include/assimp/BaseImporter.h b/include/assimp/BaseImporter.h index 06b87f1e1..bf425a849 100644 --- a/include/assimp/BaseImporter.h +++ b/include/assimp/BaseImporter.h @@ -275,6 +275,16 @@ public: // static utilities const char *ext1 = nullptr, const char *ext2 = nullptr); + // ------------------------------------------------------------------- + /** @brief Check whether a file has one of the passed file extensions + * @param pFile Input file + * @param extensions Extensions to check for. Lowercase characters only, no dot! + * @note Case-insensitive + */ + static bool HasExtension( + const std::string &pFile, + const std::set &extensions); + // ------------------------------------------------------------------- /** @brief Extract file extension from a string * @param pFile Input file From bdde96867705d9cbfc0b95f5864d6bc6357c52fd Mon Sep 17 00:00:00 2001 From: Marco Feuerstein Date: Tue, 4 Jul 2023 12:29:17 +0200 Subject: [PATCH 04/10] Address reviewer comment. --- code/Common/BaseImporter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/Common/BaseImporter.cpp b/code/Common/BaseImporter.cpp index a37297b9a..d03b2adfc 100644 --- a/code/Common/BaseImporter.cpp +++ b/code/Common/BaseImporter.cpp @@ -244,7 +244,7 @@ void BaseImporter::GetExtensionList(std::set &extensions) { // GetExtension() returns the part after the *last* dot, but some extensions // have dots inside them, e.g. ogre.mesh.xml. Compare the entire end of the // string. - for (std::set::const_iterator it = extensions.cbegin(); it != extensions.cend(); ++it) { + for (auto it = extensions.cbegin(); it != extensions.cend(); ++it) { // Yay for C++<20 not having std::string::ends_with() const std::string extension = "." + *it; if (extension.length() > pFile.length()) continue; From 87cac888e474880efdacba4cddd28f83c582fd97 Mon Sep 17 00:00:00 2001 From: Marco Feuerstein Date: Tue, 4 Jul 2023 13:18:22 +0200 Subject: [PATCH 05/10] More simplifications. --- code/Common/BaseImporter.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/Common/BaseImporter.cpp b/code/Common/BaseImporter.cpp index d03b2adfc..39c93e4be 100644 --- a/code/Common/BaseImporter.cpp +++ b/code/Common/BaseImporter.cpp @@ -244,12 +244,12 @@ void BaseImporter::GetExtensionList(std::set &extensions) { // GetExtension() returns the part after the *last* dot, but some extensions // have dots inside them, e.g. ogre.mesh.xml. Compare the entire end of the // string. - for (auto it = extensions.cbegin(); it != extensions.cend(); ++it) { + for (const std::string& ext : extensions) { // Yay for C++<20 not having std::string::ends_with() - const std::string extension = "." + *it; - if (extension.length() > pFile.length()) continue; + const std::string dotExt = "." + ext; + if (dotExt.length() > pFile.length()) continue; // Possible optimization: Fetch the lowercase filename! - if (0 == ASSIMP_stricmp(pFile.c_str() + pFile.length() - extension.length(), extension.c_str())) { + if (0 == ASSIMP_stricmp(pFile.c_str() + pFile.length() - dotExt.length(), dotExt.c_str())) { return true; } } From bf38d67935ba3c7bf663c4bb8a5c79f47392c2c1 Mon Sep 17 00:00:00 2001 From: Marco Feuerstein Date: Thu, 13 Jul 2023 11:51:56 +0200 Subject: [PATCH 06/10] Fix detection of KHR_materials_specular. --- code/AssetLib/glTF2/glTF2Exporter.cpp | 2 +- test/unit/utglTF2ImportExport.cpp | 18 ++++++++++++------ 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/code/AssetLib/glTF2/glTF2Exporter.cpp b/code/AssetLib/glTF2/glTF2Exporter.cpp index f7fa9cd42..d4568fa31 100644 --- a/code/AssetLib/glTF2/glTF2Exporter.cpp +++ b/code/AssetLib/glTF2/glTF2Exporter.cpp @@ -730,7 +730,7 @@ bool glTF2Exporter::GetMatSpecGloss(const aiMaterial &mat, glTF2::PbrSpecularGlo bool glTF2Exporter::GetMatSpecular(const aiMaterial &mat, glTF2::MaterialSpecular &specular) { // Specular requires either/or, default factors of zero disables specular, so do not export - if (GetMatColor(mat, specular.specularColorFactor, AI_MATKEY_COLOR_SPECULAR) != AI_SUCCESS || mat.Get(AI_MATKEY_SPECULAR_FACTOR, specular.specularFactor) != AI_SUCCESS) { + if (GetMatColor(mat, specular.specularColorFactor, AI_MATKEY_COLOR_SPECULAR) != AI_SUCCESS && mat.Get(AI_MATKEY_SPECULAR_FACTOR, specular.specularFactor) != AI_SUCCESS) { return false; } // The spec states that the default is 1.0 and [1.0, 1.0, 1.0]. We if both are 0, which should disable specular. Otherwise, if one is 0, set to 1.0 diff --git a/test/unit/utglTF2ImportExport.cpp b/test/unit/utglTF2ImportExport.cpp index 91ac87ee5..ba1c859ad 100644 --- a/test/unit/utglTF2ImportExport.cpp +++ b/test/unit/utglTF2ImportExport.cpp @@ -60,7 +60,7 @@ using namespace Assimp; class utglTF2ImportExport : public AbstractImportExportBase { public: - virtual bool importerMatTest(const char *file, bool spec_gloss, std::array exp_modes = { aiTextureMapMode_Wrap, aiTextureMapMode_Wrap }) { + virtual bool importerMatTest(const char *file, bool spec, bool gloss, std::array exp_modes = { aiTextureMapMode_Wrap, aiTextureMapMode_Wrap }) { Assimp::Importer importer; const aiScene *scene = importer.ReadFile(file, aiProcess_ValidateDataStructure); EXPECT_NE(scene, nullptr); @@ -105,16 +105,19 @@ public: aiColor3D spec_color = { 0, 0, 0 }; ai_real glossiness = ai_real(0.5); - if (spec_gloss) { + if (spec) { EXPECT_EQ(aiReturn_SUCCESS, material->Get(AI_MATKEY_COLOR_SPECULAR, spec_color)); constexpr ai_real spec_val(0.20000000298023225); // From the file EXPECT_EQ(spec_val, spec_color.r); EXPECT_EQ(spec_val, spec_color.g); EXPECT_EQ(spec_val, spec_color.b); + } else { + EXPECT_EQ(aiReturn_FAILURE, material->Get(AI_MATKEY_COLOR_SPECULAR, spec_color)); + } + if (gloss) { EXPECT_EQ(aiReturn_SUCCESS, material->Get(AI_MATKEY_GLOSSINESS_FACTOR, glossiness)); EXPECT_EQ(ai_real(1.0), glossiness); } else { - EXPECT_EQ(aiReturn_FAILURE, material->Get(AI_MATKEY_COLOR_SPECULAR, spec_color)); EXPECT_EQ(aiReturn_FAILURE, material->Get(AI_MATKEY_GLOSSINESS_FACTOR, glossiness)); } @@ -143,7 +146,7 @@ public: }; TEST_F(utglTF2ImportExport, importglTF2FromFileTest) { - EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF/BoxTextured.gltf", false, {aiTextureMapMode_Mirror, aiTextureMapMode_Clamp})); + EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF/BoxTextured.gltf", false, false, {aiTextureMapMode_Mirror, aiTextureMapMode_Clamp})); } TEST_F(utglTF2ImportExport, importBinaryglTF2FromFileTest) { @@ -151,7 +154,7 @@ TEST_F(utglTF2ImportExport, importBinaryglTF2FromFileTest) { } TEST_F(utglTF2ImportExport, importglTF2_KHR_materials_pbrSpecularGlossiness) { - EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured.gltf", true)); + EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured.gltf", true, true)); } void VerifyClearCoatScene(const aiScene *scene) { @@ -223,13 +226,16 @@ TEST_F(utglTF2ImportExport, importglTF2AndExport_KHR_materials_pbrSpecularGlossi // Export with specular glossiness disabled EXPECT_EQ(aiReturn_SUCCESS, exporter.Export(scene, "glb2", ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured_out.glb")); + // And re-import + EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured_out.glb", true, false)); + // Export with specular glossiness enabled ExportProperties props; props.SetPropertyBool(AI_CONFIG_USE_GLTF_PBR_SPECULAR_GLOSSINESS, true); EXPECT_EQ(aiReturn_SUCCESS, exporter.Export(scene, "glb2", ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured_out.glb", 0, &props)); // And re-import - EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured_out.glb", true)); + EXPECT_TRUE(importerMatTest(ASSIMP_TEST_MODELS_DIR "/glTF2/BoxTextured-glTF-pbrSpecularGlossiness/BoxTextured_out.glb", true, true)); } TEST_F(utglTF2ImportExport, importglTF2AndExportToOBJ) { From 1e6c7063b6e5209c156a628a2cb3a1ea33598176 Mon Sep 17 00:00:00 2001 From: Steve M Date: Thu, 13 Jul 2023 20:28:48 -0700 Subject: [PATCH 07/10] Fix typos --- test/models/IRR/scenegraphAnim.irr | 2 +- test/models/IRR/scenegraphAnim_UTF16LE.irr | Bin 47408 -> 47404 bytes 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/test/models/IRR/scenegraphAnim.irr b/test/models/IRR/scenegraphAnim.irr index 1c6fd0ef4..2300ea18f 100644 --- a/test/models/IRR/scenegraphAnim.irr +++ b/test/models/IRR/scenegraphAnim.irr @@ -126,7 +126,7 @@ - + diff --git a/test/models/IRR/scenegraphAnim_UTF16LE.irr b/test/models/IRR/scenegraphAnim_UTF16LE.irr index b22aaf4b7906af22e1cb74617cd2cd312887e143..f6794351f77b67a498679d9809865b883acca8a5 100644 GIT binary patch delta 21 dcmdn+iD}IzrVTIDCihKon7l!mWwC+!BmjCF3GM&@ delta 21 bcmZ4UiD?56y-=GRu*PNb24$ATI_i@Ecx?&D From 0e7cd18c8bab64b9975e663cc4be8fd5485acabc Mon Sep 17 00:00:00 2001 From: Marco Feuerstein Date: Fri, 14 Jul 2023 09:37:48 +0200 Subject: [PATCH 08/10] Strip aws gcs version string. --- code/Common/BaseImporter.cpp | 33 ++++++++++++++++++++++++++++++--- test/unit/utImporter.cpp | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 64 insertions(+), 3 deletions(-) diff --git a/code/Common/BaseImporter.cpp b/code/Common/BaseImporter.cpp index efcc00d4f..d2ff4a9dd 100644 --- a/code/Common/BaseImporter.cpp +++ b/code/Common/BaseImporter.cpp @@ -59,6 +59,31 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include +namespace { +// Checks whether the passed string is a gcs version. +bool IsGcsVersion(const std::string &s) { + if (s.empty()) return false; + return std::all_of(s.cbegin(), s.cend(), [](const char c) { + // gcs only permits numeric characters. + return std::isdigit(static_cast(c)); + }); +} + +// Removes a possible version hash from a filename, as found for example in +// gcs uris (e.g. `gs://bucket/model.glb#1234`), see also +// https://github.com/GoogleCloudPlatform/gsutil/blob/c80f329bc3c4011236c78ce8910988773b2606cb/gslib/storage_url.py#L39. +std::string StripVersionHash(const std::string &filename) { + const std::string::size_type pos = filename.find_last_of('#'); + // Only strip if the hash is behind a possible file extension and the part + // behind the hash is a version string. + if (pos != std::string::npos && pos > filename.find_last_of('.') && + IsGcsVersion(filename.substr(pos + 1))) { + return filename.substr(0, pos); + } + return filename; +} +} // namespace + using namespace Assimp; // ------------------------------------------------------------------------------------------------ @@ -241,6 +266,7 @@ void BaseImporter::GetExtensionList(std::set &extensions) { // ------------------------------------------------------------------------------------------------ // Check for file extension /*static*/ bool BaseImporter::HasExtension(const std::string &pFile, const std::set &extensions) { + const std::string file = StripVersionHash(pFile); // CAUTION: Do not just search for the extension! // GetExtension() returns the part after the *last* dot, but some extensions // have dots inside them, e.g. ogre.mesh.xml. Compare the entire end of the @@ -248,9 +274,9 @@ void BaseImporter::GetExtensionList(std::set &extensions) { for (const std::string& ext : extensions) { // Yay for C++<20 not having std::string::ends_with() const std::string dotExt = "." + ext; - if (dotExt.length() > pFile.length()) continue; + if (dotExt.length() > file.length()) continue; // Possible optimization: Fetch the lowercase filename! - if (0 == ASSIMP_stricmp(pFile.c_str() + pFile.length() - dotExt.length(), dotExt.c_str())) { + if (0 == ASSIMP_stricmp(file.c_str() + file.length() - dotExt.length(), dotExt.c_str())) { return true; } } @@ -259,7 +285,8 @@ void BaseImporter::GetExtensionList(std::set &extensions) { // ------------------------------------------------------------------------------------------------ // Get file extension from path -std::string BaseImporter::GetExtension(const std::string &file) { +std::string BaseImporter::GetExtension(const std::string &pFile) { + const std::string file = StripVersionHash(pFile); std::string::size_type pos = file.find_last_of('.'); // no file extension at all diff --git a/test/unit/utImporter.cpp b/test/unit/utImporter.cpp index 98080c526..5ecc45e34 100644 --- a/test/unit/utImporter.cpp +++ b/test/unit/utImporter.cpp @@ -361,3 +361,37 @@ TEST_F(ImporterTest, unexpectedException) { EXPECT_TRUE(false); } } + +// ------------------------------------------------------------------------------------------------ + +struct ExtensionTestCase { + std::string testName; + std::string filename; + std::string getExtensionResult; + std::string hasExtension; + bool hasExtensionResult; +}; + +using ExtensionTest = ::testing::TestWithParam; + +TEST_P(ExtensionTest, testGetAndHasExtension) { + const ExtensionTestCase& testCase = GetParam(); + EXPECT_EQ(testCase.getExtensionResult, BaseImporter::GetExtension(testCase.filename)); + EXPECT_EQ(testCase.hasExtensionResult, BaseImporter::HasExtension(testCase.filename, {testCase.hasExtension})); +} + +INSTANTIATE_TEST_SUITE_P( + ExtensionTests, ExtensionTest, + ::testing::ValuesIn({ + {"NoExtension", "name", "", "glb", false}, + {"NoExtensionAndEmptyVersion", "name#", "", "glb", false}, + {"WithExtensionAndEmptyVersion", "name.glb#", "glb#", "glb", false}, + {"WithExtensionAndVersion", "name.glb#1234", "glb", "glb", true}, + {"WithExtensionAndHashInStem", "name#1234.glb", "glb", "glb", true}, + {"WithExtensionAndInvalidVersion", "name.glb#_", "glb#_", "glb", false}, + {"WithExtensionAndDotAndHashInStem", "name.glb#.abc", "abc", "glb", false}, + {"WithTwoExtensions", "name.abc.def", "def", "abc.def", true}, + }), + [](const ::testing::TestParamInfo& info) { + return info.param.testName; + }); From 3161f0e754252b04e88d69d4800c4faccfc045e5 Mon Sep 17 00:00:00 2001 From: Steve M Date: Fri, 14 Jul 2023 20:19:28 -0700 Subject: [PATCH 09/10] Introduce alternate versions with animations disabled to allow sucessful load --- test/models/IRR/scenegraphAnimMod.irr | 554 ++++++++++++++++++ test/models/IRR/scenegraphAnimMod_UTF16LE.irr | Bin 0 -> 47672 bytes 2 files changed, 554 insertions(+) create mode 100644 test/models/IRR/scenegraphAnimMod.irr create mode 100644 test/models/IRR/scenegraphAnimMod_UTF16LE.irr diff --git a/test/models/IRR/scenegraphAnimMod.irr b/test/models/IRR/scenegraphAnimMod.irr new file mode 100644 index 000000000..21408b245 --- /dev/null +++ b/test/models/IRR/scenegraphAnimMod.irr @@ -0,0 +1,554 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/models/IRR/scenegraphAnimMod_UTF16LE.irr b/test/models/IRR/scenegraphAnimMod_UTF16LE.irr new file mode 100644 index 0000000000000000000000000000000000000000..7384ae29ada86ec6b7aaa1952ca7138f0280983f GIT binary patch literal 47672 zcmeHQ+j87C62)t_YX2e0^D5ERwyLz7@+D4rD~VmUa`THzcPlGPu94(*_TzW=9AYRE z$9?18yEpF4eeT}5BR6xG?$lklbN6@mrCW1f zxmA3Bi*((@Y@WZS15IW(&zZ|zwp=3@cW*-!e@qZ`|cW7M=0q_d{+E^Isf(C zoq*yw%D+Jw()w|J{bkXTJ+$b0{>u#QxxjP$R+k`r}p8!6_g1}s`rVv<~iDMRmjY0&6?Z9XC1WJf^B!V zxV}@gs!Olw-=-Jf9!J8F;Ef;OWzSu`;Z1c%-&3vF$GdYhh4T3sa-n?ojTTT>aGa|e zIrgqG4#OJn7kcFa_c=CB@pcb!=L{eAwG;7{Y}tEBLG{i@XbpAOiF;H~*mJ3OP`ZUZ zS99bE_)*b#ic-JNdpLOz_TA$`a+d~w;(c)!&(81`N8nPs<}Q8Bj}-O=&H~j($tvEK zpP-k1p1&o>akuuU-r1!s$LI?eh3vwf^B8yEK}WW!lhV4|Dm20d#-w^ftJeFFC$%nh zl&-nbJ{!Gieu+8psF0$rw~`3w=x}ai|Fc^B(mgh6-Iz-`F7NcbwBx>jK3&0#&vxu# zT%OLyE2U41fWMYDMOD_9Ru+U+o=@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3T32X_?jsT z-|4?ziZigz&7W?aloiMNu&WigHwjOr;);c@kU7S4^C}(DwEC=f7UP{Tb)9`wx?GD)U)*M zOnr+t-Euh6?YFS2t~-G7teNsnG>0q-Ri1^i(YobXr0Z4|Shu=ETP4IscF`xRY&X^Z zedq_CW5G2_yyC8bhZqHGIFpJejZBx4W0%}grYXz#@k-Szw?`L9- zs2CckebaH*JZKNJKaDuzq_qDq#3@ck&16&1QIeU0j*`wWI%$+?JQ<~FjVGrxt?^`) zrZq%f8L7(|9_@4Ei5E|?R$y5^=OJ>(%RlY&SYBHfpR=r)-~DROKBtdIbjj^kGeS4N z@b>zg2k8NAQ5Xl)LrFPLhB(E$e5oezjr@0jK z362&{2|^f{v2TFgj_UX*?OFX^khR zG_CPum8LaBUfJ)=erMb795+LR=e6&{l3dn)mj47j?qp7s{-ii3!&7g^o)wPYXYbuq zjz*V#cj;?vA!mfSB6soO4$A9A%MwwS{VVH9nhOpG3xd>f!#cS>u+^_gOJ{iP85OI2g~{TNWlx?2V)U51gY?r{1&_^*;E^#l%;D zY*W5O1&NHamw8!w{F^H*w;_EBC8J;qS5GwiKSZ;a8(8T^Izj5vf>apYTJ9m5dm zI30y#OhHE>6jRVq(iui4jY5wnqcpAYrYf$QAKiZgb#3*P?$iv;`} literal 0 HcmV?d00001 From 46be2d3380c26948883ebbaf95c70681a16ef714 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Leclercq?= Date: Sat, 15 Jul 2023 15:54:15 +0200 Subject: [PATCH 10/10] Remove /WX from CMakeLists for MSVC --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 224f6e48f..dfaa2b791 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -286,9 +286,9 @@ IF ((CMAKE_C_COMPILER_ID MATCHES "GNU") AND NOT MINGW) ELSEIF(MSVC) # enable multi-core compilation with MSVC IF(CMAKE_CXX_COMPILER_ID MATCHES "Clang" ) # clang-cl - ADD_COMPILE_OPTIONS(/bigobj /W4 /WX ) + ADD_COMPILE_OPTIONS(/bigobj) ELSE() # msvc - ADD_COMPILE_OPTIONS(/MP /bigobj /W4 /WX) + ADD_COMPILE_OPTIONS(/MP /bigobj) ENDIF() # disable "elements of array '' will be default initialized" warning on MSVC2013