Home Chasing the Raspberry pi Dragon OpenGL ES2 Accelerated Qt PI

Chasing the Raspberry pi Dragon OpenGL ES2 Accelerated Qt PI

 
The raspberry pi initiative is very compelling and (forgive me for the hype) just got even more compelling now that we have Qt 5 running with full acceleration on the target. A tagline of “An ARM Linux box for $25. Take a byte!” sums it up rather nicely and should get many a geeks pulse racing. The Mer community have been good about getting Qt up and running on the Raspberry PI and we appreciate their drive and rapid work. We will now proceed to document how to build Qt in order to have full OpenGL ES 2 (tested) and OpenVG support (untested)
The mkspecs are here with associated patch(es).
The modified simplegl driver (required for QWS support in Qt 4.8) is here.
I have tested Qt 4.8 QWS with the simplegl driver, Qt 4.8 QPA (lighthouse) trunk with the EGLFS driver and Qt 5 trunk with the EGLFS driver. We are looking great on all fronts. (Videos to follow, but the performance is great at 1360×768) The required changes were a couple lines of Broadcom specific initialization code which is added to the simplegl connect method and the QEglFSScreen constructor respectively for QWS/QPA.
We clearly can’t distribute the libraries/headers the above mkspecs reference. (Qt Embedded/QPA are both largely self contained and only require external headers/libs for EGL/GLES2/OpenVG support)
I am using the Code Sourcery 2010q1 compiler.
I am using a sd-card (read snapshot) with all the required libraries (and the EGL/GLES2/VG headers required to compile Qt)
I was happy to see how easy it was to get Qt 5 cross compiled and running on the device. I restricted my build efforts to qtbase and qtdeclarative, but this built rapidly and without fault.
Caveat!: Before proceeding, my instructions are home brewed, pragmatic and get the job done. If you have better/functional instructions on getting the Qt 5 repo to a buildable state, then please don’t walk off a cliff with me.
Checking out Qt 5:

git clone git://gitorious.org/qt/qt5.git
./init-repository
./qtrepotools/bin/qt5_tool -p
The implications of this are covered in the README
Proceeding with the build

Having symlinked in the appropriate mkspec from the git repo above and abstracting away my personal path arrangements, my configure line follows:
/opt/dev/src/qt5/qtbase/configure -prefix /opt/dev/qt-qpa-5-rasp-pi -release -no-phonon -no-qt3support -no-webkit -make libs -armfpa -arch armv6 -xplatform linux-rasp-pi-g++ -opengl es2 -confirm-license
Once this was built and you have your trusty qt 5 relevant qmake, creating a qtdeclarative directory within your shadow built qt, and running:
qmake /opt/dev/src/qt5/qtdeclarative/qtdeclarative.pro
make
make install
Gets you Qt Quick 2 (Scenegraph) enriched and merrily on your road to riches.
What remains to be done:

1) The device has OpenMax support which we could use for Audio/Video/Image decoding. It would be nice to see whether we can utilize this in Qt’s image loading plugin mechanism.
2) Get qtwebkit compiled, deployed and running on the target (Python related hijinxs stemming from the build-webkit script postponed inclusion in the done list above)
3) Turtles the whole way down (There is no shortage of board specific customization we could potentially indulge in)
I look forward to the deluge of videos showing the capabilities of accelerated Qt (4 or 5) on this fine hardware. We will be demoing this device in the demo pavilion at this year’s Qt Developer Day event in Munich and San Francisco and I will personally be on hand to answer any posting/cross compilation questions you may happen to have.
Source Qt Labs Developer Blogs

About ReadWrite’s Editorial Process

The ReadWrite Editorial policy involves closely monitoring the tech industry for major developments, new product launches, AI breakthroughs, video game releases and other newsworthy events. Editors assign relevant stories to staff writers or freelance contributors with expertise in each particular topic area. Before publication, articles go through a rigorous round of editing for accuracy, clarity, and to ensure adherence to ReadWrite's style guidelines.

Get the biggest tech headlines of the day delivered to your inbox

    By signing up, you agree to our Terms and Privacy Policy. Unsubscribe anytime.

    Tech News

    Explore the latest in tech with our Tech News. We cut through the noise for concise, relevant updates, keeping you informed about the rapidly evolving tech landscape with curated content that separates signal from noise.

    In-Depth Tech Stories

    Explore tech impact in In-Depth Stories. Narrative data journalism offers comprehensive analyses, revealing stories behind data. Understand industry trends for a deeper perspective on tech's intricate relationships with society.

    Expert Reviews

    Empower decisions with Expert Reviews, merging industry expertise and insightful analysis. Delve into tech intricacies, get the best deals, and stay ahead with our trustworthy guide to navigating the ever-changing tech market.