[Bug 726193] waylandsink: subsurface & scaling support, plus many other improvements

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Tue Jun 10 04:26:33 PDT 2014


https://bugzilla.gnome.org/show_bug.cgi?id=726193
  GStreamer | gst-plugins-bad | git

--- Comment #7 from George Kiagiadakis <kiagiadakis.george at gmail.com> 2014-06-10 11:26:29 UTC ---
And with some more improvements last week, I fixed some locking issues and also
simplified the GstWaylandVideo interface as it has been discussed in the past:

* set_surface_size is gone & replaced by gst_video_overlay_set_render_rectangle

The semantics also changed a bit there. The subsurface is now being created
inside waylandsink, so the parent application only needs to set its top-level
surface as the window handle and use set_render_rectangle to specify the
sub-area of the window where the video should appear.

* pause_rendering is now begin_geometry_change
* resume_rendering is now end_geometry_change

The implementation of these methods has also changed to just do
wl_subsurface_set_sync/desync and resizing is implemented by directly
committing a wl_viewport.set_destination change inside set_render_rectangle
(instead of waiting for the next redraw in the streaming thread). This way,
resizing is independent of rendering and the API is faster and simpler. This is
only possible because of wl_scaler version 2, though, and tbh, there is a bug
in weston that prevents it from fully working as expected (so resizing is not
really smooth unless you also call gst_video_overlay_expose() after
set_render_rectangle() and there are some complications there, but this needs
fixing in weston)

The nice part about these changes is that waylandsink can now be used properly
with gtk without ugly hacks in the client and it works pretty well. The sample
code has also been updated:

http://cgit.collabora.com/git/user/gkiagia/gst-wayland-gtk-demo.git/tree/main.c

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list