waylandsink: get the external display handle using GstContext
authorGeorge Kiagiadakis <george.kiagiadakis@collabora.com>
Wed, 21 May 2014 15:27:28 +0000 (18:27 +0300)
committerGeorge Kiagiadakis <george.kiagiadakis@collabora.com>
Tue, 17 Jun 2014 11:51:27 +0000 (13:51 +0200)
commitc62ec6f8151ee8fe41c0957433b07cd13b374e9d
treeb6718d52658a077f79234b41ee76802030446ac7
parentbd5ad17e586e7fc1171a24b4c4eeec135cb956b9
waylandsink: get the external display handle using GstContext

This drops the ugly GstWaylandWindowHandle structure and is much
more elegant because we can now request the display separately
from the window handle. Therefore the window handle can be requested
in render(), i.e. when it is really needed and we can still open
the correct display for getting caps and creating the pool earlier.

This change also separates setting the wl_surface from setting its size.
Applications should do that by calling two functions in sequence:

  gst_video_overlay_set_window_handle (overlay, surface);
  gst_wayland_video_set_surface_size (overlay, w, h);
ext/wayland/gstwaylandsink.c
ext/wayland/wlwindow.c
gst-libs/gst/wayland/wayland.h