Can SDL_FlipMode do both?

-Edit- Nevermind I’m likely to render with geometry

(SDL3) I wrote code to draw a rectangle with rounded corners. I was wondering if I could mirror the corner by setting SDL_FlipMode to 3, it works but it’s not documented so idk if I can depend on it? I could use rotation but I think flip code is more simple to read

The code inside SDL_RenderTextureRotated treats it as a bitmask but question is whether all backends treat it like that…

No, but the result of both is just a 180 degree rotation. What I’d suggest is storing “flip vertical” and “flip horizontal” flags somewhere instead of the SDL flag, and setting the flag when you’re calling SDL_RenderTextureRotated based on those values. Also remember to add that rotation to your actual rotation % 360 (it’s in degrees)

1 Like

You missed my edit. I solved it without using the rotation function :face_with_tongue: