Hi all,
Im having some trouble with the accumulation buffer, heres my routine:
Code:
GL11.glDisable(GL11.GL_DITHER);
GL11.glEnable(GL11.GL_SCISSOR_TEST);
GL11.glScissor(0, 0, width, height);
GL11.glClear(GL11.GL_COLOR_BUFFER_BIT | GL11.GL_DEPTH_BUFFER_BIT);
GL11.glDisable(GL11.GL_SCISSOR_TEST);
GL11.glEnable(GL11.GL_DITHER);
GL11.glClear(GL11.GL_ACCUM_BUFFER_BIT);
for (int i = 0; i < 16; i++) {
GL11.glBegin(GL11.GL_QUADS);
GL11.glVertex3f(0 + (i/5), 0 + (i/5), 0);
GL11.glVertex3f(0 + (i/5), 1 + (i/5), 0);
GL11.glVertex3f(1 + (i/5), 1 + (i/5), 0);
GL11.glVertex3f(1 + (i/5), 0 + (i/5), 0);
GL11.glEnd();
GL11.glAccum(GL11.GL_ACCUM, 1.0f / 16f);
}
GL11.glAccum(GL11.GL_RETURN, 1.0f);
GL11.glFlush();
Window.update();
and I get this error:
org.lwjgl.opengl.OpenGLException: Invalid operation (1282)
at org.lwjgl.opengl.Util.checkGLError(Unknown Source)
at org.lwjgl.opengl.Window.update(Unknown Source)
…
Im using LWJGL 0.9.
Any ideas?
