r600: fill in some missing XRGB tex formats
authorAlex Deucher <alexdeucher@gmail.com>
Sat, 16 Jan 2010 03:23:40 +0000 (22:23 -0500)
committerAlex Deucher <alexdeucher@gmail.com>
Sat, 16 Jan 2010 04:04:19 +0000 (23:04 -0500)
src/mesa/drivers/dri/r600/r600_texstate.c

index 61c97306277db194ae3cd9380780f742b9e1f030..8fdca0bab15b4a7aca18628ba4560ef41c71866a 100644 (file)
@@ -164,6 +164,32 @@ static GLboolean r600GetTexFormat(struct gl_texture_object *tObj, gl_format mesa
                SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_W,
                         SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask);
                break;
+       case MESA_FORMAT_XRGB8888:
+               SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8,
+                        SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask);
+
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Z,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Y,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_X,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_1,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask);
+               break;
+       case MESA_FORMAT_XRGB8888_REV:
+               SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8,
+                        SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask);
+
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_1,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_X_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_Z,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Y_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_W,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_Z_mask);
+               SETfield(t->SQ_TEX_RESOURCE4, SQ_SEL_X,
+                        SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_shift, SQ_TEX_RESOURCE_WORD4_0__DST_SEL_W_mask);
+               break;
        case MESA_FORMAT_ARGB8888_REV:
                SETfield(t->SQ_TEX_RESOURCE1, FMT_8_8_8_8,
                         SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_shift, SQ_TEX_RESOURCE_WORD1_0__DATA_FORMAT_mask);