From: Jason Ekstrand Date: Tue, 7 Jul 2015 21:42:47 +0000 (-0700) Subject: vk/vulkan.h: Remove some unused fields. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=788a8352b9f8db54304f68e15a568563e0341bce;p=mesa.git vk/vulkan.h: Remove some unused fields. In particular, the following are removed: - disableVertexReuse - clipOrigin - depthMode - pointOrigin - provokingVertex --- diff --git a/include/vulkan/vulkan.h b/include/vulkan/vulkan.h index 4e2d8dfc7cc..bef5df4785b 100644 --- a/include/vulkan/vulkan.h +++ b/include/vulkan/vulkan.h @@ -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; diff --git a/src/vulkan/meta.c b/src/vulkan/meta.c index 6c1f57a6956..1613e4356cf 100644 --- a/src/vulkan/meta.c +++ b/src/vulkan/meta.c @@ -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, }; diff --git a/src/vulkan/pipeline.c b/src/vulkan/pipeline.c index f0f578706e9..c500c7a0a33 100644 --- a/src/vulkan/pipeline.c +++ b/src/vulkan/pipeline.c @@ -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,