summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/radeon
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2012-03-11 18:31:32 -0600
committerBrian Paul <[email protected]>2012-03-12 11:40:43 -0600
commite0ed951e1361e54ffd8e9c56fbcc2027c0c4bd24 (patch)
tree2d17170304448ba99f15cc962ba1574452279b26 /src/mesa/drivers/dri/radeon
parent5bb2059be714c09bd0fbc9aebd7dabf1ba3e63b6 (diff)
radeon/r200: remove ClearDepth() and ClearStencil() driver hooks
The computed stencil.clear and depth.clear values aren't used anywhere. Those fields have been removed too. Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/radeon')
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_common_context.h6
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_state.c27
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_state_init.c13
3 files changed, 0 insertions, 46 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_common_context.h b/src/mesa/drivers/dri/radeon/radeon_common_context.h
index 80ae2d1e380..fdffb1ec04e 100644
--- a/src/mesa/drivers/dri/radeon/radeon_common_context.h
+++ b/src/mesa/drivers/dri/radeon/radeon_common_context.h
@@ -117,7 +117,6 @@ struct radeon_colorbuffer_state {
};
struct radeon_depthbuffer_state {
- GLuint clear;
struct gl_renderbuffer *rb;
};
@@ -130,10 +129,6 @@ struct radeon_scissor_state {
drm_clip_rect_t *pClipRects;
};
-struct radeon_stencilbuffer_state {
- GLuint clear; /* rb3d_stencilrefmask value */
-};
-
struct radeon_state_atom {
struct radeon_state_atom *next, *prev;
const char *name; /* for debug */
@@ -377,7 +372,6 @@ struct radeon_state {
struct radeon_colorbuffer_state color;
struct radeon_depthbuffer_state depth;
struct radeon_scissor_state scissor;
- struct radeon_stencilbuffer_state stencil;
};
/**
diff --git a/src/mesa/drivers/dri/radeon/radeon_state.c b/src/mesa/drivers/dri/radeon/radeon_state.c
index a207940e526..dcec8138594 100644
--- a/src/mesa/drivers/dri/radeon/radeon_state.c
+++ b/src/mesa/drivers/dri/radeon/radeon_state.c
@@ -305,22 +305,6 @@ static void radeonDepthMask( struct gl_context *ctx, GLboolean flag )
}
}
-static void radeonClearDepth( struct gl_context *ctx, GLclampd d )
-{
- r100ContextPtr rmesa = R100_CONTEXT(ctx);
- GLuint format = (rmesa->hw.ctx.cmd[CTX_RB3D_ZSTENCILCNTL] &
- RADEON_DEPTH_FORMAT_MASK);
-
- switch ( format ) {
- case RADEON_DEPTH_FORMAT_16BIT_INT_Z:
- rmesa->radeon.state.depth.clear = d * 0x0000ffff;
- break;
- case RADEON_DEPTH_FORMAT_24BIT_INT_Z:
- rmesa->radeon.state.depth.clear = d * 0x00ffffff;
- break;
- }
-}
-
/* =============================================================
* Fog
@@ -1346,15 +1330,6 @@ static void radeonStencilOpSeparate( struct gl_context *ctx, GLenum face, GLenum
}
}
-static void radeonClearStencil( struct gl_context *ctx, GLint s )
-{
- r100ContextPtr rmesa = R100_CONTEXT(ctx);
-
- rmesa->radeon.state.stencil.clear =
- ((GLuint) (ctx->Stencil.Clear & 0xff) |
- (0xff << RADEON_STENCIL_MASK_SHIFT) |
- ((ctx->Stencil.WriteMask[0] & 0xff) << RADEON_STENCIL_WRITEMASK_SHIFT));
-}
/* =============================================================
@@ -2234,8 +2209,6 @@ void radeonInitStateFuncs( struct gl_context *ctx )
ctx->Driver.BlendEquationSeparate = radeonBlendEquationSeparate;
ctx->Driver.BlendFuncSeparate = radeonBlendFuncSeparate;
ctx->Driver.ClearColor = radeonClearColor;
- ctx->Driver.ClearDepth = radeonClearDepth;
- ctx->Driver.ClearStencil = radeonClearStencil;
ctx->Driver.ClipPlane = radeonClipPlane;
ctx->Driver.ColorMask = radeonColorMask;
ctx->Driver.CullFace = radeonCullFace;
diff --git a/src/mesa/drivers/dri/radeon/radeon_state_init.c b/src/mesa/drivers/dri/radeon/radeon_state_init.c
index 151f4f5145a..1f445b27e3b 100644
--- a/src/mesa/drivers/dri/radeon/radeon_state_init.c
+++ b/src/mesa/drivers/dri/radeon/radeon_state_init.c
@@ -508,19 +508,6 @@ void radeonInitState( r100ContextPtr rmesa )
rmesa->radeon.state.color.clear = 0x00000000;
- switch ( ctx->Visual.depthBits ) {
- case 16:
- rmesa->radeon.state.depth.clear = 0x0000ffff;
- rmesa->radeon.state.stencil.clear = 0x00000000;
- break;
- case 24:
- rmesa->radeon.state.depth.clear = 0x00ffffff;
- rmesa->radeon.state.stencil.clear = 0xffff0000;
- break;
- default:
- break;
- }
-
rmesa->radeon.Fallback = 0;