This commit is contained in:
Felix
2024-11-26 16:18:33 +01:00
parent 7a482b74ab
commit 3e7d3dbc1b
13 changed files with 177 additions and 55 deletions

View File

@@ -1,10 +1,18 @@
varying vec2 texCoord;
// Use 'in' instead of 'varying' for inputs from the vertex shader
in vec2 texCoord;
// Declare a custom output variable for the fragment color
out vec4 fragColor;
// Uniform samplers
uniform sampler2D m_Texture;
uniform sampler2D m_NormalsTexture;
uniform sampler2D m_DepthTexture;
void main(){
vec4 color = texture2D(m_Texture, texCoord);
gl_FragColor=color;
}
void main() {
// Sample the texture at the given texture coordinates
vec4 color = texture(m_Texture, texCoord);
// Assign the color to the output variable
fragColor = color;
}