[RFC] SDL_WINDOWPOS_CENTERED always use the first display |
Emmanuel Gil Peyrot
Guest
|
Hello,
I am trying to implement display selection for fullscreen in the Wayland, as an alternative implementation of bug 2803[0] based on the patch I provided in bug 2913[1], but it seems there is no way for the application to tell SDL it doesn’t care about which display to use for fullscreen. This issue stems from the definition of SDL_WINDOWPOS_CENTERED, as follow (SDL2/SDL_video.h, line 129): #define SDL_WINDOWPOS_CENTERED SDL_WINDOWPOS_CENTERED_DISPLAY(0) What would be the best way to solve this issue? I was thinking about changing the definition of SDL_WINDOWPOS_CENTERED to something like SDL_WINDOWPOS_CENTERED_DISPLAY(SDL_DISPLAY_DONTCARE), with SDL_DISPLAY_DONTCARE defined as some currently invalid display, what do you think about that? It wouldn’t fix already-compiled programs, but any future one using SDL_WINDOWPOS_CENTERED would let the compositor select which display to use. [0] https://bugzilla.libsdl.org/show_bug.cgi?id=2803 [1] https://bugzilla.libsdl.org/show_bug.cgi?id=2913 -- Emmanuel Gil Peyrot _______________________________________________ SDL mailing list http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org |
|||||||||||
|