Ashish,

   I have written a PickScreenObject class that allows you to pick Shape3D
object(s)
off the screen , and put them in an array. It is implemented as a Behavior.

.Right now it allows you to select any Shape3D NODE  by clicking on it on the
screen.

But how to receive/use that Shape3D node in your main program is not done (I
guess
it is your job). One way could be to extend PickScreenObject to implement
PickingCallback and then retrieve the geometry inside your callback class's
method (for drawing lines between them etc).

I have included a sample program which uses this behavior also.(ColorTest.java)

Hope this will help you in figuring out your problem.

Regards,
Anand

(See attached file: PickScreenObject.java)(See attached file: ColorTest.java)
Anand Pillai
DELMIA Solutions India.
Bangalore 560 078.
[EMAIL PROTECTED]







Ashish Aggarwal <[EMAIL PROTECTED]> on 06/27/2001 02:34:26 AM

Please respond to Discussion list for Java 3D API <[EMAIL PROTECTED]>

To:   [EMAIL PROTECTED]
cc:    (bcc: Anand PILLAI/dassault-systemes)
Subject:  Re: [JAVA3D]



Hello Anand!

Thanks very much for your continuing help and because
of it I have understood lot of things. But there is a
problem with the program.  Shape3D myShape is null and
hence the if loop which states that:

if    ( myShape != null ) is not executed.

I am getting the message "scenegraph path is null",
which you will get if myshape is null.

Please inform me why myshape is null.  I am attaching
the program with this mail for your reference. Please
run the program and try to draw a line between two
solids, you will get messages in console window. I
hope you won't have to waste too much time over it.

Thanks for your continuing supoport.

Ashish



__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

SimpleLine.java

PickScreenObject.java

ColorTest.java

Reply via email to