Hello All,
How to Flip CALayer Sublayer.
i have tried :
CGFloat timeOffset = 0;
CABasicAnimation *animation = [CABasicAnimation animationWithKeyPath:@"transform"];
CATransform3D transform = CATransform3DMakeRotation(M_PI/2, 0, 1, 0);
animation.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseIn];
animation.toValue = [NSValue valueWithCATransform3D:transform];
animation.duration = 0.2;
animation.beginTime = CACurrentMediaTime() + timeOffset;
animation.fillMode = kCAFillModeBoth;
animation.removedOnCompletion = NO;
[selectedLayer addAnimation:animation forKey:nil];
timeOffset += 0.1;
in this code selected layer is not flipping properly,
Give me some suggestions.
Thank you