OrbitBehavior() Utility Class Troubles
I am trying to get the OrbitBehavior() class to work within the SimpleUniverse I am creating. The code compiles but it seems as if the either the mouse listeners are not being tied to the canvas, or the events arent being captured...(I am new to Java3d so I m not entirely sure). I looked at the code for the utility classes and the OrbitBehavior() class ties the MouseMotionListener and the MouseListener to the canvas by calling its parent ViewPlatformAWTBehavior(). The Canvas does have focus.If anyone could shed some light on this or tell me if I missing something obvious I would appreciate it. You can post here, talk to me in irc on Starchat in #discordstudios, or email me : ezrael@home.com.
Thanks,
Jeremy "NeoAeZ" Collins
[760 byte] By [
NeoAeZ] at [2007-9-26 5:04:41]

THIS IS WHAT I DID FOR MY CODE
//////////////////////////////////////////////////////////////
simpuniv.getViewingPlatform().setNominalViewingTransform();
ViewingPlatform viewingPlatform = simpuniv.getViewingPlatform();
BoundingSphere infiniteBounds = new BoundingSphere(new Point3d(), Double.MAX_VALUE);
orbit = new OrbitBehavior(canvas3D,112); // 112 =REVERSE_ALL
orbit.setSchedulingBounds(infiniteBounds);
// Define a new rotation point here if needed...or do so
// with in some other place...but make sure to either
// make the 'orbit' variable global or pass it along so
// that it can be changed.
//Point3d cen = new Point3d(0.0, 0.0, 0.0);
//orbit.setRotationCenter(cen);
viewingPlatform.setViewPlatformBehavior(orbit);
simpuniv.addBranchGraph(scene);
//////////////////////////////////////////////////////////////
Mario Zaczek
mzaczek@ems.jsc.nasa.gov
zaczek at 2007-6-29 19:02:56 >
