Remove terrain specular and fix washed-out tonemap

Drop specular lighting from terrain shader — ground materials (dirt, grass,
stone) are purely diffuse and specular highlights made them look plastic.
Replace Reinhard tonemapper with a shoulder-only compressor that is identity
below 0.9 and softly rolls off HDR values above, preserving scene contrast.
This commit is contained in:
Kelsi 2026-02-04 15:33:00 -08:00
parent 09e1ee0ae2
commit 1c718dce22
3 changed files with 5 additions and 15 deletions

View file

@ -1176,9 +1176,9 @@ void Renderer::initPostProcess(int w, int h) {
out vec4 FragColor;
void main() {
vec3 color = texture(uScene, vUV).rgb;
float exposure = 1.8;
color *= exposure;
vec3 mapped = color / (color + vec3(1.0));
// Shoulder tonemap: identity below 0.9, soft rolloff above
vec3 excess = max(color - 0.9, 0.0);
vec3 mapped = min(color, vec3(0.9)) + 0.1 * excess / (excess + 0.1);
FragColor = vec4(mapped, 1.0);
}
)";