iOS/buildlibs/armv7/allegro-4.4.2/addons/allegrogl/src/amesa/raster.c
/* Write a horizontal span of values into the depth buffer.  Only write
 * depth[i] value if mask[i] is nonzero.
 */
Write a horizontal span of values into the depth buffer.  Only write
depth[i] value if mask[i] is nonzero.
Write a horizontal span of values into the depth buffer . Only write depth [ i ] value if mask [ i ] is nonzero .
static void AMesaWriteDepthSpan( GLcontext *ctx, GLuint n, GLint x, GLint y,
	const GLdepth depth[], const GLubyte mask[])
{
	AMesaContext context = (AMesaContext)(ctx->DriverCtx);
	BITMAP *bmp = context->Buffer->Active;
	float* zb_addr = (float*)(bmp_write_line(context->Buffer->DepthBuffer, bmp->h - y) + x * sizeof(float));
	while (n--) {
		if (mask[0])
			zb_addr[0] = 1. / depth[0];
		zb_addr++;
		mask++;
		depth++;
	}
}
static void AMesaWriteDepthSpan ( GLcontext * ctx , GLuint n , GLint x , GLint y , const GLdepth depth [ ] , const GLubyte mask [ ] ) { AMesaContext context = ( AMesaContext ) ( ctx -> DriverCtx ) ; BITMAP * bmp = context -> Buffer -> Active ; float * zb_addr = ( float * ) ( bmp_write_line ( context -> Buffer -> DepthBuffer , bmp -> h - y ) + x * sizeof ( float ) ) ; while ( n -- ) { if ( mask [ 0 ] ) zb_addr [ 0 ] = 1. / depth [ 0 ] ; zb_addr ++ ; mask ++ ; depth ++ ; } }
Write a horizontal span of values into the depth buffer.
Write a horizontal span of values into the depth buffer .