vk/0.210.0: Remove depth clip and add depth clamp
authorJason Ekstrand <jason.ekstrand@intel.com>
Thu, 3 Dec 2015 01:07:26 +0000 (17:07 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 3 Dec 2015 21:43:59 +0000 (13:43 -0800)
include/vulkan/vulkan.h
src/vulkan/anv_meta.c
src/vulkan/anv_meta_clear.c
src/vulkan/gen8_pipeline.c

index 8036b6126aa6200c389764c5771b8dcc0bcbc942..67ab34ddf23c5fe66b166b7009540bd7bfe5e3fe 100644 (file)
@@ -1688,7 +1688,7 @@ typedef struct VkPipelineRasterizationStateCreateInfo {
     VkStructureType                             sType;
     const void*                                 pNext;
     VkPipelineRasterizationStateCreateFlags     flags;
-    VkBool32                                    depthClipEnable;
+    VkBool32                                    depthClampEnable;
     VkBool32                                    rasterizerDiscardEnable;
     VkPolygonMode                               polygonMode;
     VkCullModeFlags                             cullMode;
index 67651c542b7a48dfe33231b15c337cf2577a4f94..bed01980a0d0079b24e4687368d038ca0c95f396 100644 (file)
@@ -334,7 +334,6 @@ anv_device_init_meta_blit_state(struct anv_device *device)
       },
       .pRasterizationState = &(VkPipelineRasterizationStateCreateInfo) {
          .sType = VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_STATE_CREATE_INFO,
-         .depthClipEnable = true,
          .rasterizerDiscardEnable = false,
          .polygonMode = VK_POLYGON_MODE_FILL,
          .cullMode = VK_CULL_MODE_NONE,
index a2667c7bb6e4bdbde46f18036d1350b5fa008828..24ff1ea75e49c9be417d9da47d29648492e08c7b 100644 (file)
@@ -160,13 +160,11 @@ create_pipeline(struct anv_device *device,
          },
          .pRasterizationState = &(VkPipelineRasterizationStateCreateInfo) {
             .sType = VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_STATE_CREATE_INFO,
-            .depthClipEnable = false,
             .rasterizerDiscardEnable = false,
             .polygonMode = VK_POLYGON_MODE_FILL,
             .cullMode = VK_CULL_MODE_NONE,
             .frontFace = VK_FRONT_FACE_COUNTER_CLOCKWISE,
             .depthBiasEnable = false,
-            .depthClipEnable = false,
          },
          .pMultisampleState = &(VkPipelineMultisampleStateCreateInfo) {
             .sType = VK_STRUCTURE_TYPE_PIPELINE_MULTISAMPLE_STATE_CREATE_INFO,
index 82a63d3bfb3d4b9583e50809aeddaf59052fe758..d0395741474415bb135205727c6671bab2f3ee49 100644 (file)
@@ -135,11 +135,11 @@ emit_rs_state(struct anv_pipeline *pipeline,
       .BackFaceFillMode = vk_to_gen_fillmode[info->polygonMode],
       .ScissorRectangleEnable = !(extra && extra->disable_scissor),
 #if ANV_GEN == 8
-      .ViewportZClipTestEnable = info->depthClipEnable
+      .ViewportZClipTestEnable = true,
 #else
       /* GEN9+ splits ViewportZClipTestEnable into near and far enable bits */
-      .ViewportZFarClipTestEnable = info->depthClipEnable,
-      .ViewportZNearClipTestEnable = info->depthClipEnable,
+      .ViewportZFarClipTestEnable = true,
+      .ViewportZNearClipTestEnable = true,
 #endif
    };