summaryrefslogtreecommitdiff
path: root/dri2proto.h
diff options
context:
space:
mode:
authorChad Versace <chad.versace@linux.intel.com>2012-05-02 12:03:31 -0700
committerChad Versace <chad.versace@linux.intel.com>2012-05-21 14:39:41 -0700
commit652fe8d9dd2393127b11741ba63cb95a83ad454f (patch)
treee3e6b87fee1d0bb04fe5575b2d57c248472fd933 /dri2proto.h
parent428688d1eaa3d0faa13a61613cdaeaabcb351f0e (diff)
dri2proto: Add DRI2GetParam request
Bump protocol version to 1.4. Bump package version to 2.7. This new protocol request effectively allows clients to perform feature detection on the DDX. If I had DRI2GetParam in June 2011, when I was implementing support in the Intel DDX and Mesa for new hardware that required a new DRI2 attachment format, then I could have avoided a week of pain caused by the necessity to write a horrid feature detection hack [1] in Mesa. In the future, when the work begins to add MSAA support to the Intel DDX, having a clean way to do feature detection will allow us to avoid revisiting and expanding that hack. [1] mesa, commit aea2236a, function intel_verify_dri2_has_hi Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Ian Romanick <idr@freedesktop.org> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
Diffstat (limited to 'dri2proto.h')
-rw-r--r--dri2proto.h28
1 files changed, 26 insertions, 2 deletions
diff --git a/dri2proto.h b/dri2proto.h
index cd82afb..128b807 100644
--- a/dri2proto.h
+++ b/dri2proto.h
@@ -35,11 +35,11 @@
#define DRI2_NAME "DRI2"
#define DRI2_MAJOR 1
-#define DRI2_MINOR 3
+#define DRI2_MINOR 4
#define DRI2NumberErrors 0
#define DRI2NumberEvents 2
-#define DRI2NumberRequests 13
+#define DRI2NumberRequests 14
#define X_DRI2QueryVersion 0
#define X_DRI2Connect 1
@@ -54,6 +54,7 @@
#define X_DRI2WaitMSC 10
#define X_DRI2WaitSBC 11
#define X_DRI2SwapInterval 12
+#define X_DRI2GetParam 13
/*
* Events
@@ -330,4 +331,27 @@ typedef struct {
} xDRI2InvalidateBuffers;
#define sz_xDRI2InvalidateBuffers 32
+typedef struct {
+ CARD8 reqType;
+ CARD8 dri2ReqType;
+ CARD16 length B16;
+ CARD32 drawable B32;
+ CARD32 param B32;
+} xDRI2GetParamReq;
+#define sz_xDRI2GetParamReq 12
+
+typedef struct {
+ BYTE type; /*X_Reply*/
+ BOOL is_param_recognized;
+ CARD16 sequenceNumber B16;
+ CARD32 length B32;
+ CARD32 value_hi B32;
+ CARD32 value_lo B32;
+ CARD32 pad1 B32;
+ CARD32 pad2 B32;
+ CARD32 pad3 B32;
+ CARD32 pad4 B32;
+} xDRI2GetParamReply;
+#define sz_xDRI2GetParamReply 32
+
#endif