如何降低RotateAnimation实例的旋转速度。我使用下面的代码片段来做动画。
rotateAnimation = new RotateAnimation(currentRotation, currentRotation + (360 * 5), Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
currentRotation = (currentRotation + (360 * 5));
rotateAnimation.setDuration(10000);
rotateAnimation.setInterpolator(new LinearInterpolator());
rotateAnimation.setRepeatCount(Animation.INFINITE);
rotateAnimation.setRepeatMode(Animation.INFINITE);
rotateAnimation.setFillEnabled(true);
rotateAnimation.setFillAfter(true);
rotateAnimation.setAnimationListener(animationInListener);
recordRingImageView.startAnimation(rotateAnimation);发布于 2013-10-29 13:16:25
增加其持续时间,因为速度=距离/时间
rotateAnimation.setDuration(30000);发布于 2013-10-29 13:16:16
只需增加动画的持续时间。持续时间是执行动画的时间,所以如果增加持续时间,动画将需要更多的时间来完成,换句话说,动画的速度会降低。
https://stackoverflow.com/questions/19659250
复制相似问题