Closed tigrazone closed 2 months ago
ok, I will check this models, gltf import have some known issues need to fix 😆
Maybe is better to use fastgltf but without draco yet? I post to author and he plan to implement draco in few weeks
seems it is tinygltf's draco issue, I resave with blender no compression, it renders ok
Maybe it is not draco problem. I will read success reference code to import glb/gltf and maybe fix it
sketchfab downloaded glb have the same problem, and it will be ok resaved by blender. I just notice that sketchfab glb have some wireframe data and the indices always be unsigned int. maybe some corner-case when using tinygltf there.
and yes, sketchfab not use draco compress.
buggy still have some TRS order issue, this is the known issues, I will work on it tomorrow~
TRS order is ok, but some glb provide matrix directly, fixed in https://github.com/gameknife/gkNextRenderer/commit/fedc8f1571ead276dc66b5d8b350ae32029792c5
Maybe is better to use fastgltf but without draco yet? I post to author and he plan to implement draco in few weeks
the tinygltf is a widely used library, performance is acceptable in release build. currently bugs was the wrong way to use it, I think is not the time to change it~
I can try to use fastgltf in experimental branch and compare. One of goods of tastgltf is supported meshopt compression. I dont find supported meshopt with tinygltf
Also yesterday I find one of bugs is wrong camera import. Maybe matrix wrong use or so
I checked last commits and now glb import doesnt broke vertices and model imported ok. But camera imported sometimes wrong - wrong fov, position wrong. Please get camera info directly from glb file without presets or something else
the glb above seems has no camera,so I use the obj's auto focus
on some files vertices and whole model imported as broken scene for reproduce https://sketchfab.com/3d-models/rank-3-police-unit-d7698f6a7acf49c68ff0a50c5a1b1d52 one more scene https://sketchfab.com/3d-models/spherical-ship-a1bed2ab95544638ba24589679a0e898 and https://sketchfab.com/3d-models/free-character-bot-blast-r-325-by-oscar-creativo-7c3843d203aa4044ae38f7a74645b345 and https://sketchfab.com/3d-models/sci-fi-buggy-085bd97876a64eacbc041299ac945e9c ... many of