Android: Rotate image in imageview by an angle

前端 未结 25 2647
野趣味
野趣味 2020-11-22 06:35

I am using the following code to rotate a image in ImageView by an angle. Is there any simpler and less complex method available.

ImageView iv = (ImageView)f         


        
25条回答
  •  -上瘾入骨i
    2020-11-22 07:14

    Sadly, I don't think there is. The Matrix class is responsible for all image manipulations, whether it's rotating, shrinking/growing, skewing, etc.

    http://developer.android.com/reference/android/graphics/Matrix.html

    My apologies, but I can't think of an alternative. Maybe someone else might be able to, but the times I've had to manipulate an image I've used a Matrix.

    Best of luck!

提交回复
热议问题