Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How to check out HDMI and LVDS in one project on imx6dl
I want to use two screens( hdmi and lvds) to show different windows.
the second screen is hdmi (has set
echo 0 > /sys/class/graphics/fb2/blank),but
qApp->desktop()->screenCount()always returns 1.
What configuration else should I set?
What device are you targeting ?
What rendering backend are you using ?
Sorry I don't understand the targeting device you said.
Now I 'm using imx6dl with their zimage, dtb and rootfs(for Qt 5.6.2). The screens are LVDS and HDMI like computer screen.
uboot has been set
video=mxcfb0:dev=hdmi,1920x1080M@60,if=RGB24,bpp=32 video=mxcfb1:dev=ldb,1024x768M@60,if=RGB24,bpp=32. I know imx6 can not use more than one screen in one program. Does that mean a program can not know all the screens the device has on imx6?
Two screens are two different devices, classic backends access only one device.. If you want your application to manage both then you will have to consider using something like wayland.
Mihan last edited by Mihan
what's the diffecence between Wayland and X11 or FB( should I say xcb or eglfs)?
Is Wayland better than X11 or FB?
What should I change my Qt project ( both Qt Widget and Qt Quick) if I replace the system from X11 to Wayland
Not the same technologies. Wayland goal is to replace X11. FB is a direct access to the frame buffer so you do not have a graphics server/window manager.
You can use the -platform switch to use a different backend when running your application.
@SGaist thank you so much
So, If I'm using X11, how to use
--platformto set the second screen for the other program?
-platform linuxfb：fb = / dev / fb2for eglfs
Usually when you have a graphical server, it handles all the available screens. Why do you want to use two different backends ?
Mihan last edited by Mihan
when you have a graphical server, it handles all the available screens
Sorry maybe my statement is unclear.
As you said the graphical server can handles all the available, so how to run the program on the second screen on X11?
The example I said above is that I read this content in Qt wiki for imx6--Multiple screens, which just has
-platformfor FB. So I want to know the params of
It's the xcb backend.
Can you explain your use case ?
@SGaist Sorry, I'm late.
Sure. I'm using imx6dl with kernel 4.1.15 for X11 Qt 5.6.2. Then I want to show different contents on different screens( hdmi and lvds).
The hardware is ok that I can control which one is the first screen( hdmi -> fb0 or lvds -> fb0).
So how to show the other content on fb2 by running the other program?
BTW, I must use
export DISPLAY=:0.0so that the first program can be run.
If you are attacking directly the frame buffers, you can set which one to use through environment variables for example.