comparison src/video/SDL_video.c @ 3448:bc27e1fdd3a7

If we explicitly request a driver, try to initialize it.
author Sam Lantinga <slouken@libsdl.org>
date Wed, 18 Nov 2009 08:54:13 +0000
parents 9f62f47d989b
children 173199bce642
comparison
equal deleted inserted replaced
3447:294b770c1989 3448:bc27e1fdd3a7
191 driver_name = SDL_getenv("SDL_VIDEODRIVER"); 191 driver_name = SDL_getenv("SDL_VIDEODRIVER");
192 } 192 }
193 if (driver_name != NULL) { 193 if (driver_name != NULL) {
194 for (i = 0; bootstrap[i]; ++i) { 194 for (i = 0; bootstrap[i]; ++i) {
195 if (SDL_strcasecmp(bootstrap[i]->name, driver_name) == 0) { 195 if (SDL_strcasecmp(bootstrap[i]->name, driver_name) == 0) {
196 if (bootstrap[i]->available()) { 196 video = bootstrap[i]->create(index);
197 video = bootstrap[i]->create(index);
198 }
199 break; 197 break;
200 } 198 }
201 } 199 }
202 } else { 200 } else {
203 for (i = 0; bootstrap[i]; ++i) { 201 for (i = 0; bootstrap[i]; ++i) {