The simplest thing you can do - btw. I'm doing that in my own program - is to get the bounding sphere from your scene and then encapsulate your scene in a TransformGroup where the Transform only translate the scene with the negated value of the scene center.
Other option will be to set the transform of the ViewingPlatform so that your Viewer will look at the center of the scene. Here some code to play with... Hope it works... BranchGroup objRoot = new BranchGroup(); BranchGroup objects = ... here you get the branch group representing your objects ... BoundingSphere bs = (BoundingSphere)objects.getBounds(); Point3d center = new Point3d(); bs.getCenter(center); Transform3D t3d = new Transform3D(); Point3d displ = (Point3d)center.clone(); displ.negate(); t3d.set(1.0f, new Vector3f(displ)); TransformGroup centeredObjects = new TransformGroup(t3d); objRoot.addChild(centeredObjects); Cheers, Florin -----Ursprüngliche Nachricht----- Von: David Bourgais [mailto:[EMAIL PROTECTED]] Gesendet: Donnerstag, 4. Juli 2002 15:24 An: [EMAIL PROTECTED] Betreff: Re: [JAVA3D] Displaying entire scene [ Was Re: VRML] Hello Thanks a lot for your tips. I tried many methods to center my VRML scenes. Unfortunately, it doesn't works ! Are you much luckier than me for this problem ? If it's the case, could you send me a part of your code which could help me ? Thank you very much. Have a nice day. David Bourgais =========================================================================== 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".