Fix #141112: EEVEE: Plane Probe is cut off in camera view if Shift X/Y
The projection matrix Y offset was not inverted properly to compensate the view matrix Z axis flip. Pull Request: https://projects.blender.org/blender/blender/pulls/141227
This commit is contained in:
committed by
Clément Foucault
parent
ff5e9c66e7
commit
1b499bdffb
@@ -19,6 +19,8 @@ void PlanarProbe::set_view(const draw::View &view, int layer_id)
|
||||
this->viewmat = from_scale<float4x4>(float3(1, -1, 1)) * view.viewmat() *
|
||||
reflection_matrix_get();
|
||||
this->winmat = view.winmat();
|
||||
/* Invert Y offset in the projection matrix to compensate the flip above (see #141112). */
|
||||
this->winmat[2][1] = -this->winmat[2][1];
|
||||
this->world_to_object_transposed = float3x4(transpose(world_to_plane));
|
||||
this->normal = normalize(plane_to_world.z_axis());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user