diff --git a/.gitignore b/.gitignore index d9c29a0..1f4da7d 100644 --- a/.gitignore +++ b/.gitignore @@ -3,4 +3,4 @@ bin/ int/ dep/ *aps -*res \ No newline at end of file +*.res \ No newline at end of file diff --git a/NothinFancy/res/defaultShader/fragment.shader b/NothinFancy/res/defaultShader/fragment.shader new file mode 100644 index 0000000..b2875d5 --- /dev/null +++ b/NothinFancy/res/defaultShader/fragment.shader @@ -0,0 +1,9 @@ +#version 330 core + +out vec4 color; + +in vec2 texCoord; + +void main() { + color = vec4(1.0, 0.0, 1.0, 1.0); +} diff --git a/NothinFancy/res/defaultShader/vertex.shader b/NothinFancy/res/defaultShader/vertex.shader new file mode 100644 index 0000000..3527294 --- /dev/null +++ b/NothinFancy/res/defaultShader/vertex.shader @@ -0,0 +1,16 @@ +#version 330 core + +layout(location = 0) in vec3 pos; +layout(location = 1) in vec2 texCoords; + +uniform mat4 model; +uniform mat4 view; +uniform mat4 proj; + +out vec2 texCoord; + +void main() { + //gl_Position = proj * view * model * vec4(pos, 1.0); + gl_Position = model * vec4(pos, 1.0); + texCoord = texCoords; +}