PDA

View Full Version : Multisampling with SWT java binding (LWJGL)



Michael Imhof
04-11-2006, 09:36 AM
Does somebody has experience with the lwjgl java binding for SWT.
I try to enable multisampling but it's not working.

GLData glData = new GLData();
glData.doubleBuffer = true;
glData.sampleBuffers = 8;
glData.alphaSize = 16;
glData.depthSize = 1;
glData.stencilSize = 0;
glData.samples = 4;
final GLCanvas glCanvas = new GLCanvas(shell, SWT.NO_BACKGROUND, glData);
glCanvas.setCurrent();

GLContext.loadOpenGLLibrary();

glCanvas.addPaintListener(new PaintListener() {
public void paintControl(PaintEvent e) {
glCanvas.setCurrent();
GLContext.useContext(glCanvas);
// Initializing OpenGL
// Drawing oval to test antialiasing
glCanvas
}
}Michael

mikael_aronsson
04-15-2006, 07:29 AM
I suggest you post this message on the LWJGL forum instead as the problem is related to the binding not to OpenGL itself.

Mikael