From e24e8e1276f573b95b1eb98c012c48c6b96f1e49 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim-Philipp=20M=C3=BCller?= Date: Tue, 22 Nov 2005 11:13:49 +0000 Subject: [PATCH] sys/: Call gst_x_overlay_prepare_xwindow_id() to give applications a final chance to set their own xwindow id before ... Original commit message from CVS: * sys/ximage/ximagesink.c: (gst_ximagesink_setcaps): * sys/xvimage/xvimagesink.c: (gst_xvimagesink_setcaps): Call gst_x_overlay_prepare_xwindow_id() to give applications a final chance to set their own xwindow id before the video sink creates its own window. --- ChangeLog | 8 ++++++++ sys/ximage/ximagesink.c | 5 +++++ sys/xvimage/xvimagesink.c | 5 +++++ 3 files changed, 18 insertions(+) diff --git a/ChangeLog b/ChangeLog index 458b585..a0e567b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2005-11-22 Tim-Philipp Müller + + * sys/ximage/ximagesink.c: (gst_ximagesink_setcaps): + * sys/xvimage/xvimagesink.c: (gst_xvimagesink_setcaps): + Call gst_x_overlay_prepare_xwindow_id() to give applications + a final chance to set their own xwindow id before the video + sink creates its own window. + 2005-11-22 Julien MOUTTE * sys/xvimage/xvimagesink.c: diff --git a/sys/ximage/ximagesink.c b/sys/ximage/ximagesink.c index 96e600d..f9679b2 100644 --- a/sys/ximage/ximagesink.c +++ b/sys/ximage/ximagesink.c @@ -1124,6 +1124,11 @@ gst_ximagesink_setcaps (GstBaseSink * bsink, GstCaps * caps) GST_VIDEO_SINK_HEIGHT (ximagesink) = new_height; ximagesink->framerate = fps; + /* Notify application to set xwindow id now */ + if (!ximagesink->xwindow) { + gst_x_overlay_prepare_xwindow_id (GST_X_OVERLAY (ximagesink)); + } + /* Creating our window and our image */ g_assert (GST_VIDEO_SINK_WIDTH (ximagesink) > 0); g_assert (GST_VIDEO_SINK_HEIGHT (ximagesink) > 0); diff --git a/sys/xvimage/xvimagesink.c b/sys/xvimage/xvimagesink.c index 8313bd7..8fa63a8 100644 --- a/sys/xvimage/xvimagesink.c +++ b/sys/xvimage/xvimagesink.c @@ -1503,6 +1503,11 @@ gst_xvimagesink_setcaps (GstBaseSink * bsink, GstCaps * caps) GST_DEBUG_OBJECT (xvimagesink, "scaling to %dx%d", GST_VIDEO_SINK_WIDTH (xvimagesink), GST_VIDEO_SINK_HEIGHT (xvimagesink)); + /* Notify application to set xwindow id now */ + if (!xvimagesink->xwindow) { + gst_x_overlay_prepare_xwindow_id (GST_X_OVERLAY (xvimagesink)); + } + /* Creating our window and our image with the display size in pixels */ g_assert (GST_VIDEO_SINK_WIDTH (xvimagesink) > 0); g_assert (GST_VIDEO_SINK_HEIGHT (xvimagesink) > 0); -- 2.7.4