[Bf-blender-cvs] [bbc1507] master: Fix T48848: Cycles - Camera Culling - Camera Culling removes objects which are still in frame

Sergey Sharybin noreply at git.blender.org
Mon Jul 18 14:30:27 CEST 2016


Commit: bbc15078710a15642982bd4e72e973b1d496598c
Author: Sergey Sharybin
Date:   Mon Jul 18 14:29:37 2016 +0200
Branches: master
https://developer.blender.org/rBbbc15078710a15642982bd4e72e973b1d496598c

Fix T48848: Cycles - Camera Culling - Camera Culling removes objects which are still in frame

===================================================================

M	intern/cycles/blender/blender_object.cpp

===================================================================

diff --git a/intern/cycles/blender/blender_object.cpp b/intern/cycles/blender/blender_object.cpp
index 80768c0..ede8c47 100644
--- a/intern/cycles/blender/blender_object.cpp
+++ b/intern/cycles/blender/blender_object.cpp
@@ -253,11 +253,10 @@ static bool object_boundbox_clip(Scene *scene,
 		                       boundbox[3 * i + 1],
 		                       boundbox[3 * i + 2]);
 		p = transform_point(&tfm, p);
-		p = transform_point(&worldtondc, p);
+		p = transform_perspective(&worldtondc, p);
 		if(p.z >= -margin) {
 			all_behind = false;
 		}
-		p /= p.z;
 		bb_min = min(bb_min, p);
 		bb_max = max(bb_max, p);
 	}




More information about the Bf-blender-cvs mailing list