、CABasicAnimation基本的なアニメーション(場合、fromValueとtoValueの)
二、CAKeyframeAnimationのキーフレームアニメーション:
図1に示すように、パスのキーフレームアニメーション経路
図2に示すように、値のキーフレームアニメーション(「S」字型アニメーション)
三、UIViewのコールのコードブロック:
1、レイヤ的にCATransform3DIdentity。
romate.layer.transform = CATransform3DIdentity。
[UIViewのanimateWithDuration:20
遅延:0
オプション:UIViewAnimationOptionAllowUserInteraction |
UIViewAnimationOptionCurveLinear
アニメーション:^ {
romate.layer.transform = CATransform3DMakeRotation(M_PI / 4、0、0、1)。
}
完了:NULL
];
図2は、CGAffineTransformIdentity的図です。
romate.transform = CGAffineTransformIdentity。
[UIViewのanimateWithDuration:100
遅延:0
オプション:UIViewAnimationOptionAllowUserInteraction |
UIViewAnimationOptionCurveLinear
アニメーション:^ {
romate.transform = CGAffineTransformMakeRotation(M_PI)。
}
完了:NULL
];