我试图以一种方式旋转/翻转imageView,其中有问题的图像(卡片)翻转到它的另一侧,即沿其Z轴旋转3d动画。那可能吗?
我在下面编写了这段代码,但它只在2d中旋转,仅更改其方向而不是其侧面。
// animations
private static final float ROTATE_FROM = 0.0f;
private static final float ROTATE_TO = -10.0f * 360.0f;
private RotateAnimation mRotateAnimation;
mRotateAnimation = new RotateAnimation(ROTATE_FROM, ROTATE_TO, Animation.RELATIVE_TO_SELF, 0.5f,
Animation.RELATIVE_TO_SELF, 0.5f);
mRotateAnimation.setDuration((long)2 * 150);
mRotateAnimation.setRepeatCount(0);
mCardImage.startAnimation(mRotateAnimation);