hi.Greetz Martin
(B
(BI try it as you said.
(B
(B GraphicsConfiguration config = SimpleUniverse.getPreferredConfiguration();
(B // Construct the 3D applet canvas
(B canvas = new Canvas3D(config,true);
(B canvas.setVisible(false);
(B // create a buffered Image
(B BufferedImage bi=new
(BBufferedImage(xOffset*10,yOffset*10,BufferedImage.TYPE_INT_ARGB);
(B // add the bufferedImage to ImageComponent2D used by Canvas3D
(B ImageComponent2D buffer=new
(BImageComponent2D(ImageComponent2D.FORMAT_RGBA,bi);
(B // set off screen buffer
(B canvas.setOffScreenBuffer(buffer);
(B // off screen randering
(B * canvas.renderOffScreenBuffer();
(B canvas.waitForOffScreenRendering();
(B // get the image
(B BufferedImage bi=canvas.getOffScreenBuffer().getImage();
(B // Set up the picture label and put it in a scroll pane
(B ImageIcon imageIcon = new ImageIcon(bi);
(B JLabel picture = new JLabel(imageIcon);
(B add(picture,BorderLayout.CENTER);
(B
(Bbut it has error at *
(B
(Bjava.lang.IllegalStateException : Canvas3D : The width of the associated
(BScreen3D's size is <= 0
(B at javax.media.j3d.Canvas3D.renderOffScreenBuffer(Canvas3D.java:1853)
(B at com.tose.JXViewer.LWVieArea.run(LWViewArea.java:47)
(B at java.lang.Thread.run(Unknown Source)
(B
(Bhas anothers to set before rander?
(B
(B###########################################
(BCheng Huang
(B
(BE-Mail : [EMAIL PROTECTED]
(B###########################################
(B
(B===========================================================================
(BTo unsubscribe, send email to [EMAIL PROTECTED] and include in the body
(Bof the message "signoff JAVA3D-INTEREST". For general help, send email to
([EMAIL PROTECTED] and include in the body of the message "help".