开发者

How can I create an animation frame with netbeans?

开发者 https://www.devze.com 2022-12-15 21:56 出处:网络
I use netbeans,and I insert an image on the lable which is on the desktop pane ,I want to rotate that image in its place ,what should i开发者_开发技巧 do?

I use netbeans,and I insert an image on the lable which is on the desktop pane ,I want to rotate that image in its place ,what should i开发者_开发技巧 do? please help me. thanks.


You could use the Graphics2D and specifically [this][1] method which lets you redraw the image with an AffineTransform and that lets you 'rotate' the image.

[1]: http://java.sun.com/javase/6/docs/api/java/awt/Graphics2D.html#drawImage(java.awt.Image, java.awt.geom.AffineTransform, java.awt.image.ImageObserver)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号