如何在Java中计算旋转图像匹配。给我一个建议。
public void onClickButtonRotation(View v){
if(this.blnButtonRotation){
int run = new Random().nextInt(360) + 3600;
RotateAnimation rotateAnimation = new RotateAnimation((float)this.intDegrees,(float)
(this.intDegrees + ((long)run)),1,0.5f,1,0.5f);
this.intDegrees = (this.intDegrees + ((long)run)) % 360;
rotateAnimation.setDuration((long)run);
rotateAnimation.setFillAfter(true);
rotateAnimation.setInterpolator(new DecelerateInterpolator());
rotateAnimation.setAnimationListener(this);
imageRoulette.setAnimation(rotateAnimation);
imageRoulette.startAnimation(rotateAnimation);
}
}