Hello again,

        The solution came to me after I sent this note.  I ditched the extended
MouseRotate Class and called a method in the main from the body of
PickRotateBehavior and passed the TransformGroup rather than the
Transfrom3D.  With this, I was able to  use == in an if...then statement to
find a matching SceneObject instance.

Sean

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of Sean J.
> Miller
> Sent: Thursday, January 28, 1999 8:49 PM
> To: [EMAIL PROTECTED]
> Subject: [java3d] Identifying Picked Transform?
>
>
> Hello,
>
>       I am writing a 3D paint program for a specific type of
> drawing (pipes,
> valves, & stuff).  This is the gist of how I'm handling the elements:
>
> -     a class called SceneObject holds the transform group name
> of the created
> object.
> -     an instance of SceneObject will create shape of the users
> choice (pipe,
> valve, etc.)
> -     All the elements (pipes, valves, etc.) are stored in an area of
> SceneObjects.
> -     I use Pick behaviors to grab on to individual transform
> groups (pipes,
> valves, etc.) to spin them around.
>
>
> My desire is:
>       Once a transform group is picked, I want to let the main
> program know what
> SceneObject instance the transform belonged to.
>
> What I've done:
> -     I made an extended class to MouseRotate called MyMouseRotate.
> -     I revamped the pick behaviors to use MyMouseRotate instead
> of MouseRotate.
> -     I overridded the method "transformChanged" in MyMouseRotate
> to send back
> to the main program the Transform3D that was  manipulated in the pick.
>
> My question is:
>
>       How do you compare a Transform3D to another?  Simply using
> == doesn't get
> it - nor does using toString() on the two Transform3Ds compared.  If I can
> find a way to compare, then I can just use a for loop to cycle through my
> SceneObject array until it finds a hit.  Any other suggests?
>
> Thanks,
> Sean
>
>
> =====================================================================
> To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
> Java 3D Home Page: http://java.sun.com/products/java-media/3D/
>

=====================================================================
To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
Java 3D Home Page: http://java.sun.com/products/java-media/3D/

Reply via email to