[SDL] changing display resolution using SDL_WINDOW_FULLSCREEN with multiple displays not working on mac OS X (el capitan) ?
jeroen.clarysse at telenet.be
Mon Sep 26 04:41:32 PDT 2016
using THREE monitors, and trying to create two SDL_windows like this :
int display_main_num = 1;
int display_2nd_num = 2;
m_main_window_w = 1024;
m_main_window_h = 768;
m_2nd_window_w = 1024;
m_2nd_window_h = 768;
m_main_window = SDL_CreateWindow("Main window",SDL_WINDOWPOS_CENTERED_DISPLAY(display_main_num),SDL_WINDOWPOS_CENTERED_DISPLAY(display_main_num),m_main_window_w,m_main_window_h,SDL_WINDOW_SHOWN|SDL_WINDOW_FULLSCREEN_DESKTOP);
m_main_renderer = SDL_CreateRenderer(m_main_window, -1, SDL_RENDERER_SOFTWARE);
m_2nd_window = SDL_CreateWindow("2nd window",SDL_WINDOWPOS_CENTERED_DISPLAY(display_2nd_num),SDL_WINDOWPOS_CENTERED_DISPLAY(display_2nd_num),m_2nd_window_w,m_2nd_window_h,SDL_WINDOW_SHOWN|SDL_WINDOW_FULLSCREEN_DESKTOP);
m_2nd_renderer = SDL_CreateRenderer(m_2nd_window, -1, SDL_RENDERER_SOFTWARE);
this works nicely, but these call don't change resolutions yet. However, when I change the flags SDL_WINDOW_FULLSCREEN_DESKTOP to SDL_WINDOW_FULLSCREEN, SDL is supposed to change the resolution of both monitors to 1024 x 768. A lot happens on the screen : flickering windows, typical macos fullscreen resizing animation, flashing menu bar, … but the whole function stays stuck in he first CreateWindow() call
after I click around a bit, the code continues, but the windows are NOT fullscreen.
has anyone succeeded in using multiple displays WITH resolution changes ?
I also tried with using only ONE display resolution and leaving the other at desktop res, but even that didn’t work
More information about the SDL