Hi all,
I am getting the buffer swap error that the JOGL Animator class references in it’s source. If I use the JOGL Animator, all is well. The problem is I am making my own Animator type class, the game loop, that makes the similar calls. However, I can not make the exact same calls because one call made in the Animator contructor is internal to JOGL (not public) and so any call outside of that name space can not call it.
From Animator:
/** Creates a new Animator for a particular drawable. */
public Animator(GLDrawable drawable) {
this.drawable = drawable;
// Workaround for NVidia driver bug 80174
if (drawable instanceof GLCanvas) {
((GLCanvas) drawable).willSetRenderingThread();
}
}
The error is:
net.java.games.jogl.GLException: Error swapping buffers
at net.java.games.jogl.impl.windows.WindowsOnscreenGLContext.swapBuffers(WindowsOnscreenGLContext.java:140)
at net.java.games.jogl.impl.GLContext.invokeGL(GLContext.java:193)
at net.java.games.jogl.GLCanvas.displayImpl(GLCanvas.java:182)
at net.java.games.jogl.GLCanvas.display(GLCanvas.java:82)
at com.imi.jist3d.BasicRenderer.render(BasicRenderer.java:243)
at com.imi.jist3d.Animator$1.run(BasicViewer.java:895)
at java.lang.Thread.run(Thread.java:534)
I thought I remembered others dealing with this but forum search did not turn up this error. ( or my search was lousey :-))
Does anyone know a work around for this? Pretty much I can’t really run my app because this blows-up almost anytime the window is resized, or the canvas adjusted, which happens whenever I load a model since I am showing the scene graph tree in an adjacent panel.
Thanks!