From b8c3f0b69d4d22f21d2bb26f048d07bdb795b6b3 Mon Sep 17 00:00:00 2001 From: Giuseppe Modarelli Date: Wed, 21 Dec 2022 09:12:17 +0100 Subject: [PATCH] Fix frustum top plane calculation --- .../Desktop/D3D12MeshShaders/src/DynamicLOD/D3D12DynamicLOD.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Samples/Desktop/D3D12MeshShaders/src/DynamicLOD/D3D12DynamicLOD.cpp b/Samples/Desktop/D3D12MeshShaders/src/DynamicLOD/D3D12DynamicLOD.cpp index d0e3a886f..63ebbd198 100644 --- a/Samples/Desktop/D3D12MeshShaders/src/DynamicLOD/D3D12DynamicLOD.cpp +++ b/Samples/Desktop/D3D12MeshShaders/src/DynamicLOD/D3D12DynamicLOD.cpp @@ -477,7 +477,7 @@ void D3D12DynamicLOD::OnUpdate() XMPlaneNormalize(XMVectorAdd(vp.r[3], vp.r[0])), // Left XMPlaneNormalize(XMVectorSubtract(vp.r[3], vp.r[0])), // Right XMPlaneNormalize(XMVectorAdd(vp.r[3], vp.r[1])), // Bottom - XMPlaneNormalize(XMVectorAdd(vp.r[3], vp.r[1])), // Top + XMPlaneNormalize(XMVectorSubtract(vp.r[3], vp.r[1])), // Top XMPlaneNormalize(vp.r[2]), // Near XMPlaneNormalize(XMVectorSubtract(vp.r[3], vp.r[2])), // Far };