Skip to content

Commit

Permalink
HOTFIX: fix too agressive block culling
Browse files Browse the repository at this point in the history
  • Loading branch information
RealBadAngel authored and est31 committed Feb 18, 2016
1 parent c3b2797 commit 1ec1a60
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/util/numeric.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 1ec1a60

Please sign in to comment.