Merge branch 'lp-offset-twoside'
[mesa.git] / src / mesa / drivers / dri / nouveau / nouveau_util.h
index 584cb80ef62fa3e8479d8428f91b9f1d09103abd..6d01934dade5ea518bf96418418cd71b05112bce 100644 (file)
@@ -130,7 +130,7 @@ get_scissors(struct gl_framebuffer *fb, int *x, int *y, int *w, int *h)
 }
 
 static inline void
-get_viewport_scale(GLcontext *ctx, float a[16])
+get_viewport_scale(struct gl_context *ctx, float a[16])
 {
        struct gl_viewport_attrib *vp = &ctx->Viewport;
        struct gl_framebuffer *fb = ctx->DrawBuffer;
@@ -147,7 +147,7 @@ get_viewport_scale(GLcontext *ctx, float a[16])
 }
 
 static inline void
-get_viewport_translate(GLcontext *ctx, float a[4])
+get_viewport_translate(struct gl_context *ctx, float a[4])
 {
        struct gl_viewport_attrib *vp = &ctx->Viewport;
        struct gl_framebuffer *fb = ctx->DrawBuffer;
@@ -163,6 +163,12 @@ get_viewport_translate(GLcontext *ctx, float a[4])
        a[2] = fb->_DepthMaxF * (vp->Far + vp->Near) / 2;
 }
 
+static inline void
+OUT_RINGb(struct nouveau_channel *chan, GLboolean x)
+{
+       OUT_RING(chan, x ? 1 : 0);
+}
+
 static inline void
 OUT_RINGm(struct nouveau_channel *chan, float m[16])
 {