Constant interpolation animation on sketchfab

animation
3d

(Mrchlblng) #1

@flumba @cpt.mcbacon,

we really loved your respective models https://sketchfab.com/models/bd47f3140b914cf19fcd5ddb84922a28 and https://sketchfab.com/models/ca461a8fbd03469aadaa1a4757cfc13b and saw your issues about how the animation renders in sketchfab. To be honest, I think you must be quite the first to use constant interpolation on sketchfab (or at least the first to notice those issues). And it looks like a bug indeed.

To give a bit of an overview, we bake animations (using the fbx sdk or blender 'native' code) as it gives us the assurance that the interpolation will be correct and also the baked data is easy to compress so it feels like the best thing to do on the web. We then use linear interpolation on the baked frames.

The issue is that we uniformly bake at 30 fps so if the curve has a "plateau" change in between (baked) frames, it will then be linearly inteprolated on sketchfab and will produce 'short' glitches.
We're working on a fix in both our fbx and blender processing pipeline to fix this.

Thanks a lot for your awesome models!


(Flumba) #2

Hey, sounds great! Constant interpolation isn't something I use every day but it's good for performance saving tricks and stuff. In the case of the carrot counter, there's just one properly rigged carrot and once a carrot lands it gets swapped with a static one and the same rigged carrot goes back underground to become the next one :smiley: Frame-by-frame animation like @cpt.mcbacon is a really nice use case too, and something that is becoming more popular so support for it would be awesome!


(Cpt Mcbacon) #3

@mrchlblng that's so nice of you for looking into this. I didn't think it was such a big issue, since not many people use it, so I didn't want to feature-creep you guys, haha!
I just realized, after seeing @flumba's model (which is awesome, btw!), that the technique can be really helpful in cartoony/snappy animations.
If it's any help: I also tried doing linear interpolation on the frames and duplicating them until the next frame, but I think that the duplicates got removed during the optimization.

Cheers and thanks!
Tudor.