* Wayland Egl Engine: Add support for Multi-Sample Anti-Aliasing and GL Direct Images.
Add support for using native image binding.
Add support for setting GL surface capabilities.
+
+2012-08-30 Carsten Haitzler (The Rasterman)
+
+ 1.7.0 release
+
+2012-09-05 Carsten Haitzler (The Rasterman)
+
+ * Fix EGL/GLES bug when setting up rgba dest alpha windows where they
+ cease to be rendered to. use a shared context and it works.
+
#if defined (GLES_VARIETY_S3C6410) || defined (GLES_VARIETY_SGX)
static EGLContext context = EGL_NO_CONTEXT;
-static EGLContext rgba_context = EGL_NO_CONTEXT;
#else
// FIXME: this will only work for 1 display connection (glx land can have > 1)
static GLXContext context = 0;
eng_window_free(gw);
return NULL;
}
- if (gw->alpha)
- {
- if (rgba_context == EGL_NO_CONTEXT)
- rgba_context = eglCreateContext(gw->egl_disp, gw->egl_config, NULL,
- context_attrs);
- gw->egl_context[0] = rgba_context;
- }
- else
- {
- if (context == EGL_NO_CONTEXT)
- context = eglCreateContext(gw->egl_disp, gw->egl_config, NULL,
- context_attrs);
- gw->egl_context[0] = context;
- }
+
+ gw->egl_context[0] = eglCreateContext
+ (gw->egl_disp, gw->egl_config, context, context_attrs);
if (gw->egl_context[0] == EGL_NO_CONTEXT)
{
ERR("eglCreateContext() fail. code=%#x", eglGetError());
eng_window_free(gw);
return NULL;
}
+ if (context == EGL_NO_CONTEXT) context = gw->egl_context[0];
+
if (eglMakeCurrent(gw->egl_disp,
gw->egl_surface[0],
gw->egl_surface[0],
eglMakeCurrent(gw->egl_disp, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
if (gw->egl_surface[0] != EGL_NO_SURFACE)
eglDestroySurface(gw->egl_disp, gw->egl_surface[0]);
+ if (gw->egl_context[0] != context)
+ eglDestroyContext(gw->egl_disp, gw->egl_context[0]);
if (ref == 0)
{
if (context) eglDestroyContext(gw->egl_disp, context);
- if (rgba_context) eglDestroyContext(gw->egl_disp, rgba_context);
eglTerminate(gw->egl_disp);
context = EGL_NO_CONTEXT;
- rgba_context = EGL_NO_CONTEXT;
}
#else
if (gw->glxwin) glXDestroyWindow(gw->disp, gw->glxwin);