Search code examples
iphonecore-animation

How do I use a timing function within an animation on the iPhone?


I want to use a timing function lets say kCAMediaTimingFunctionEaseInEaseOut

My aim is I have start point (X1,Y1) and end point (X2,Y2) and I want a ease function which will provide the easing functionality over this points range. Like varying the (X,Y) range and giving me a curve from start to end.

How to do that in iPhone. Like in the following article

http://www.the-art-of-web.com/css/timing-function/

we can see the blocks moving, I want something like that.


Solution

  • This post is a good starting point for you:

    http://icodeblog.com/2009/07/23/nstimer-the-poor-mans-threading-code-snapshot/