It didn't do what I expected....

I draw a polyhedron centered at (0,0,0) so that some of the
polyhderon's edges are in the -z region.

I use LineArray to define the edges.

I want to clip everything that is in the -z region.

So I set the back clipping distance by (thanks Barry)(SU = SimpleUniverse)

   SU.getViewer().getView().setBackClipDistance(5.0f);

   vpTrans = SU.getViewingPlatform().getViewPlatformTransform();
   translate.set(0.0f, 0.0f, 5.0f);
   T3D.setTranslation(translate);
   vpTrans.setTransform(T3D);

When the polyhedron is displayed, it still has its -z edges displayed.
I thought by setting the back clipping distance to be the same as the
ViewingPlatform z-location that lines intersection the z=0 plane would
be cut at z=0 and lines totally beyond z=0 ( -z region) would be erased.

Any thoughts on what I am doing wrong?

Bob Gray




-----Original Message-----
From: Barry Walsh [mailto:[EMAIL PROTECTED]]
Sent: Monday, August 23, 1999 9:26 AM
To: [EMAIL PROTECTED]
Subject: Re: [JAVA3D] SimpleUniverse View


Bob,

   Use this to set the backClipDistance.

  SU.getViewer().getView().setBackClipDistance(float distance);

-----Original Message-----
From:   Bob Gray [SMTP:[EMAIL PROTECTED]]
Sent:   Monday, August 23, 1999 10:43 AM
To:     [EMAIL PROTECTED]
Subject:        [JAVA3D] SimpleUniverse View

I am using a SimpleUniverse and I want to set a back clipping distance.

I thought I would have to first get a View from the SimpleUniverse and then
use the View's methods to set the back clipping distance.

But I can't figure out how to get the View object that the SimpleUniverse
uses.

I can get the ViewPlatform with SU.getViewingPlatform() but I can't figure
out how to get the View object.

Is there any documentation on SimpleUniverse?  The Java 3D API specification
does not list SimpleUniverse.

Where is the documentation for com.sun.j3d.utils.universe.*?

Bob Gray

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to