Commit Graph

139 Commits

Author SHA1 Message Date
Jerome St-Louis
0be7cdd6db glTF2: Avoid lookups for generating IDs (#6120)
* glTF2: Reduce lookups for generating IDs
- closes https://github.com/assimp/assimp/issues/5661
2025-11-13 10:50:26 +01:00
copycd
536cd59807 + Only up to recognizing the KTX2 compressed image as a texture object is handled. (#6139) 2025-05-08 21:28:30 +02:00
krishty
88959b2be7 Fix Whitespace (#6063)
* Fix Whitespace

No functional changes. This commit removes trailing spaces, undesired line breaks, and formatting screwups.

* Remove more useless line breaks in license (500 out of 630 license copies do NOT use double line breaks here)

---------

Co-authored-by: Krishty <krishty@krishty.com>
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2025-03-26 00:12:55 +01:00
Kim Kulling
45898eee55 Refactorings: glTF cleanups (#6028) 2025-03-05 21:37:47 +01:00
1323236654
bc47836a8f fix: reduce gltf2 export time (#5972)
* fix: reduce gltf2 export time

* fix: use std::less<> in std::map

---------

Co-authored-by: huangxinchuang <huangxinchuang@pointcode.com>
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2025-01-25 21:50:33 +01:00
Lutz Hören
ba4455c9c0 Added GLTF Extension KHR_materials_anisotropy (#5950)
* added gltf extension KHR_materials_anisotropy

* Update glTF2Importer.cpp

---------

Co-authored-by: lutz.hoeren <lutz.hoeren@redplant.de>
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2025-01-21 00:02:46 +01:00
BurntRanch
2a0969d4d9 Add customExtension support to the scene (#5954)
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2025-01-17 16:09:23 +01:00
HandsomeXi
164a5ae8cf bugfix: Fixed the issue that draco compressed gltf files cannot be loaded normally (#5882) (#5883)
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2024-12-04 22:03:57 +01:00
Florian Born
76de7cedf4 A fuzzed stride could cause the max count to become negative and hence wrap around uint (#5414)
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2024-07-23 16:17:54 +02:00
Kim Kulling
193f2c5d87 Fix compile warning (#5657) 2024-07-08 17:09:17 +02:00
Kim Kulling
01231d0e60 Add 2024 to copyright infos (#5475) 2024-02-23 22:30:05 +01:00
Florian Born
f59a5fab1a More GLTF loading hardening (#5415)
Co-authored-by: Kim Kulling <kimkulling@users.noreply.github.com>
2024-02-04 21:23:31 +01:00
Alexey Medvedev
a72289b327 glTF KHR_materials_specular fixes 2023-12-11 11:09:18 +01:00
Futuremappermydud
a0b3df6dbd Fix target names not being imported on some gLTF2 models 2023-12-04 21:11:55 +01:00
Marco Feuerstein
37a1366fb7 Add missing rapidjson headers. 2023-07-21 11:33:06 +02:00
Kim Kulling
466f6960ac Merge branch 'gltf2_metadata_export' of https://github.com/C-Tech-Development-Corp/assimp into C-Tech-Development-Corp-gltf2_metadata_export 2023-05-30 08:14:49 +02:00
Kim Kulling
b7a8c4ba75 Update glTF2Asset.inl 2023-05-23 10:33:14 +02:00
Adam Beili
e193220ad8 Merge branch 'master' into refactor/KHR_material_specular 2023-04-06 02:42:18 +02:00
Adam Beili
8ac0af5c58 . 2023-03-26 17:13:16 +02:00
Adam Beili
c9177b7811 Merge branch 'master' into refactor/KHR_material_specular 2023-03-24 21:47:19 +01:00
Florian Born
60cefdd549 Jan's fedback 2023-03-10 12:10:38 +01:00
Florian Born
dfd70b5c10 GLTF Importer: Build a list of the actual vertices so it works well with shared attribute lists 2023-03-09 19:06:58 +01:00
Krishty
3d3e856925 Trim Trailing Whitespace 2023-01-16 09:12:35 +01:00
Adam Beili
54068637ee Merge branch 'master' into refactor/KHR_material_specular 2022-11-29 17:35:52 +01:00
Kim Kulling
8fb7ba3444 Merge branch 'master' into modernize-smartptrs-literals 2022-11-29 09:58:17 +01:00
Adam
822b240694 Support both pbrSpecGlos and materials_specular 2022-11-08 23:09:50 +02:00
Aaron Gokaslan
ccfb175460 Apply various clang-tidy checks for smartprs and modern C++ types 2022-11-08 11:03:55 -05:00
Adam Beili
945d93b46a fixed indentation 2022-11-04 09:37:28 -07:00
Adam
852ea8325c Added support for KHR_materials_emissive_strength
according to spec https://github.com/KhronosGroup/glTF/tree/main/extensions/2.0/Khronos/KHR_materials_emissive_strength
2022-11-03 23:11:21 +02:00
Bengt Rosenberger
abfe8ad413 Added suggested changes and fixed automated check errors 2022-08-01 14:39:10 +02:00
Bengt Rosenberger
da58fbe8fb Got rid of gltf2::ExtrasValue and used gltf2::CustomExtension instead 2022-08-01 14:12:27 +02:00
Bengt Rosenberger
99c3104588 Rewrote gltf2 node extras import and added node extras export.
No support for AI_AIVECTOR3D metadata type. No support for json arrays of metadata, just json objects.
2022-08-01 14:12:27 +02:00
xiaohunqupo
de6e90a657 Fix commit error 2022-03-31 15:36:57 +08:00
xiaohunqupo
2152aae2a3 Fix compile error due to namespace conflicts in VC140. 2022-03-31 15:34:49 +08:00
Promit Roy
765b38cf04 Update glTF2Asset.inl
Fixing mistakes in attribute names for GLTF. This causes attribute index to not be parsed out correctly (e.g. JOINTS_1) and fails the scene load.
2022-03-16 16:49:45 -04:00
Viktor Kovacs
c71f4bc95a Merge branch 'master' into common_base64 2022-01-11 18:46:08 +01:00
Kim Kulling
50c7301a38 Update copyrights 2022-01-10 21:13:43 +01:00
kovacsv
bbe12240ca Move Base64 encode/decode functionality to the common folder. 2022-01-02 19:47:43 +01:00
Max Vollmer (Microsoft Havok)
0015823bef Reject files with an invalid byteLength value 2021-11-26 13:01:15 +00:00
Jan Krassnigg
1a5d66714f Prevent out-of-range memory writes by sparse accessors
This turned up during fuzz testing. Corrupted data would make assimp write to random memory locations, leading to subsequent crashes.
2021-11-25 11:20:26 +01:00
ruyo
60bfde78eb Fixed an incorrect indeiciesType in the glTF2 sparse accessor. 2021-11-21 23:23:22 +09:00
Kim Kulling
e2ccd17494 Fix typo 2021-11-12 11:20:22 +01:00
Kim Kulling
157e032bde Fix small findings
- Merge anonymous functions into one block.
- Some reformattings
2021-11-12 11:08:19 +01:00
Kim Kulling
37c81e7a28 Merge branch 'master' into MalcolmTyrrell/jsonSchemaSupport 2021-11-12 10:37:19 +01:00
RichardTea
aaae3e3a10 size_t is 32bit on some platforms
Also assert if size_t is smaller than uint32_t (probably not necessary)
Note: 32bit builds will crash OOM if a really large model is loaded, as cannot allocate that much in total, let alone contiguously.
2021-11-08 15:05:20 +00:00
RichardTea
9433fc526a Apply clangformat 2021-11-08 14:42:21 +00:00
RichardTea
69cafe64b4 Cap glTFv1 & 2 json size to ~4GB
Ensures size_t cannot overflow
Limits the maximum contiguous memory allocation to something plausible.
2021-11-08 14:41:13 +00:00
Kim Kulling
8c0b869998 Merge branch 'master' into MalcolmTyrrell/jsonSchemaSupport 2021-10-28 13:38:41 +02:00
Malcolm Tyrrell
ceddfe19d8 Add comment with link to schema repo. 2021-10-07 10:01:32 +01:00
Malcolm Tyrrell
a283a255a5 Allow schema checking of glTF2 file. 2021-10-07 10:01:32 +01:00