From: Dae Kim Date: Thu, 22 Feb 2018 15:43:54 +0000 (+0000) Subject: Added missing gl_PointSizes when drawing points X-Git-Tag: upstream/1.3.5~2565^2~44 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3a7dd8c0c8a666a85d1e7213a6aa4413761c87ee;p=platform%2Fupstream%2FVK-GL-CTS.git Added missing gl_PointSizes when drawing points Some tests using point list primitive topology were not specifying point sizes with the gl_PointSize built-in. Affects: dEQP-VK.subgroups.* dEQP-VK.synchronization.* Components: Vulkan VK-GL-CTS issue: 1035 Change-Id: I6f1690adef24ac76103bc22a86405ceec77865f4 --- diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsArithmeticTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsArithmeticTests.cpp index e483d32..a0f9eb9 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsArithmeticTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsArithmeticTests.cpp @@ -659,6 +659,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; programCollection.glslSources.add("vert") << glu::VertexSource(vertex) << vk::ShaderBuildOptions(vk::SPIRV_VERSION_1_3, 0u); diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotBroadcastTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotBroadcastTests.cpp index 0c0b9cf..25bf8f8 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotBroadcastTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotBroadcastTests.cpp @@ -340,6 +340,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f\n;" "}\n"; const std::string tesc = diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotOtherTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotOtherTests.cpp index 7ba3a95..91b7282 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotOtherTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotOtherTests.cpp @@ -508,6 +508,7 @@ void initPrograms (SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; const string tesc = diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotTests.cpp index caa46bc..f45b3ae 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBallotTests.cpp @@ -220,6 +220,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; const string tesc = diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBasicTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBasicTests.cpp index 5936fb4..559c7cb 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBasicTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBasicTests.cpp @@ -550,6 +550,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) << " float pixelSize = 2.0f/1024.0f;\n" << " float pixelPosition = pixelSize/2.0f - 1.0f;\n" << " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + << " gl_PointSize = 1.0f;\n" << "}\n"; programCollection.glslSources.add("vert") << glu::VertexSource(vertex.str()) << vk::ShaderBuildOptions(vk::SPIRV_VERSION_1_3, 0u); @@ -801,6 +802,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; programCollection.glslSources.add("vert") << glu::VertexSource(vertex) << vk::ShaderBuildOptions(vk::SPIRV_VERSION_1_3, 0u); diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinMaskVarTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinMaskVarTests.cpp index c7373dc..11c21bc 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinMaskVarTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinMaskVarTests.cpp @@ -253,6 +253,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; programCollection.glslSources.add("vert") << glu::VertexSource(vertex) << vk::ShaderBuildOptions(vk::SPIRV_VERSION_1_3, 0u); diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinVarTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinVarTests.cpp index 87fec01..54a3ef6 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinVarTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsBuiltinVarTests.cpp @@ -398,6 +398,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; */ const string vertex = @@ -458,6 +459,8 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) "%41 = OpVariable %40 Output\n" "%48 = OpConstant %26 0\n" "%50 = OpTypePointer Output %36\n" + "%52 = OpConstant %12 1\n" + "%53 = OpTypePointer Output %26\n" "%4 = OpFunction %2 None %3\n" "%5 = OpLabel\n" "%28 = OpVariable %27 Function\n" @@ -482,10 +485,11 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) "%49 = OpCompositeConstruct %36 %47 %48 %48 %34\n" "%51 = OpAccessChain %50 %41 %13\n" "OpStore %51 %49\n" + "%54 = OpAccessChain %53 %41 %52\n" + "OpStore %54 %34\n" "OpReturn\n" "OpFunctionEnd\n"; programCollection.spirvAsmSources.add("vert") << vertex << SpirVAsmBuildOptions(SPIRV_VERSION_1_3); - } { diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsShuffleTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsShuffleTests.cpp index 7ace300..66158f0 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsShuffleTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsShuffleTests.cpp @@ -320,6 +320,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; programCollection.glslSources.add("vert") diff --git a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsVoteTests.cpp b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsVoteTests.cpp index 849bff2..c0f891b 100644 --- a/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsVoteTests.cpp +++ b/external/vulkancts/modules/vulkan/subgroups/vktSubgroupsVoteTests.cpp @@ -384,6 +384,7 @@ void initPrograms(SourceCollections& programCollection, CaseDefinition caseDef) " float pixelSize = 2.0f/1024.0f;\n" " float pixelPosition = pixelSize/2.0f - 1.0f;\n" " gl_Position = vec4(float(gl_VertexIndex) * pixelSize + pixelPosition, 0.0f, 0.0f, 1.0f);\n" + " gl_PointSize = 1.0f;\n" "}\n"; programCollection.glslSources.add("vert") << glu::VertexSource(vertex) << vk::ShaderBuildOptions(vk::SPIRV_VERSION_1_3, 0u); diff --git a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationInternallySynchronizedObjectsTests.cpp b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationInternallySynchronizedObjectsTests.cpp index 77c166a..2e994f1 100644 --- a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationInternallySynchronizedObjectsTests.cpp +++ b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationInternallySynchronizedObjectsTests.cpp @@ -1115,6 +1115,7 @@ public: << "void main (void)\n" << "{\n" << " sb_out.result[gl_VertexIndex] = int(gl_VertexIndex);\n" + << " gl_PointSize = 1.0f;\n" << "}\n"; programCollection.glslSources.add("vert_0") << glu::VertexSource(src.str()); } @@ -1131,6 +1132,7 @@ public: << " {\n" << " sb_out.result[ndx] = int(ndx);\n" << " }\n" + << " gl_PointSize = 1.0f;\n" << "}\n"; programCollection.glslSources.add("vert_1") << glu::VertexSource(src.str()); } @@ -1147,6 +1149,7 @@ public: << " {\n" << " sb_out.result[uint(ndx)] = ndx;\n" << " }\n" + << " gl_PointSize = 1.0f;\n" << "}\n"; programCollection.glslSources.add("vert_2") << glu::VertexSource(src.str()); } diff --git a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp index eaf1f1a..5ae90d9 100644 --- a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp +++ b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp @@ -3360,6 +3360,7 @@ public: << "void main (void)\n" << "{\n" << " b_out.data[gl_VertexIndex] = v_in_data;\n" + << " gl_PointSize = 1.0f;\n" << "}\n"; programCollection.glslSources.add("input_vert") << glu::VertexSource(src.str()); }