From ff97614e765ad6582074c46d23d9b40edacb273c Mon Sep 17 00:00:00 2001 From: David Rose Date: Fri, 15 Jun 2001 20:29:18 +0000 Subject: [PATCH] workaround for culling bugs --- direct/src/actor/Actor.py | 15 +++++++++++++++ direct/src/showbase/ShowBase.py | 1 + 2 files changed, 16 insertions(+) diff --git a/direct/src/actor/Actor.py b/direct/src/actor/Actor.py index 2bafa476be..fad56a3f22 100644 --- a/direct/src/actor/Actor.py +++ b/direct/src/actor/Actor.py @@ -188,6 +188,21 @@ class Actor(PandaObject, NodePath): # copy the anim dictionary from other self.__copyAnimControls(other) + + # For now, all Actors will by default set their top bounding + # volume to be the "final" bounding volume: the bounding + # volumes below the top volume will not be tested. If a cull + # test passes the top bounding volume, the whole Actor is + # rendered. + + # We do this partly because an Actor is likely to be a fairly + # small object relative to the scene, and is pretty much going + # to be all onscreen or all offscreen anyway; and partly + # because of the Character bug that doesn't update the + # bounding volume for pieces that animate away from their + # original position. It's disturbing to see someone's hands + # disappear; better to cull the whole object or none of it. + self.__geomNode.arc().setFinal(1) def delete(self): try: diff --git a/direct/src/showbase/ShowBase.py b/direct/src/showbase/ShowBase.py index 1a671d4975..481e99ff4d 100644 --- a/direct/src/showbase/ShowBase.py +++ b/direct/src/showbase/ShowBase.py @@ -450,6 +450,7 @@ class ShowBase: self.oobeButtonEventsType = TypeRegistry.ptr().findType('ButtonEvents_ButtonEventDataTransition') self.oobeVis = loader.loadModelOnce('models/misc/camera') + self.oobeVis.arc().setFinal(1) self.oobeCullFrustum = None # Make sure the MouseValve is monitoring the Control key.