by =?iso-8859-1?q?In=E1cio_Ferrarini?= <inacio.ferrarini@[EMAIL PROTECTED]
>
Apr 20, 2007 at 03:29 AM
Hi there.
I=B4ve never added a JFrame inside another.
Try changing program3d to a JPanel or a Canvas and then try to add it
to a JFrame.
See you,
- In=E1cio Ferrarini.
On Apr 19, 12:30 pm, Misterysw...@[EMAIL PROTECTED]
wrote:
> Hi all!! I have got a JAVA3D application that I show it in a JFrame.
> So, everything is correct.
>
> --->This schem is correct:
>
> class program3D extends JFrame{
>
> public program3D(){ }
>
> public BranchGroup createSceneGraph(){ }
>
> public static void main ( String arg[] )
> {
> new program3D();
>
> }
> }
>
> _______________________________________________________________________
> The problem is when I want to draw the scene inside of JPanel, and
> then, this JPanel put inside of JFrame.
>
> --->THE PROBLEM:The scene is not seen !!!
>
> class program3D extends JPanel{
>
> public program3D(){ }
>
> public BranchGroup createSceneGraph(){ }
>
> public static void main ( String arg[] )
> {
> JFrame window=3Dnew JFrame("Main");
> window.setLayout( new BorderLayout() );
> window.getContentPane().add( new program3D(),
> BorderLayout.CENTER); //PROBLEM
>
> window.setSize(500,500);
> window.setVisible(true);
>
> }
> }
>
> Regards!