Graphics/AbstractViewer: Fix Unproject code

This commit is contained in:
Lynix 2018-05-29 21:05:03 +02:00
parent af34567ae7
commit e46aa6772e
1 changed files with 2 additions and 0 deletions

View File

@ -44,6 +44,8 @@ namespace Nz
normalizedPosition.z = screenPos.z * 2.f - 1.f;
normalizedPosition.w = 1.f;
normalizedPosition.y = -normalizedPosition.y;
Nz::Matrix4f invMatrix = GetViewMatrix() * GetProjectionMatrix();
invMatrix.Inverse();