<div dir="auto"><div><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le mar. 30 juill. 2019 05 h 25, horai <<a href="mailto:ivo.hora@seznam.cz">ivo.hora@seznam.cz</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Dear all,<br>
<br>
I found  excellent post related to integrating Gstreamer sink into GTK on<br>
top of Wayland. I was learning from this DEMO:<br>
<a href="https://git.collabora.com/cgit/user/gkiagia/gst-wayland-gtk-demo.git/tree/?h=demo" rel="noreferrer noreferrer" target="_blank">https://git.collabora.com/cgit/user/gkiagia/gst-wayland-gtk-demo.git/tree/?h=demo</a><br>
<br>
I would like to kindly ask  a help, I am about to test how it would perform<br>
with 4 GtkBox and each has encapsulated video.<br>
It works fine in X11, since I get unique ID for every GtkEventBox (ID:<br>
videoarea)<br>
d->window_handle3 = GDK_WINDOW_XID(window);<br>
But I am facing issues on top of Wayland backend probably related to this<br>
line:<br>
d->window_handle3 = (guintptr) gdk_wayland_window_get_wl_surface(window);<br>
<br>
Even thought the pointer represented by variable window is unique for each<br>
videoarea (ID: videoarea0, videoarea1, etc.), I am getting equally same<br>
pointer for GDK surface for each window (d->video_window0 =<br>
GTK_WIDGET(gtk_builder_get_object(builder, "videoarea0"));)<br>
<br>
I blame this for not resizing my GtkBoxes properly when resizing the main<br>
Window.There is also a note about GTK not supporting subsurfaces, but this</blockquote></div></div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
DEMO is 5 years old, so I hope there is</blockquote></div></div><div dir="auto"><br></div><div dir="auto">You'll find this demo upstream in gst-plugins-bad. Gtk/GDK does not explicitly expose subsurface, but will use it for popover. In Wayland, GStreamer creates it's own subsurface, as there is only one surface per application, you have to pass the location relative to your app through gst_video_overlay_set_render_rectangle().</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> a solution. I am utilizing<br>
waylandsink (it yields a warning with scalability at the start of my<br>
application).<br></blockquote></div></div><div dir="auto"><br></div><div dir="auto">This is fixed in gnome-shell 3.32, but came with other regression. Weston works. Also, Weston has support for yuv which is still to be released in gnome-shell, so don't expect ideal performance.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Would you mind giving me an advice how to workaround the issue with fixed<br>
GDK surface ID?<br>
Maybe the problem is somewhere else, but GDK_WINDOW_XID(window) gives unique<br>
ID to the same variable where  <br>
gdk_wayland_window_get_wl_surface(window); gives the same to all rendering<br>
windows.<br>
<br>
<br>
<br>
Thank you very much<br>
Best regards,<br>
Ivo<br>
<br>
<br>
<br>
--<br>
Sent from: <a href="http://gstreamer-devel.966125.n4.nabble.com/" rel="noreferrer noreferrer" target="_blank">http://gstreamer-devel.966125.n4.nabble.com/</a><br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank" rel="noreferrer">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a></blockquote></div></div></div>