From 32aa40eee46fd0b15f3873069f2440ea2dd75408 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 1 Oct 2009 21:13:25 -0600 Subject: mesa: removed gl_texture_image::CompressedSize field Just call ctx->Driver.CompressedTextureSize() when we need to get the compressed image size. --- src/mesa/state_tracker/st_cb_texture.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/mesa/state_tracker/st_cb_texture.c') diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c index 2574eeb996..dc3ab61425 100644 --- a/src/mesa/state_tracker/st_cb_texture.c +++ b/src/mesa/state_tracker/st_cb_texture.c @@ -563,10 +563,6 @@ st_TexImage(GLcontext * ctx, if (_mesa_is_format_compressed(texImage->TexFormat)) { /* must be a compressed format */ texelBytes = 0; - texImage->CompressedSize = - ctx->Driver.CompressedTextureSize(ctx, texImage->Width, - texImage->Height, texImage->Depth, - texImage->TexFormat); } else { texelBytes = _mesa_get_format_bytes(texImage->TexFormat); @@ -697,7 +693,11 @@ st_TexImage(GLcontext * ctx, else { /* Allocate regular memory and store the image there temporarily. */ if (_mesa_is_format_compressed(texImage->TexFormat)) { - sizeInBytes = texImage->CompressedSize; + sizeInBytes = ctx->Driver.CompressedTextureSize(ctx, + texImage->Width, + texImage->Height, + texImage->Depth, + texImage->TexFormat); dstRowStride = _mesa_compressed_row_stride(texImage->TexFormat, width); assert(dims != 3); -- cgit v1.2.3