BUGS.txt
author Sam Lantinga <slouken@libsdl.org>
Wed, 18 Oct 2017 08:52:04 -0700
changeset 11630 ad4b5d85edee
parent 10952 fabcc99bb455
permissions -rw-r--r--
Fixed bug 3821 - Allow SDL_CreateWindow and SDL_CreateRenderer with OpenGL ES 3.0 (GLES3) for Angle (Windows)

Carlos

Angle supports GLES3 but when using these functions (SDL_CreateWindow and SDL_CreateRenderer), defaults again to GLES2.0.

A current workaround (hack) to retrieve a GLES3.0 context with Angle is:

1) set

SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 0);

after InitSDL AND after calling SDL_CreateWindow (before SDL_CreateRenderer)

2) Comment lines 2032-2044 in SDL_render_gles2.c, funtion GLES2_CreateRenderer

window_flags = SDL_GetWindowFlags(window);
if (!(window_flags & SDL_WINDOW_OPENGL) ||
profile_mask != SDL_GL_CONTEXT_PROFILE_ES || major != RENDERER_CONTEXT_MAJOR || minor != RENDERER_CONTEXT_MINOR) {

changed_window = SDL_TRUE;
SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_ES);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, RENDERER_CONTEXT_MAJOR);
SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, RENDERER_CONTEXT_MINOR);

if (SDL_RecreateWindow(window, window_flags | SDL_WINDOW_OPENGL) < 0) {
goto error;
}
}

This retrives a GLES3 context as confirmed using glGetString(GL_VERSION). This should be fixed by modifying a few if's.
slouken@7222
     1
slouken@7222
     2
Bugs are now managed in the SDL bug tracker, here:
slouken@7222
     3
icculus@10236
     4
    https://bugzilla.libsdl.org/
slouken@7222
     5
slouken@7222
     6
You may report bugs there, and search to see if a given issue has already
slouken@7222
     7
 been reported, discussed, and maybe even fixed.
slouken@7222
     8
slouken@7222
     9
icculus@10952
    10
You may also find help at the SDL forums/mailing list:
slouken@7222
    11
icculus@10952
    12
    https://discourse.libsdl.org/
slouken@7222
    13
slouken@7222
    14
Bug reports are welcome here, but we really appreciate if you use Bugzilla, as
slouken@7222
    15
 bugs discussed on the mailing list may be forgotten or missed.
slouken@7222
    16