From: eihrul Date: Tue, 6 Oct 2009 19:57:39 +0000 (+0000) Subject: fixed biasing issue in shadowmap frustum culling X-Git-Tag: xonotic-v0.1.0preview~1317 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=6d58389d72b548356cb830c55699323e97a6f4a5;p=xonotic%2Fdarkplaces.git fixed biasing issue in shadowmap frustum culling git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9317 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/r_shadow.c b/r_shadow.c index 38171250..244424ef 100644 --- a/r_shadow.c +++ b/r_shadow.c @@ -1386,7 +1386,7 @@ int R_Shadow_FrustumCullSides(rtlight_t *rtlight, float size, float border) int i, j; int sides = 0x3F; // cos(45 + bias) - float scale = 0.707106781186548*(size - 2*border)/size; + float scale = 0.707106781186548*size/(size - 2*border); for (i = 0;i < 5;i++) { if (PlaneDiff(rtlight->shadoworigin, &r_refdef.view.frustum[i]) > -0.03125)