Output WebRTCBin to GTK Window using VideoOverlay
Matthew Waters
ystreet00 at gmail.com
Fri Jul 3 02:01:22 UTC 2020
GstVideoOverlay is an interface that is implemented by most video
sinks. You need to call gst_video_overlay_set_window_handle() on your
video sink, not webrtcbin.
On 3/7/20 6:40 am, Busayo Famutimi wrote:
> Hi Devs,
>
> I am trying to display a video stream from WebRTCBin to a GTK Window
> using VideoOverlay rather than have gstreamer create it's own window.
>
> The code works fine (gstwebrtc-demos - sendrecv.c
> <https://github.com/centricular/gstwebrtc-demos/blob/master/sendrecv/gst/webrtc-sendrecv.c>).
> I managed to tweak it to suit my intended purpose but I keep getting
> the following error:
>
> *GLib-GObject-WARNING **: 21:14:46.552: invalid cast from
> 'GstWebRTCBin' to 'GstVideoOverlay'
>
> ** (webrtc-sendrecv.exe:6304): CRITICAL **: 21:14:46.552:
> gst_video_overlay_set_window_handle: assertion
> 'GST_IS_VIDEO_OVERLAY (overlay)' failed*
>
> *
> *
> The error is coming from this line of the code:
>
> */* Pass it to playbin, which implements VideoOverlay and will
> forward it to the video sink */
>
> gst_video_overlay_set_window_handle(GST_VIDEO_OVERLAY(webrtc1),
> window_handle);*
>
> *
> *
> Please how can I handle this situation?
>
> Thanks.
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20200703/acd60c20/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20200703/acd60c20/attachment.sig>
More information about the gstreamer-devel
mailing list