learnOpengl/shaders/vertexShader.glsl
2023-10-12 15:07:28 +08:00

9 lines
237 B
GLSL

#version 330 core
layout (location = 0) in vec3 aPos;
layout (location = 1) in vec3 aColor;
uniform float position;
out vec3 ourColor;
void main(){
gl_Position = vec4(aPos.x + position , -aPos.y, aPos.z, 1.0f);
ourColor = aPos;
}