Unless you've moved your camera, your cube and camera are probably at the
same location (the origin).  Try moving the camera back a bit.

    TransformGroup vtg =
simpleUniverse.getViewingPlatform().getViewPlatformTransform();
    Transform3D backup = new Transform3D();
    backup.setTranslation(new Vector3f(0.0f, 0.0f, 10.0f));
    vtg.setTransform(backup);


----- Original Message -----
From: "F�bio Magalh�es" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, March 06, 2002 7:26 PM
Subject: [JAVA3D] load .obj file , why not ?


> is This code correct ? Because, in my pc the app with
> it , don't show the cube file. Anyone know why ?
>
> Thanks, Fabio.
>
>
>
> private BranchGroup constructContentBranch()
>   {
> ObjectFile myOBJ = new ObjectFile();
>      Scene myOBJScene = null;
>
>      //Attempt to load in the OBJ content using
> ObjectFile.
>      try {
>          myOBJScene = myOBJ.load(".\\cube.obj");
>          }
>      catch (Exception e)
>         {
>         System.out.println("Could not open OBJ
> file...exiting");
>         //System.exit(1);
>         }
>
>      //Construct and return branch group containing
> our OBJ scene.
>      BranchGroup contentBranchGroup = new
> BranchGroup();
>
> contentBranchGroup.addChild(myOBJScene.getSceneGroup());
>      return(contentBranchGroup);
>
>
>   }
>
>
____________________________________________________________________________
___________________
> Yahoo! Empregos
> O trabalho dos seus sonhos pode estar aqui. Cadastre-se hoje mesmo no
Yahoo! Empregos e tenha acesso a milhares de vagas abertas!
> http://br.empregos.yahoo.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".

Reply via email to