[英]java2d and scale
當我使用g2d.scale(2,2)或AffineTransform縮放形狀[Rectangle]時,由於我的形狀比例仍然與以前相同,並且只有形狀的視圖發生了變化,因此無法檢測到正確的形狀碰撞。
g2d.scale(2,2)
AffineTransform
我需要解決此問題的解決方案[變換后更改形狀的大小]。
謝謝
您可以使用逆變換,如圖所示這里 ,或明確做縮放,如圖所示這里 。
[英]How to select a figure to move, rotate and scale with Java2D
[英]Java2D artifact?
[英]Java2D Performance Issues
[英]Transformations in Java2D API
[英]Animate Image in Java2d
[英]Java2D: scaling issues
[英]Creating videos with Java2D
[英]refresh repaint() JAVA2D
[英]Evaluation of curve in Java2D
[英]Text rotation in Java2D
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.