This commit is contained in:
Tleety
2016-02-24 13:57:54 +01:00
parent 8d23c531af
commit 6f9ce8a0c1
5 changed files with 30 additions and 21 deletions
+4 -4
View File
@@ -23,12 +23,12 @@ out VertexData{
void main()
{
gl_Position = P*V*M * vec4(Position, 1.0);
mat4 TIM = transpose(inverse(M));
Output.Position = Position;
Output.TextureCoordinate = TextureCoords;
Output.Normal = vec3(M * vec4(Normal, 0.0));
Output.Tangent = vec3(M * vec4(Tangent, 0.0));
Output.BiTangent = vec3(M * vec4(BiTangent, 0.0));
Output.Normal = vec3(TIM) * Normal;
Output.Tangent = vec3(TIM) * Tangent;
Output.BiTangent = vec3(TIM) * BiTangent;
Output.ExplosionColor = vec4(1.0);
Output.ExplosionPercentageElapsed = 0.0;
}