[cogl/wip/outputs: 6/11] stash: Adds _USES_KMS constraint



commit 1fd98b1d71fbe3108156899dbf8828ee23125771
Author: Robert Bragg <robert linux intel com>
Date:   Fri Apr 19 01:27:18 2013 +0100

    stash: Adds _USES_KMS constraint

 cogl/cogl-renderer.h              |    4 +++-
 cogl/winsys/cogl-winsys-egl-kms.c |    2 ++
 2 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/cogl/cogl-renderer.h b/cogl/cogl-renderer.h
index a3b4fc2..c7e6a5a 100644
--- a/cogl/cogl-renderer.h
+++ b/cogl/cogl-renderer.h
@@ -265,6 +265,7 @@ cogl_renderer_connect (CoglRenderer *renderer, CoglError **error);
  *    renderer supports creating a #CoglGLES2Context via
  *    cogl_gles2_context_new(). This can be used to integrate GLES 2.0
  *    code into Cogl based applications.
+ * @COGL_RENDERER_CONSTRAINT_USES_KMS: Require the renderer to be KMS based
  *
  * These constraint flags are hard-coded features of the different renderer
  * backends. Sometimes a platform may support multiple rendering options which
@@ -286,7 +287,8 @@ typedef enum
   COGL_RENDERER_CONSTRAINT_USES_X11 = (1 << 0),
   COGL_RENDERER_CONSTRAINT_USES_XLIB = (1 << 1),
   COGL_RENDERER_CONSTRAINT_USES_EGL = (1 << 2),
-  COGL_RENDERER_CONSTRAINT_SUPPORTS_COGL_GLES2 = (1 << 3)
+  COGL_RENDERER_CONSTRAINT_SUPPORTS_COGL_GLES2 = (1 << 3),
+  COGL_RENDERER_CONSTRAINT_USES_KMS = (1 << 4)
 } CoglRendererConstraint;
 
 
diff --git a/cogl/winsys/cogl-winsys-egl-kms.c b/cogl/winsys/cogl-winsys-egl-kms.c
index 2b8baaa..02d3f8a 100644
--- a/cogl/winsys/cogl-winsys-egl-kms.c
+++ b/cogl/winsys/cogl-winsys-egl-kms.c
@@ -1179,6 +1179,8 @@ _cogl_winsys_egl_kms_get_vtable (void)
       vtable.id = COGL_WINSYS_ID_EGL_KMS;
       vtable.name = "EGL_KMS";
 
+      vtable.constraints |= COGL_RENDERER_CONSTRAINT_USES_KMS;
+
       vtable.renderer_connect = _cogl_winsys_renderer_connect;
       vtable.renderer_disconnect = _cogl_winsys_renderer_disconnect;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]