aboutsummaryrefslogtreecommitdiff
path: root/gl
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-12-25 20:23:51 +0100
committerMarc Haesen <marc@hc-consult.be>2011-12-25 20:23:51 +0100
commita4b099ae2dbb3a093e29f9a58a2067db9d9280f3 (patch)
tree6364ecb29fca042a557ce1c2ebb1be70aa2d9311 /gl
parent7fd4689bd7bac15dcc0ab13d4689a11e2c303681 (diff)
downloadvcxsrv-a4b099ae2dbb3a093e29f9a58a2067db9d9280f3.tar.gz
vcxsrv-a4b099ae2dbb3a093e29f9a58a2067db9d9280f3.tar.bz2
vcxsrv-a4b099ae2dbb3a093e29f9a58a2067db9d9280f3.zip
Solved compilation error
Diffstat (limited to 'gl')
-rw-r--r--gl/internal/dri_interface.h74
1 files changed, 71 insertions, 3 deletions
diff --git a/gl/internal/dri_interface.h b/gl/internal/dri_interface.h
index 7de74edb4..035f8e92c 100644
--- a/gl/internal/dri_interface.h
+++ b/gl/internal/dri_interface.h
@@ -55,6 +55,8 @@ typedef unsigned int drm_drawable_t;
typedef struct drm_clip_rect drm_clip_rect_t;
#endif
+#include <stdint.h>
+
/**
* \name DRI interface structures
*
@@ -681,7 +683,7 @@ struct __DRIlegacyExtensionRec {
* conjunction with the core extension.
*/
#define __DRI_SWRAST "DRI_SWRast"
-#define __DRI_SWRAST_VERSION 2
+#define __DRI_SWRAST_VERSION 3
struct __DRIswrastExtensionRec {
__DRIextension base;
@@ -701,6 +703,22 @@ struct __DRIswrastExtensionRec {
const __DRIconfig *config,
__DRIcontext *shared,
void *data);
+
+ /**
+ * Create a context for a particular API with a set of attributes
+ *
+ * \since version 3
+ *
+ * \sa __DRIdri2ExtensionRec::createContextAttribs
+ */
+ __DRIcontext *(*createContextAttribs)(__DRIscreen *screen,
+ int api,
+ const __DRIconfig *config,
+ __DRIcontext *shared,
+ unsigned num_attribs,
+ const uint32_t *attribs,
+ unsigned *error,
+ void *loaderPrivate);
};
/**
@@ -783,11 +801,45 @@ struct __DRIdri2LoaderExtensionRec {
* constructors for DRI2.
*/
#define __DRI_DRI2 "DRI_DRI2"
-#define __DRI_DRI2_VERSION 2
+#define __DRI_DRI2_VERSION 3
-#define __DRI_API_OPENGL 0
+#define __DRI_API_OPENGL 0 /**< OpenGL compatibility profile */
#define __DRI_API_GLES 1
#define __DRI_API_GLES2 2
+#define __DRI_API_OPENGL_CORE 3 /**< OpenGL 3.2+ core profile */
+
+#define __DRI_CTX_ATTRIB_MAJOR_VERSION 0
+#define __DRI_CTX_ATTRIB_MINOR_VERSION 1
+#define __DRI_CTX_ATTRIB_FLAGS 2
+
+#define __DRI_CTX_FLAG_DEBUG 0x00000001
+#define __DRI_CTX_FLAG_FORWARD_COMPATIBLE 0x00000002
+
+/**
+ * \name Reasons that __DRIdri2Extension::createContextAttribs might fail
+ */
+/*@{*/
+/** Success! */
+#define __DRI_CTX_ERROR_SUCCESS 0
+
+/** Memory allocation failure */
+#define __DRI_CTX_ERROR_NO_MEMORY 1
+
+/** Client requested an API (e.g., OpenGL ES 2.0) that the driver can't do. */
+#define __DRI_CTX_ERROR_BAD_API 2
+
+/** Client requested an API version that the driver can't do. */
+#define __DRI_CTX_ERROR_BAD_VERSION 3
+
+/** Client requested a flag or combination of flags the driver can't do. */
+#define __DRI_CTX_ERROR_BAD_FLAG 4
+
+/** Client requested an attribute the driver doesn't understand. */
+#define __DRI_CTX_ERROR_UNKNOWN_ATTRIBUTE 5
+
+/** Client requested a flag the driver doesn't understand. */
+#define __DRI_CTX_ERROR_UNKNOWN_FLAG 6
+/*@}*/
struct __DRIdri2ExtensionRec {
__DRIextension base;
@@ -822,6 +874,22 @@ struct __DRIdri2ExtensionRec {
int height);
void (*releaseBuffer)(__DRIscreen *screen,
__DRIbuffer *buffer);
+
+ /**
+ * Create a context for a particular API with a set of attributes
+ *
+ * \since version 3
+ *
+ * \sa __DRIswrastExtensionRec::createContextAttribs
+ */
+ __DRIcontext *(*createContextAttribs)(__DRIscreen *screen,
+ int api,
+ const __DRIconfig *config,
+ __DRIcontext *shared,
+ unsigned num_attribs,
+ const uint32_t *attribs,
+ unsigned *error,
+ void *loaderPrivate);
};