这对我有用:
CABasicAnimation* animation = [CABasicAnimation animationWithKeyPath: @"transform"]; CATransform3D transform = CATransform3DMakeRotation (DegreesToRadians (90), 0, 0, 1); animation.toValue = [NSValue valueWithCATransform3D: transform]; animation.duration = 60; animation.cumulative = NO; animation.repeatCount = 10000; animation.removedOnCompletion = YES;