I have done it as follows
TransformGroup vpTrans =
m_universe.getViewingPlatform().getViewPlatformTransform();
Transform3D T3D = new Transform3D();
T3D.setTranslation( new Vector3f(0.0f, 0.5f, 0.0f) );
vpTrans.setTransform(T3D);
also I have written my own mouse behavior which I set as follows
WalkBehavior mouse = new WalkBehavior(vpTrans);
mouse.setSchedulingBounds(m_bounds);
objRoot.addChild( mouse );
Ahmed
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>Original Message<<<<<<<<<<<<<<<<<<
From: Sterling Wright [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 22, 2000 8:36 PM
To: [EMAIL PROTECTED]
Subject: [JAVA3D] Rotation about a target
Hello all,
I am new to Java and graphic programming, and am trying to rotate the
ViewPlatform around a lookat point. I have the correct Matrix4d setup for
rotation about the X, Y and Z axis but don't know how to use it in Java3D?
The steps I take are:
1) Construct the Matrix4d and initialize it
2) Set the Matrix4d in the Transform3D
3) Set the Transform3D in the TransformGroup above the ViewPlatform
4) Run program
My ViewPlatform translates to the point but doesn't rotate to my lookat
point(which is the origin (0,0,0)).
I want to use this as a helper method to enter a lookat point and a camera
position and have the ViewPlatform rotate to my camera target.
Any help, or source will be appreciated
Sterling Wright
______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com
===========================================================================
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".