Re: FBO with GLCanvas
Posted by Bob on Dec 04, 2019; 5:41pm
URL: https://forum.jogamp.org/FBO-with-GLCanvas-tp4040147p4040168.html
Hello,
Yes, there is no problem with getDefaultReadBuffer() which returns the correct default read buffer of the drawable (GL_BACK or GL_FRONT for GLDrawableImpl, GL_COLOR_ATTACHMENTi for GLFBODrawableImpl).
Sorry if I was not clear.
There is an error in my case because I bind an FBO in my GLCanvas to draw offscreen for one display.
So I have a GLCanvas containing the default WindowsOnscreenWGLDrawable but with an FBO as read and write buffer.
That is why glReadBuffer(getDefaultReadBuffer=GL_BACK) ends in error.
Is it possible to bind an FBO with glBindFramebuffer when the drawable is not a GLFBODrawable ?
Should I use another drawable (GLFBODrawable) ?
Maybe AWTGLReadBufferUtil/GLReadBufferUtil cannot be used when the current read buffer is different from the default read buffer ?
Beside that, I saw that the 2.4.0 release was almost here.
Congratulations and thanks for this good work.