reorganized directory

This commit is contained in:
Alessandro Mauri 2025-06-09 12:25:48 +02:00
parent 9d507e38cb
commit 076355e2d1
35 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,29 @@
#version 450 core
// Explicitly set the output location for Vulkan
layout(location = 0) out vec4 vColor;
void main() {
// Initialize with default values
vec2 pos = vec2(0.0);
vec4 color = vec4(0.0);
// Use Vulkan's gl_VertexIndex instead of gl_VertexID
switch(gl_VertexIndex) {
case 0:
pos = vec2(-1.0, -1.0);
color = vec4(1.0, 0.0, 0.0, 1.0);
break;
case 1:
pos = vec2(1.0, -1.0);
color = vec4(0.0, 1.0, 0.0, 1.0);
break;
case 2:
pos = vec2(0.0, 1.0);
color = vec4(0.0, 0.0, 1.0, 1.0);
break;
}
gl_Position = vec4(pos, 0.0, 1.0);
vColor = color;
}

View file

@ -0,0 +1,9 @@
#version 450 core
layout(location = 0) in vec4 Color; // Explicit location for fragment input
layout(location = 0) out vec4 FragColor; // Explicit location for fragment output
void main()
{
FragColor = Color;
}