X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2Fswrast%2Fs_masking.c;h=2e68f8c4bd7d0f72c1e754fc8e26a33c0e7d6d62;hb=1be3764dbe8d8ab2259c206a2158fe8f3c62c962;hp=69c2feb6da899e713bcca55405375e2ae6328b22;hpb=080c40ab32b2abd6d8381b4a0cc143d36a1652b2;p=mesa.git diff --git a/src/mesa/swrast/s_masking.c b/src/mesa/swrast/s_masking.c index 69c2feb6da8..2e68f8c4bd7 100644 --- a/src/mesa/swrast/s_masking.c +++ b/src/mesa/swrast/s_masking.c @@ -40,7 +40,7 @@ * Apply the color mask to a span of rgba values. */ void -_swrast_mask_rgba_span(GLcontext *ctx, struct gl_renderbuffer *rb, +_swrast_mask_rgba_span(struct gl_context *ctx, struct gl_renderbuffer *rb, SWspan *span, GLuint buf) { const GLuint n = span->end; @@ -101,34 +101,3 @@ _swrast_mask_rgba_span(GLcontext *ctx, struct gl_renderbuffer *rb, } } } - - -/** - * Apply the index mask to a span of color index values. - */ -void -_swrast_mask_ci_span(GLcontext *ctx, struct gl_renderbuffer *rb, - SWspan *span) -{ - const GLuint srcMask = ctx->Color.IndexMask; - const GLuint dstMask = ~srcMask; - GLuint *index = span->array->index; - GLuint dest[MAX_WIDTH]; - GLuint i; - - ASSERT(span->arrayMask & SPAN_INDEX); - ASSERT(span->end <= MAX_WIDTH); - ASSERT(rb->DataType == GL_UNSIGNED_INT); - - if (span->arrayMask & SPAN_XY) { - _swrast_get_values(ctx, rb, span->end, span->array->x, span->array->y, - dest, sizeof(GLuint)); - } - else { - _swrast_read_index_span(ctx, rb, span->end, span->x, span->y, dest); - } - - for (i = 0; i < span->end; i++) { - index[i] = (index[i] & srcMask) | (dest[i] & dstMask); - } -}