vpenades / SharpGLTF

glTF reader and writer for .NET Standard
MIT License
454 stars 72 forks source link

Support KHR_animation_pointer extension #172

Open issacclee opened 1 year ago

issacclee commented 1 year ago

Hi,

I'm looking to implement the support for KHR_animation_pointerextension(which is close to getting ratified).

One of the major changes this extension implies is the ability to set animation.channel.target.path as "pointer". I was wondering does that mean we have to add the pointer path definition to the generated gltf.g.cs file and modify the AnimationChannelTarget class to accommodate the new target path type?

vpenades commented 1 year ago

Most probably yes. Another alternative is, given the path seems to be quite "open", I could consider converting it to a string, but then it would break the APIs.

vpenades commented 1 year ago

Looking at the extension. The extension itself its tiny, but its implications are huge across all the architecture of glTF

So it's not enough to simply add the extension. After adding it, suddenly, you have to make all the properties that can be targeted by this extension, "animation aware" .... it makes pretty much anything within the scene animatable

issacclee commented 1 year ago

Looking at the extension. The extension itself its tiny, but its implications are huge across all the architecture of glTF

So it's not enough to simply add the extension. After adding it, suddenly, you have to make all the properties that can be targeted by this extension, "animation aware" .... it makes pretty much anything within the scene animatable

I agree, it will have huge impact on the current implementation. If you take all the necessary validation that needs to be perform into account.