I have tackled and conquered this problem however not with a camera's view
point but the viewers.
I have extensively rewritten the mouse and picking behaviors to satisfy my
problems but you would only have to do the mouse.
I had plan to post my behaviors on the web and I will try to do it this
weekend.
The key for what I did was to pass a TransformGroup to the behaviors that
had the view platforms transform in it. In your case you would need to
pass in the camera's transform.
I didn't use he LookAt method or Euler angles, it is all matrix math.
You do have some of the algorithm right in that you need to do a translate,
a matrix multiplication and then the translate. I don't remember the
specifics.
I can't do this at work now so I will get that stuff on the web this weekend.
Nag me if I don't.
At 09:08 AM 09/22/2000 -0400, you wrote:
>In my project the user "orbits" around the object in the scene, always
>looking at the object.
>What doesn't work? I'm guessing that your object goes out of view. That's
>probably because you're only translating, not rotating to keep the z-axis
>pointing directly away from the object you want to see. To do that uses a
>little trig, or you can use the LookAt method.
>
>Daniel
>
>-----Original Message-----
>From: Hans RAKOTOMANGA [mailto:[EMAIL PROTECTED]]
>Sent: Friday, September 22, 2000 6:28 AM
>To: [EMAIL PROTECTED]
>Subject: [JAVA3D] View Rotation
>
>
>Hi all, i am trying to create a HomeWorld style visualization, ie : Rotation
>of the camera around selected objects controlled via the mouse.
>So i modified the mouse rotate behavior, attached it to the viewingplatform
>of a simpleUniverse.
>
>In the behavior, i set translation to Origin, then perform an Euler
>transform upon the viewingplatform's transform
>and then translate back.
>
>This doesnt work however and i would like some feedback. ( i hope it isn't a
>view_attach_policy or anything of the sort, otherwise i am
>gonna shoot myself)
>
>Thanks alot.
>
>Hans
>
>===========================================================================
>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".
***********************************************************************
Eric Reiss - http://www.sigda.acm.org/Eric/
Email: [EMAIL PROTECTED]
SIGDA Internet Server Manager - http://www.sigda.acm.org/
Assistant Systems Manager - School of Engineering
University of Pittsburgh
***********************************************************************
===========================================================================
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".