diff options
author | RealBadAngel <maciej.kasatkin@o2.pl> | 2016-02-13 23:39:37 +0100 |
---|---|---|
committer | est31 <MTest31@outlook.com> | 2016-02-18 18:07:28 +0100 |
commit | 1ec1a605d664b42a034cecb9f2e768fab3d738d4 (patch) | |
tree | 6c8558286541d50e9029623a5fe5bfb224ed5e0e /src/util | |
parent | c3b279750ece0b5144bf8e973d55108347462223 (diff) | |
download | minetest-1ec1a605d664b42a034cecb9f2e768fab3d738d4.tar.gz minetest-1ec1a605d664b42a034cecb9f2e768fab3d738d4.tar.bz2 minetest-1ec1a605d664b42a034cecb9f2e768fab3d738d4.zip |
HOTFIX: fix too agressive block culling
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/numeric.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/util/numeric.cpp b/src/util/numeric.cpp index bfd5d6e38..42ebd9022 100644 --- a/src/util/numeric.cpp +++ b/src/util/numeric.cpp @@ -244,7 +244,10 @@ bool isBlockInSight(v3s16 blockpos_b, v3f camera_pos, v3f camera_dir, f32 cosangle = dforward / blockpos_adj.getLength(); // If block is not in the field of view, skip it - if(cosangle < cos(camera_fov / 2)) + // HOTFIX: use sligthly increased angle (+10%) to fix too agressive + // culling. Somebody have to find out whats wrong with the math here. + // Previous value: camera_fov / 2 + if(cosangle < cos(camera_fov * 0.55)) return false; return true; |