mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-04 00:30:59 -05:00
Set up an OpenGL Context to be shared between threads beforehand
Allows for plugins that depend on Qt WebEngine module.
This commit is contained in:
parent
9cdf76a9a2
commit
249c75b993
@ -884,6 +884,15 @@ int main( int argc, char *argv[] )
|
||||
QCoreApplication::setAttribute( Qt::AA_DisableWindowContextHelpButton, true );
|
||||
#endif
|
||||
|
||||
// Set up an OpenGL Context to be shared between threads beforehand
|
||||
// for plugins that depend on Qt WebEngine module.
|
||||
// As suggested by Qt documentation at:
|
||||
// - https://doc.qt.io/qt-5/qtwebengine.html
|
||||
// - https://code.qt.io/cgit/qt/qtwebengine.git/plain/src/webenginewidgets/api/qtwebenginewidgetsglobal.cpp
|
||||
#if defined(QT_OS_WIN) && !defined(QT_NO_OPENGL) && (QT_VERSION >= QT_VERSION_CHECK(5, 4, 0) )
|
||||
QCoreApplication::setAttribute( Qt::AA_ShareOpenGLContexts, true );
|
||||
#endif
|
||||
|
||||
// Set up the QgsSettings Global Settings:
|
||||
// - use the path specified with --globalsettingsfile path,
|
||||
// - use the environment if not found
|
||||
|
Loading…
x
Reference in New Issue
Block a user