Added Mirror, it kinda works..?

This commit is contained in:
Anemunt
2025-12-19 07:03:03 -05:00
parent 4d82874157
commit ff3bf6ee21
8 changed files with 178 additions and 8 deletions

View File

@@ -11,6 +11,7 @@ uniform sampler2D normalMap;
uniform float mixAmount = 0.2;
uniform bool hasOverlay = false;
uniform bool hasNormalMap = false;
uniform bool unlit = false;
uniform vec3 viewPos;
uniform vec3 materialColor = vec3(1.0);
@@ -52,6 +53,11 @@ void main()
}
vec3 baseColor = texColor * materialColor;
if (unlit) {
FragColor = vec4(baseColor, tex1.a);
return;
}
// Normal map (tangent-space)
if (hasNormalMap) {
vec3 mapN = texture(normalMap, TexCoord).xyz * 2.0 - 1.0;