*
*/
static GLboolean
-stencil_and_ztest_span(GLcontext *ctx, struct sw_span *span, GLuint face)
+stencil_and_ztest_span(GLcontext *ctx, SWspan *span, GLuint face)
{
struct gl_framebuffer *fb = ctx->DrawBuffer;
struct gl_renderbuffer *rb = fb->_StencilBuffer;
}
#endif
- stencil = rb->GetPointer(ctx, rb, x, y);
+ stencil = (GLstencil *) rb->GetPointer(ctx, rb, x, y);
if (!stencil) {
rb->GetRow(ctx, rb, n, x, y, stencilRow);
stencil = stencilRow;
* GL_TRUE - one or more fragments passed the testing
*/
static GLboolean
-stencil_and_ztest_pixels( GLcontext *ctx, struct sw_span *span, GLuint face )
+stencil_and_ztest_pixels( GLcontext *ctx, SWspan *span, GLuint face )
{
struct gl_framebuffer *fb = ctx->DrawBuffer;
struct gl_renderbuffer *rb = fb->_StencilBuffer;
* GL_FALSE = all fragments failed.
*/
GLboolean
-_swrast_stencil_and_ztest_span(GLcontext *ctx, struct sw_span *span)
+_swrast_stencil_and_ztest_span(GLcontext *ctx, SWspan *span)
{
/* span->facing can only be non-zero if using two-sided stencil */
ASSERT(ctx->Stencil._TestTwoSide || span->facing == 0);
if (rb->DataType == GL_UNSIGNED_BYTE) {
GLint i, j;
for (i = 0; i < height; i++) {
- GLubyte *stencil = rb->GetPointer(ctx, rb, x, y + i);
+ GLubyte *stencil = (GLubyte*) rb->GetPointer(ctx, rb, x, y + i);
for (j = 0; j < width; j++) {
stencil[j] = (stencil[j] & invMask) | clearVal;
}
else {
GLint i, j;
for (i = 0; i < height; i++) {
- GLushort *stencil = rb->GetPointer(ctx, rb, x, y + i);
+ GLushort *stencil = (GLushort*) rb->GetPointer(ctx, rb, x, y + i);
for (j = 0; j < width; j++) {
stencil[j] = (stencil[j] & invMask) | clearVal;
}
if (width == rb->Width && rb->DataType == GL_UNSIGNED_BYTE) {
/* optimized case */
/* Note: bottom-to-top raster assumed! */
- GLubyte *stencil = rb->GetPointer(ctx, rb, x, y);
+ GLubyte *stencil = (GLubyte *) rb->GetPointer(ctx, rb, x, y);
GLuint len = width * height * sizeof(GLubyte);
_mesa_memset(stencil, clearVal, len);
}
_mesa_memset(stencil, clearVal, width);
}
else {
- _mesa_memset16(stencil, clearVal, width);
+ _mesa_memset16((short unsigned int*) stencil, clearVal, width);
}
}
}