comparison src/video/photon/SDL_ph_image.c @ 1658:e49147870aac SDL-1.3

glSDL support
author Sam Lantinga <slouken@libsdl.org>
date Mon, 01 May 2006 06:58:33 +0000
parents d910939febfa
children 782fd950bd46
comparison
equal deleted inserted replaced
1657:5b0805ceb50f 1658:e49147870aac
313 } 313 }
314 #endif /* 6.3.0 */ 314 #endif /* 6.3.0 */
315 315
316 if (ph_SetupOpenGLContext(this, screen->w, screen->h, screen->format->BitsPerPixel, screen->flags)!=0) 316 if (ph_SetupOpenGLContext(this, screen->w, screen->h, screen->format->BitsPerPixel, screen->flags)!=0)
317 { 317 {
318 screen->flags &= ~SDL_OPENGL; 318 screen->flags &= ~SDL_INTERNALOPENGL;
319 return -1; 319 return -1;
320 } 320 }
321 321
322 return 0; 322 return 0;
323 } 323 }
326 326
327 void ph_DestroyImage(_THIS, SDL_Surface* screen) 327 void ph_DestroyImage(_THIS, SDL_Surface* screen)
328 { 328 {
329 329
330 #if SDL_VIDEO_OPENGL 330 #if SDL_VIDEO_OPENGL
331 if ((screen->flags & SDL_OPENGL)==SDL_OPENGL) 331 if (screen->flags & SDL_INTERNALOPENGL)
332 { 332 {
333 if (oglctx) 333 if (oglctx)
334 { 334 {
335 #if (_NTO_VERSION < 630) 335 #if (_NTO_VERSION < 630)
336 PhDCSetCurrent(NULL); 336 PhDCSetCurrent(NULL);
484 int setupresult=-1; 484 int setupresult=-1;
485 485
486 ph_DestroyImage(this, screen); 486 ph_DestroyImage(this, screen);
487 487
488 #if SDL_VIDEO_OPENGL 488 #if SDL_VIDEO_OPENGL
489 if ((flags & SDL_OPENGL)==SDL_OPENGL) 489 if (flags & SDL_INTERNALOPENGL)
490 { 490 {
491 setupresult=ph_SetupOpenGLImage(this, screen); 491 setupresult=ph_SetupOpenGLImage(this, screen);
492 } 492 }
493 else 493 else
494 { 494 {