[Solved] -platform and linuxfb documentation
-
hi img_man,
bq. fbX is just an example, you need to insert the correct number for X. List (ls -la) your /dev directory and find the correct frame buffer.
--> I know but it does not work even with fb0. I also tried in Qt5.1, it does work but display position is incorrect and touch input dies.bq. If there are two frame buffers in /dev, they may already be blended by your hardware.
--> I think they are not blended since I used QDesktop instance to check number of screen and available geometry. Only one screen is recognized.bq. Perhaps you’ve already done that, in which case, I would suggest trying something easy, like ‘cat /dev/urandom > /dev/fb0’. Which should populate your screen with (psuedo) random pixel data. Does it work?
--> yes, it does. -
Hi img_man,
Even if it works then I can only switch the display output for the entire app. What I would like is to create an app that can manipulate its output itself. Lets take an example: a video playback app which has a list of video files displayed on the first screen. When one file is selected, its content is played on the second screen.
Hope you can help me with this and thank you very much for your reply!
-
Interesting. So, you have at least one frame buffer that is full screen, you can write to it, but your app stops when you try to launch it?
I've struggled with seg faults in QT also. One thing that's helped me is to make sure that all the QT libraries (or at least links to the libraries) are in /usr/lib. If QT tries to start and can't find the libraries it needs, it will fail.
You also need to have the platform directory in your app directory, with the correct platform libraries in it that you wish to use.
Not sure about touch input, I haven't tried that yet.
Does your /dev directory show two frame buffers? Are you using two displays?
-
Hello All,
I tried the same thing [QT Version: 5.2.1]. Here is my actual command:
./gui_qt -platform linuxfb:fb="/dev/fb0"
but i got following error:
This application failed to start because it could not find or load the Qt platform plugin "linuxfb".
Reinstalling the application may fix this problem.
Aborted (core dumped)Kindly help me out. Thanks
Sid -
Hi Sidii,
I haven't used qt in a little while now, but I seem to recall that there's an undocumented requirement that the platform plugins you intend to use must be located in a folder named "platform", located in the same folder as your app. These can be links, instead of a direct copy of the plugin from your install directory.
I may have the folder name wrong, but it should be easy to find it in your install directory and copy it to your app directory (or make a soft link).
The directory structure, for instance, should look like
app_name
platforms
platforms/linuxfbplugin_nameSorry if I forget some of the details on the naming conventions qt uses, but I think you should be able to extrapolate my meaning.
-
Dear img_man,
I created a folder called platforms. This has 3 files: libqlinuxfb.so, libqminimal.so and libqoffscreen.so.
Now when i start my application with following command:
@ ./gui_qt -platform linuxfb:fb=/dev/fb0@
I get following error:
This application failed to start because it could not find or load the Qt platform plugin "linuxfb".
Available platform plugins are: linuxfb, minimal, offscreen.
Reinstalling the application may fix this problem.
Aborted (core dumped)Any idea whats going wrong??
-
I have a similar issue except I don't get the line saying what IS available.
export LD_LIBRARY_PATH=/home/isaw/Qt/lib:/home/isaw/Qt/plugins/platforms:/$LD_LIBRARY_PATH
/home/isaw/iBaseQtWidget
/home/isaw/fonts/... (not configured)
/home/isaw/lib/... libQt5xxxxx.so.5.3.2
/home/isaw/plugins/...
.../platform/... libqlinuxfb.so, libqminimal.so, and libqoffscreen.soLinux 2.6.21 on Arm920t processor.
-
my add-on issue solved by http://qt-project.org/forums/viewthread/46640/