Hi, thanks for sharing. I’ve seen that post and this only works for one dimesional properties.
If you want to handle multidimensional ones, there are 3 more kinds that need special handling for each case.
PropertyValueType.SHAPE, where average speed is always 1
PropertyValueType.ThreeD, PropertyValueType.TwoD and PropertyValueType.TwoD where each dimensions has its own average speed (this is the more similar to the example)
PropertyValueType.ThreeD_SPATIAL, PropertyValueType.TwoD_SPATIAL, where, to get the average speed, you need to calculate the length of the spatial curve and divide it by the duration.
In addition to that, for the third case, influence in not well reported in some cases, since AE limits this curve as not to have negative values. So, I made a script to find the real influence.
I made an AE to html animation exporter during the last 8 months and I’ve just shared it on github, if you want to see the code.
It’s at https://github.com/bodymovin/bodymovin
There are some examples of animations exported from after effects.
If you’re still working on this and want to exchange some ideas, I’d be glad to. It has been a long lonely road to get to this point 🙂