1
我有一個圖標,並且我希望它始終處於旋轉狀態。到目前爲止非常好,只是我想限制幀爲12fps,以便它會產生我預期的效果。我怎樣才能做到這一點?Android:極限旋轉動畫fps
ImageView loadingCircle= (ImageView) getActivity().findViewById(R.id.loading_circle_image);
RotateAnimation rotateAnimation = new RotateAnimation(0.0f, 1.0f * 360.0f,Animation.RELATIVE_TO_SELF, 0.5f, Animation.RELATIVE_TO_SELF, 0.5f);
rotateAnimation.setDuration(1000);
rotateAnimation.setInterpolator(new LinearInterpolator());
rotateAnimation.setRepeatCount(Animation.INFINITE);
rotateAnimation.setRepeatMode(Animation.INFINITE);
loadingCircle.startAnimation(rotateAnimation);
你不能這樣做,對不起 – pskink 2014-11-06 10:23:53
如果你的動畫有點快,那麼嘗試增加持續時間。你不能玩fps。 – 2014-11-06 11:03:50