X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=shaderlib%2Fcommon.glsl;h=4a81636037be1224d0d2856cdfd90b67d8eef3fc;hb=f38c24ad1765f39f620267c0a85e532cb851baac;hp=05648e4c0c106f469b63ed0346dc4c8b32c0c9be;hpb=146df2d02940a04aeafe854bdd981a1489cc80b3;p=libs%2Fgl.git diff --git a/shaderlib/common.glsl b/shaderlib/common.glsl index 05648e4c..4a816360 100644 --- a/shaderlib/common.glsl +++ b/shaderlib/common.glsl @@ -68,7 +68,7 @@ void main() vec3 get_fragment_normal() { if(use_normal_map) - return texture(normal_map, texcoord.xy).xyz*2.0-1.0; + return normalize(texture(normal_map, texcoord.xy).xyz*2.0-1.0); else return vec3(0.0, 0.0, 1.0); }