mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-26 21:00:21 +00:00
examples/qt_opengl: Use fbo of the widget and not the thread context
Sometimes QOpenGLWidget may be redirecting it's output to a framebuffer object rather than the frontbuffer, in which case the current thread's context render fbo is different from the widget's. Use the widget's desired fbo instead.
This commit is contained in:
@@ -80,7 +80,7 @@ void MpvWidget::initializeGL()
|
||||
|
||||
void MpvWidget::paintGL()
|
||||
{
|
||||
mpv_opengl_cb_draw(mpv_gl, QOpenGLContext::currentContext()->defaultFramebufferObject(), width(), -height());
|
||||
mpv_opengl_cb_draw(mpv_gl, defaultFramebufferObject(), width(), -height());
|
||||
}
|
||||
|
||||
void MpvWidget::swapped()
|
||||
|
||||
Reference in New Issue
Block a user