+ """
+
+ # Use the object bounding box
+ # (whose points are already in WorldSpace Coordinate)
+
+ bb = o.getBoundBox()
+
+ points_outside = 0
+ for p in bb:
+ p_vect = Vector(cam_pos) - Vector(p)
+
+ d = p_vect * view_vect
+ theta = AngleBetweenVecs(p_vect, view_vect)
+
+ # Is this point outside the view frustum?
+ if (d < near) or (d > far) or (theta > fovy):
+ points_outside += 1
+
+ # If the bb is all outside the view frustum we clip the whole
+ # object away
+ if points_outside == len(bb):
+ scene.unlink(o)
+
+