core-animation

Animating "sliding" in NSOutlineView

I've done a fair amount of Googling, but still haven't find any proper solution for animating the expansion of NSOutlineView. I'm trying to mimic a "sliding" animation when expanding/collapsing rows. Anyone know a good strategy for attempting this? Animating this: }} Folder 1 To expand and look like this: }} Folder 1 }}}}} Item 1 ...

Best way to handle multiple UITableViews in one UIViewController?

I have a UIViewController that should be capable of displaying tableViews with multiple data sources. The UITableView spans about half the size of the screen, and there is and up and down button that allows you to go through different data. Everytime the up and down button is hit, I'd like to ultimately use UIViewAnimationTransitionCurlD...

presentation layer current position

Hi, I am using the UIView animation to move a ball. But in some conditions i want to stop the animation in between. And same time i am accessing the position of the ball. But it doesn't give the exact position but the some point behind the actual position. CALayer *la = (CALayer*)ball.layer; CGPoint pos = [[la presentationLayer] positio...

NSViewController. Core Animation sublayer not drawing.

Hi, I create NSViewController. It manage my view hierarchy and set other views in one NSBox. - (void)displayViewController:(ManagingViewController *)vc { NSWindow *w = [box window]; NSView *v = [vc view]; [box setContentView:v]; } I have two alternate views. The views have Quartz Composer root layer and CALayer sublayer. // ...

Removing all CALayer's sublayers

Hi. I have trouble with deleting all layer's sublayers. I do this manually, but it's unwanted code clutter. I found many topics about this in google, but no answer. I tried to do something like this: for(CALayer *layer in rootLayer.sublayers) { [layer removeFromSublayer]; } but it didn't work. Also, i tried to clone rootLayer....

Is there a way to use the Core Animation timers?

I have a CALayer which its position needs to be recomputed as often as possible. I'm currently using a NSTimer for that matter, but I would prefer to hook myself into Core Animation directly. When you add an animation to a layer, the values are refreshed as often as possible without any timers. Is there any way to use this mechanism? I ...

What are the two options that come with the core animations beginAnnimations method?

I was wondering what they mean by: [CustomView beginAnimations:@"whatIsThis" context:whatIsThis]; I am just wondering what those who things do and how I would use them? Please help! ...

Need help to make my iPhone animation work?

I'm brand new in iPhone animation feature. I wrote a simple testing program to spin a red rectangle; however, the animation doesn't act at all. What's wrong with my code? Thanks a lot... //.h #import <UIKit/UIKit.h> #import <QuartzCore/QuartzCore.h> #define DegreesToRadians(X) (M_PI*X/180.0) //.m - (void)viewDidLoad { [super viewD...

How to clip a CAShapeLayer ?

I have a CAShapeLayer that i add a CAGradientLayer to, but there is no clipping about the shape of the CAShapeLayer. ...

Finding a sublayers position on the screen after several CATransforms?

My iPhone app has a mainView. added as a sublayer to this MainView is CircleView. CircleView rotates as the phone turns and tilts as the phone tilts, using 3 concatenated CATransform3D transforms. DotView is added as a sublayer to CircleView. After all these transoforms, I have no easy (or apparent) way of knowing the coordinates of dotV...

CABasicAnimation, rotation, major slowdown.

Hi. I have created an animated color wheel where the user navigates through different views and each time the wheel rotates to the next color. Each view is loaded with navigation buttons, sound buttons and pictures ect. Everything works fine except that every time the animation is called the image remains in the background and eventual...

morphing in iphone

is there a (simple) way to make a morphing (faces as a typical example) using core animation or openGL? ...

How to distort a Sprite into a trapezoid?

Hello, I am trying to transform a Sprite into a trapezoid, I don't really care about the interpolation even though I know without it my image will lose detail. All I really want to do is Transform my rectangular Sprite into a trapezoid like this: / \ / \ /__________\ Has anyone done this with CGAffineTransforms or...

iPhone SDK - how can I tell when an animation has finished?

I am starting an animated enlargement when an image is touched, and then scaling it back down to normal size when it is released. By using setAnimationBeginsFromCurrentState:YES the zooming effect is nice and smooth if you lift your finger part way through animating. However, what I want to do is "lock" the larger size in place if you'...

Grouping two Core Animations with CAAnimationGroup causes one CABasicAnimation to not run

I have two animations that I'm trying to perform on a UILabel on the iPhone with OS 3.1.2. The first rocks the UILabel back and forth: CAKeyframeAnimation *rock; rock = [CAKeyframeAnimation animationWithKeyPath:@"transform.rotation.z"]; [rock setBeginTime:0.0f]; [rock setDuration:5.0]; [rock setRepeatCount:10000]; NSMutableArray *value...

Want a flickering UIImageView (CoreAnimation and alpha-value)

Hello, I would like to have an UIImageView that flickers. I thougt I can make it with CoreAnimation and the alpha-value. I tried this: for (int a = 1; a <= 100; a++) { schwarz.alpha = 0.7; [UIView beginAnimations:nil context:nil]; [UIView setAnimationCurve:UIViewAnimationCurveEaseIn]; [UIView setAnimationDuration:1]; ...

NSWindow grow animation (Like the Quick Look Window)

What is the basic principles of doing complex animations on an NSWindow? I'd like to mimic the Quick Look window animation (grow/shrink) but haven't found anything on this. Animating views is well documented but nothing on NSWindow. If you look closely at the Quick Look window, you'll see that it doesn't change the frame size, but reall...

Fastest / most efficient way to draw moving speech bubbles on screen - CoreAnimation, Quartz2D?

I am adding some functionality to an iPhone app, and could use some help in picking the fastest / most efficient / best practice approach for solving this problem: At the upper-half of my screen, I have speech bubbles (think comic book) that are UIImageViews translating across the screen (dynamic x & y position). It is a UIImageView bec...

Making an icon "jump" with iPhone core animation

What would be the best way to make an icon seem to "jump" from a toolbar into a UITabBarItem. I have found the CAKeyframeAnimation class which looks promising but I just can't get it to work. I have been using code similar to this : http://www.bdunagan.com/2009/04/26/core-animation-on-the-iphone/ but no matter what I set my endPoint to,...

Can I speed up my use of Core Graphics to draw moving triangles every 1/10th of a second

I have recently added some Core Graphics elements to my app and it has slowed dramatically, rendering it just about useless. I am not sure if I am just not using Core Graphics efficiently (how do I make it faster?) or if this problem is inherent in the use of Core Graphics. My code is below, after this description: There are speech bubb...