When my application goes into the background state and reappears, all CoreAnimations are stopped. In my case the animation in the view was endless, so I would like to restart it when the user resturns.
How can I do this? Do I have to listen to applicationDidBecomeActive in every view/layer that has such an animation? That doesn't sound...
I read an article somewhere explaining that apple uses OpenGL ES to implement the page turning effect in the iBooks app. Since you can perform 3D animations on 2D Layers using only Core Animation, what might be some reasons you'd have to use OpenGL ES to create that page transition animation?
Thanks in advance for your thoughts!
...
I'm trying to figure out how I could create a curl or peel effect on an image in my iPad app using Core Animation, but as I'm learning the API, I only understand different ways to move, scale, and rotate the 2D image (including the 3D transformations). I'd like to accomplish this effect on small, individual layers (i.e. sprites) that ha...
I have a basic NSWindow with no decorations (titlebar etc), NSWindow set to not opaque no shadow etc. It sits at the screensaver level (so "topmost" window of application)
contentView is set to a subclassed NSView of mine that says "Loading" achieved by drawing a CIImage.
This entire window is centered in the screen. It's opened wh...
Hello!
I've been working on a new app and was really hoping to implement a swipe to reveal more options menu inside my application. I've searched and searched, but it seems no one else has successfully made it work (aside from Loren). What I'm trying to do is swipe the cell, and simultaneously use CABasicAnimation to push it to x: 320...
I have an NSTextView and an NSImageView that is bound to a NSString and an NSImage in my code. I would like to have the displayed string and image cross-dissolve when I change the string and image in code. Any way to do this? Do I need to stop using bindings? (And if I do, is there any trick to getting the string and the image to cro...
Hi everybody!
I am trying to apply mask to my UIView. I have method on my UIView:
- (void) applyMask :(CGRect)maskZone :(NSArray*)gradientColors :(CGFloat*)gradientLocations {
CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();.
CGContextRef context = CGBitmapContextCreate (NULL, self.bounds.size.wi...
Hi , I am very new to cocoa . Well I have multiple UIImageView (animationView)flying around the screen. I am using UIAnimation class to animate them. While I have one more UIImageView (myObject).I m trying to collide these while i move "myObject" around the screen using touchesMoved method. The problem is I am not able to detect the coll...
Hi,
I'm using UIView animation blocks to animate CALayer properties (backgroundColor in this case) on multiple layers on the display at once.
All layers are opaque, and I'm animating everything in one block, essentially like this
[UIView beginAnimations:@"outer" context:nil];
float duration = .25;
float offset = 0.0;
for( NSArray *vie...
I hardly know how to explain my case other than to point to the excellent Absolute vodka app, Drink Spiration.
I am trying to make a carousel like image browsing with a little spice. I would really like to find a simple core animation explanation on how to accomplish something like the above app.
I hope someone can help with this. Th...
I have the following code that gets called after the view loads. It works perfectly on the iPhone, but appears to do nothing at all on the iPad. I have confirmed the frame/bounds of my UIImageView is set to the size of the iPad's screen. Recommendations please?
- (void)startNextAnimation {
CABasicAnimation *crossFade = [CABasicAnimat...
Hello! I am using the code:
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDelegate:self];
[UIView setAnimationDuration:0.3];
[info setFrame:CGRectMake( 0, 96, 320, 384)];
[UIView commitAnimations];
to have an animation of the object "info" to change its heght to 384... Nothing else is changed, but the only way to do t...
Hello all,
I want to zoom in and out a UIVIew on to specific point something similer effect to focus + zoom in. I don't want to use UISCrollView. What is the right approach to do this if anyone could suggest.
Thanks
...
hi
this my code
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:1.5];
if ([sender tag] == 1) {
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:placeholder cache:YES];
}
else {
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromRight forV...
Say I want to animate a ball rolling 1000 pixels to the right, specifying a timing function in the process – something like this:
UIView *ball = [[UIView alloc] initWithFrame:CGRectMake(0,0,30,30)];
CABasicAnimation* anim =
[CABasicAnimation animationWithKeyPath:@"transform.translation.x"];
anim.toValue = [NSNumber numberWithFlo...
I want an image view of some size say 25 by 25, to move in a linear motion from left to right and then right left continuously.
Lets say the image starts moving from left, then at the time it reaches reaches the right, it should start moving back to the left, then this should repeat.
I have this code, which lets the view move down, but...
I have a custom UITableView cell which has a button and a label. I fire a method when someone taps on the button, and then color that row. It's all working fine.
What I want to actually do is
user taps button, the row is colored in a gradient (it works now)
The gradient fades away
My code is below (BackView is the view in my custom ...
Hi everyone, how can I make it so all of my view's subviews aren't animated here and only the currentPage's representedView and the newPage's represented view's?
CATransition *transition = [CATransition animation];
[transition setType:kCATransitionPush];
[transition setSubtype:([self indexOfPage:currentPage] < [self indexOfPage:...
Hi everyone, I am making custom NSScrollers for use in NSScrollView. But when any of the superviews of the NSScroller gets Core Animation enabled. I get this drawing issue that's a huge nuisance. Whenever i scroll into the corners of the scroll view the scrollers clip. But if a scroller starts out drawing in the corner, the scroller part...
I'm having trouble with a layer hosting view. This version of initWithFrame: works as expected (the view is filled black) providing 'Wants Core Animation Layer' is selected in Interface Builder:
- (id)initWithFrame:(NSRect)frame
{
self = [super initWithFrame:frame];
if (self)
{
[self setWantsLayer:YES];
[[s...