Monday, February 17, 2014

My thoughts about Qt on the i.MX series

I have been tinkering with Qt on the i.MX6/53/51 platforms for some time now. It has been quite an adventure. I started up with a plain QWS on
the i.MX51. I felt that the drawing was much faster than on X11 and I found a old application , Xqt. Xqt is a Xwindows server for running on Qt.
It was designed for Qtopia running on Zaurus and friends. It was written for Qt2 so it needed some porting efforts to be able to run on Qt4.
Xqt was for me a big win. Xwindows actually rendered faster on top on Qt.


On the photo above you can see Gnome running in QWS on a i.MX51 based computer made by Genesi (http://www.genesi-usa.com)
The next step for me was to get GLES working on Qt, My first effort was to create a QWS plugin that rendered all its graphics with
GLES. It also provided a QGlscreen , so the hello_es example worked. The problem with QWS and GLES is that you only can use
GLES in fullscreen mode ,which means that there is no way to add widgets in a normal way. I did not like that fact .
So I did a "hack" to be able to show "hello_es" as it should be displayed:



Some of you participated in a beta test of this. Unfortunately It had some problems and after some testing I decided not to release it.

So all work done that far was on MX51/53. What about MX6?

When I got my hand on a i.MX6 board , Qt4 was on its way out and Qt5 was stepping in. Qt5 comes with EGLFS QPA backend
which makes it easy to display GL content on the framebuffer. The biggest issue I have with Qt5 is the lack of support for widgets
on a embedded display. The only way I could control GL content on a framebuffer display was with QtQuick /Quick3d.

So what's next?

My current plan is to focus on getting widget/c++ back to framebuffer displays. If you have tried to use the LINUXFB backend
in Qt5 you know what I mean. A alternative is to use the DirectFB backend , but it behaves almost as bad. I have customers
using Qt on systems that don't use EGL and for the moment I can't recommend them to use Qt5 , which is very sad.

6 comments:

Unknown said...

Hi,

next week at Embedded World we'll have a nice demo with Qt 5.2, running on MX6 with full OpenGL acceleration. It is a preview about what will happen in the mainline kernel in the near future - we currently have the stack running on linux-3.13.2, still with a lot of patches.

Robert

Michael Grunditz said...

Robert, which platform plugin will you be running on , waylay?

Unknown said...

We currently don't have it running with Wayland and Qt+GL at the same time; either Qt with EGLFS backend, or Wayland without any acceleration.

Robert

Unknown said...

Hey Michael. This might be an inconvenient way and quite a long shot, but here it goes.

I'm working on an electric motorcycle (see www.storm-eindhoven.com), and for our user interface we are using a Hummingboard (iMX6). Plan is to write the interface in Qt. I am however unable to cross-compile a Qt application for the iMX6.

I can tell from your blog that you have been able to compile Qt applications for iMX6 and was hoping you could shed some light on how you did this. All the guides I have found are outdated, incorrect or I am doing something terribly wrong.

If you could give me any pointers on how to do this I would be very grateful! Further communication might be better via e-mail, you can contact me at b.d.vries at storm-eindhoven dot com.

Thanks for reading my message anyway!

Michael Grunditz said...

Bob, mail sent!

Unknown said...

Hi Michael !

I'm presently working at DesoutterTools, on a product using an IMX6. I've got a Qt app to display (with Qt5.5) and, just like Bob, I'm failing at using Qt platform plugins, specially EGLFS and DirectFb. I've already tried LinuxFb as a plugin, but it does not support the portrait format of my screen (it always displays the interface as a landscape), plus I want to bench all the plugins to see which one is more suitable for my application.
Could you give me some insight about how you made it working ?
You can contact me via e-mail with: pierrick.guitter@external.desouttertools.com

Sincerely,
Pierrick