forked from enlightenment/efl
egl actually doesnt need a full reset - we CAN get the current context
and draw/read surfaces. SVN revision: 55977
This commit is contained in:
parent
13df30ab2b
commit
d7e8cfba62
|
@ -541,7 +541,11 @@ eng_output_redraws_next_update_get(void *data, int *x, int *y, int *w, int *h, i
|
|||
re = (Render_Engine *)data;
|
||||
/* get the upate rect surface - return engine data as dummy */
|
||||
if (!re->win->draw.redraw) return NULL;
|
||||
#if defined (GLES_VARIETY_S3C6410) || defined (GLES_VARIETY_SGX)
|
||||
// dont need to for egl - eng_window_use() can check for other ctxt's
|
||||
#else
|
||||
eng_window_use(NULL);
|
||||
#endif
|
||||
eng_window_use(re->win);
|
||||
if (!_re_wincheck(re)) return NULL;
|
||||
evas_gl_common_context_flush(re->win->gl_context);
|
||||
|
|
|
@ -477,7 +477,22 @@ eng_window_free(Evas_GL_X11_Window *gw)
|
|||
void
|
||||
eng_window_use(Evas_GL_X11_Window *gw)
|
||||
{
|
||||
if (_evas_gl_x11_window != gw)
|
||||
Eina_Bool force_use = EINA_FALSE;
|
||||
|
||||
#if defined (GLES_VARIETY_S3C6410) || defined (GLES_VARIETY_SGX)
|
||||
if (_evas_gl_x11_window)
|
||||
{
|
||||
if ((eglGetCurrentContext() !=
|
||||
_evas_gl_x11_window->egl_context[0]) ||
|
||||
(eglGetCurrentSurface(EGL_READ) !=
|
||||
_evas_gl_x11_window->egl_surface[0]) ||
|
||||
(eglGetCurrentSurface(EGL_DRAW) !=
|
||||
_evas_gl_x11_window->egl_surface[0]))
|
||||
force_use = EINA_TRUE;
|
||||
}
|
||||
#else
|
||||
#endif
|
||||
if ((_evas_gl_x11_window != gw) || (force_use))
|
||||
{
|
||||
if (_evas_gl_x11_window)
|
||||
evas_gl_common_context_flush(_evas_gl_x11_window->gl_context);
|
||||
|
|
Loading…
Reference in New Issue