diff options
| -rw-r--r-- | intermediate/surface.glsl | 4 | 
1 files changed, 2 insertions, 2 deletions
| diff --git a/intermediate/surface.glsl b/intermediate/surface.glsl index 7988502..8afc657 100644 --- a/intermediate/surface.glsl +++ b/intermediate/surface.glsl @@ -99,8 +99,8 @@ type: vec4  void main() {  	vec4 pos = c_mvp.model * vec4(position, 1.0);  	vec3 t = normalize((c_mvp.model * vec4(tangent, 0.0)).xyz); -	vec3 b = normalize((c_mvp.model * vec4(normal, 0.0)).xyz); -	vec3 n = normalize((c_mvp.model * vec4(cross(normal, tangent), 0.0)).xyz); +	vec3 n = normalize((c_mvp.model * vec4(normal, 0.0)).xyz); +	vec3 b = cross(t, n);  	interpolator.normal = n;  	interpolator.tbn = mat3(t, b, n);  	interpolator.uv = uv; |