Hi Arvi,
I think the easiest thing to do is that you create your scenegraph in a way
that you can add and remove the mousebehaviors which take affect on the whole
scene. So add an TransformGroup to the TransformGroup where the mousebehavior
are now attached to, and move these mousebehaviors to that new TransformGroup.
Now when you want to use the mousebehavior which only take affect on one object
you generate an event which removes the TransformGroup with the behavior which
take affect on the whole scene.
I hope it works. Succes,
Arvi Chahal wrote:
> Hi,
>
> I'm working on a program, where i have vrml models loaded into the
> canvas3D.
>
> For example say i have a table. Now i have mouse behaviors(rotate, zoom,
> translate) that can take effect on the whole scene ie. all the table will
> rotate, or be translated. But also i have picking mouse behaviors on each
> object that makes up the model, ie. each leg of the table can be rotated,
> translated, zoomed individually.
>
> My problem is both behaviors are clashing. As i rotate 1 table leg, then
> that rotates but so does the whole model. How can i turn off one behavior
> when i want the other. ie. how can i switch off rotation of the whole table
> scene when i only want to rotate 1 leg of the table?
>
> Any help will be appreciated. Thanks.
>
> Arvi.
>
> ************************************************
> Arvi Chahal
> [EMAIL PROTECTED]
> ************************************************
>
> =====================================================================
> To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
> Java 3D Home Page: http://java.sun.com/products/java-media/3D/
--
----------------------------------------------------
ing. Patrick Janssen
3i Communication
Intelligent Interactive Internet Communication
http://www.3icommunication.com/
tel: 040-2960040, fax: 040-2960041
----------------------------------------------------
=====================================================================
To subscribe/unsubscribe, send mail to [EMAIL PROTECTED]
Java 3D Home Page: http://java.sun.com/products/java-media/3D/