Bir yol etrafında animasyon yaptığım bir top resmim var. Animasyon sonsuza dek tekrarlanacak şekilde ayarlandı, ancak tekrarlar arasında neden gecikme var?CAKeyFrameAnimasyon tekrarlanmadan önce erteleniyor
CGPathRef aPath;
aPath = CGPathCreateWithEllipseInRect(CGRectMake(0, 0, SIZE, SIZE), NULL);
[CATransaction begin];
arcAnimation = [CAKeyframeAnimation animationWithKeyPath: @"position"];
[arcAnimation setBeginTime:CACurrentMediaTime()];
[arcAnimation setDuration: 1.5];
[arcAnimation setTimingFunction:[CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionLinear]];
[arcAnimation setAutoreverses: NO];
[arcAnimation setRepeatCount:HUGE_VALF];
arcAnimation.removedOnCompletion = NO;
arcAnimation.fillMode = kCAFillModeRemoved;
[arcAnimation setPath: aPath];
[ball.layer addAnimation: arcAnimation forKey: @"position"];
[CATransaction commit];
CFRelease(aPath);
Evet, bu bir çekicilik gibi çalışır! Teşekkürler! –
Bunu anlamaya çalışmak için bir saat harcadı ... Neden bu varsayılan olmaz ?! – cph2117