Mercurial > sdl-ios-xcode
comparison src/video/SDL_renderer_gles.c @ 3161:494559cc723b
OpenPandora support added by David Carré
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 31 May 2009 11:53:12 +0000 |
parents | 7f684f249ec9 |
children | a252014ce27d |
comparison
equal
deleted
inserted
replaced
3160:210e209b87cc | 3161:494559cc723b |
---|---|
39 { | 39 { |
40 return; | 40 return; |
41 } | 41 } |
42 | 42 |
43 #endif /* __QNXNTO__ */ | 43 #endif /* __QNXNTO__ */ |
44 | |
45 #if SDL_VIDEO_DRIVER_PANDORA | |
46 GL_API void GL_APIENTRY | |
47 glDrawTexiOES(GLint x, GLint y, GLint z, GLint width, GLint height) | |
48 { | |
49 return; | |
50 } | |
51 #endif /* SDL_VIDEO_DRIVER_PANDORA */ | |
44 | 52 |
45 /* OpenGL ES 1.1 renderer implementation, based on the OpenGL renderer */ | 53 /* OpenGL ES 1.1 renderer implementation, based on the OpenGL renderer */ |
46 | 54 |
47 static const float inv255f = 1.0f / 255.0f; | 55 static const float inv255f = 1.0f / 255.0f; |
48 | 56 |
282 if (SDL_GL_GetAttribute(SDL_GL_DOUBLEBUFFER, &doublebuffer) == 0) { | 290 if (SDL_GL_GetAttribute(SDL_GL_DOUBLEBUFFER, &doublebuffer) == 0) { |
283 if (!doublebuffer) { | 291 if (!doublebuffer) { |
284 renderer->info.flags |= SDL_RENDERER_SINGLEBUFFER; | 292 renderer->info.flags |= SDL_RENDERER_SINGLEBUFFER; |
285 } | 293 } |
286 } | 294 } |
287 | 295 #if SDL_VIDEO_DRIVER_PANDORA |
296 data->GL_OES_draw_texture_supported = SDL_FALSE; | |
297 data->useDrawTexture = SDL_FALSE; | |
298 #else | |
288 if (SDL_GL_ExtensionSupported("GL_OES_draw_texture")) { | 299 if (SDL_GL_ExtensionSupported("GL_OES_draw_texture")) { |
289 data->GL_OES_draw_texture_supported = SDL_TRUE; | 300 data->GL_OES_draw_texture_supported = SDL_TRUE; |
290 data->useDrawTexture = SDL_TRUE; | 301 data->useDrawTexture = SDL_TRUE; |
291 } else { | 302 } else { |
292 data->GL_OES_draw_texture_supported = SDL_FALSE; | 303 data->GL_OES_draw_texture_supported = SDL_FALSE; |
293 data->useDrawTexture = SDL_FALSE; | 304 data->useDrawTexture = SDL_FALSE; |
294 } | 305 } |
306 #endif | |
295 | 307 |
296 data->glGetIntegerv(GL_MAX_TEXTURE_SIZE, &value); | 308 data->glGetIntegerv(GL_MAX_TEXTURE_SIZE, &value); |
297 renderer->info.max_texture_width = value; | 309 renderer->info.max_texture_width = value; |
298 data->glGetIntegerv(GL_MAX_TEXTURE_SIZE, &value); | 310 data->glGetIntegerv(GL_MAX_TEXTURE_SIZE, &value); |
299 renderer->info.max_texture_height = value; | 311 renderer->info.max_texture_height = value; |