1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-25 05:35:25 +02:00

Avoid shadow flicker at certain angles (#12961)

Change the way look direction and camera position are quantized when calculating light frustum
This commit is contained in:
x2048
2022-11-20 21:28:01 +01:00
committed by GitHub
parent 5f24a3c0c7
commit 70a82b0784
2 changed files with 21 additions and 7 deletions

View File

@@ -114,6 +114,10 @@ private:
v3f pos;
v3f direction{0};
v3f last_cam_pos_world{0,0,0};
v3f last_look{0,1,0};
shadowFrustum shadow_frustum;
shadowFrustum future_frustum;
bool dirty{false};