Commit Graph

16 Commits (b87f67db4c10d568637d19a35bd986db49e92ceb)

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
Krishty 9dc66b0003 removed dead code
BaseImporter::GetExtensionList() is not a virtual function; overriding it is useless. This probably stemmed from a misunderstanding.
2021-04-23 15:15:21 +02:00
Kim Kulling 9e8dbd0ca5 Update copyrights to 2021. 2021-02-28 12:17:54 +01:00
Kim Kulling ef9a78b49d
remove unused attributes. 2020-09-28 20:34:44 +02:00
Kim Kulling d6892b3f58 Merge branch 'master' into pugi_xml 2020-09-25 21:00:09 +02:00
Kim Kulling c1f50e116a fix next unittests. 2020-09-11 00:46:29 +02:00
Kim Kulling 0b8ed5c03a fix crash when x3d is empty 2020-09-02 21:49:40 +02:00
kimkulling 582a8b1887 Fix xml-migration bild. 2020-08-27 17:05:09 +02:00
Kim Kulling 56381241c5 move hasAttribute to XmlParser scope. 2020-08-19 00:19:56 +02:00
Kim Kulling 554ed1bf91 next step.s 2020-08-18 20:44:06 +02:00
Malcolm Tyrrell 0f6127e90e No need to build strings. 2020-08-18 18:21:20 +01:00
Malcolm Tyrrell b7c789da67 Stop concatenating std::strings. Use formatter. 2020-08-18 17:35:08 +01:00
kimkulling 7e93ae4428 3MF: Migration. 2020-08-18 16:54:29 +02:00
Kim Kulling 394651e640 x3d: migration of goups. 2020-08-10 22:13:45 +02:00
Kim Kulling 58b81a2590 start migrating X3D. 2020-07-26 10:17:21 +02:00
Kim Kulling f8e6512a63 Move format importer and exporter into its won folder. 2020-05-02 15:14:38 +02:00