java Programming Glossary: at.translate
Java ball object doesn't bounce off of drawn rectangles like it's supposed to. http://stackoverflow.com/questions/13261767/java-ball-object-doesnt-bounce-off-of-drawn-rectangles-like-its-supposed-to g2d.getTransform AffineTransform at new AffineTransform at.translate getX getY at.rotate Math.toRadians rotation getWidth 2 getHeight..
Rotate an image in java by the specified angle http://stackoverflow.com/questions/14884480/rotate-an-image-in-java-by-the-specified-angle getAngle x rectangle.width 2 y rectangle.height 2 at.translate x y g2d.setTransform at g2d.draw rectangle g2d.dispose You..
Java make a directed line and make it move http://stackoverflow.com/questions/15607427/java-make-a-directed-line-and-make-it-move AffineTransform at new AffineTransform at.translate width bounds.width 2 height bounds.height 2 at.rotate Math.toRadians.. mouseEnd AffineTransform at new AffineTransform at.translate mouseEnd.x bounds.width 2 mouseEnd.y bounds.height 2 at.rotate..
Rotate BufferedImage Inside JPanel http://stackoverflow.com/questions/15779877/rotate-bufferedimage-inside-jpanel getAngle x image.getWidth 2 y image.getHeight 2 at.translate x y g2d.setTransform at g2d.drawImage image 0 0 this g2d.dispose.. getAngle x image.getWidth 2 y image.getHeight 2 at.translate x y g2d.setTransform at g2d.drawImage image 0 0 TestPane.this..
add thumnails to spring layout like a grid? http://stackoverflow.com/questions/15961412/add-thumnails-to-spring-layout-like-a-grid float scale 1f AffineTransform at new AffineTransform at.translate getWidth 2 img.getWidth scale 2 getHeight 2 img.getHeight..
Scaling/Translating a Shape to a given Rectangle using AffineTransform http://stackoverflow.com/questions/3843105/scaling-translating-a-shape-to-a-given-rectangle-using-affinetransform Shape is first rotated then scaled and finally translated. at.translate SIZE 2 SIZE 2 at.scale 60 60 at.rotate Math.PI 4 return at.createTransformedShape..
Rotating BufferedImage instances http://stackoverflow.com/questions/4918482/rotating-bufferedimage-instances 4. translate it to the center of the component at.translate getWidth 2 getHeight 2 3. do the actual rotation at.rotate.. object so that you rotate it around the center easier at.translate image.getWidth 2 image.getHeight 2 draw the image Graphics2D..
Rotating a shape vertically around the x-axis http://stackoverflow.com/questions/5593066/rotating-a-shape-vertically-around-the-x-axis h 2 g2d.drawPolygon p1 g2d.drawPolygon p2 at.setToIdentity at.translate w 2 h 2 at.scale scale scale at.translate p3x 5 10 p3y 5 g2d.setPaint.. at.setToIdentity at.translate w 2 h 2 at.scale scale scale at.translate p3x 5 10 p3y 5 g2d.setPaint Color.blue g2d.fill at.createTransformedShape..
|