diff options
author | Juan Linietsky <reduzio@gmail.com> | 2014-10-14 01:01:25 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2014-10-14 01:01:25 -0300 |
commit | a84ba9c853f972f8e666b17f3e0f875b7282e6c1 (patch) | |
tree | 70a5d44acbecc93011333d13dd51b1786d42eae3 /drivers/gles2/shaders | |
parent | 13a848e332092b40956739a08fa0dac3357db950 (diff) |
Collada
-=-=-=-
-Fixed some DAE import & export bugs
-Changed Collada exporter to use the mesh loops API
-Added tangent export to Collada exporter
-Added triangulation option to Collada exporter
-Changed a little how normalmaps are handled in shader. Not sure if it's working properly, be careful.
-Fixed some strange bug with kinematic bodies #776
-Fix release compilaiton issues #782
Diffstat (limited to 'drivers/gles2/shaders')
-rw-r--r-- | drivers/gles2/shaders/material.glsl | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gles2/shaders/material.glsl b/drivers/gles2/shaders/material.glsl index 63ff4a5f47..bf82822378 100644 --- a/drivers/gles2/shaders/material.glsl +++ b/drivers/gles2/shaders/material.glsl @@ -819,6 +819,10 @@ void main() { vec4 color = color_interp; #endif +#if defined(ENABLE_NORMALMAP) + + vec3 normalmap = vec3(0.0); +#endif @@ -833,6 +837,11 @@ FRAGMENT_SHADER_CODE } +#if defined(ENABLE_NORMALMAP) + + normal = normalize( tangent_interp * normalmap.x + binormal_interp * normalmap.y + normal_interp * normalmap.z ) * side; +#endif + #if defined(ENABLE_DISCARD) if (discard_) { //easy to eliminate dead code |