You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I'm wondering what would be the best way to add support for custom glTF extensions.
I suppose I could fork your glTF repository and add my schema files there, and then also fork cesium-native add reference them in glTF.json - but that complicates things a bit more than I had hoped. Are there any other ways, or would you consider adding support for a custom extension folder and config file, so that I could call:
Update: Ok, so while the generated JsonHandlers are output as separate files, that's not the case for the Json-writer code - which are a collection of "writeJson" functions inside ModelJsonWriter.cpp
So I guess this means that the only way of adding custom extensions would be to fork these two repositories then, right?
The text was updated successfully, but these errors were encountered:
Yeah I think the two forks are the only option right now. Otherwise, as you suggested, the code generator needs to be extended to support externally-defined extensions. That'll likely require a bit of refactoring.
@kring Yeah. For generating the extension class files and JSON reader code it would maybe not be that much work, but the code generation output for the JSON writers would have to be changed quite a bit..
But thanks for answering! I've forked both repos now, and that worked fine for me :) So should we close this issue, or is it worth keeping it open?
And just in case other users who want to do the same read this issue someday in future, this is what I did:
Forked the glTF repository ("tree/3d-tiles-next" branch for 3d-tiles next) and added my schema.json files to new a folder inside "extensions/2.0/Vendor"
Forked cesium-native and replaced the Cesium's glTF-repo URL with our own fork in package.json, and also modified glTF.json by adding our extension to "extensions" and added class name overrides under "classes".
Hi, I'm wondering what would be the best way to add support for custom glTF extensions.
I suppose I could fork your glTF repository and add my schema files there, and then also fork cesium-native add reference them in glTF.json - but that complicates things a bit more than I had hoped. Are there any other ways, or would you consider adding support for a custom extension folder and config file, so that I could call:
Thanks for reading!
Update: Ok, so while the generated JsonHandlers are output as separate files, that's not the case for the Json-writer code - which are a collection of "writeJson" functions inside ModelJsonWriter.cpp
So I guess this means that the only way of adding custom extensions would be to fork these two repositories then, right?
The text was updated successfully, but these errors were encountered: