summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/swrast/swrast_priv.h
diff options
context:
space:
mode:
authorGeorge Sapountzis <gsapountzis@gmail.com>2010-03-14 11:36:45 +0200
committerGeorge Sapountzis <gsapountzis@gmail.com>2010-03-15 01:17:17 +0200
commitcf8a1caa231b748d3ba7c776ab076ad3de99e963 (patch)
tree97da7f8c27abbdd8c991a667ea01d52145858e66 /src/mesa/drivers/dri/swrast/swrast_priv.h
parent6e376485c10896229f7bfaf5b0cce9c8b67f61b1 (diff)
dri/swrast: port to dri_sw (context)
Diffstat (limited to 'src/mesa/drivers/dri/swrast/swrast_priv.h')
-rw-r--r--src/mesa/drivers/dri/swrast/swrast_priv.h27
1 files changed, 21 insertions, 6 deletions
diff --git a/src/mesa/drivers/dri/swrast/swrast_priv.h b/src/mesa/drivers/dri/swrast/swrast_priv.h
index c83c64b487..130598bbd8 100644
--- a/src/mesa/drivers/dri/swrast/swrast_priv.h
+++ b/src/mesa/drivers/dri/swrast/swrast_priv.h
@@ -59,6 +59,27 @@
/**
* Data types
*/
+struct dri_context
+{
+ /* mesa */
+ GLcontext Base;
+
+ /* dri */
+ __DRIcontext *cPriv;
+};
+
+static INLINE struct dri_context *
+dri_context(__DRIcontext * driContextPriv)
+{
+ return (struct dri_context *)driContextPriv->driverPrivate;
+}
+
+static INLINE struct dri_context *
+swrast_context(GLcontext *ctx)
+{
+ return (struct dri_context *) ctx;
+}
+
struct swrast_renderbuffer {
struct gl_renderbuffer Base;
@@ -68,12 +89,6 @@ struct swrast_renderbuffer {
GLuint bpp;
};
-static INLINE __DRIcontext *
-swrast_context(GLcontext *ctx)
-{
- return (__DRIcontext *) ctx;
-}
-
static INLINE __DRIdrawable *
swrast_drawable(GLframebuffer *fb)
{