This question is very easy for formulate. I capture an
image to the off-screen buffer (code at the bottom).
It works on my Linux machine and my Win95 machine.
However, on my NT4.0 box (which is where I *need* it
to work) it doesn't work and instead gives me a black
square. The error that I sort of get is
wglCreateContext Failed: The pixel format is invalid.
extensionStr == null
It doesn't get spit out until I quit my program (I
guess it gets buffered until then)) so I can't quite
pinpoint the location. My code follows...
Thanks for the help!
public BufferedImage pTakeAPicture(int inWidth, int
inHeight) {
BufferedImage bImage = new BufferedImage(inWidth,
inHeight, BufferedImage.TYPE_INT_RGB);
ImageComponent2D buffer = new
ImageComponent2D(ImageComponent2D.FORMAT_RGB, bImage);
myOffScreenCanvas.getScreen3D().setSize(inWidth,
inHeight);
myOffScreenCanvas.setOffScreenBuffer(buffer);
myOffScreenCanvas.getScreen3D().setPhysicalScreenHeight(5.0);
myOffScreenCanvas.getScreen3D().setPhysicalScreenWidth(5.0);
myOffScreenCanvas.renderOffScreenBuffer();
myOffScreenCanvas.waitForOffScreenRendering();
bImage =
myOffScreenCanvas.getOffScreenBuffer().getImage();
return bImage;
}
__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.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".