开发者

CAKeyframeAnimation - move along path and use easing

Is it possible to use CAKeyframeAnimation to move something along a path and at the same time use some sort of eas开发者_Go百科ing so there is acceleration or deceleration? I know there is timingFunctions and keyTimes, but I don't see how they would work if you are simply moving along a path.


Something like

anim.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseOut]

?

Or swift 5:

anim.timingFunction = CAMediaTimingFunction(name: CAMediaTimingFunctionName.easeInEaseOut)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜