Prefer the OpenGL ES 2.0 context when it's available, make it possible to create an OpenGL 2.0 context on iPhoneOS
This commit is contained in:
parent
ccdb593a0b
commit
b1c0c48f03
8 changed files with 99 additions and 72 deletions
|
@ -184,6 +184,9 @@ GLES_CreateRenderer(SDL_Window * window, Uint32 flags)
|
|||
|
||||
renderer->info.flags = SDL_RENDERER_ACCELERATED;
|
||||
|
||||
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 1);
|
||||
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1);
|
||||
|
||||
data->context = SDL_GL_CreateContext(window);
|
||||
if (!data->context) {
|
||||
GLES_DestroyRenderer(renderer);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue