diff options
author | Alan Hourihane <[email protected]> | 2004-04-26 10:10:22 +0000 |
---|---|---|
committer | Alan Hourihane <[email protected]> | 2004-04-26 10:10:22 +0000 |
commit | 462183fe4cb6df6d90632d9e2cee881c8d26b1cb (patch) | |
tree | 0fb5d1c17d80026bec0fe3c2e0449fe30ea9e69e /src/mesa/drivers/dri | |
parent | 08fa6de85035c428d77cb88b11a4638b706794b5 (diff) |
bring over build fixes from stable branch
Diffstat (limited to 'src/mesa/drivers/dri')
24 files changed, 57 insertions, 37 deletions
diff --git a/src/mesa/drivers/dri/common/texmem.c b/src/mesa/drivers/dri/common/texmem.c index a40d33f1e9d..c76d3716822 100644 --- a/src/mesa/drivers/dri/common/texmem.c +++ b/src/mesa/drivers/dri/common/texmem.c @@ -1083,7 +1083,7 @@ driValidateTextureHeaps( driTexHeap * const * texture_heaps, * the correct heap. * * Check the texobj base address corresponds to the MemBlock - * range. Check the texobj size (recalculate???) fits within + * range. Check the texobj size (recalculate?) fits within * the MemBlock. * * Count the number of texobj's using this heap. diff --git a/src/mesa/drivers/dri/common/utils.c b/src/mesa/drivers/dri/common/utils.c index 81429c167e3..d337cb6b948 100644 --- a/src/mesa/drivers/dri/common/utils.c +++ b/src/mesa/drivers/dri/common/utils.c @@ -46,7 +46,8 @@ driParseDebugString( const char * debug, flag = 0; if ( debug != NULL ) { while( control->string != NULL ) { - if ( strstr( debug, control->string ) != NULL ) { + if ( !strcmp( debug, "all" ) || + strstr( debug, control->string ) != NULL ) { flag |= control->flag; } diff --git a/src/mesa/drivers/dri/common/vblank.h b/src/mesa/drivers/dri/common/vblank.h index 718ecd7b1f3..3dc965def1a 100644 --- a/src/mesa/drivers/dri/common/vblank.h +++ b/src/mesa/drivers/dri/common/vblank.h @@ -55,6 +55,10 @@ extern int driWaitForVBlank( const __DRIdrawablePrivate *priv, #include <unistd.h> /* for usleep() */ #include <sched.h> /* for sched_yield() */ +#ifdef linux +#include <sched.h> /* for sched_yield() */ +#endif + #define DO_USLEEP(nr) \ do { \ if (0) fprintf(stderr, "%s: usleep for %u\n", __FUNCTION__, nr ); \ diff --git a/src/mesa/drivers/dri/ffb/ffb_vbtmp.h b/src/mesa/drivers/dri/ffb/ffb_vbtmp.h index 5baa4eb03e0..a1d1254d979 100644 --- a/src/mesa/drivers/dri/ffb/ffb_vbtmp.h +++ b/src/mesa/drivers/dri/ffb/ffb_vbtmp.h @@ -3,7 +3,9 @@ static void TAG(emit)(GLcontext *ctx, GLuint start, GLuint end) { ffbContextPtr fmesa = FFB_CONTEXT(ctx); +#if defined(VB_DEBUG) || (IND & (FFB_VB_XYZ_BIT | FFB_VB_RGBA_BIT)) struct vertex_buffer *VB = &TNL_CONTEXT(ctx)->vb; +#endif #if (IND & (FFB_VB_RGBA_BIT)) GLfloat (*col0)[4]; GLuint col0_stride; diff --git a/src/mesa/drivers/dri/i810/i810texmem.c b/src/mesa/drivers/dri/i810/i810texmem.c index 87f535dc23f..08900cc67d8 100644 --- a/src/mesa/drivers/dri/i810/i810texmem.c +++ b/src/mesa/drivers/dri/i810/i810texmem.c @@ -60,6 +60,7 @@ void i810DestroyTexObj(i810ContextPtr imesa, i810TextureObjectPtr t) +#if defined(i386) || defined(__i386__) /* From linux kernel i386 header files, copes with odd sizes better * than COPY_DWORDS would: */ @@ -80,6 +81,10 @@ __asm__ __volatile__( : "memory"); return (to); } +#else +/* Allow compilation on other architectures */ +#define __memcpy memcpy +#endif /* Upload an image from mesa's internal copy. */ diff --git a/src/mesa/drivers/dri/i830/i830_texmem.c b/src/mesa/drivers/dri/i830/i830_texmem.c index 6cb55313499..b61ce6f8674 100644 --- a/src/mesa/drivers/dri/i830/i830_texmem.c +++ b/src/mesa/drivers/dri/i830/i830_texmem.c @@ -68,6 +68,7 @@ void i830DestroyTexObj(i830ContextPtr imesa, i830TextureObjectPtr t) } } +#if defined(i386) || defined(__i386__) /* From linux kernel i386 header files, copes with odd sizes better * than COPY_DWORDS would: */ @@ -88,7 +89,10 @@ __asm__ __volatile__( : "memory"); return (to); } - +#else +/* Allow compilation on other architectures */ +#define __memcpy memcpy +#endif /* Upload an image from mesa's internal copy. */ diff --git a/src/mesa/drivers/dri/mga/mgacontext.h b/src/mesa/drivers/dri/mga/mgacontext.h index 83aaa27bdf6..2009634b13c 100644 --- a/src/mesa/drivers/dri/mga/mgacontext.h +++ b/src/mesa/drivers/dri/mga/mgacontext.h @@ -29,7 +29,6 @@ #ifndef MGALIB_INC #define MGALIB_INC -#include <inttypes.h> #include "drm.h" #include "mga_drm.h" #include "dri_util.h" diff --git a/src/mesa/drivers/dri/mga/mgavb.c b/src/mesa/drivers/dri/mga/mgavb.c index 2d5d6825f36..dacb38dd9fc 100644 --- a/src/mesa/drivers/dri/mga/mgavb.c +++ b/src/mesa/drivers/dri/mga/mgavb.c @@ -115,8 +115,8 @@ static struct { #define PTEX_FALLBACK() FALLBACK(ctx, MGA_FALLBACK_TEXTURE, 1) -#define INTERP_VERTEX setup_tab[MGA_CONTEXT(ctx)->SetupIndex].interp -#define COPY_PV_VERTEX setup_tab[MGA_CONTEXT(ctx)->SetupIndex].copy_pv +#define INTERP_VERTEX setup_tab[mmesa->SetupIndex].interp +#define COPY_PV_VERTEX setup_tab[mmesa->SetupIndex].copy_pv /*********************************************************************** diff --git a/src/mesa/drivers/dri/r128/r128_ioctl.c b/src/mesa/drivers/dri/r128/r128_ioctl.c index b0073eb74ec..6ea8d529652 100644 --- a/src/mesa/drivers/dri/r128/r128_ioctl.c +++ b/src/mesa/drivers/dri/r128/r128_ioctl.c @@ -33,6 +33,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. */ #include <errno.h> +#define STANDALONE_MMIO #include "r128_context.h" #include "r128_state.h" #include "r128_ioctl.h" @@ -266,7 +267,7 @@ void r128CopyBuffer( const __DRIdrawablePrivate *dPriv ) if ( R128_DEBUG & DEBUG_VERBOSE_API ) { fprintf( stderr, "\n********************************\n" ); fprintf( stderr, "\n%s( %p )\n\n", - __FUNCTION__, rmesa->glCtx ); + __FUNCTION__, (void *)rmesa->glCtx ); fflush( stderr ); } @@ -344,7 +345,7 @@ void r128PageFlip( const __DRIdrawablePrivate *dPriv ) if ( R128_DEBUG & DEBUG_VERBOSE_API ) { fprintf( stderr, "\n%s( %p ): page=%d\n\n", - __FUNCTION__, rmesa->glCtx, rmesa->sarea->pfCurrentPage ); + __FUNCTION__, (void *)rmesa->glCtx, rmesa->sarea->pfCurrentPage ); } FLUSH_BATCH( rmesa ); diff --git a/src/mesa/drivers/dri/r200/r200_context.h b/src/mesa/drivers/dri/r200/r200_context.h index ae7d2f47bd3..69ac92b1f10 100644 --- a/src/mesa/drivers/dri/r200/r200_context.h +++ b/src/mesa/drivers/dri/r200/r200_context.h @@ -38,7 +38,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #ifdef GLX_DIRECT_RENDERING -#include <inttypes.h> #include "tnl/t_vertex.h" #include "drm.h" #include "radeon_drm.h" diff --git a/src/mesa/drivers/dri/r200/r200_screen.c b/src/mesa/drivers/dri/r200/r200_screen.c index e356309ae10..d115ef20fca 100644 --- a/src/mesa/drivers/dri/r200/r200_screen.c +++ b/src/mesa/drivers/dri/r200/r200_screen.c @@ -41,6 +41,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "imports.h" #include "context.h" +#define STANDALONE_MMIO #include "r200_screen.h" #include "r200_context.h" #include "r200_ioctl.h" @@ -364,6 +365,8 @@ r200CreateScreen( __DRIscreenPrivate *sPriv ) return NULL; } + RADEONMMIO = screen->mmio.map; + screen->status.handle = dri_priv->statusHandle; screen->status.size = dri_priv->statusSize; if ( drmMap( sPriv->fd, diff --git a/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S b/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S index 56a4144e8e7..4ad2b6f1f0d 100644 --- a/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S +++ b/src/mesa/drivers/dri/r200/r200_vtxtmp_x86.S @@ -391,6 +391,7 @@ GLOBL( _x86_MultiTexCoord2f_2 ) ret GLOBL( _x86_MultiTexCoord2f_2_end ) +#if defined(USE_SSE_ASM) /** * This can be used as a template for either Color3fv (when the color * target is also a 3f) or Normal3fv. @@ -490,3 +491,4 @@ GLOBL( _sse_MultiTexCoord2f_2 ) movlps %xmm0, (%eax) ret GLOBL( _sse_MultiTexCoord2f_2_end ) +#endif diff --git a/src/mesa/drivers/dri/radeon/radeon_context.h b/src/mesa/drivers/dri/radeon/radeon_context.h index 42b768dc846..30346150dbf 100644 --- a/src/mesa/drivers/dri/radeon/radeon_context.h +++ b/src/mesa/drivers/dri/radeon/radeon_context.h @@ -40,7 +40,6 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #ifdef GLX_DIRECT_RENDERING -#include <inttypes.h> #include "dri_util.h" #include "drm.h" #include "radeon_drm.h" diff --git a/src/mesa/drivers/dri/radeon/radeon_ioctl.c b/src/mesa/drivers/dri/radeon/radeon_ioctl.c index 6d51b886d80..c5707a02807 100644 --- a/src/mesa/drivers/dri/radeon/radeon_ioctl.c +++ b/src/mesa/drivers/dri/radeon/radeon_ioctl.c @@ -49,6 +49,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "radeon_tcl.h" #include "radeon_sanity.h" +#define STANDALONE_MMIO #include "radeon_macros.h" /* for INREG() */ #include "vblank.h" @@ -750,12 +751,10 @@ static uint32_t radeonGetLastFrame (radeonContextPtr rmesa) else ret = -EINVAL; -#ifndef __alpha__ if ( ret == -EINVAL ) { frame = INREG( RADEON_LAST_FRAME_REG ); ret = 0; } -#endif if ( ret ) { fprintf( stderr, "%s: drm_radeon_getparam_t: %d\n", __FUNCTION__, ret ); exit(1); @@ -1043,12 +1042,10 @@ static void radeonClear( GLcontext *ctx, GLbitfield mask, GLboolean all, } else ret = -EINVAL; -#ifndef __alpha__ if ( ret == -EINVAL ) { clear = INREG( RADEON_LAST_CLEAR_REG ); ret = 0; } -#endif if ( ret ) { fprintf( stderr, "%s: drm_radeon_getparam_t: %d\n", __FUNCTION__, ret ); exit(1); diff --git a/src/mesa/drivers/dri/radeon/radeon_screen.c b/src/mesa/drivers/dri/radeon/radeon_screen.c index 8d26935e6be..14ea13648c9 100644 --- a/src/mesa/drivers/dri/radeon/radeon_screen.c +++ b/src/mesa/drivers/dri/radeon/radeon_screen.c @@ -39,6 +39,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "glheader.h" #include "imports.h" +#define STANDALONE_MMIO #include "radeon_context.h" #include "radeon_screen.h" #include "radeon_macros.h" diff --git a/src/mesa/drivers/dri/radeon/radeon_tex.c b/src/mesa/drivers/dri/radeon/radeon_tex.c index 87c26f89780..3de407df3bb 100644 --- a/src/mesa/drivers/dri/radeon/radeon_tex.c +++ b/src/mesa/drivers/dri/radeon/radeon_tex.c @@ -244,7 +244,7 @@ static radeonTexObjPtr radeonAllocTexObj( struct gl_texture_object *texObj ) texObj->DriverData = t; if ( t != NULL ) { if ( RADEON_DEBUG & DEBUG_TEXTURE ) { - fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, texObj, t ); + fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, (void *)texObj, (void *)t ); } /* Initialize non-image-dependent parts of the state: @@ -666,7 +666,7 @@ static void radeonBindTexture( GLcontext *ctx, GLenum target, struct gl_texture_object *texObj ) { if ( RADEON_DEBUG & (DEBUG_STATE|DEBUG_TEXTURE) ) { - fprintf( stderr, "%s( %p ) unit=%d\n", __FUNCTION__, texObj, + fprintf( stderr, "%s( %p ) unit=%d\n", __FUNCTION__, (void *)texObj, ctx->Texture.CurrentUnit ); } @@ -683,7 +683,7 @@ static void radeonDeleteTexture( GLcontext *ctx, driTextureObject * t = (driTextureObject *) texObj->DriverData; if ( RADEON_DEBUG & (DEBUG_STATE|DEBUG_TEXTURE) ) { - fprintf( stderr, "%s( %p (target = %s) )\n", __FUNCTION__, texObj, + fprintf( stderr, "%s( %p (target = %s) )\n", __FUNCTION__, (void *)texObj, _mesa_lookup_enum_by_nr( texObj->Target ) ); } diff --git a/src/mesa/drivers/dri/radeon/radeon_texmem.c b/src/mesa/drivers/dri/radeon/radeon_texmem.c index 61f187762cd..235df8dcd1a 100644 --- a/src/mesa/drivers/dri/radeon/radeon_texmem.c +++ b/src/mesa/drivers/dri/radeon/radeon_texmem.c @@ -56,7 +56,7 @@ void radeonDestroyTexObj( radeonContextPtr rmesa, radeonTexObjPtr t ) { if ( RADEON_DEBUG & DEBUG_TEXTURE ) { - fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, t, t->base.tObj ); + fprintf( stderr, "%s( %p, %p )\n", __FUNCTION__, (void *)t, (void *)t->base.tObj ); } if ( rmesa != NULL ) { @@ -189,7 +189,7 @@ static void uploadSubImage( radeonContextPtr rmesa, radeonTexObjPtr t, if ( RADEON_DEBUG & DEBUG_TEXTURE ) { fprintf( stderr, "%s( %p, %p ) level/width/height/face = %d/%d/%d/%u\n", - __FUNCTION__, t, t->base.tObj, level, width, height, face ); + __FUNCTION__, (void *)t, (void *)t->base.tObj, level, width, height, face ); } ASSERT(face < 6); @@ -306,7 +306,7 @@ int radeonUploadTexImages( radeonContextPtr rmesa, radeonTexObjPtr t, GLuint fac if ( RADEON_DEBUG & (DEBUG_TEXTURE|DEBUG_IOCTL) ) { fprintf( stderr, "%s( %p, %p ) sz=%d lvls=%d-%d\n", __FUNCTION__, - rmesa->glCtx, t->base.tObj, t->base.totalSize, + (void *)rmesa->glCtx, (void *)t->base.tObj, t->base.totalSize, t->base.firstLevel, t->base.lastLevel ); } diff --git a/src/mesa/drivers/dri/radeon/radeon_texstate.c b/src/mesa/drivers/dri/radeon/radeon_texstate.c index 16682b1f649..a3be9280c80 100644 --- a/src/mesa/drivers/dri/radeon/radeon_texstate.c +++ b/src/mesa/drivers/dri/radeon/radeon_texstate.c @@ -391,7 +391,7 @@ static GLboolean radeonUpdateTextureEnv( GLcontext *ctx, int unit ) || (texUnit->_Current != NULL) ); if ( RADEON_DEBUG & DEBUG_TEXTURE ) { - fprintf( stderr, "%s( %p, %d )\n", __FUNCTION__, ctx, unit ); + fprintf( stderr, "%s( %p, %d )\n", __FUNCTION__, (void *)ctx, unit ); } /* Set the texture environment state. Isn't this nice and clean? diff --git a/src/mesa/drivers/dri/radeon/radeon_vtxfmt.c b/src/mesa/drivers/dri/radeon/radeon_vtxfmt.c index 9fb699e3d61..7a0ff51dd46 100644 --- a/src/mesa/drivers/dri/radeon/radeon_vtxfmt.c +++ b/src/mesa/drivers/dri/radeon/radeon_vtxfmt.c @@ -527,7 +527,7 @@ static void wrap_buffer( void ) for (i = 0 ; i < nrverts; i++) { if (RADEON_DEBUG & DEBUG_VERTS) { int j; - fprintf(stderr, "re-emit vertex %d to %p\n", i, rmesa->vb.dmaptr); + fprintf(stderr, "re-emit vertex %d to %p\n", i, (void *)rmesa->vb.dmaptr); if (RADEON_DEBUG & DEBUG_VERBOSE) for (j = 0 ; j < rmesa->vb.vertex_size; j++) fprintf(stderr, "\t%08x/%f\n", *(int*)&tmp[i][j], tmp[i][j]); diff --git a/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S b/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S index c77b41059ef..569d3b9b481 100644 --- a/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S +++ b/src/mesa/drivers/dri/radeon/radeon_vtxtmp_x86.S @@ -391,6 +391,7 @@ GLOBL( _x86_MultiTexCoord2f_2 ) ret GLOBL( _x86_MultiTexCoord2f_2_end ) +#if defined(USE_SSE_ASM) /** * This can be used as a template for either Color3fv (when the color * target is also a 3f) or Normal3fv. @@ -490,3 +491,4 @@ GLOBL( _sse_MultiTexCoord2f_2 ) movlps %xmm0, (%eax) ret GLOBL( _sse_MultiTexCoord2f_2_end ) +#endif diff --git a/src/mesa/drivers/dri/sis/sis_alloc.c b/src/mesa/drivers/dri/sis/sis_alloc.c index 1789fbb5ffe..0e85e6faff5 100644 --- a/src/mesa/drivers/dri/sis/sis_alloc.c +++ b/src/mesa/drivers/dri/sis/sis_alloc.c @@ -170,7 +170,7 @@ sisAllocZStencilBuffer( sisContextPtr smesa ) memset( &smesa->zClearPacket, 0, sizeof(ENGPACKET) ); smesa->zClearPacket.dwSrcPitch = (z_depth == 2) ? 0x80000000 : 0xf0000000; - smesa->zClearPacket.dwDestBaseAddr = (GLint)(addr - + smesa->zClearPacket.dwDestBaseAddr = (unsigned long)(addr - (unsigned long)smesa->FbBase); smesa->zClearPacket.wDestPitch = width2; smesa->zClearPacket.stdwDestPos.wY = 0; @@ -218,7 +218,7 @@ sisAllocBackbuffer( sisContextPtr smesa ) addr = (char *)ALIGNMENT( (unsigned long)addr, DRAW_BUFFER_HW_ALIGNMENT ); smesa->backbuffer = addr; - smesa->backOffset = (GLint)(addr - (unsigned long)smesa->FbBase); + smesa->backOffset = (unsigned long)(addr - (unsigned long)smesa->FbBase); smesa->backPitch = width2 * depth; memset ( &smesa->cbClearPacket, 0, sizeof(ENGPACKET) ); diff --git a/src/mesa/drivers/dri/tdfx/tdfx_screen.c b/src/mesa/drivers/dri/tdfx/tdfx_screen.c index 48cff3f02cf..679c2d75606 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_screen.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_screen.c @@ -118,7 +118,7 @@ static GLboolean tdfxInitDriver( __DRIscreenPrivate *sPriv ) { if ( TDFX_DEBUG & DEBUG_VERBOSE_DRI ) { - fprintf( stderr, "%s( %p )\n", __FUNCTION__, sPriv ); + fprintf( stderr, "%s( %p )\n", __FUNCTION__, (void *)sPriv ); } /* Check the DRI externsion version */ @@ -195,7 +195,7 @@ tdfxSwapBuffers( __DRIdrawablePrivate *driDrawPriv ) GLframebuffer *mesaBuffer; if ( TDFX_DEBUG & DEBUG_VERBOSE_DRI ) { - fprintf( stderr, "%s( %p )\n", __FUNCTION__, driDrawPriv ); + fprintf( stderr, "%s( %p )\n", __FUNCTION__, (void *)driDrawPriv ); } mesaBuffer = (GLframebuffer *) driDrawPriv->driverPrivate; diff --git a/src/mesa/drivers/dri/tdfx/tdfx_span.c b/src/mesa/drivers/dri/tdfx/tdfx_span.c index 43fcb90fd23..0d2bc811e04 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_span.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_span.c @@ -572,14 +572,6 @@ GetFbParams(tdfxContextPtr fxMesa, * * Recall that x and y are screen coordinates. */ -#define GET_FB_DATA(ReadParamsp, type, x, y) \ - (((x) < (ReadParamsp)->firstWrappedX) \ - ? (((type *)((ReadParamsp)->lfbPtr)) \ - [(y) * ((ReadParamsp)->LFBStrideInElts) \ - + (x)]) \ - : (((type *)((ReadParamsp)->lfbWrapPtr)) \ - [((y)) * ((ReadParamsp)->LFBStrideInElts) \ - + ((x) - (ReadParamsp)->firstWrappedX)])) #define GET_ORDINARY_FB_DATA(ReadParamsp, type, x, y) \ (((type *)((ReadParamsp)->lfbPtr)) \ [(y) * ((ReadParamsp)->LFBStrideInElts) \ @@ -588,12 +580,21 @@ GetFbParams(tdfxContextPtr fxMesa, (((type *)((ReadParamsp)->lfbWrapPtr)) \ [((y)) * ((ReadParamsp)->LFBStrideInElts) \ + ((x) - (ReadParamsp)->firstWrappedX)]) -#define PUT_FB_DATA(ReadParamsp, type, x, y, value) \ - (GET_FB_DATA(ReadParamsp, type, x, y) = (type)(value)) +#define GET_FB_DATA(ReadParamsp, type, x, y) \ + (((x) < (ReadParamsp)->firstWrappedX) \ + ? GET_ORDINARY_FB_DATA(ReadParamsp, type, x, y) \ + : GET_WRAPPED_FB_DATA(ReadParamsp, type, x, y)) #define PUT_ORDINARY_FB_DATA(ReadParamsp, type, x, y, value) \ (GET_ORDINARY_FB_DATA(ReadParamsp, type, x, y) = (type)(value)) #define PUT_WRAPPED_FB_DATA(ReadParamsp, type, x, y, value) \ (GET_WRAPPED_FB_DATA(ReadParamsp, type, x, y) = (type)(value)) +#define PUT_FB_DATA(ReadParamsp, type, x, y, value) \ + do { \ + if ((x) < (ReadParamsp)->firstWrappedX) \ + PUT_ORDINARY_FB_DATA(ReadParamsp, type, x, y, value); \ + else \ + PUT_WRAPPED_FB_DATA(ReadParamsp, type, x, y, value); \ + } while (0) static void tdfxDDWriteDepthSpan(GLcontext * ctx, diff --git a/src/mesa/drivers/dri/tdfx/tdfx_texman.c b/src/mesa/drivers/dri/tdfx/tdfx_texman.c index 9bfd5de5f9e..6f303aee666 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_texman.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_texman.c @@ -880,7 +880,7 @@ tdfxTMMoveOutTM_NoLock( tdfxContextPtr fxMesa, struct gl_texture_object *tObj ) tdfxTexInfo *ti = TDFX_TEXTURE_DATA(tObj); if (MESA_VERBOSE & VERBOSE_DRIVER) { - fprintf(stderr, "fxmesa: %s(%p (%d))\n", __FUNCTION__, tObj, tObj->Name); + fprintf(stderr, "fxmesa: %s(%p (%d))\n", __FUNCTION__, (void *)tObj, tObj->Name); } /* |