1

I have two displays connected to my computer. When I move a window from SDL2 to my second display and the code calls the SDL_SetWindowPosition function, the window automatically moves to my first display. Is there a way to prevent this or move the window back to the display it was earlier?

user11914177
  • 885
  • 11
  • 33

1 Answers1

2

So the important thing is to set the window position to SDL_WINDOWPOS_CENTERED_DISPLAY(n) n specifies which window should be used.

user11914177
  • 885
  • 11
  • 33