Reputation: 10097
I have built a Qt application in C++ that utilizes OpenCV and runs on a Raspberry Pi. For some reason I cannot get this application to run directly on the Raspberry Pi's display.
The application runs fine if I send the display to a remote xserver, but if I try and run it and display it on the xserver running on the Pi I get the following errors:
libEGL warning: DRI2: failed to authenticate
qt5ct: using qt5ct plugin
** (LCVTrial_CppOpenCV:1914): WARNING **: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files
(LCVTrial_CppOpenCV:1914): GLib-GObject-WARNING **: cannot register existing type 'GtkWidget'
(LCVTrial_CppOpenCV:1914): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion 'G_TYPE_IS_INSTANTIATABLE (instance_type)' failed
(LCVTrial_CppOpenCV:1914): GLib-GObject-WARNING **: cannot register existing type 'GtkBuildable'
(LCVTrial_CppOpenCV:1914): GLib-GObject-CRITICAL **: g_type_interface_add_prerequisite: assertion 'G_TYPE_IS_INTERFACE (interface_type)' failed
(LCVTrial_CppOpenCV:1914): GLib-CRITICAL **: g_once_init_leave: assertion 'result != 0' failed
(LCVTrial_CppOpenCV:1914): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion 'G_TYPE_IS_INSTANTIATABLE (instance_type)' failed
(LCVTrial_CppOpenCV:1914): GLib-GObject-CRITICAL **: g_type_register_static: assertion 'parent_type > 0' failed
No errors are shown when running to a remote display.
I made a "stripped down" version of the application with only the GUI, removing OpenCV, and it runs fine on the Pi's display.
Any ideas or direction on where to look / investigate would be appreciated!
Upvotes: 0
Views: 838
Reputation: 85
there are some missing libs on Raspi try on raspi terminal
sudo apt-get install at-spi2-core
in /etc/environment add
QT_QPA_PLATFORMTHEME=gtk2
and do not forget update gstreamer
Hope it helps
Upvotes: 1