anv/blit2d: Use the tiling enum for simplicity
authorNanley Chery <nanley.g.chery@intel.com>
Tue, 8 Mar 2016 17:37:43 +0000 (09:37 -0800)
committerNanley Chery <nanley.g.chery@intel.com>
Wed, 9 Mar 2016 18:57:47 +0000 (10:57 -0800)
Signed-off-by: Nanley Chery <nanley.g.chery@intel.com>
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
src/intel/vulkan/anv_meta_blit2d.c

index d49b4708f8eb7a7e63e104046b1820b5ad0db450..6f0734254bf8bd554affea8ad97be8bac0247f55 100644 (file)
@@ -110,8 +110,7 @@ anv_meta_blit2d(struct anv_cmd_buffer *cmd_buffer,
       struct isl_tile_info tile_info;
 
       anv_image_info.isl_tiling_flags = 1 << src->tiling;
-      image_info.tiling = anv_image_info.isl_tiling_flags ==
-                          ISL_TILING_LINEAR_BIT ?
+      image_info.tiling = src->tiling == ISL_TILING_LINEAR ?
                           VK_IMAGE_TILING_LINEAR : VK_IMAGE_TILING_OPTIMAL;
       image_info.usage = src_usage;
       image_info.format = src_format,
@@ -125,8 +124,7 @@ anv_meta_blit2d(struct anv_cmd_buffer *cmd_buffer,
                        &cmd_buffer->pool->alloc, &src_image);
 
       anv_image_info.isl_tiling_flags = 1 << dst->tiling;
-      image_info.tiling = anv_image_info.isl_tiling_flags ==
-                          ISL_TILING_LINEAR_BIT ?
+      image_info.tiling = dst->tiling == ISL_TILING_LINEAR ?
                           VK_IMAGE_TILING_LINEAR : VK_IMAGE_TILING_OPTIMAL;
       image_info.usage = dst_usage;
       image_info.format = dst_format,