good news, i’ve found a way to rendering a correct fbo to the quad in the scene.

it was dependend of the order of the painter->beginNativePainting(); line. i switch the order, that the painter->beginNativePainting(); is before the QGLContext and QGLFramebufferobject is init.

the message is still active but the result is correct.

source
Qt Code:
  1. painter->beginNativePainting();
  2.  
  3. // ------------ FBO begin ------------
  4.  
  5. context = new QGLContext(QGLFormat(QGL::SampleBuffers | QGL::DoubleBuffer | QGL::AlphaChannel), widget);
  6. context->create(); // !!!
  7. context->makeCurrent();
  8.  
  9. fbo = new QGLFramebufferObject(512, 512); // GLWidget::GLWidget (constructor)
  10.  
  11. fbo->bind();
  12. {
  13. ...
  14. }
  15. fbo->release();
To copy to clipboard, switch view to plain text mode