SFML community forums
Help => Graphics => Topic started by: esrix on October 04, 2007, 02:05:46 pm
-
I was wondering if there is a way to flip a sprite on the x or y axis. For example, if the image of a sprite appeared to be facing left, is there a way to flip it on the x axis to make it appear to be facing right?
I looked through the documentation to see if I could invert the x or y scale, but it states that a sprite's scale values must be strictly positive.
I know how to do it by setting a quad and scaling it in OpenGL, but I was wondering if SFML was capable of doing it.
-
There is currently no way to do it, but I'll think about it. Maybe allowing negative scales will be enough.
-
Happy to hear your considering it :)
-
You could use the getpixel and setpixel functions of Image to manually flip an axis...