What is in my program that works in full screen mode (hiding menus, docks, panels, etc.):
if ( SDL_Init( SDL_INIT_VIDEO | SDL_INIT_TIMER ) < 0 ) { throw SDL_GetError(); } const SDL_VideoInfo* vidinfo = SDL_GetVideoInfo(); int max_w = vidinfo->current_w; int max_h = vidinfo->current_h; . . . SDL_Surface *screen = SDL_SetVideoMode(max_w,max_h,0,SDL_FULLSCREEN);
Be sure to call SDL_GetVideoInfo () before SDL_SetVideoMode ().
source share