1
0
Fork 0

ubershader: restore lightmap feature

This commit is contained in:
Clément de l'Hamaide 2013-10-21 13:27:35 +02:00
parent f4a134da3b
commit 40013ba1c7
2 changed files with 3 additions and 3 deletions

View file

@ -341,7 +341,7 @@ void main (void)
} else {
lightmapcolor = lightmapTexel.rgb * lightmap_r_color * lightmapFactor.r;
}
fragColor.rgb = max(fragColor.rgb, lightmapcolor * gl_FrontMaterial.diffuse.rgb * mixedcolor);
fragColor.rgb = max(fragColor.rgb, lightmapcolor * gl_FrontMaterial.diffuse.rgb * smoothstep(0.0, 1.0, mixedcolor*.5 + lightmapcolor*.5));
}
//////////////////////////////////////////////////////////////////////
// END lightmap

View file

@ -192,7 +192,7 @@ void main (void)
} else {
lightmapcolor = lightmapTexel.rgb * lightmap_r_color * lightmapFactor.r;
}
fragColor.rgb = max(fragColor.rgb, lightmapcolor * gl_FrontMaterial.diffuse.rgb * mixedcolor);
fragColor.rgb = max(fragColor.rgb, lightmapcolor * gl_FrontMaterial.diffuse.rgb * smoothstep(0.0, 1.0, mixedcolor*.5 + lightmapcolor*.5));
}
//////////////////////////////////////////////////////////////////////
// END lightmap
@ -200,4 +200,4 @@ void main (void)
fragColor.rgb = fog_Func(fragColor.rgb, fogType);
gl_FragColor = fragColor;
}
}