Hello.
I finally upgraded to the v1.89.6 imgui which included the fix for the glBindSampler in #6375
Unfortunately I still noticed the flicker.
After stepping through the code on iOS, GlProfileIsES3 is not true.
I think the #ifdef order is not correct (or needs to be reworked):
|
#if !defined(IMGUI_IMPL_OPENGL_ES2) |
|
GLint major = 0; |
|
GLint minor = 0; |
|
glGetIntegerv(GL_MAJOR_VERSION, &major); |
|
glGetIntegerv(GL_MINOR_VERSION, &minor); |
|
if (major == 0 && minor == 0) |
|
{ |
|
// Query GL_VERSION in desktop GL 2.x, the string will start with "<major>.<minor>" |
|
const char* gl_version = (const char*)glGetString(GL_VERSION); |
|
sscanf(gl_version, "%d.%d", &major, &minor); |
|
} |
|
bd->GlVersion = (GLuint)(major * 100 + minor * 10); |
|
#if defined(GL_CONTEXT_PROFILE_MASK) |
|
glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &bd->GlProfileMask); |
|
bd->GlProfileIsCompat = (bd->GlProfileMask & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT) != 0; |
|
#endif |
|
|
|
bd->UseBufferSubData = false; |
|
/* |
|
// Query vendor to enable glBufferSubData kludge |
|
#ifdef _WIN32 |
|
if (const char* vendor = (const char*)glGetString(GL_VENDOR)) |
|
if (strncmp(vendor, "Intel", 5) == 0) |
|
bd->UseBufferSubData = true; |
|
#endif |
|
*/ |
|
#elif defined(IMGUI_IMPL_OPENGL_ES2) |
|
bd->GlVersion = 200; // GLES 2 |
|
bd->GlProfileIsES2 = true; |
|
#elif defined(IMGUI_IMPL_OPENGL_ES3) |
|
bd->GlVersion = 200; // Don't raise version as it is intended as a desktop version check for now. |
|
bd->GlProfileIsES3 = true; |
|
#endif |
You end up skipping the IMGUI_IMPL_OPENGL_ES3 path because of the !defined(IMGUI_IMPL_OPENGL_ES2)
Also, should bd->GlVersion = 200 be bd->GlVersion = 300 ?
Hello.
I finally upgraded to the
v1.89.6imgui which included the fix for theglBindSamplerin #6375Unfortunately I still noticed the flicker.
After stepping through the code on iOS,
GlProfileIsES3is not true.I think the
#ifdeforder is not correct (or needs to be reworked):imgui/backends/imgui_impl_opengl3.cpp
Lines 286 to 318 in 4fab72b
You end up skipping the
IMGUI_IMPL_OPENGL_ES3path because of the!defined(IMGUI_IMPL_OPENGL_ES2)Also, should
bd->GlVersion = 200bebd->GlVersion = 300?