Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
533 views
in Technique[技术] by (71.8m points)

linux - What is the use of various Qt platform plugins?

I was doing some cross compiling of a Qt5.2 application for an ARM based target (TI AM335x EVM) and it was failing to display anything on my platform. After doing some google’ing I found that if I launched it with:

 ./helloworld -platform eglfs

it would show up (full screen, but it worked)!

I started looking at all the platform options, I found:

android, eglfs, linuxfb, minimalegl, windows, xcb, cocoa, ios, offscreen, qnx, directfp, kms, minimal, openwfd

I’m wondering what they are for. I assume, for example, that if I wanted to run my application on an Android device I’d have to pass -platform android, but they’re not all obvious to me.

Is there a listing anywhere of when each of these parameters should be used?

For example, what does eglfs stand for? And why did I need to use that where as linuxfb didn’t work?
(I would have thought the linux frame buffer was how I wanted to launch my application since it was running on embedded linux)

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

If the linuxfb plugin doesn't work, then possibly you didn't correctly configure the framebuffer device on your system. Maybe a directf layer is already running, so you may want to try the directfb plugin instead.

If you wish to avoid having to specify the platform option when you run the executable, you can pass the default one to configure when you build Qt.

The plugins can be described as follows:

  • Linux plugins - those use Linux-specific input devices and various output devices

  • eglfs - Uses the OpenGL ES in fullscreen mode. There's no other way since OpenGL has no concept of a window manager.

  • directfb (not directfp) - Uses the linux frame buffer with OpenGL ES via the directfb layer (see also wikipedia). Integrates into the directfb windowing.

  • linuxfb - Uses the linux frame buffer in fullscreen mode. There's no other way since linuxfb has no concept of a window manager.

  • kms - Uses linux kernel modesetting API in fullscreen mode. There's no other way since DRM has no concept of a window manager.

  • openwfd - Uses an openwfd Wifi display in fullscreen mode. There's no other way since openwfd has no concept of a window manager.

  • Platform-independent plugins - could be made to run on any OS

  • xcb - Runs on an X11 server and is integrated into the X11 windowing environment. Generally it won't behave correctly without a window manager running as well. Can be made to work on Windows, given a Windows implementation of xlib, if you want to, say, serve applications from a Windows server to X11 thin terminals (typically Unix boxes).

  • offscreen - Renders to an offscreen buffer. Useful for rendering to custom displays.

  • minimal - A minimalistic backing store that optionally dumps the virtual screen to a file. Implements the bare minimum of functionality just to demonstrate how to start writing a platform plugin.

  • Other platform-specific plugins

  • android - Uses the Android APIs and is integrated into the Android environment.

  • windows - Uses the WINAPI and is integrated into the Windows windowing environment.

  • cocoa - Uses the Cocoa APIs and is integrated into the OS X windowing environment.

  • iOS - Uses the iOS toolkits and is integrated into the iOS environment.

  • qnx - Uses the QNX APIs and is integrated into the QNX photon windowing environment.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...