Bru*_*uno 10 javascript internet-explorer bezier jquery-animate
我的目标:
路径http://i50.tinypic.com/dwwhhy.jpg
我考虑过的
我的计划
我的问题
vsy*_*ync 14
有一个很小的脚本(基于SVG),只适用于不是直线的动画, 
 
称为pathAnimator(2kb),它非常小而且效率很高.
不需要jQuery.
var path = "M150 0 L75 200 L225 200 Z";         // an SVG path
    pathAnimator = new PathAnimator( path ),    // initiate a new pathAnimator object
    speed = 6,              // seconds that will take going through the whole path
    reverse = false,        // go back or forward along the path
    startOffset = 0,        // between 0% to 100%
    easing = function(t){ t*(2-t) };    // optional easing function
pathAnimator.start( speed, step, reverse, startOffset, finish, easing);
function step( point, angle ){
    // do something every "frame" with: point.x, point.y & angle
}
function finish(){
    // do something when animation is done
}
(使用fastdom甚至可以提高效率)
我建议你使用GSAP:http://www.greensock.com/get-started-js/
有了它你可以处理时间表,这是一个bezier插件:http://api.greensock.com/js/com/greensock/plugins/BezierPlugin.html
问候
| 归档时间: | 
 | 
| 查看次数: | 15177 次 | 
| 最近记录: |