Fix T100163: Eevee: Regression: Displacement maps affected by rotation
This was an oversight as the matrix multiplication present in original code was reversed. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D15858
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
void node_displacement_object(float height, float midlevel, float scale, vec3 N, out vec3 result)
|
||||
{
|
||||
N = transform_direction(ModelMatrix, N);
|
||||
N = transform_direction(ModelMatrixInverse, N);
|
||||
result = (height - midlevel) * scale * normalize(N);
|
||||
/* Apply object scale and orientation. */
|
||||
result = transform_direction(ModelMatrix, result);
|
||||
|
||||
Reference in New Issue
Block a user