summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/texobj.c
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/main/texobj.c
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/main/texobj.c')
-rw-r--r--src/mesa/main/texobj.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c
index 31832184c0e..aaccc03a7c6 100644
--- a/src/mesa/main/texobj.c
+++ b/src/mesa/main/texobj.c
@@ -33,6 +33,7 @@
#include "context.h"
#include "enums.h"
#include "fbobject.h"
+#include "formats.h"
#include "hash.h"
#include "imports.h"
#include "macros.h"
@@ -740,6 +741,10 @@ _mesa_get_fallback_texture(GLcontext *ctx)
_mesa_init_teximage_fields(ctx, GL_TEXTURE_2D, texImage,
8, 8, 1, 0, GL_RGBA);
+ texImage->TexFormat =
+ ctx->Driver.ChooseTextureFormat(ctx, GL_RGBA, GL_RGBA, GL_UNSIGNED_BYTE);
+ ASSERT(texImage->TexFormat != MESA_FORMAT_NONE);
+
/* set image data */
ctx->Driver.TexImage2D(ctx, GL_TEXTURE_2D, 0, GL_RGBA,
8, 8, 0,