I'm attempting to rotate an image about its center point, using something
like:
DIM background AS Image = Image.Load("grass.png")
DIM f AS Float
FOR f = 0 TO 6.2831853 STEP 0.01
Draw.Begin(DrawingArea)
Draw.Image(background.Rotate(f), 0, 0)
Draw.End
WAIT
NEXT
The resolution of the returned rotated image actually changes based on the
angle, such that the entire original image is preserved (no clipping
occurs). This would be extremely useful in most cases, but not in mine as
I'm making a game.
Anyone know what math I should use to try to keep the rotated image centered
about its mid-point while being rotated? Thanks all.
-----
Kevin Fishburne, Eight Virtues
www: http://sales.eightvirtues.com http://sales.eightvirtues.com
e-mail: mailto:[email protected] [email protected]
phone: (770) 853-6271
--
View this message in context:
http://old.nabble.com/gb.image%3A-how-to-keep-a-rotated-image-centered-tp29356475p29356475.html
Sent from the gambas-user mailing list archive at Nabble.com.
------------------------------------------------------------------------------
This SF.net email is sponsored by
Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________
Gambas-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gambas-user