40 lines
1.5 KiB
Diff
40 lines
1.5 KiB
Diff
|
diff -uNr gl4es/src/glx/glx.c gl4es.mod/src/glx/glx.c
|
||
|
--- gl4es/src/glx/glx.c 2021-10-13 23:49:59.663443188 +0800
|
||
|
+++ gl4es.mod/src/glx/glx.c 2021-10-13 23:48:57.699443233 +0800
|
||
|
@@ -770,8 +770,11 @@
|
||
|
}
|
||
|
|
||
|
result = egl_eglChooseConfig(eglDisplay, configAttribs, fake->eglConfigs, 64, &fake->eglConfigsCount);
|
||
|
+
|
||
|
+#ifndef NO_GBM
|
||
|
if(fake->eglConfigsCount && globals4es.usegbm)
|
||
|
fake->eglconfigIdx = FindGBMConfig(eglDisplay, fake->eglConfigs, fake->eglConfigsCount);
|
||
|
+#endif
|
||
|
|
||
|
CheckEGLErrors();
|
||
|
if (result != EGL_TRUE || fake->eglConfigsCount == 0) {
|
||
|
@@ -951,10 +954,12 @@
|
||
|
}
|
||
|
|
||
|
result = egl_eglChooseConfig(eglDisplay, configAttribs, fake->eglConfigs, 64, &fake->eglConfigsCount);
|
||
|
+
|
||
|
+ fake->eglconfigIdx = 0;
|
||
|
+#ifndef NO_GBM
|
||
|
if(fake->eglConfigsCount && globals4es.usegbm)
|
||
|
fake->eglconfigIdx = FindGBMConfig(eglDisplay, fake->eglConfigs, fake->eglConfigsCount);
|
||
|
- else
|
||
|
- fake->eglconfigIdx = 0;
|
||
|
+#endif
|
||
|
|
||
|
CheckEGLErrors();
|
||
|
if (result != EGL_TRUE || fake->eglConfigsCount == 0) {
|
||
|
@@ -1819,7 +1824,7 @@
|
||
|
attr[cur++] = EGL_STENCIL_SIZE;
|
||
|
attr[cur++] = tmp;
|
||
|
}
|
||
|
- attr[1] |= (globals4es.usepbuffer)?(/*EGL_PBUFFER_BIT|*/EGL_PIXMAP_BIT):EGL_WINDOW_BIT;
|
||
|
+ attr[1] |= (globals4es.usepbuffer)?(EGL_PBUFFER_BIT/*|EGL_PIXMAP_BIT*/):EGL_WINDOW_BIT;
|
||
|
|
||
|
attr[cur++] = EGL_RENDERABLE_TYPE;
|
||
|
attr[cur++] = (hardext.esversion==1)?EGL_OPENGL_ES_BIT:EGL_OPENGL_ES2_BIT;
|