I have a QApplication on TX2 that renders on HDMI.
X11 is completely disabled and not present in system.
I use KMS/DRM as plaform for rendering, hence my startup configuration is:
QT_QPA_EGLFS_LAYER_INDEX = 0
QT_QPA_EGLFS_KMS_PLANE_INDEX = 1
QT_QPA_EGLFS_KMS_CONNECTOR_INDEX = 0
QT_QPA_PLATFORM = eglfs
QT_QPA_EGLFS_INTEGRATION = eglfs_kms_egldevice
QT_QPA_EGLFS_KMS_ATOMIC = 1
QT_QPA_EGLFS_ALWAYS_SET_MODE = 1
If I have HDMI monitor plugged everything works fine.
I need to take care of monitor plug/unplug and hence screen availability, else qt app crashes.
I am using therefore QT screen interface https://doc.qt.io/qt-5/qguiapplication.html
- method QGuiApplication::screens()
This method does not change result during runtime.
If I create application and then call method it always returns initial value, also if monitor plugged/unplugged
None of the above signals get fired if I plug/unplug monitor.
I couldn’t find any issues in https://doc.qt.io/qt-5/embedded-linux.html
So my question is, is the screen add/remove/list changes NOT supported on TX2 EGLFS with the eglfs_kms DRM Backend?
Any other ways to check monitor plugged/unplugged?