NOTE: This is a candidate for stable branches.
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Acked-by: Paul Berry <stereotype441@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
#include "nv_object.xml.h"
#include "nv04_3d.xml.h"
#include "nv04_driver.h"
+#include "main/stencil.h"
static unsigned
get_comparison_op(unsigned op)
nv04->ctrl[1] |= NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_ENABLE;
nv04->ctrl[1] |= get_comparison_op(ctx->Stencil.Function[0]) << 4 |
- ctx->Stencil.Ref[0] << 8 |
+ _mesa_get_stencil_ref(ctx, 0) << 8 |
ctx->Stencil.ValueMask[0] << 16 |
ctx->Stencil.WriteMask[0] << 24;
#include "nv10_3d.xml.h"
#include "nv10_driver.h"
+#include "main/stencil.h"
+
void
nv10_emit_alpha_func(struct gl_context *ctx, int emit)
{
BEGIN_NV04(push, NV10_3D(STENCIL_FUNC_FUNC), 3);
PUSH_DATA (push, nvgl_comparison_op(ctx->Stencil.Function[0]));
- PUSH_DATA (push, ctx->Stencil.Ref[0]);
+ PUSH_DATA (push, _mesa_get_stencil_ref(ctx, 0));
PUSH_DATA (push, ctx->Stencil.ValueMask[0]);
}