r600g: use LINEAR_ALIGNED tiling for 1D array textures and if height0 <= 3
authorMarek Olšák <maraeo@gmail.com>
Tue, 13 Nov 2012 15:04:13 +0000 (16:04 +0100)
committerMarek Olšák <maraeo@gmail.com>
Tue, 13 Nov 2012 16:17:05 +0000 (17:17 +0100)
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
src/gallium/drivers/r600/r600_texture.c

index 42010bf778539dc803180f834c7f4450fe9f6d3b..0054c5b1d28c643e97b93baa27f15845026d71dd 100644 (file)
@@ -509,7 +509,9 @@ struct pipe_resource *r600_texture_create(struct pipe_screen *screen,
                if (!(templ->bind & PIPE_BIND_SCANOUT) &&
                    templ->usage != PIPE_USAGE_STAGING &&
                    templ->usage != PIPE_USAGE_STREAM &&
-                   templ->target != PIPE_TEXTURE_1D) {
+                   templ->target != PIPE_TEXTURE_1D &&
+                   templ->target != PIPE_TEXTURE_1D_ARRAY &&
+                   templ->height0 > 3) {
                        array_mode = V_038000_ARRAY_2D_TILED_THIN1;
                } else if (util_format_is_compressed(templ->format)) {
                        array_mode = V_038000_ARRAY_1D_TILED_THIN1;