Domanda

Say I have a shape that I have drawn through paintComponent(), fillRect, or drawOval,

How would I go about flipping it, so that the shape would not be going from the top left, but from the bottom upwards?

È stato utile?

Soluzione

All I had to do was use the height of my panel, and subtract it from the height of the object.

for ex:

    int height = (1000 - n);

where n is the height that you wish the shape to be.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top