diff options
Diffstat (limited to 'src/mesa/drivers/dri/tdfx')
-rw-r--r-- | src/mesa/drivers/dri/tdfx/tdfx_tex.c | 32 | ||||
-rw-r--r-- | src/mesa/drivers/dri/tdfx/tdfx_texstate.c | 24 |
2 files changed, 28 insertions, 28 deletions
diff --git a/src/mesa/drivers/dri/tdfx/tdfx_tex.c b/src/mesa/drivers/dri/tdfx/tdfx_tex.c index cf4de23b368..6d39067de40 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_tex.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_tex.c @@ -98,7 +98,7 @@ _mesa_halve2x2_teximage2d ( GLcontext *ctx, srcRowStride, /* dstRowStride */ 0, /* dstImageStride */ srcWidth, srcHeight, 1, - texImage->Format, _t, srcImage, &ctx->DefaultPacking); + texImage->_BaseFormat, _t, srcImage, &ctx->DefaultPacking); } if (srcHeight == 1) { @@ -139,7 +139,7 @@ _mesa_halve2x2_teximage2d ( GLcontext *ctx, if (bpt) { src = _s; dst = _d; - texImage->TexFormat->StoreImage(ctx, 2, texImage->Format, + texImage->TexFormat->StoreImage(ctx, 2, texImage->_BaseFormat, texImage->TexFormat, dstImage, 0, 0, 0, /* dstX/Y/Zoffset */ dstWidth * bpt, @@ -1185,7 +1185,7 @@ adjust2DRatio (GLcontext *ctx, return GL_FALSE; } - texImage->TexFormat->StoreImage(ctx, 2, texImage->Format, + texImage->TexFormat->StoreImage(ctx, 2, texImage->_BaseFormat, texImage->TexFormat, tempImage, 0, 0, 0, /* dstX/Y/Zoffset */ width * texelBytes, /* dstRowStride */ @@ -1229,7 +1229,7 @@ adjust2DRatio (GLcontext *ctx, width, height, /* src */ newWidth, newHeight, /* dst */ rawImage /*src*/, tempImage /*dst*/ ); - texImage->TexFormat->StoreImage(ctx, 2, texImage->Format, + texImage->TexFormat->StoreImage(ctx, 2, texImage->_BaseFormat, texImage->TexFormat, texImage->Data, xoffset * mml->wScale, yoffset * mml->hScale, 0, /* dstX/Y/Zoffset */ dstRowStride, @@ -1321,7 +1321,7 @@ tdfxTexImage2D(GLcontext *ctx, GLenum target, GLint level, case GL_RGBA4_S3TC: internalFormat = GL_COMPRESSED_RGBA_FXT1_3DFX; } - texImage->IntFormat = internalFormat; + texImage->InternalFormat = internalFormat; } #endif #if FX_TC_NAPALM @@ -1333,7 +1333,7 @@ tdfxTexImage2D(GLcontext *ctx, GLenum target, GLint level, texNapalm = GL_COMPRESSED_RGBA_FXT1_3DFX; } if (texNapalm) { - texImage->IntFormat = internalFormat = texNapalm; + texImage->InternalFormat = internalFormat = texNapalm; texImage->IsCompressed = GL_TRUE; } } @@ -1386,7 +1386,7 @@ tdfxTexImage2D(GLcontext *ctx, GLenum target, GLint level, else { /* no rescaling needed */ /* unpack image, apply transfer ops and store in texImage->Data */ - texImage->TexFormat->StoreImage(ctx, 2, texImage->Format, + texImage->TexFormat->StoreImage(ctx, 2, texImage->_BaseFormat, texImage->TexFormat, texImage->Data, 0, 0, 0, /* dstX/Y/Zoffset */ dstRowStride, @@ -1469,11 +1469,11 @@ tdfxTexSubImage2D(GLcontext *ctx, GLenum target, GLint level, assert(mml); assert(texImage->Data); /* must have an existing texture image! */ - assert(texImage->Format); + assert(texImage->_BaseFormat); texelBytes = texImage->TexFormat->TexelBytes; if (texImage->IsCompressed) { - dstRowStride = _mesa_compressed_row_stride(texImage->IntFormat, mml->width); + dstRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, mml->width); } else { dstRowStride = mml->width * texelBytes; } @@ -1496,7 +1496,7 @@ tdfxTexSubImage2D(GLcontext *ctx, GLenum target, GLint level, } else { /* no rescaling needed */ - texImage->TexFormat->StoreImage(ctx, 2, texImage->Format, + texImage->TexFormat->StoreImage(ctx, 2, texImage->_BaseFormat, texImage->TexFormat, texImage->Data, xoffset, yoffset, 0, dstRowStride, @@ -1736,12 +1736,12 @@ tdfxCompressedTexSubImage2D( GLcontext *ctx, GLenum target, mml = TDFX_TEXIMAGE_DATA(texImage); assert(mml); - srcRowStride = _mesa_compressed_row_stride(texImage->IntFormat, width); + srcRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, width); - destRowStride = _mesa_compressed_row_stride(texImage->IntFormat, + destRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, mml->width); dest = _mesa_compressed_image_address(xoffset, yoffset, 0, - texImage->IntFormat, + texImage->InternalFormat, mml->width, (GLubyte*) texImage->Data); @@ -1757,9 +1757,9 @@ tdfxCompressedTexSubImage2D( GLcontext *ctx, GLenum target, * see fxDDCompressedTexImage2D for caveats */ if (mml->wScale != 1 || mml->hScale != 1) { - srcRowStride = _mesa_compressed_row_stride(texImage->IntFormat, texImage->Width); + srcRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, texImage->Width); - destRowStride = _mesa_compressed_row_stride(texImage->IntFormat, + destRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, mml->width); _mesa_upscale_teximage2d(srcRowStride, texImage->Height / 4, destRowStride, mml->height / 4, @@ -1829,7 +1829,7 @@ tdfxTestProxyTexImage(GLcontext *ctx, GLenum target, tObj->Image[0][level]->Height = height; tObj->Image[0][level]->Border = border; #if 0 - tObj->Image[0][level]->IntFormat = internalFormat; + tObj->Image[0][level]->InternalFormat = internalFormat; #endif if (level == 0) { /* don't use mipmap levels > 0 */ diff --git a/src/mesa/drivers/dri/tdfx/tdfx_texstate.c b/src/mesa/drivers/dri/tdfx/tdfx_texstate.c index 7059b56e3d0..f5f385fad7c 100644 --- a/src/mesa/drivers/dri/tdfx/tdfx_texstate.c +++ b/src/mesa/drivers/dri/tdfx/tdfx_texstate.c @@ -1629,7 +1629,7 @@ static void setupTextureSingleTMU(GLcontext * ctx, GLuint unit) /* Check if we really need to update the texenv state */ envMode = ctx->Texture.Unit[unit].EnvMode; - baseFormat = tObj->Image[0][tObj->BaseLevel]->Format; + baseFormat = tObj->Image[0][tObj->BaseLevel]->_BaseFormat; if (TDFX_IS_NAPALM(fxMesa)) { /* see if we really need to update the unit */ @@ -1952,10 +1952,10 @@ static void setupTextureDoubleTMU(GLcontext * ctx) baseImage0->Format != fxMesa->TexState.TexFormat[1] || (fxMesa->Fallback & TDFX_FALLBACK_TEXTURE_ENV)*/) { hw1 = SetupTexEnvNapalm(ctx, GL_TRUE, &ctx->Texture.Unit[0], - baseImage0->Format, &fxMesa->TexCombineExt[1]); + baseImage0->_BaseFormat, &fxMesa->TexCombineExt[1]); #if 0/*JJJ*/ fxMesa->TexState.EnvMode[1] = envMode0; - fxMesa->TexState.TexFormat[1] = baseImage0->Format; + fxMesa->TexState.TexFormat[1] = baseImage0->_BaseFormat; fxMesa->TexState.Enabled[0] = ctx->Texture.Unit[0]._ReallyEnabled; #endif } @@ -1964,13 +1964,13 @@ static void setupTextureDoubleTMU(GLcontext * ctx) if (1/*fxMesa->TexState.Enabled[1] != ctx->Texture.Unit[1]._ReallyEnabled || envMode1 != fxMesa->TexState.EnvMode[0] || envMode1 == GL_COMBINE_EXT || - baseImage1->Format != fxMesa->TexState.TexFormat[0] || + baseImage1->_BaseFormat != fxMesa->TexState.TexFormat[0] || (fxMesa->Fallback & TDFX_FALLBACK_TEXTURE_ENV)*/) { hw2 = SetupTexEnvNapalm(ctx, GL_FALSE, &ctx->Texture.Unit[1], - baseImage1->Format, &fxMesa->TexCombineExt[0]); + baseImage1->_BaseFormat, &fxMesa->TexCombineExt[0]); #if 0/*JJJ*/ fxMesa->TexState.EnvMode[0] = envMode1; - fxMesa->TexState.TexFormat[0] = baseImage1->Format; + fxMesa->TexState.TexFormat[0] = baseImage1->_BaseFormat; fxMesa->TexState.Enabled[1] = ctx->Texture.Unit[1]._ReallyEnabled; #endif } @@ -1994,21 +1994,21 @@ static void setupTextureDoubleTMU(GLcontext * ctx) envMode0 == GL_COMBINE_EXT || envMode1 != fxMesa->TexState.EnvMode[unit1] || envMode1 == GL_COMBINE_EXT || - baseImage0->Format != fxMesa->TexState.TexFormat[unit0] || - baseImage1->Format != fxMesa->TexState.TexFormat[unit1] || + baseImage0->_BaseFormat != fxMesa->TexState.TexFormat[unit0] || + baseImage1->_BaseFormat != fxMesa->TexState.TexFormat[unit1] || (fxMesa->Fallback & TDFX_FALLBACK_TEXTURE_ENV)*/) { if (!SetupDoubleTexEnvVoodoo3(ctx, unit0, - ctx->Texture.Unit[0].EnvMode, baseImage0->Format, - ctx->Texture.Unit[1].EnvMode, baseImage1->Format)) { + ctx->Texture.Unit[0].EnvMode, baseImage0->_BaseFormat, + ctx->Texture.Unit[1].EnvMode, baseImage1->_BaseFormat)) { FALLBACK(fxMesa, TDFX_FALLBACK_TEXTURE_ENV, GL_TRUE); } #if 0/*JJJ*/ fxMesa->TexState.EnvMode[unit0] = envMode0; - fxMesa->TexState.TexFormat[unit0] = baseImage0->Format; + fxMesa->TexState.TexFormat[unit0] = baseImage0->_BaseFormat; fxMesa->TexState.EnvMode[unit1] = envMode1; - fxMesa->TexState.TexFormat[unit1] = baseImage1->Format; + fxMesa->TexState.TexFormat[unit1] = baseImage1->_BaseFormat; fxMesa->TexState.Enabled[0] = ctx->Texture.Unit[0]._ReallyEnabled; fxMesa->TexState.Enabled[1] = ctx->Texture.Unit[1]._ReallyEnabled; #endif |