Draw red example triangle
This commit is contained in:
10
lib/shaders/monochrome.fragment.glsl
Normal file
10
lib/shaders/monochrome.fragment.glsl
Normal file
@@ -0,0 +1,10 @@
|
||||
#version 330 core
|
||||
|
||||
out vec4 fragmentColor;
|
||||
|
||||
uniform vec3 color;
|
||||
|
||||
void main()
|
||||
{
|
||||
fragmentColor = vec4(color.r, color.g, color.b, 1.0);
|
||||
}
|
8
lib/shaders/passthrough2d.vertex.glsl
Normal file
8
lib/shaders/passthrough2d.vertex.glsl
Normal file
@@ -0,0 +1,8 @@
|
||||
#version 330 core
|
||||
|
||||
layout (location = 0) in vec2 inputVertex;
|
||||
|
||||
void main()
|
||||
{
|
||||
gl_Position = vec4(inputVertex.x, inputVertex.y, 0.0, 1.0);
|
||||
}
|
8
lib/shaders/passthrough3d.vertex.glsl
Normal file
8
lib/shaders/passthrough3d.vertex.glsl
Normal file
@@ -0,0 +1,8 @@
|
||||
#version 330 core
|
||||
|
||||
layout (location = 0) in vec3 inputVertex;
|
||||
|
||||
void main()
|
||||
{
|
||||
gl_Position = vec4(inputVertex.x, inputVertex.y, inputVertex.z, 1.0);
|
||||
}
|
Reference in New Issue
Block a user