How can I run a Qt applicaton on ivi-shell?

Yang Zhonghua happy2discover at gmail.com
Wed Dec 6 22:21:46 EST 2017


Hi Helsing,

First of all, thank you for your time.

I followed your advice with WAYLAND_DEBUG=1, here are the logs after
executing "./hello-qt-quick2 -platform wayland":

[2068056.617]  -> wl_display at 1.get_registry(new id wl_registry at 2)
[2068057.204]  -> wl_display at 1.sync(new id wl_callback at 3)
[2068057.911] wl_display at 1.delete_id(3)
[2068058.083] wl_registry at 2.global(1, "wl_compositor", 3)
[2068058.286]  -> wl_registry at 2.bind(1, "wl_compositor", 3, new id
[unknown]@4)
[2068058.481] wl_registry at 2.global(2, "wl_subcompositor", 1)
[2068058.638] wl_registry at 2.global(3, "wl_scaler", 2)
[2068058.782] wl_registry at 2.global(4, "presentation", 1)
[2068058.918] wl_registry at 2.global(5, "wl_data_device_manager", 2)
[2068059.099]  -> wl_registry at 2.bind(5, "wl_data_device_manager", 1, new id
[unknown]@5)
[2068059.284] wl_registry at 2.global(6, "wl_shm", 1)
[2068059.421]  -> wl_registry at 2.bind(6, "wl_shm", 1, new id [unknown]@6)
[2068059.593] wl_registry at 2.global(7, "wl_viv", 1)
[2068059.731] wl_registry at 2.global(8, "wl_viv", 1)
[2068059.866] wl_registry at 2.global(9, "wl_output", 2)
[2068060.052]  -> wl_registry at 2.bind(9, "wl_output", 2, new id [unknown]@7)
[2068060.285]  -> wl_display at 1.sync(new id wl_callback at 8)
[2068060.386] wl_registry at 2.global(10, "wl_seat", 4)
[2068060.587]  -> wl_registry at 2.bind(10, "wl_seat", 3, new id [unknown]@9)
[2068060.814]  -> wl_data_device_manager at 5.get_data_device(new id
wl_data_device at 10, wl_seat at 9)
[2068061.061] wl_registry at 2.global(11, "wl_input_panel", 1)
[2068061.215] wl_registry at 2.global(12, "wl_input_method", 1)
[2068061.353] wl_registry at 2.global(13, "wl_text_input_manager", 1)
[2068061.528]  -> wl_registry at 2.bind(13, "wl_text_input_manager", 1, new id
[unknown]@11)
[2068061.709] wl_registry at 2.global(14, "wl_shell", 1)
[2068061.882]  -> wl_registry at 2.bind(14, "wl_shell", 1, new id [unknown]@12)
[2068062.060] wl_registry at 2.global(15, "xdg_shell", 1)
[2068062.210] wl_registry at 2.global(16, "desktop_shell", 3)
[2068062.351] wl_registry at 2.global(17, "workspace_manager", 1)
[2068062.490] wl_registry at 2.global(18, "screenshooter", 1)
[2068062.630] wl_callback at 3.done(3)
[2068063.154] wl_display at 1.delete_id(8)
[2068063.263] wl_output at 7.geometry(0, 0, -1, -1, 0, "unknown", "DISP4 BG",
0)
[2068063.519] wl_output at 7.scale(1)
[2068063.599] wl_output at 7.mode(3, 1280, 800, 64216)
[2068063.743] wl_output at 7.done()
[2068063.875] wl_callback at 8.done(3)
[2068063.957] wl_seat at 9.capabilities(0)
[2068064.034] wl_seat at 9.name("default")
[2068064.654]  -> wl_shm at 6.create_pool(new id wl_shm_pool at 8, fd 6, 4096)
[2068065.240]  -> wl_shm_pool at 8.resize(8832)
[2068065.527]  -> wl_shm_pool at 8.resize(18624)
Using Wayland-EGL
[2068132.476]  -> wl_display at 1.get_registry(new id wl_registry at 3)
[2068132.606]  -> wl_display at 1.sync(new id wl_callback at 13)
[2068133.003] wl_display at 1.delete_id(13)
[2068133.058] wl_registry at 3.global(1, "wl_compositor", 3)
[2068133.123] wl_registry at 3.global(2, "wl_subcompositor", 1)
[2068133.178] wl_registry at 3.global(3, "wl_scaler", 2)
[2068133.231] wl_registry at 3.global(4, "presentation", 1)
[2068133.282] wl_registry at 3.global(5, "wl_data_device_manager", 2)
[2068133.334] wl_registry at 3.global(6, "wl_shm", 1)
[2068133.384] wl_registry at 3.global(7, "wl_viv", 1)
[2068133.438]  -> wl_registry at 3.bind(7, "wl_viv", 1, new id [unknown]@14)
[2068133.508] wl_registry at 3.global(8, "wl_viv", 1)
[2068133.561]  -> wl_registry at 3.bind(8, "wl_viv", 1, new id [unknown]@15)
[2068133.629] wl_registry at 3.global(9, "wl_output", 2)
[2068133.681] wl_registry at 3.global(10, "wl_seat", 4)
[2068133.730] wl_registry at 3.global(11, "wl_input_panel", 1)
[2068133.780] wl_registry at 3.global(12, "wl_input_method", 1)
[2068133.830] wl_registry at 3.global(13, "wl_text_input_manager", 1)
[2068133.880] wl_registry at 3.global(14, "wl_shell", 1)
[2068133.929] wl_registry at 3.global(15, "xdg_shell", 1)
[2068133.978] wl_registry at 3.global(16, "desktop_shell", 3)
[2068134.028] wl_registry at 3.global(17, "workspace_manager", 1)
[2068134.078] wl_registry at 3.global(18, "screenshooter", 1)
[2068134.127] wl_callback at 13.done(3)
[2068326.444]  -> wl_compositor at 4.create_surface(new id wl_surface at 13)
Failed to load shell integration ivi-shell
[2068326.781]  -> wl_shell at 12.get_shell_surface(new id wl_shell_surface at 16,
wl_surface at 13)
[2068326.911]  -> wl_shell_surface at 16.set_title("")
[2068326.996]  -> wl_shell_surface at 16.set_class("hello-qt-quick2")
[2068327.068]  -> wl_shell_surface at 16.set_toplevel()
[2068327.127]  -> wl_surface at 13.set_buffer_scale(1)
[2068327.272]  -> wl_surface at 13.set_buffer_transform(0)
[2068327.327]  -> wl_surface at 13.commit()
[2068341.556]  -> wl_compositor at 4.create_surface(new id wl_surface at 17)
[2068352.679]  -> wl_surface at 17.destroy()
[2068429.359]  -> wl_viv at 15.create_buffer(new id wl_buffer at 18, 326, 273,
1344, 212, 6, 25, 6)
[2068430.427]  -> wl_surface at 13.frame(new id wl_callback at 19)
[2068430.499]  -> wl_surface at 13.attach(wl_buffer at 18, 0, 0)
[2068430.559]  -> wl_surface at 13.damage(0, 0, 326, 273)
[2068430.619]  -> wl_surface at 13.commit()
[2068431.009] wl_display at 1.delete_id(17)
[2068431.061] wl_surface at 13.enter(wl_output at 7)

It is complicated for me to analyze the logs so far. Could you give me
some hints?

B.R.&Thanks,

Yang Zhonghua
happy2discover at gmail.com


On Wed, Dec 6, 2017 at 6:41 PM, Johan Helsing <johan.helsing at qt.io> wrote:

> Also, it's a good idea to post the application output, and also the output
> with WAYLAND_DEBUG=1, and perhaps a stack trace if appropriate.
>
>
> It's hard to give meaningful advice when all we now is "couldn't run".
>
>
> Br,
>
> Johan Helsing
> ------------------------------
> *From:* genivi-ivi-layer-management <genivi-ivi-layer-management-
> bounces at lists.genivi.org> on behalf of zhangyang <zhangyang-0206 at 163.com>
> *Sent:* Wednesday, December 6, 2017 10:34:06 AM
> *To:* Yang Zhonghua
> *Cc:* genivi-ivi-layer-management at lists.genivi.org
> *Subject:* Re:How can I run a Qt applicaton on ivi-shell?
>
> Hi yang:
> 1. If you want your qt application run with ivi-shell, you should export
> QT_WAYLAND_SHELL_INTEGRATION=ivi-shell first.
>
> 2. I don't know your qt version, if it is >= 5.7,  you can set
> QT_IVI_SURFACE_ID to specify ivi-surface-id for your qt app. follows this:
>
> https://codereview.qt-project.org/#/c/121297/
> else if it is <5.7, you should apply genivi-ivi patch here:
> https://github.com/GENIVI/genivi-dev-platform/tree/
> master/meta-genivi-dev/meta-qt5
>
>
> 3. Be sure your ubuntu already have genivi-ivi-extension support
>
>
>
> good luck!
>
>
>
>
>
> At 2017-12-06 09:30:09, "Yang Zhonghua" <happy2discover at gmail.com> wrote:
> >Hi guys,
> >
> >I am new to wayland.
> >
> >[situation]
> >The ivi-shell demo could run correctly on Ubuntu 17.10 so far.
> >
> >[goal]
> >1. I made a hello-world Qt Quick2 application and tried to make it managed
> >by ivi-shell.
> >2. Two fullscreen applications could run on diffrent layers at the same
> >time. The bottom one could show directly when the top one exits.
> >
> >[problem]
> >I copied weston.ini in ivi-shell folder and added the following lines.
> >
> >[ivi-launcher]
> >workspace-id=3
> >icon-id=4010
> >icon=/home/ubuntu/Downloads/weston/data/icon_ivi_hello-
> world-qt-quick2.png
> >path=/home/ubuntu/Projects/hello-world-qt-quick2/hello-world-qt-quick2
> >
> >
> >But the hello-world Qt Quick2 application couldn't run on ivi-shell.
> >AFAIK, the Qt application should make a request to generate surface-id.
> >Anybody knows how to do it? Thanks so much!
> >
> >I've been stuck for almost one month...
> >_______________________________________________
> >genivi-ivi-layer-management mailing list
> >genivi-ivi-layer-management at lists.genivi.org
> >https://lists.genivi.org/mailman/listinfo/genivi-ivi-layer-management
> _______________________________________________
> genivi-ivi-layer-management mailing list
> genivi-ivi-layer-management at lists.genivi.org
> https://lists.genivi.org/mailman/listinfo/genivi-ivi-layer-management
>



More information about the genivi-ivi-layer-management mailing list