Fix T100602: Incoming Vector in world shader for Eevee is inverted

Regression from {rBf4d7ea2cf61} where the direction was flipped.

Maniphest Tasks: T100602

Differential Revision: https://developer.blender.org/D15779
This commit is contained in:
Philipp Oeser 2022-08-25 10:38:30 +02:00
parent c9723d9464
commit 60420f6ea4
Notes: blender-bot 2023-02-14 11:42:40 +01:00
Referenced by issue #100602, Incoming Vector in world shader for Eevee is inverted in 3.3 beta
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ GlobalData init_globals(void)
GlobalData surf;
# if defined(WORLD_BACKGROUND) || defined(PROBE_CAPTURE)
surf.P = transform_direction(ViewMatrixInverse, viewCameraVec(viewPosition));
surf.P = transform_direction(ViewMatrixInverse, -viewCameraVec(viewPosition));
surf.N = surf.Ng = -surf.P;
surf.ray_length = 0.0;
# else