From: Dave Airlie <airl...@redhat.com>

This enables tessellation shaders and sets some values for
the maximums.

Signed-off-by: Dave Airlie <airl...@redhat.com>
---
 src/amd/vulkan/radv_device.c   | 18 +++++++++---------
 src/amd/vulkan/radv_pipeline.c |  1 +
 2 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c
index b75d76b..af82926 100644
--- a/src/amd/vulkan/radv_device.c
+++ b/src/amd/vulkan/radv_device.c
@@ -452,7 +452,7 @@ void radv_GetPhysicalDeviceFeatures(
                .imageCubeArray                           = true,
                .independentBlend                         = true,
                .geometryShader                           = true,
-               .tessellationShader                       = false,
+               .tessellationShader                       = true,
                .sampleRateShading                        = false,
                .dualSrcBlend                             = true,
                .logicOp                                  = true,
@@ -565,14 +565,14 @@ void radv_GetPhysicalDeviceProperties(
                .maxVertexInputAttributeOffset            = 2047,
                .maxVertexInputBindingStride              = 2048,
                .maxVertexOutputComponents                = 128,
-               .maxTessellationGenerationLevel           = 0,
-               .maxTessellationPatchSize                 = 0,
-               .maxTessellationControlPerVertexInputComponents = 0,
-               .maxTessellationControlPerVertexOutputComponents = 0,
-               .maxTessellationControlPerPatchOutputComponents = 0,
-               .maxTessellationControlTotalOutputComponents = 0,
-               .maxTessellationEvaluationInputComponents = 0,
-               .maxTessellationEvaluationOutputComponents = 0,
+               .maxTessellationGenerationLevel           = 64,
+               .maxTessellationPatchSize                 = 32,
+               .maxTessellationControlPerVertexInputComponents = 128,
+               .maxTessellationControlPerVertexOutputComponents = 128,
+               .maxTessellationControlPerPatchOutputComponents = 120,
+               .maxTessellationControlTotalOutputComponents = 4096,
+               .maxTessellationEvaluationInputComponents = 128,
+               .maxTessellationEvaluationOutputComponents = 128,
                .maxGeometryShaderInvocations             = 32,
                .maxGeometryInputComponents               = 64,
                .maxGeometryOutputComponents              = 128,
diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c
index 84cb244..e89ee96 100644
--- a/src/amd/vulkan/radv_pipeline.c
+++ b/src/amd/vulkan/radv_pipeline.c
@@ -212,6 +212,7 @@ radv_shader_compile_to_nir(struct radv_device *device,
                        .float64 = true,
                        .image_read_without_format = true,
                        .image_write_without_format = true,
+                       .tessellation = true,
                };
                entry_point = spirv_to_nir(spirv, module->size / 4,
                                           spec_entries, num_spec_entries,
-- 
2.9.3

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to