Open GL QT embedded on imx6 with Yocto dora

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Open GL QT embedded on imx6 with Yocto dora

7,562 Views
mariorodriguez
Contributor II

Hello Community!

So far I have being able to "bake" a build using Yocto dora and use the Vivante examples :smileygrin:.

The image that I built was qte-in-use-image and I append the vivante examples. Everything seems to work even though I had to disable X11 manually on the local.conf because it seems like the vivante library can be used for X11 or with framebuffer but not with both enabled.

DISTRO_FEATURES_remove = "x11 wayland"

See this post for more info:Google Groups

I am using the sabre lite board from boundary devices.

in the qte-in-use-image there are some QT examples. Unfortunately the ones for OpenGL didn't work .

When I try to run the helloOpenGL example on /usr/bin/qtopia/examples/opengl/hellogl_es2 I get the following message:

(I run it by giving it the -qws option)

Unable to load library icui18n "Cannot load library icui18n: (icui18n: cannot open shared object file: No such file or directory)"

pwm_config: pwm freq = 32786, clk_select=2 clock_rate=22000000

pwm_config: pwm freq = 20000, clk_select=2 clock_rate=22000000

And I see the QT widget with menus and everything but the middle of the screen is pitch black. The same happens with the texture example. I see the widget, but there where the textures should come I can only see black squares.

Do I need to cross-compile them with a special option or how does that work? I would appreciate any hint.

Does anyone have succedded running the hellogl_es2 example for the imx6 on dora?

Regards,

Mario

Regards!

Mario

10 Replies

2,358 Views
daiane_angolini
NXP Employee
NXP Employee

"because it seems like the vivante library can be used for X11 or with framebuffer but not with both enabled."

Yes, or you have a system with X11, or you have a system with framebuffer. And I would say it´s not a "vivante thing" :smileywink:

Wayland + X11 is only possible because there is a version of Wayland to be run *over* X11

Otherwise, backends are incompatible each other.

icui18n library is not related with GPU stack. Do you know this lib?

Are you using QT4.8 or QT5?

2,358 Views
mariorodriguez
Contributor II

Hello Daiane,

thanks for responding :smileygrin: I am using QT4.8

Yes I agree that it is not a vivante thing but it cost some time to figure it out.

I don't know the icui18n library. I think it has to do with QT.

But I found something quite interesting... I created a meta-toolchain-qte. (with bitbake)

(Which by the way I can only compile if I add again X11 and wayland)

I see that on the following folder:

/opt/qte_poky/1.5.1/sysroots/cortexa9hf-vfp-neon-poky-linux-gnueabi/usr/include/qtopia

There is no QtOpenGL folder....

I wanted to crosscompile again on my machine the hellogl_es2 example and I found this. I think OpenGL was not configured correctly (the OpenGL flag was not given) I am trying to find out where does this happen. I inspected the meta-toolchain-qte.bb and that lead me to meta-toolchain-qt.inc... I would expect that the recipe from /opt/yocto-freescale/sources/meta-fsl-arm/recipes-qt/qt4/qt4-embedded_4.8.5.bbappend should be somewhere on this file included but I cannot find it.

What I am missing? Or I am looking at the wrong place?

0 Kudos
Reply

2,359 Views
daiane_angolini
NXP Employee
NXP Employee

I´m not sure, but I think you´ve facing those problems because you´ve been using the same build folder to build different DISTRO_FEATURES images.

When you change DISTRO_FEATURES in your local.conf, do you remove tmp folder?

2,359 Views
mariorodriguez
Contributor II

Hi Daiane,

I did not delete my tmp folder. But then I manually modified the ./poky/meta/recipes-qt/packagegroups/packagegroup-qt-toolchain-target.inc file and I manually added the OpenGL library entry there and I got the headers on my sdk :smileygrin:. Do I really need to delete my tmp folder everytime I touch local.conf?

And does OpenGL + QT without X11 and wayland runs on the mx6 board? Which examples do yo recommend to test? What would be better to use QT4 or QT5?

Thanks!

2,359 Views
OtavioSalvador
Senior Contributor II

Hello Mario,

Not every time but when you change DISTRO_FEATURES you must to start over.

Please do that and report back.

2,359 Views
mariorodriguez
Contributor II

Hi Otavio,

I buid meta-toolchain-qte again, delete the tmp folder. I removed my fix from packagegroup-qt-toolchain-target.inc and... there is no QtOpenGL folder... I think the Qt is not configured with the opengl es2 flag. I also see that the qmake.conf has no trace of opengl....

/opt/poky/1.5.1/sysroots/cortexa9hf-vfp-neon-poky-linux-gnueabi/usr/share/qtopia/mkspecs/linux-g++/qmake.conf

I wanted to crosscompile a very simple example and the GL constants and functions are not found. i.e. GL_POLYGON, glMatrixMode and so on...

I will have to download qt and configure it. But it would be nice if I know which flags do I need to set up...

And OpenGL + QT is really supported (using framebuffer only)? The GPU is really used?

Regards,

Mario

0 Kudos
Reply

2,359 Views
daiane_angolini
NXP Employee
NXP Employee

hummmmmmmmmmmmmmmmmmmmmmmmmmm

Which board are you using?

0 Kudos
Reply

2,359 Views
daiane_angolini
NXP Employee
NXP Employee

Let´s start over, OK?

If you cannot see *any* GPU lib inside your rootfs, let´s focus first on this.

Please, double check:

1) your machine name

2) your bblayer.conf

3) youc local.conf

4) bitbake -e | grep DISTRO_FEATURES

Send me the logs and I will try to figure out what would be the problem

0 Kudos
Reply

2,359 Views
mariorodriguez
Contributor II

No no no no, I can see the open GL libraries. I mean they are there.

Sorry my mistake I forgot to add the

QT += opengl

to my *.pro file.

And now I can see them.

But anyway there is definetly something funny with the sdk.

My board is a sabre lite from boundary devices. opengl is definetly in DISTRO_FEATURES

0 Kudos
Reply

2,359 Views
daiane_angolini
NXP Employee
NXP Employee

:smileygrin:

Ok, so know I´m confused

What is funny with your sdk? And, when you say SDK, you mean SDK, the toolchain?

0 Kudos
Reply