summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2013-09-27 11:39:25 -0700
committerEric Anholt <eric@anholt.net>2013-10-24 14:04:20 -0700
commitf93533d118b6dab00022cc9bc1448615a25946dc (patch)
treeeac8fb7a9f34ba1f8b14738aef46dfc0184c6dd1 /include
parent67caf36489e29c93ed1a25541944b191ed50df52 (diff)
downloadmesa-f93533d118b6dab00022cc9bc1448615a25946dc.tar.gz
mesa-f93533d118b6dab00022cc9bc1448615a25946dc.tar.bz2
mesa-f93533d118b6dab00022cc9bc1448615a25946dc.zip
dri: Pass in the dlsym()ed driver extension to screen creation.
This will allow a megadrivers build to reference the actual driver being loaded from the shared dri_util screen creation code. v2: Fix indentation, fallback case in EGL (review by Emil). Reviewed-by: Matt Turner <mattst88@gmail.com> (v1) Reviewed-by: Chad Versace <chad.versace@linux.intel.com> (v1) Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Diffstat (limited to 'include')
-rw-r--r--include/GL/internal/dri_interface.h27
1 files changed, 25 insertions, 2 deletions
diff --git a/include/GL/internal/dri_interface.h b/include/GL/internal/dri_interface.h
index 2122ae9ed48..a7afa224664 100644
--- a/include/GL/internal/dri_interface.h
+++ b/include/GL/internal/dri_interface.h
@@ -713,7 +713,7 @@ struct __DRIlegacyExtensionRec {
* conjunction with the core extension.
*/
#define __DRI_SWRAST "DRI_SWRast"
-#define __DRI_SWRAST_VERSION 3
+#define __DRI_SWRAST_VERSION 4
struct __DRIswrastExtensionRec {
__DRIextension base;
@@ -749,6 +749,18 @@ struct __DRIswrastExtensionRec {
const uint32_t *attribs,
unsigned *error,
void *loaderPrivate);
+
+ /**
+ * createNewScreen() with the driver extensions passed in.
+ *
+ * \since version 4
+ */
+ __DRIscreen *(*createNewScreen2)(int screen,
+ const __DRIextension **loader_extensions,
+ const __DRIextension **driver_extensions,
+ const __DRIconfig ***driver_configs,
+ void *loaderPrivate);
+
};
/**
@@ -831,7 +843,7 @@ struct __DRIdri2LoaderExtensionRec {
* constructors for DRI2.
*/
#define __DRI_DRI2 "DRI_DRI2"
-#define __DRI_DRI2_VERSION 3
+#define __DRI_DRI2_VERSION 4
#define __DRI_API_OPENGL 0 /**< OpenGL compatibility profile */
#define __DRI_API_GLES 1 /**< OpenGL ES 1.x */
@@ -939,6 +951,17 @@ struct __DRIdri2ExtensionRec {
const uint32_t *attribs,
unsigned *error,
void *loaderPrivate);
+
+ /**
+ * createNewScreen with the driver's extension list passed in.
+ *
+ * \since version 4
+ */
+ __DRIscreen *(*createNewScreen2)(int screen, int fd,
+ const __DRIextension **loader_extensions,
+ const __DRIextension **driver_extensions,
+ const __DRIconfig ***driver_configs,
+ void *loaderPrivate);
};