
Some parts of this message have been removed.
Learn more about Nabble's
security policy.
initBounds | length x y z |
length := xLength max: (yLength max: (zEnd - zStart)).
x := xLength/2.
y := yLength/2.
z := (zEnd - zStart)/2.
boundSphere := TBoundSphere localPosition: (self startingPoint + (x@y@z)) radius: length.
boundSphere frame: self.
As requested, the above is the message that instantiates the TBoundSphere and places it in the center of the cube. The variable length stores the longest side among the width, length and height of the cube which will then be the radius for the boundSphere.
----- Original Message ----
From: Darius Clarke <
socinian@...>
To:
croquet-dev@...; Phua Khai Fong <
kayef8@...>
Sent: Wednesday, March 19, 2008 0:37:54
Subject: Re: [croquet-dev] Trouble rendering with TBoundsphere
Is it possible to send to us a copy or segment of the code where you use TBoundSphere?
Cheers,
Darius
On Tue, Mar 18, 2008 at 3:27 AM, Phua Khai Fong <
kayef8@...> wrote:
Hi,
I have a problem with the rendering of an object in the world. First, i create a cube and specify a TBoundSphere surrounding it. After having the TBoundSphere, the cube seems to have problems rendering itself, it becomes invisible at some angles to the avatar meaning, if i move around the cube, at some points, the cube will just disappear but it'll appear again at other points. It renders fine without the TBoundSphere. Has anyone encountered this problem? By the way, the cube can have different length, width and depth. The TBoundSphere is centered at the center point with a radius which is the maximum value between the length, width and depth.
Send instant messages to your online friends
http://uk.messenger.yahoo.com
Send instant messages to your online friends http://uk.messenger.yahoo.com