summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/common
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-10-28 21:24:11 -0600
committerBrian Paul <[email protected]>2009-10-28 21:24:11 -0600
commit1f196b786d6bd0c6a5dbdc638574ff716cc3d4de (patch)
tree5ae2753b99070f8b35c51576bd39e52df63879d6 /src/mesa/drivers/common
parent0ea575d721821262a862ceef010db9b1a8b4a6d9 (diff)
parent086f9fc0e2aef27f54eda87c733685500555bf20 (diff)
Merge branch 'texformat-rework'
Conflicts: src/mesa/drivers/dri/radeon/radeon_fbo.c src/mesa/drivers/dri/s3v/s3v_tex.c src/mesa/drivers/dri/s3v/s3v_xmesa.c src/mesa/drivers/dri/trident/trident_context.c src/mesa/main/debug.c src/mesa/main/mipmap.c src/mesa/main/texformat.c src/mesa/main/texgetimage.c
Diffstat (limited to 'src/mesa/drivers/common')
-rw-r--r--src/mesa/drivers/common/driverfuncs.c1
-rw-r--r--src/mesa/drivers/common/meta.c15
2 files changed, 8 insertions, 8 deletions
diff --git a/src/mesa/drivers/common/driverfuncs.c b/src/mesa/drivers/common/driverfuncs.c
index 4d21b033f7d..e5aab02a42c 100644
--- a/src/mesa/drivers/common/driverfuncs.c
+++ b/src/mesa/drivers/common/driverfuncs.c
@@ -115,7 +115,6 @@ _mesa_init_driver_functions(struct dd_function_table *driver)
driver->CompressedTexSubImage2D = _mesa_store_compressed_texsubimage2d;
driver->CompressedTexSubImage3D = _mesa_store_compressed_texsubimage3d;
driver->GetCompressedTexImage = _mesa_get_compressed_teximage;
- driver->CompressedTextureSize = _mesa_compressed_texture_size;
driver->BindTexture = NULL;
driver->NewTextureObject = _mesa_new_texture_object;
driver->DeleteTexture = _mesa_delete_texture_object;
diff --git a/src/mesa/drivers/common/meta.c b/src/mesa/drivers/common/meta.c
index 64b77d864c2..22cd6de5640 100644
--- a/src/mesa/drivers/common/meta.c
+++ b/src/mesa/drivers/common/meta.c
@@ -43,6 +43,7 @@
#include "main/depth.h"
#include "main/enable.h"
#include "main/fbobject.h"
+#include "main/formats.h"
#include "main/image.h"
#include "main/macros.h"
#include "main/matrix.h"
@@ -2083,7 +2084,7 @@ _mesa_meta_check_generate_mipmap_fallback(GLcontext *ctx, GLenum target,
srcLevel = texObj->BaseLevel;
baseImage = _mesa_select_tex_image(ctx, texObj, target, srcLevel);
- if (!baseImage || baseImage->IsCompressed) {
+ if (!baseImage || _mesa_is_format_compressed(baseImage->TexFormat)) {
return GL_TRUE;
}
@@ -2492,11 +2493,11 @@ copy_tex_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
return;
}
- if (texImage->TexFormat == &_mesa_null_texformat)
- texImage->TexFormat = ctx->Driver.ChooseTextureFormat(ctx,
- internalFormat,
- format,
- type);
+ if (texImage->TexFormat == MESA_FORMAT_NONE)
+ texImage->TexFormat = ctx->Driver.ChooseTextureFormat(ctx,
+ internalFormat,
+ format,
+ type);
_mesa_unlock_texture(ctx, texObj); /* need to unlock first */
@@ -2593,7 +2594,7 @@ copy_tex_sub_image(GLcontext *ctx, GLuint dims, GLenum target, GLint level,
texObj = _mesa_select_tex_object(ctx, texUnit, target);
texImage = _mesa_select_tex_image(ctx, texObj, target, level);
- format = texImage->TexFormat->BaseFormat;
+ format = _mesa_get_format_base_format(texImage->TexFormat);
type = get_temp_image_type(ctx, format);
bpp = _mesa_bytes_per_pixel(format, type);
if (bpp <= 0) {