[Interest] Getting "Segmentation Fault" if QML application started without monitor attached

Nenad Lazovic nlazovic at entaros.com
Fri Dec 22 17:55:20 CET 2017


My application is console application (no gui), that runs QQmlEngine, plays
qml file, does offscreen rendering (QOffscreenSurface /
QOpenGLFramebufferObject) to capture frames to files (every n'th frame).
Implementation is very similar to
<https://github.com/qtquickvcp/qml-oled-renderer>
https://github.com/qtquickvcp/qml-oled-renderer.

I am facing problem that my app does NOT want to run if monitor is not
attached (although no GUI on app). If monitor is attached, all works ok.

 

Tried running with different QPA platforms, no luck

root at tinkerboard:/home/linaro/qt5build/qt5/tests/appTest4# ./appTest4
-platform offscreen

This plugin does not support createPlatformOpenGLContext!

QQuickRenderControl::initialize called with incorrect current context

Segmentation fault

 

root at tinkerboard:/home/linaro/qt5build/qt5/tests/appTest4# ./appTest4
-platform minimalegl

Opened display 0x7fcc6f60

Could not initialize egl display

EGL error

Aborted

 

root at tinkerboard:/home/linaro/qt5build/qt5/tests/appTest4# ./appTest4
-platform minimal

This plugin does not support createPlatformOpenGLContext!

QQuickRenderControl::initialize called with incorrect current context

Segmentation fault

 

My setup is QT 5.9.3. or 5.10 on Asus Tinkerboard with latest OS (Latest
version v2.0.4 - Debian stretch based. 2017/11/15, Thread:
<https://tinkerboarding.co.uk/forum/thread-839.html>
https://tinkerboarding.co.uk/forum/thread-839.html).


I was hoping that fact that my app is doing offscreeen rendering I would not
need monitor attached.

I am not that much familiar with inner QT workings.

I am looking into any suggestion 

.         Where does dependency on monitor being attached comes from (QPA
plugin selected, QT build, ..., base class used to initialize app ) ?

.         any suggestion what to change to remove dependency on monitor ?

 

 

Thanks in advance for any suggestion.

 

Sincerely,

Nenad Lazovic

 

 



---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20171222/a5d1fa65/attachment.html>


More information about the Interest mailing list