Can anyone explain Qt OpenGL support on Raspberry Pi in simple English please?
I finally got a Raspi and am starting to try compiling my app for it. It's a very intriguing bit of kit - worth the wait.
I don't yet have a good net connection so I just installed Debian Wheezy and Qt4.8.2 to keep me going (this seemed the best starting point just to get something compiling and to resolve any platform specific issues with my app). My app uses a QGLWidget and GLSL for OpenGL 3.3 or OpenGL ES2.0 depending on whether it's been built for Desktop or mobile devices. The QGLWidget is within a QMainWindow. It runs on Linux desktop, N9 and N900 mobile phones. The code is fairly stable and I have directives compiler directives for switching between OGL versions - so I was hoping it would work without much fuss on the Pi.
I can get my C++/Qt app to compile and run but the 3D part does not work - it returns:
@QGLTempContext: No GL capable X visuals available.@
Thanks to QtonPi mailing list (QtonPi@qt-project.org) / Carsten Munk I now understand this is because Raspi does not support X11 and only supports OGL in fullscreen windows at the moment.
bq. You're better off going straight to Qt5. Long story short the 3d
drivers in the Raspberry Pi does not support X11 windows and only
fullscreen windows. On top of that, Qt4.8.2 in traditional
distributions is not built for GLESv2/EGL and instead is for GL which
is a problem on ARM distributions.
Qt5 has a '-platform eglfs' plugin you would be able to utilize for
My questions are:
Can anyone point me to an easy to understand explanation of the situation with OpenGLES2.0 / Wayland / Qt5 on the Raspberry Pi please? I don't understand all the implications of the explanation here (http://qt-project.org/wiki/RaspberryPi)
Should I wait for Qt5 with Wayland support to be available for Debian Wheezy? (as this has a window manager) Any ideas how long this will be?
Thanks for your help,
Qt 5 is already available, and has Wayland support built-in. If you want to wait for the official version to hit Debian repos... I would estimate you will have to wait about a year.
Interesting that nobody gave a particularly helpful answer to this, and its more than 18 months since the post, and still Qt isn't available in the offical repo (unless I'm missing something). I'm trying to wade through the terminology of Qt5 / Wayland / openGL etc etc and I'd be interested to know if there is a simple explanation anywhere. There is plenty of information out there, but its hard to know what is out of date and what isn't.
This is the closest I've come to an answer (spoiler: it isn't - for me at least)
To be honest I've given up for the time being - it just consumes too much time trying to fathom out who knows what and whether there's any mileage in the half finished methods already out there for what I want to do.
My understanding is that to run an Qt5 Widget based window with OpenGL ES2 graphics contained within it, on the Wayland desktop, needs the Pi Foundation and/or Collabora to finish writing their Weston/Wayland drivers and then for others to make the standard desktop apps work under this environment. (This last part is necessary to debug the drivers and the build process).
My guess (based on nothing more than the wait so far) is another 2+ years before you can take a Qt Widget OGL2ES project, a standard raspbian install and run 'qmake; make'.
I don't mean to sound bitter about this - it's great that the Pi Foundation are onto this in some form!