jQuery easing function — variables' comprehension

后端 未结 5 881
无人共我
无人共我 2020-11-30 01:00

How does the easing function for jQuery work? Take for example:

easeInQuad = function (x, t, b, c, d) {
    return c*(t/=d)*t + b;
};

How d

5条回答
  •  伪装坚强ぢ
    2020-11-30 01:36

    Looked through the 1.11 jquery code. The x parameter seems to mean 'percent', independent from initial time value. So, x is always (0 <= x <= 1) (means abstract coefficient), and t is x * d (means time elapsed).

提交回复
热议问题