Android Positioning A Drawbitmap That Uses Rect
I searched through this site to find out how to rotate a image back and forth and came up with my own with the help of other post on this site, it works great, the only problem is
Solution 1:
This is a piece of code from that other post you referenced:
Rectsrc=newRect(0, 0, width, height);
Rectdst=newRect(x, y, x + width, y + height);
It's the x and y in the dst Rect that determine the location of the bitmap.
Your code:
Rectsrc=newRect(width - width, height - height, width, height);
Rectdst=newRect(width - width, height - height, width, height);
Is going to always draw it at 0, 0 because width - width will be 0 and height - height will be 0.
Post a Comment for "Android Positioning A Drawbitmap That Uses Rect"