is not all fastgltf::Extensions is supported?
tigrazone opened this issue · 9 comments
I change
Line 733 in 5aa08e2
to
fastgltf::Parser parser((fastgltf::Extensions) ~0);
to support all possible extensions but not all scenes loaded.
I checked scenes from https://github.com/gkjohnson/3d-demo-data and without my change I have error is Extensions not supported but now where is no messages but some scenes not loaded.
How to fix it?
One more question. Is it possible to make example how to use fastgltf with vulkan raytracer?
And one more question.
Is fastgltf support more extensions then tinygltf?
The extension bits passed to the constructor of Parser are meant to provide a list of extensions the renderer supports. The fastgltf parser itself supports nearly all official KHR extensions and some EXT extensions, which it will try to load if the user asks for it. Both gl_viewer
and this Vulkan renderer don't support all extensions, and therefore I don't ask for them to be loaded. If a glTF file requires one or more extensions I don't support, the renderer can't load/render the scene correctly. This is different if the glTF file only marks the extensions as being used, or (in different words) the extension is optional. In those cases the Parser will not return an error, even if the extension bits were not passed. I noticed that you already reported exactly the same thing as a "bug" before: spnda/fastgltf#34. Please go over this answer and my previous answer again, and perhaps use some translator if you're having difficulties understanding it, as the behaviour you're describing is the intended behaviour.
Is fastgltf support more extensions then tinygltf?
Out of the box, yes, since fastgltf natively supports and loads nearly all KHR and many popular EXT extensions. With tinygltf you need to load everything manually, but you could load any extension that way. I am considering adding an extension parse callback if you need some extension that fastgltf doesn't support out of the box.
Is it possible to make example how to use fastgltf with vulkan raytracer?
I think as an example that could become quite difficult, as it would quickly become far too complex to be classified as an example in my opinion. However, my goal with this project is actually to implement a hybrid renderer that uses mesh shading and/or ray tracing using the Vulkan extensions, which could be used as a reference for a few advanced features of fastgltf. And the code in this repository is still very basic and is missing a lot of things compared to the OpenGL example, and I only made this public because I had an issue where I wanted somebody to check my code. I decided not to put this into the fastgltf repository as there are a lot of dependencies and a lot of code.
As i understand by your reference to my previously asked question is EXT_meshopt_compression is unsupported yet or how to make it supported by vk renderer and fastgltf?
As a tester of vk_gltf_viewer, i have lack of mouse control
As a tester of vk_gltf_viewer, i have lack of mouse control
Mouse control is only active when the middle mouse button is pressed, kinda like a toggle between UI interaction and movement.
As i understand by your reference to my previously asked question is EXT_meshopt_compression is unsupported yet or how to make it supported by vk renderer and fastgltf?
EXT_meshopt_compression
is fully supported by fastgltf. The gl_viewer in the fastgltf repository and this Vulkan renderer both, however, don't support the extension. To load the buffers from that extension, you need to call some decode functions from the mesh optimizer library. I will, in the coming days, add support for it in this renderer as I already use meshopt for meshlet generation anyway.
Thank you!
Support of EXT_meshopt_compression can be a big plus over tinygltf which cant open these files by default.
And maybe project like https://github.com/nvpro-samples/vk_shaded_gltfscene can promote fastgltf
An example of how to use EXT_meshopt_compression with fastgltf can now be found in this repo. Added with commit 38a0c5a. I had to change some things with the buffer data adapter interface in fastgltf, so this change requires the latest revision of fastgltf. I will add a section to the fastgltf documentation on how to implement this yourself soon.
commit 38a0c5a
works better but new issue.
when I select camera, WASD and mouse move locked and dont work. It is not good. Camera selection is not camera movement lock
when I select camera, WASD and mouse move locked and dont work. It is not good. Camera selection is not camera movement lock
Intended behaviour, as the location and rotation of the camera are defined by the glTF file. The code goes through the node hierarchy to find the viewMatrix, and therefore applies transforms as is with meshes. Changing that is difficult and is not in line with what glTF intends.
Maybe better to copy saved camera position and unlock camera for move from keyboard and mouse?