nv50: fix tile flags for scanout tex usage
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 16 Jan 2010 16:58:35 +0000 (17:58 +0100)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 16 Jan 2010 17:07:31 +0000 (18:07 +0100)
src/gallium/drivers/nv50/nv50_miptree.c

index cecb1efc9008fcf7a06c87bd0cbdc129bab64c55..dc8364ced7e8150cb86074c9bd81412a4f805ba5 100644 (file)
@@ -92,12 +92,23 @@ nv50_miptree_create(struct pipe_screen *pscreen, const struct pipe_texture *tmp)
        case PIPE_FORMAT_Z24S8_UNORM:
                tile_flags = 0x1800;
                break;
+       case PIPE_FORMAT_Z16_UNORM:
+               tile_flags = 0x6c00;
+               break;
        case PIPE_FORMAT_X8Z24_UNORM:
        case PIPE_FORMAT_S8Z24_UNORM:
                tile_flags = 0x2800;
                break;
+       case PIPE_FORMAT_R32G32B32A32_FLOAT:
+       case PIPE_FORMAT_R32G32B32_FLOAT:
+               tile_flags = 0x7400;
+               break;
        default:
-               tile_flags = 0x7000;
+               if ((pt->tex_usage & PIPE_TEXTURE_USAGE_PRIMARY) &&
+                   util_format_get_blocksizebits(pt->format) == 32)
+                       tile_flags = 0x7a00;
+               else
+                       tile_flags = 0x7000;
                break;
        }