Commit Graph

14 Commits (628cba9490c067aa811a24f1943529bcfb490c51)

Author SHA1 Message Date
Krishty b00de10eb3 Simplified importer search and fixed a few bugs
The search for a matching importer had a few issues, see #3791. There were two different mechanisms to determine whether an importer accepts a specific file extension:
1. `aiImporterDesc::mFileExtensions`, which was forwarded to the UI via `BaseImporter::GetExtensionList()`.
2. `BaseImporter::CanRead()` when called with `checkSig == false`, which determines whether to actually use that importer.
Both were redundant and got out of sync repeatedly. I removed 2. completely and replaced it with 1., thereby syncing UI/import and shortening all `BaseImporter::CanRead()` implementations.

Further bugfixes:
- fixed glTF2 importer throwing exceptions when checking whether it can load a file
- removed `BaseImporter::SimpleExtensionCheck()` because it is no longer used and had a bug with case sensitivity

Since the `checkSig` parameter in `BaseImporter::CanRead()` is now useless, it can be removed completely. I’m not sure if this would break ABI compatiblity, so I’ll submit it with a later pull request.
2021-04-24 00:17:50 +02:00
Kim Kulling 9e8dbd0ca5 Update copyrights to 2021. 2021-02-28 12:17:54 +01:00
Jukka Maatta 6848a18999 Fix for issue #3445
Add const to avoid creating a temporary copy.

This should fix the cmake compilation error on XGLLoader.cpp shown in bug #3445

The fix is similar to commit bbe6f7f213
2020-10-13 21:56:43 +03:00
Kim Kulling 50d21e08f3
fix memoy leak. 2020-09-30 12:05:32 +02:00
Kim Kulling c598a12340
Remove unused variable. 2020-09-28 09:15:56 +02:00
Kim Kulling 31f3812241 XGL: fix import of node values. 2020-09-10 21:03:02 +02:00
kimkulling 6ec07e4dc7 XGL: next steps. 2020-09-10 17:31:30 +02:00
Kim Kulling 73fa2cbe88 Fix memory handling of xml-nodes in the parser. 2020-09-01 21:48:50 +02:00
kimkulling 6a8edb21f8 fix merge issues 2020-08-18 17:41:37 +02:00
Kim Kulling 394651e640 x3d: migration of goups. 2020-08-10 22:13:45 +02:00
Kim Kulling b1369d0912 next steps. 2020-07-02 15:18:59 +02:00
Kim Kulling 6205af4efb replace NULL and avoid ai_assert with more than 2 tests. 2020-06-23 21:05:42 +02:00
Kim Kulling 2be731d1bf Merge branch 'master' into pugi_xml 2020-05-22 10:09:46 +02:00
Kim Kulling f8e6512a63 Move format importer and exporter into its won folder. 2020-05-02 15:14:38 +02:00