From 20981c0a0bd43aff4972c1300f990b06dfa789d1 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Tue, 24 Mar 2009 15:06:19 +1000 Subject: [PATCH] radeon: fixup some issue with fbos and sw fallbacks --- src/mesa/drivers/dri/radeon/radeon_fbo.c | 7 ------- src/mesa/drivers/dri/radeon/radeon_texture.c | 5 ++++- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/mesa/drivers/dri/radeon/radeon_fbo.c b/src/mesa/drivers/dri/radeon/radeon_fbo.c index 2c30f9ddfde..40945855d96 100644 --- a/src/mesa/drivers/dri/radeon/radeon_fbo.c +++ b/src/mesa/drivers/dri/radeon/radeon_fbo.c @@ -380,13 +380,6 @@ radeon_update_wrapper(GLcontext *ctx, struct radeon_renderbuffer *rrb, rrb->base.DataType = GL_UNSIGNED_BYTE; DBG("Render to RGBA8 texture OK\n"); } - else if (texImage->TexFormat == &_mesa_texformat_argb4444) { - rrb->cpp = 2; - rrb->base._ActualFormat = GL_RGBA8; - rrb->base._BaseFormat = GL_RGBA; - rrb->base.DataType = GL_UNSIGNED_BYTE; - DBG("Render to RGBA4 texture OK\n"); - } else if (texImage->TexFormat == &_mesa_texformat_rgb565) { rrb->cpp = 2; rrb->base._ActualFormat = GL_RGB5; diff --git a/src/mesa/drivers/dri/radeon/radeon_texture.c b/src/mesa/drivers/dri/radeon/radeon_texture.c index 63680b495c9..d212898acd8 100644 --- a/src/mesa/drivers/dri/radeon/radeon_texture.c +++ b/src/mesa/drivers/dri/radeon/radeon_texture.c @@ -139,9 +139,12 @@ void radeonMapTexture(GLcontext *ctx, struct gl_texture_object *texObj) radeonTexObj* t = radeon_tex_obj(texObj); int face, level; + if (!radeon_validate_texture_miptree(ctx, texObj)) + return; + /* for r100 3D sw fallbacks don't have mt */ if (!t->mt) - return; + return; radeon_bo_map(t->mt->bo, GL_FALSE); for(face = 0; face < t->mt->faces; ++face) { -- 2.30.2