replaced gl_ prefix with _mesa_ prefix on depth funcs

This commit is contained in:
Brian Paul
2000-02-02 22:16:04 +00:00
parent b34024bc62
commit 4bad6744d2
4 changed files with 32 additions and 28 deletions

View File

@@ -1,4 +1,4 @@
/* $Id: buffers.c,v 1.2 2000/02/02 21:52:26 brianp Exp $ */
/* $Id: buffers.c,v 1.3 2000/02/02 22:16:04 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -292,7 +292,7 @@ _mesa_Clear( GLbitfield mask )
/* do software clearing here */
if (newMask) {
if (newMask & ctx->Color.DrawDestMask) clear_color_buffers( ctx );
if (newMask & GL_DEPTH_BUFFER_BIT) gl_clear_depth_buffer( ctx );
if (newMask & GL_DEPTH_BUFFER_BIT) _mesa_clear_depth_buffer( ctx );
if (newMask & GL_ACCUM_BUFFER_BIT) _mesa_clear_accum_buffer( ctx );
if (newMask & GL_STENCIL_BUFFER_BIT) gl_clear_stencil_buffer( ctx );
}
@@ -550,7 +550,7 @@ _mesa_ResizeBuffersMESA( void )
/* Reallocate other buffers if needed. */
if (ctx->DrawBuffer->UseSoftwareDepthBuffer) {
gl_alloc_depth_buffer( ctx );
_mesa_alloc_depth_buffer( ctx );
}
if (ctx->DrawBuffer->UseSoftwareStencilBuffer) {
gl_alloc_stencil_buffer( ctx );

View File

@@ -1,4 +1,4 @@
/* $Id: depth.c,v 1.11 1999/12/10 19:09:22 brianp Exp $ */
/* $Id: depth.c,v 1.12 2000/02/02 22:16:04 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -370,8 +370,8 @@ depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
* Apply depth test to span of fragments. Hardware or software z buffer.
*/
GLuint
gl_depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
const GLdepth z[], GLubyte mask[] )
_mesa_depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
const GLdepth z[], GLubyte mask[] )
{
GLdepth zbuffer[MAX_WIDTH];
GLdepth *zptr;
@@ -881,9 +881,10 @@ hardware_depth_test_pixels( GLcontext *ctx, GLuint n, GLdepth zbuffer[],
void gl_depth_test_pixels( GLcontext *ctx,
GLuint n, const GLint x[], const GLint y[],
const GLdepth z[], GLubyte mask[] )
void
_mesa_depth_test_pixels( GLcontext *ctx,
GLuint n, const GLint x[], const GLint y[],
const GLdepth z[], GLubyte mask[] )
{
if (ctx->Driver.ReadDepthPixels) {
/* read depth values from hardware Z buffer */
@@ -918,8 +919,9 @@ void gl_depth_test_pixels( GLcontext *ctx,
* x,y - location of first pixel
* Output: depth - the array of depth values
*/
void gl_read_depth_span_float( GLcontext* ctx,
GLuint n, GLint x, GLint y, GLfloat depth[] )
void
_mesa_read_depth_span_float( GLcontext* ctx,
GLuint n, GLint x, GLint y, GLfloat depth[] )
{
const GLfloat scale = 1.0F / DEPTH_SCALE;
@@ -960,7 +962,8 @@ void gl_read_depth_span_float( GLcontext* ctx,
* it will be free()'d. The new depth buffer will be uniniitalized.
* This function is only called through Driver.alloc_depth_buffer.
*/
void gl_alloc_depth_buffer( GLcontext* ctx )
void
_mesa_alloc_depth_buffer( GLcontext* ctx )
{
/* deallocate current depth buffer if present */
if (ctx->DrawBuffer->UseSoftwareDepthBuffer) {
@@ -990,7 +993,8 @@ void gl_alloc_depth_buffer( GLcontext* ctx )
* allocate it now.
* This function is only called through Driver.clear_depth_buffer.
*/
void gl_clear_depth_buffer( GLcontext* ctx )
void
_mesa_clear_depth_buffer( GLcontext* ctx )
{
GLdepth clear_value = (GLdepth) (ctx->Depth.Clear * DEPTH_SCALE);

View File

@@ -1,4 +1,4 @@
/* $Id: depth.h,v 1.5 1999/12/10 19:09:22 brianp Exp $ */
/* $Id: depth.h,v 1.6 2000/02/02 22:16:04 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -60,26 +60,26 @@ _mesa_DepthMask( GLboolean flag );
extern GLuint
gl_depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
const GLdepth z[], GLubyte mask[] );
_mesa_depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
const GLdepth z[], GLubyte mask[] );
extern void
gl_depth_test_pixels( GLcontext *ctx,
GLuint n, const GLint x[], const GLint y[],
const GLdepth z[], GLubyte mask[] );
_mesa_depth_test_pixels( GLcontext *ctx,
GLuint n, const GLint x[], const GLint y[],
const GLdepth z[], GLubyte mask[] );
extern void
gl_read_depth_span_float( GLcontext *ctx, GLuint n, GLint x, GLint y,
GLfloat depth[] );
_mesa_read_depth_span_float( GLcontext *ctx, GLuint n, GLint x, GLint y,
GLfloat depth[] );
extern void
gl_alloc_depth_buffer( GLcontext* ctx );
_mesa_alloc_depth_buffer( GLcontext* ctx );
extern void
gl_clear_depth_buffer( GLcontext* ctx );
_mesa_clear_depth_buffer( GLcontext* ctx );

View File

@@ -1,10 +1,10 @@
/* $Id: stencil.c,v 1.13 1999/12/10 19:09:22 brianp Exp $ */
/* $Id: stencil.c,v 1.14 2000/02/02 22:16:04 brianp Exp $ */
/*
* Mesa 3-D graphics library
* Version: 3.3
*
* Copyright (C) 1999 Brian Paul All Rights Reserved.
* Copyright (C) 1999-2000 Brian Paul All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -580,7 +580,7 @@ stencil_and_depth_test_span( GLcontext *ctx, GLuint n, GLint x, GLint y,
MEMCPY(oldmask, mask, n * sizeof(GLubyte));
/* apply the depth test */
gl_depth_test_span(ctx, n, x, y, z, mask);
_mesa_depth_test_span(ctx, n, x, y, z, mask);
/* Set the stencil pass/fail flags according to result of depth testing.
* if oldmask[i] == 0 then
@@ -1059,7 +1059,7 @@ gl_stencil_and_depth_test_pixels( GLcontext *ctx,
MEMCPY(oldmask, mask, n * sizeof(GLubyte));
gl_depth_test_pixels(ctx, n, x, y, z, mask);
_mesa_depth_test_pixels(ctx, n, x, y, z, mask);
for (i=0;i<n;i++) {
ASSERT(mask[i] == 0 || mask[i] == 1);
@@ -1099,7 +1099,7 @@ gl_stencil_and_depth_test_pixels( GLcontext *ctx,
MEMCPY(oldmask, mask, n * sizeof(GLubyte));
gl_depth_test_pixels(ctx, n, x, y, z, mask);
_mesa_depth_test_pixels(ctx, n, x, y, z, mask);
for (i=0;i<n;i++) {
ASSERT(mask[i] == 0 || mask[i] == 1);