Unsolved EGL Error : Could not create the egl surface: error = 0x3003
-
Hello!
I build qt-5.6.1 from qtbase-opensource-src-5.6.1-1.tar.xz for ARM CPU.
Unfortunately example application not work and exit with follow message:./analogclock Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). EGL Error : Could not create the egl surface: error = 0x3003 Aborted
Qt builded with follow parameters:
Configure summary Building on: linux-g++ (x86_64, CPU features: mmx sse sse2) Building for: devices/linux-arm-hisilicon-hi3798mv100 (arm, CPU features: neon) Platform notes: - Also available for Linux: linux-clang linux-kcc linux-icc linux-cx x qmake vars .......... styles += mac fusion windows DEFINES += QT_NO_LIBUDEV DEFI NES += QT_NO_TSLIB DEFINES += QT_NO_LIBINPUT QMAKE_X11_PREFIX = /usr QMAKE_CFLAG S_DIRECTFB = -D_REENTRANT -I/hisilicon/usr/include/directfb QMAKE_LIBS_DIRECTFB = -ldirectfb -lpthread -lvoodoo -lfusion -ldirect -lpthread EXTRA_INCLUDEPATH += "/hisilicon/usr/include/" "/hisilicon/usr/include/freetype2" EXTRA_LIBS += -L"/hisilicon/usr/lib/" sql-drivers = sql-plugins = sqlite qmake switches .... ..... Build options: Configuration .......... accessibility alsa audio-backend c++11 clock-gettime clock-monotonic compile_examples concurrent cross_compile directfb egl eglfs egl fs_mali enable_new_dtags evdev eventfd force_debug_info full-config getaddrinfo getifaddrs harfbuzz inotify ipv6ifname large-config largefile linuxfb medium-con fig minimal-config mremap mtdev neon no-qml-debug opengl opengles2 openssl png p osix_fallocate qpa qpa reduce_exports release rpath separate_debug_info shared s mall-config system-freetype system-jpeg system-png system-zlib threadsafe-cloexe c Build parts ............ libs examples Mode ................... release (with debug info) Using sanitizer(s)...... none Using C++ standard ..... c++11 Using gold linker....... no Using new DTAGS ........ yes Using PCH .............. no Using LTCG ............. no Target compiler supports: Neon ................. yes Qt modules and options: Qt D-Bus ............... no Qt Concurrent .......... yes Qt GUI ................. yes Qt Widgets ............. yes Large File ............. yes QML debugging .......... no Use system proxies ..... no Support enabled for: Accessibility .......... yes ALSA ................... yes CUPS ................... no Evdev .................. yes FontConfig ............. no FreeType ............... yes (system library) Glib ................... no GStreamer .............. no GTK theme .............. no HarfBuzz ............... yes (bundled copy) Iconv .................. no ICU .................... no Image formats: GIF .................. yes (plugin, using bundled copy) JPEG ................. yes (plugin, using system library) PNG .................. yes (in QtGui, using system library) libinput................ no Logging backends: journald ............... no syslog ............... no mtdev .................. yes (system library) Networking: getaddrinfo .......... yes getifaddrs ........... yes IPv6 ifname .......... yes libproxy.............. no OpenSSL .............. yes (loading libraries at run-time) NIS .................... no OpenGL / OpenVG: EGL .................. yes OpenGL ............... yes (OpenGL ES 2.0+) OpenVG ............... no PCRE ................... system pkg-config ............. yes PulseAudio ............. no QPA backends: DirectFB ............. yes EGLFS ................ yes EGLFS i.MX6 ........ no EGLFS i.MX6 Wayland. no EGLFS EGLDevice .... no EGLFS GBM .......... no EGLFS Mali ......... yes EGLFS Raspberry Pi . no EGLFS X11 .......... no LinuxFB .............. yes Mir client............ no XCB .................. no Session management ..... yes SQL drivers: DB2 .................. no InterBase ............ no MySQL ................ no OCI .................. no ODBC ................. no PostgreSQL ........... no SQLite 2 ............. no SQLite ............... yes (plugin, using bundled copy) TDS .................. no tslib .................. no udev ................... no xkbcommon-x11........... no xkbcommon-evdev......... no zlib ................... yes (system library) NOTE: Qt is using double for qreal on this system. This is binary incompatible a gainst Qt 5.1. Configure with '-qreal float' to create a build that is binary compatible with 5 .1.
How can I solve this problem and excuse my bad english.
-
@debian hi , have you solved the problem? I basically has the same qt configuration as you do with open GL es 2.0, and I end up with the egl surface error.
/Peilang
-
On an iMX6 board setting the framebuffer to 16 or 32 bpp instead of 24 solved this problem for me.
echo 32 > /sys/class/graphics/fb2/bits_per_pixelYou can also set the framebuffer to be used with: export QT_QPA_EGLFS_FB=/dev/fb2
-
Thanks.. it helped me
-
@RikusW So many thanks for share. It also worked for fb0 on my imx6 solo sabresd board
-
@RikusW Thanks !!! it also worked for my imx6dl
-
Too many time, but ...
I was upgrade Qt to 5.12.6 and have same error, my solution - use double height.# fbset mode "1280x720-0" # D: 0.000 MHz, H: 0.000 kHz, V: 0.000 Hz geometry 1280 720 1280 720 32 timings 4294967295 4294967295 4294967295 4294967295 4294967295 4294967295 4294967295 accel false rgba 8/16,8/8,8/0,8/24 endmode # /usr/sbin/app Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). ............. EGL Error : Could not create the egl surface: error = 0x3003 Terminating application with signal 6 ........... ~ # fbset -g 1280 720 1280 1440 32 ~ # fbset mode "1280x720-0" # D: 0.000 MHz, H: 0.000 kHz, V: 0.000 Hz geometry 1280 720 1280 1440 32 timings 4294967295 4294967295 4294967295 4294967295 4294967295 4294967295 4294967295 accel false rgba 8/16,8/8,8/0,8/24 endmode ~ # /usr/sbin/app Unable to query physical screen size, defaulting to 100 dpi. To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). ............. Attribute Qt::AA_ShareOpenGLContexts must be set before QCoreApplication is created. ...........
-
HTH in some cases:
I've faced the same issue once decreased the reserved memory size for gpu in my raspberry pi zero (from 64 to 32, but in your case it could vary from your board and display).
So I thing the other option to solve 0x3003 is to try increase gpu memory buffer.