diff options
| author | David Reid <[email protected]> | 2018-05-21 20:26:28 +1000 |
|---|---|---|
| committer | David Reid <[email protected]> | 2018-05-21 20:26:28 +1000 |
| commit | 6d8cc250bd086a6bfdf34effad4b9b3cca3e97a7 (patch) | |
| tree | 95d9092e666ef409dd4cb75a5f836e37acabfdf9 /examples/models/resources | |
| parent | 3ca5047c8285318c2385c6b52b2e2b5f12905f0d (diff) | |
| parent | e025e62445913bf1ec9cf075eaaf1dc7374da83c (diff) | |
| download | raylib-6d8cc250bd086a6bfdf34effad4b9b3cca3e97a7.tar.gz raylib-6d8cc250bd086a6bfdf34effad4b9b3cca3e97a7.zip | |
Merge branch 'master' of https://github.com/raysan5/raylib into dr/mini_al
Diffstat (limited to 'examples/models/resources')
| -rw-r--r-- | examples/models/resources/shaders/pbr.vs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/models/resources/shaders/pbr.vs b/examples/models/resources/shaders/pbr.vs index 885cb199..8bd3faa1 100644 --- a/examples/models/resources/shaders/pbr.vs +++ b/examples/models/resources/shaders/pbr.vs @@ -16,7 +16,7 @@ in vec4 vertexTangent; // Input uniform values uniform mat4 mvp; -uniform mat4 mMatrix; +uniform mat4 matModel; // Output vertex attributes (to fragment shader) out vec3 fragPosition; @@ -31,10 +31,10 @@ void main() vec3 vertexBinormal = cross(vertexNormal, vec3(vertexTangent)); // Calculate fragment normal based on normal transformations - mat3 normalMatrix = transpose(inverse(mat3(mMatrix))); + mat3 normalMatrix = transpose(inverse(mat3(matModel))); // Calculate fragment position based on model transformations - fragPosition = vec3(mMatrix*vec4(vertexPosition, 1.0f)); + fragPosition = vec3(matModel*vec4(vertexPosition, 1.0f)); // Send vertex attributes to fragment shader fragTexCoord = vertexTexCoord; |
