From 1127cf8b849106dee61781269aa1fd907327f6a8 Mon Sep 17 00:00:00 2001 From: Vicki Pfau Date: Mon, 12 Dec 2022 03:12:06 -0800 Subject: [PATCH] Qt: Fix proxy context creation on Nvidia (fixes #2746) --- src/platform/qt/DisplayGL.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/platform/qt/DisplayGL.cpp b/src/platform/qt/DisplayGL.cpp index b8c0f8cd9..9f5729a67 100644 --- a/src/platform/qt/DisplayGL.cpp +++ b/src/platform/qt/DisplayGL.cpp @@ -425,10 +425,10 @@ void DisplayGL::setVideoProxy(std::shared_ptr proxy) { void DisplayGL::setupProxyThread() { m_proxyContext->moveToThread(&m_proxyThread); + m_proxySurface.create(); connect(&m_proxyThread, &QThread::started, m_proxyContext.get(), [this]() { m_proxyContext->setShareContext(m_painter->shareContext()); m_proxyContext->create(); - m_proxySurface.create(); m_proxyContext->makeCurrent(&m_proxySurface); #if defined(_WIN32) && defined(USE_EPOXY) epoxy_handle_external_wglMakeCurrent(); @@ -576,6 +576,7 @@ void PainterGL::create() { m_backend->filter = false; m_backend->lockAspectRatio = false; m_backend->interframeBlending = false; + m_gl->doneCurrent(); emit created(); }