Chapter 8 importing my own glTF models

Hey I’m loving your book. I’ve just finished chapter 8 and wanted to import some of my glTFs which I have exported from blender. But the program won’t run. On line 767 in GLFTAsset.swift, I am getting a Fatal error saying Vertex attribute joints(6) is missing from the vertex descriptor. I was wondering if there was a fix to this that I was missing and that you could help with.

re: Chapter 8 importing my own glTF models

@harrymorris Thanks for coming to the forum. I’ll reply later, but I was wondering if you’re able to share privately a glTF that doesn’t work?

The glTF import provided with the book is unfortunately not a full implementation. There is a full import and Metal renderer, but in Objective C, by Warren Moore at GitHub - warrenm/GLTFKit: An Objective-C glTF 2.0 loader and Metal-based renderer.

Thank you very much for this book, I can’t wait to finish it.
As the the reader before me I am trying to load my own glTF model and Im getting:
WARNING! - Attribute: TEXCOORD_1 not supported
for all the 80 materials, which are in a subfolder textures.
I tried Mr. Moore glTFviewer and it worked.
How can I use his loader with your chapter 8 code.
Thank you in advance

@mjeragh - Unfortunately you can’t easily use Warren Moore’s excellent glTFViewer with the book’s code. The book’s importer and Warren’s importer read glTF, but they place the results into completely different data structures.

The book’s importer is a cut-down version, that doesn’t take into account all the available things in glTF.

If you are feeling more confident with Metal, it would be an excellent lesson to examine and compare the structure of both importers. Don’t be put off by the Objective C in Warren’s glTFKit!

I’m having the same issue. Were you able to find a solution?
Thank you in advance

Im having the same problem as @harrymorris, did you have a solution you can please share.
Thank you in advance

@mjeragh - unfortunately not at this time. The glTF importer is a limited one, which won’t work on more complex glTF files.