comparison src/video/dummy/SDL_nullvideo.c @ 1911:7577fd11cee4

Create a fake desktop mode for windowed mode apps
author Sam Lantinga <slouken@libsdl.org>
date Sun, 16 Jul 2006 03:35:44 +0000
parents c121d94672cb
children 83420da906a5
comparison
equal deleted inserted replaced
1910:c26194009c9c 1911:7577fd11cee4
107 int 107 int
108 DUMMY_VideoInit(_THIS) 108 DUMMY_VideoInit(_THIS)
109 { 109 {
110 SDL_DisplayMode mode; 110 SDL_DisplayMode mode;
111 111
112 SDL_AddBasicVideoDisplay(NULL); 112 /* Use a fake 32-bpp desktop mode */
113 mode.format = SDL_PixelFormat_RGB888;
114 mode.w = 1024;
115 mode.h = 768;
116 mode.refresh_rate = 0;
117 SDL_AddBasicVideoDisplay(&mode);
113 SDL_AddRenderDriver(0, &SDL_DUMMY_RenderDriver); 118 SDL_AddRenderDriver(0, &SDL_DUMMY_RenderDriver);
114 119
115 SDL_zero(mode); 120 SDL_zero(mode);
116 SDL_AddDisplayMode(0, &mode); 121 SDL_AddDisplayMode(0, &mode);
117 122