当前位置:网站首页>Dealing with the crash of QT quick project in offscreen mode

Dealing with the crash of QT quick project in offscreen mode

2022-07-06 22:26:00 Hua Weiyun

Based on squish build qt I encountered a problem in the smoking project , When the test project is cut into off screen mode , contain qml Function page crash ;


The error stack is as follows :
```
(QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>))) [0x7fc925b3fa2b]
libqoffscreen.so(+0x14580) [0x7fc91a804580]
```

The solution is to set qml Soft rendering :

export QT_QPA_PLATFORM='offscreen'
export QMLSCENE_DEVICE='softwarecontext'

Reference resources :
https://stackoverflow.com/questions/52527672/crash-when-running-qt-application-on-ubuntu-server
https://stackoverflow.com/questions/33090346/is-there-any-way-to-use-qtwebengine-without-opengl

原网站

版权声明
本文为[Hua Weiyun]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/187/202207061428578370.html