summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/glide/fxddtex.c
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-09-27 19:53:54 -0600
committerBrian Paul <brianp@vmware.com>2009-09-27 19:53:54 -0600
commit21db8959c1134b43c9fe6d6179ee8fd9cde0b911 (patch)
tree8db92ce09191b1c0f1ea127db72a6028cfa7c32f /src/mesa/drivers/glide/fxddtex.c
parent2de768328067fa42501bdd4b753490e7a00167a4 (diff)
glide: use _mesa_get_format_bytes()
Diffstat (limited to 'src/mesa/drivers/glide/fxddtex.c')
-rw-r--r--src/mesa/drivers/glide/fxddtex.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/drivers/glide/fxddtex.c b/src/mesa/drivers/glide/fxddtex.c
index a63301d964..035c2ab92a 100644
--- a/src/mesa/drivers/glide/fxddtex.c
+++ b/src/mesa/drivers/glide/fxddtex.c
@@ -40,6 +40,7 @@
#include "fxdrv.h"
#include "main/enums.h"
+#include "main/formats.h"
#include "main/image.h"
#include "main/teximage.h"
#include "main/texstore.h"
@@ -1396,7 +1397,7 @@ fxDDTexImage2D(GLcontext * ctx, GLenum target, GLint level,
texImage->TexFormat = (*ctx->Driver.ChooseTextureFormat)(ctx,
internalFormat, format, type);
assert(texImage->TexFormat);
- texelBytes = texImage->TexFormat->TexelBytes;
+ texelBytes = _mesa_get_format_bytes(texImage->TexFormat->MesaFormat);
/*if (!fxMesa->HaveTexFmt) assert(texelBytes == 1 || texelBytes == 2);*/
mml->glideFormat = fxGlideFormat(texImage->TexFormat->MesaFormat);
@@ -1531,7 +1532,7 @@ fxDDTexSubImage2D(GLcontext * ctx, GLenum target, GLint level,
assert(texImage->Data); /* must have an existing texture image! */
assert(texImage->_BaseFormat);
- texelBytes = texImage->TexFormat->TexelBytes;
+ texelBytes = _mesa_get_format_bytes(texImage->TexFormat->MesaFormat);
if (texImage->IsCompressed) {
dstRowStride = _mesa_compressed_row_stride(texImage->InternalFormat, mml->width);
} else {