Setting AnimationCurve for implicit animations
Setting AnimationCurve for implicit animations
- Subject: Setting AnimationCurve for implicit animations
- From: Joachim Deelen <email@hidden>
- Date: Tue, 30 Oct 2007 22:21:05 +0100
Hi List,
does anybody know, if it's possible, to change the AnimationCurve of
an implicit Animation. I know I can create a CAAnimation an set an
CAMediaTimingFunction into it but how do I get the Animation Object
for an implicit animation which is not a property?
An Example for this, is the CAScrollLayer with its Method
"scrollToPoint". This is perfectly animated but always uses Ease In /
Ease out as the animation curve, but I want it to be linear.
I get a smooth scrolling effect with just a few lines of code:
[CATransaction begin];
[CATransaction setValue:[NSNumber numberWithFloat:((NSWidth([textView
bounds])-NSWidth([self bounds]))/2)*0.10f]
forKey:kCATransactionAnimationDuration];
[textLayer scrollPoint:NSMakePoint((NSWidth([textView bounds])-
NSWidth([self bounds])), 0.0)];
[CATransaction commit];
The "textLayer" of Type CATextLayer, is included within a
CAScrollLayer. As I said before, scrolling is fine but with the wrong
curve. How can I get the animation Object that is responsible for the
Animation of "scrollPoint" to set its "timming" Property?
Any Ideas?
regards
Joachim
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden