comparison src/video/SDL_video.c @ 1918:092bd3a019c5

Starting on the OpenGL renderer...
author Sam Lantinga <slouken@libsdl.org>
date Wed, 19 Jul 2006 07:18:45 +0000
parents 83420da906a5
children 00816063b9c9
comparison
equal deleted inserted replaced
1917:3f54b3ec5a07 1918:092bd3a019c5
25 25
26 #include "SDL.h" 26 #include "SDL.h"
27 #include "SDL_sysvideo.h" 27 #include "SDL_sysvideo.h"
28 #include "SDL_blit.h" 28 #include "SDL_blit.h"
29 #include "SDL_pixels_c.h" 29 #include "SDL_pixels_c.h"
30 #include "SDL_renderer_gl.h"
30 #include "SDL_renderer_sw.h" 31 #include "SDL_renderer_sw.h"
31 #include "../events/SDL_sysevents.h" 32 #include "../events/SDL_sysevents.h"
32 #include "../events/SDL_events_c.h" 33 #include "../events/SDL_events_c.h"
33 34
34 /* Available video drivers */ 35 /* Available video drivers */
277 } 278 }
278 279
279 /* The software renderer is always available */ 280 /* The software renderer is always available */
280 for (i = 0; i < _this->num_displays; ++i) { 281 for (i = 0; i < _this->num_displays; ++i) {
281 if (_this->displays[i].num_render_drivers > 0) { 282 if (_this->displays[i].num_render_drivers > 0) {
282 SDL_AddRenderDriver(i, &SDL_SW_RenderDriver); 283 #if SDL_VIDEO_OPENGL
284 SDL_AddRenderDriver(i, &GL_RenderDriver);
285 #endif
286 SDL_AddRenderDriver(i, &SW_RenderDriver);
283 } 287 }
284 } 288 }
285 289
286 /* We're ready to go! */ 290 /* We're ready to go! */
287 return 0; 291 return 0;