devilhorns pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b2785f01c52ed7f6919c76ffe2bacfaf98bedeaf

commit b2785f01c52ed7f6919c76ffe2bacfaf98bedeaf
Author: Chris Michael <cp.mich...@samsung.com>
Date:   Wed Nov 4 11:18:25 2015 -0500

    evas-gl-drm: Find symlink for eglSetDamageRegionKHR
    
    In efforts to reduce tearing in the gl_drm engine, find and link to
    the eglSetDamageRegionKHR function so we can mark damaged regions of a
    surface
    
    @fix
    
    Signed-off-by: Chris Michael <cp.mich...@samsung.com>
---
 src/modules/evas/engines/gl_drm/evas_engine.c | 17 +++++++++++++++--
 src/modules/evas/engines/gl_drm/evas_engine.h |  1 +
 2 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/src/modules/evas/engines/gl_drm/evas_engine.c 
b/src/modules/evas/engines/gl_drm/evas_engine.c
index bfa9d58..145c5df 100644
--- a/src/modules/evas/engines/gl_drm/evas_engine.c
+++ b/src/modules/evas/engines/gl_drm/evas_engine.c
@@ -77,9 +77,10 @@ glsym_func_void_ptr glsym_evas_gl_common_current_context_get 
= NULL;
 _eng_fn (*glsym_eglGetProcAddress)(const char *a) = NULL;
 void *(*glsym_eglCreateImage)(EGLDisplay a, EGLContext b, EGLenum c, 
EGLClientBuffer d, const int *e) = NULL;
 void (*glsym_eglDestroyImage)(EGLDisplay a, void *b) = NULL;
-void (*glsym_glEGLImageTargetTexture2DOES)(int a, void *b)  = NULL;
+void (*glsym_glEGLImageTargetTexture2DOES)(int a, void *b) = NULL;
 unsigned int (*glsym_eglSwapBuffersWithDamage)(EGLDisplay a, void *b, const 
EGLint *d, EGLint c) = NULL;
 unsigned int (*glsym_eglQueryWaylandBufferWL)(EGLDisplay a, struct wl_resource 
*b, EGLint c, EGLint *d) = NULL;
+unsigned int (*glsym_eglSetDamageRegionKHR)(EGLDisplay a, EGLSurface b, EGLint 
*c, EGLint d) = NULL;
 
 /* local function prototypes */
 static void gl_symbols(void);
@@ -229,6 +230,9 @@ gl_symbols(void)
    FINDSYM(glsym_eglSwapBuffersWithDamage, "eglSwapBuffersWithDamage",
            glsym_func_uint);
 
+   FINDSYM(glsym_eglSetDamageRegionKHR, "eglSetDamageRegionKHR",
+           glsym_func_uint);
+
    FINDSYM(glsym_eglQueryWaylandBufferWL, "eglQueryWaylandBufferWL",
            glsym_func_uint);
 
@@ -253,8 +257,17 @@ gl_extn_veto(Render_Engine *re)
           {
              _extn_have_buffer_age = 0;
              glsym_eglSwapBuffersWithDamage = NULL;
+             glsym_eglSetDamageRegionKHR = NULL;
+          }
+        if (!strstr(str, "EGL_EXT_buffer_age"))
+          {
+             if (!strstr(str, "EGL_KHR_partial_update"))
+               _extn_have_buffer_age = 0;
           }
-        if (!strstr(str, "EGL_EXT_buffer_age")) _extn_have_buffer_age = 0;
+
+        if (!strstr(str, "EGL_KHR_partial_update"))
+          glsym_eglSetDamageRegionKHR = NULL;
+
         if (!strstr(str, "EGL_EXT_swap_buffers_with_damage"))
           glsym_eglSwapBuffersWithDamage = NULL;
      }
diff --git a/src/modules/evas/engines/gl_drm/evas_engine.h 
b/src/modules/evas/engines/gl_drm/evas_engine.h
index 740c305..1ef0e7c 100644
--- a/src/modules/evas/engines/gl_drm/evas_engine.h
+++ b/src/modules/evas/engines/gl_drm/evas_engine.h
@@ -142,5 +142,6 @@ _re_wincheck(Outbuf *ob)
 }
 
 extern unsigned int (*glsym_eglSwapBuffersWithDamage)(EGLDisplay a, void *b, 
const EGLint *d, EGLint c);
+extern unsigned int (*glsym_eglSetDamageRegionKHR)(EGLDisplay a, EGLSurface b, 
EGLint *c, EGLint d);
 
 #endif

-- 


Reply via email to