vk/vulkan.h: Remove some unused fields.
authorJason Ekstrand <jason.ekstrand@intel.com>
Tue, 7 Jul 2015 21:42:47 +0000 (14:42 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Tue, 7 Jul 2015 22:33:00 +0000 (15:33 -0700)
In particular, the following are removed:

 - disableVertexReuse
 - clipOrigin
 - depthMode
 - pointOrigin
 - provokingVertex

include/vulkan/vulkan.h
src/vulkan/meta.c
src/vulkan/pipeline.c

index 4e2d8dfc7cc22ea01cc35bc8b0fe9ae16f12c245..bef5df4785bc5d4026399e68a11120f5bce16678 100644 (file)
@@ -1061,27 +1061,6 @@ typedef enum {
 } VkMemoryInputFlagBits;
 typedef VkFlags VkMemoryInputFlags;
 
-typedef enum {
-    VK_PROVOKING_VERTEX_FIRST                               = 0x00000000,
-    VK_PROVOKING_VERTEX_LAST                                = 0x00000001,
-
-    VK_ENUM_RANGE(PROVOKING_VERTEX, FIRST, LAST)
-} VkProvokingVertex;
-
-typedef enum {
-    VK_COORDINATE_ORIGIN_UPPER_LEFT                         = 0x00000000,
-    VK_COORDINATE_ORIGIN_LOWER_LEFT                         = 0x00000001,
-
-    VK_ENUM_RANGE(COORDINATE_ORIGIN, UPPER_LEFT, LOWER_LEFT)
-} VkCoordinateOrigin;
-
-typedef enum {
-    VK_DEPTH_MODE_ZERO_TO_ONE                               = 0x00000000,
-    VK_DEPTH_MODE_NEGATIVE_ONE_TO_ONE                       = 0x00000001,
-
-    VK_ENUM_RANGE(DEPTH_MODE, ZERO_TO_ONE, NEGATIVE_ONE_TO_ONE)
-} VkDepthMode;
-
 typedef enum {
     // Info type for vkGetPhysicalDeviceInfo()
     VK_PHYSICAL_DEVICE_INFO_TYPE_PROPERTIES                 = 0x00000000,
@@ -1450,7 +1429,6 @@ typedef struct {
     VkStructureType                             sType;
     const void*                                 pNext;
     VkPrimitiveTopology                         topology;
-    bool32_t                                    disableVertexReuse;
     bool32_t                                    primitiveRestartEnable;
 } VkPipelineIaStateCreateInfo;
 
@@ -1464,8 +1442,6 @@ typedef struct {
     VkStructureType                             sType;
     const void*                                 pNext;
     uint32_t                                    viewportCount;
-    VkCoordinateOrigin                          clipOrigin;
-    VkDepthMode                                 depthMode;
 } VkPipelineVpStateCreateInfo;
 
 typedef struct {
@@ -1474,8 +1450,6 @@ typedef struct {
     bool32_t                                    depthClipEnable;
     bool32_t                                    rasterizerDiscardEnable;
     bool32_t                                    programPointSize;
-    VkCoordinateOrigin                          pointOrigin;
-    VkProvokingVertex                           provokingVertex;
     VkFillMode                                  fillMode;
     VkCullMode                                  cullMode;
     VkFrontFace                                 frontFace;
index 6c1f57a6956dbf05ab871ed4fdda8b9879f73fdf..1613e4356cf4707df3cd7f624b0ec71e37ee470e 100644 (file)
@@ -36,7 +36,6 @@ anv_device_init_meta_clear_state(struct anv_device *device)
    VkPipelineIaStateCreateInfo ia_create_info = {
       .sType = VK_STRUCTURE_TYPE_PIPELINE_IA_STATE_CREATE_INFO,
       .topology = VK_PRIMITIVE_TOPOLOGY_TRIANGLE_STRIP,
-      .disableVertexReuse = false,
       .primitiveRestartEnable = false,
    };
 
@@ -311,7 +310,6 @@ anv_device_init_meta_blit_state(struct anv_device *device)
    VkPipelineIaStateCreateInfo ia_create_info = {
       .sType = VK_STRUCTURE_TYPE_PIPELINE_IA_STATE_CREATE_INFO,
       .topology = VK_PRIMITIVE_TOPOLOGY_TRIANGLE_STRIP,
-      .disableVertexReuse = false,
       .primitiveRestartEnable = false,
    };
 
index f0f578706e9bed38db6213618b45fdb2742ea81a..c500c7a0a33d1fac5b3f6415c20e7f0183f2a1bf 100644 (file)
@@ -177,21 +177,13 @@ emit_rs_state(struct anv_pipeline *pipeline, VkPipelineRsStateCreateInfo *info,
       [VK_FRONT_FACE_CCW]                       = CounterClockwise,
       [VK_FRONT_FACE_CW]                        = Clockwise
    };
-   
-   static const uint32_t vk_to_gen_coordinate_origin[] = {
-      [VK_COORDINATE_ORIGIN_UPPER_LEFT]         = UPPERLEFT,
-      [VK_COORDINATE_ORIGIN_LOWER_LEFT]         = LOWERLEFT
-   };
 
    struct GEN8_3DSTATE_SF sf = {
       GEN8_3DSTATE_SF_header,
       .ViewportTransformEnable = !(extra && extra->disable_viewport),
-      .TriangleStripListProvokingVertexSelect =
-         info->provokingVertex == VK_PROVOKING_VERTEX_FIRST ? 0 : 2,
-      .LineStripListProvokingVertexSelect =
-         info->provokingVertex == VK_PROVOKING_VERTEX_FIRST ? 0 : 1,
-      .TriangleFanProvokingVertexSelect =
-         info->provokingVertex == VK_PROVOKING_VERTEX_FIRST ? 0 : 2,
+      .TriangleStripListProvokingVertexSelect = 0,
+      .LineStripListProvokingVertexSelect = 0,
+      .TriangleFanProvokingVertexSelect = 0,
       .PointWidthSource = info->programPointSize ? Vertex : State,
    };
 
@@ -214,8 +206,7 @@ emit_rs_state(struct anv_pipeline *pipeline, VkPipelineRsStateCreateInfo *info,
    anv_batch_emit(&pipeline->batch, GEN8_3DSTATE_SBE,
                   .ForceVertexURBEntryReadLength = false,
                   .ForceVertexURBEntryReadOffset = false,
-                  .PointSpriteTextureCoordinateOrigin =
-                     vk_to_gen_coordinate_origin[info->pointOrigin],
+                  .PointSpriteTextureCoordinateOrigin = UPPERLEFT,
                   .NumberofSFOutputAttributes =
                      pipeline->wm_prog_data.num_varying_inputs);
 
@@ -645,7 +636,7 @@ anv_pipeline_create(
                      .MaximumNumberofThreads = device->info.max_vs_threads - 1,
                      .StatisticsEnable = false,
                      .SIMD8DispatchEnable = true,
-                     .VertexCacheDisable = ia_info->disableVertexReuse,
+                     .VertexCacheDisable = false,
                      .FunctionEnable = true,
 
                      .VertexURBEntryOutputReadOffset = offset,