michaelvillar / dynamics.js

Javascript library to create physics-based animations
http://dynamicsjs.com
7.57k stars 414 forks source link

The pin example grows over time #20

Open catamphetamine opened 8 years ago

catamphetamine commented 8 years ago

Open this example http://dynamicsjs.com/examples/pin.html

And leave it for ~10 minutes. In my case (Chrome, Windows, DevTools open) the svg slowly grows bigger than the .pin. Maybe that's because the previous transform3d is not identity matrix when the new transform3d is applied.

michaelvillar commented 8 years ago

Yes definitely a problem. One solution would be to have an optional from parameter to setup attributes at their initial position. I'm not sure I'll work on that soon.

dalisoft commented 7 years ago

This issue comes from performance.now and rAF timing. With date.now this issue will be fixed