Skip to content

Commit ac45bf9

Browse files
committed
Make triangle look for specific shader entry point
This reinstates the behavior after upstream's master sync. Without this triangle did not work.
1 parent a33c6af commit ac45bf9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/triangle/triangle.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -816,7 +816,7 @@ class VulkanExample : public VulkanExampleBase
816816
// Load binary SPIR-V shader
817817
shaderStages[0].module = loadSPIRVShader(getShadersPath() + "triangle/triangle.vert.spv");
818818
// Main entry point for the shader
819-
shaderStages[0].pName = "main";
819+
shaderStages[0].pName = getShaderEntryPoint(VK_SHADER_STAGE_VERTEX_BIT);
820820
assert(shaderStages[0].module != VK_NULL_HANDLE);
821821

822822
// Fragment shader
@@ -826,7 +826,7 @@ class VulkanExample : public VulkanExampleBase
826826
// Load binary SPIR-V shader
827827
shaderStages[1].module = loadSPIRVShader(getShadersPath() + "triangle/triangle.frag.spv");
828828
// Main entry point for the shader
829-
shaderStages[1].pName = "main";
829+
shaderStages[1].pName = getShaderEntryPoint(VK_SHADER_STAGE_FRAGMENT_BIT);
830830
assert(shaderStages[1].module != VK_NULL_HANDLE);
831831

832832
// Set pipeline shader stage info

0 commit comments

Comments
 (0)