diff --git a/tests/examples/clutter/clutteractor.c b/tests/examples/clutter/clutteractor.c index 0c644b1f9f..8088ba722e 100644 --- a/tests/examples/clutter/clutteractor.c +++ b/tests/examples/clutter/clutteractor.c @@ -26,7 +26,7 @@ #include #include #include -#include +#include #define W 320 #define H 240 @@ -100,17 +100,17 @@ static GstBusSyncReply create_window (GstBus * bus, GstMessage * message, gpointer data) { GstGLClutterActor *actor = (GstGLClutterActor *) data; - // ignore anything but 'prepare-xwindow-id' element messages + // ignore anything but 'prepare-window-handle' element messages if (GST_MESSAGE_TYPE (message) != GST_MESSAGE_ELEMENT) return GST_BUS_PASS; - if (!gst_structure_has_name (message->structure, "prepare-xwindow-id")) + if (!gst_is_video_overlay_prepare_window_handle_message (message)) return GST_BUS_PASS; g_debug ("CREATING WINDOW"); - gst_x_overlay_set_window_handle (GST_X_OVERLAY (GST_MESSAGE_SRC (message)), - actor->win); + gst_video_overlay_set_window_handle (GST_VIDEO_OVERLAY (GST_MESSAGE_SRC + (message)), actor->win); clutter_threads_add_idle ((GSourceFunc) create_actor, actor); gst_message_unref (message); @@ -154,7 +154,7 @@ main (int argc, char *argv[]) pipeline = GST_PIPELINE (gst_parse_launch - ("videotestsrc ! video/x-raw-rgb, width=320, height=240, framerate=(fraction)30/1 ! " + ("videotestsrc ! video/x-raw, width=320, height=240, framerate=(fraction)30/1 ! " "glupload ! gleffects effect=twirl ! glimagesink", NULL)); bus = gst_pipeline_get_bus (GST_PIPELINE (pipeline)); diff --git a/tests/examples/clutter/clutteractortee.c b/tests/examples/clutter/clutteractortee.c index a867ff4c66..36608ae2dd 100644 --- a/tests/examples/clutter/clutteractortee.c +++ b/tests/examples/clutter/clutteractortee.c @@ -18,13 +18,15 @@ * Boston, MA 02111-1307, USA. */ +#define GLIB_DISABLE_DEPRECATION_WARNINGS + #include #include #include #include #include #include -#include +#include #define ROWS 3 #define COLS 3 @@ -69,11 +71,11 @@ create_window (GstBus * bus, GstMessage * message, gpointer data) GstGLClutterActor **actor = (GstGLClutterActor **) data; static gint count = 0; static GMutex *mutex = NULL; - // ignore anything but 'prepare-xwindow-id' element messages + // ignore anything but 'prepare-window-handle' element messages if (GST_MESSAGE_TYPE (message) != GST_MESSAGE_ELEMENT) return GST_BUS_PASS; - if (!gst_structure_has_name (message->structure, "prepare-xwindow-id")) + if (!gst_is_video_overlay_prepare_window_handle_message (message)) return GST_BUS_PASS; if (!mutex) @@ -83,8 +85,8 @@ create_window (GstBus * bus, GstMessage * message, gpointer data) if (count < N_ACTORS) { g_message ("adding actor %d", count); - gst_x_overlay_set_window_handle (GST_X_OVERLAY (GST_MESSAGE_SRC (message)), - actor[count]->win); + gst_video_overlay_set_window_handle (GST_VIDEO_OVERLAY (GST_MESSAGE_SRC + (message)), actor[count]->win); clutter_threads_add_idle ((GSourceFunc) create_actor, actor[count]); count++; } @@ -164,13 +166,13 @@ main (int argc, char *argv[]) } /* desc = g_strdup_printf ("v4l2src ! " - "video/x-raw-yuv, width=640, height=480, framerate=30/1 ! " + "video/x-raw, width=640, height=480, framerate=30/1 ! " "videoscale !" - "video/x-raw-yuv, width=%d, height=%d ! " + "video/x-raw, width=%d, height=%d ! " "identity", W, H); */ desc = g_strdup_printf ("videotestsrc ! " - "video/x-raw-rgb, width=%d, height=%d !" "identity", W, H); + "video/x-raw, format=RGB, width=%d, height=%d !" "identity", W, H); pipeline = GST_PIPELINE (gst_pipeline_new (NULL)); srcbin = gst_parse_bin_from_description (desc, TRUE, NULL); diff --git a/tests/examples/clutter/cluttershare.c b/tests/examples/clutter/cluttershare.c index 0a14594050..4bd8ef20a3 100644 --- a/tests/examples/clutter/cluttershare.c +++ b/tests/examples/clutter/cluttershare.c @@ -277,7 +277,7 @@ main (int argc, char *argv[]) pipeline = GST_PIPELINE (gst_parse_launch - ("videotestsrc ! video/x-raw-yuv, width=320, height=240, framerate=(fraction)30/1 ! " + ("videotestsrc ! video/x-raw, width=320, height=240, framerate=(fraction)30/1 ! " "glupload ! gleffects effect=5 ! glfiltercube ! fakesink sync=1", NULL)); diff --git a/tests/examples/gtk/fxtest/fxtest.c b/tests/examples/gtk/fxtest/fxtest.c index 8f08828cea..75811f7212 100644 --- a/tests/examples/gtk/fxtest/fxtest.c +++ b/tests/examples/gtk/fxtest/fxtest.c @@ -18,6 +18,8 @@ * Boston, MA 02111-1307, USA. */ +#define GLIB_DISABLE_DEPRECATION_WARNINGS + #include #include #include @@ -25,18 +27,18 @@ #include "../gstgtk.h" -#include +#include -/* TODO: use x overlay in the proper way (like suggested in docs, see gtkxoverlay example) */ +/* TODO: use video overlay in the proper way (like suggested in docs, see gtkvideooverlay example) */ static gboolean expose_cb (GtkWidget * widget, GdkEventExpose * event, gpointer data) { - GstXOverlay *overlay = - GST_X_OVERLAY (gst_bin_get_by_interface (GST_BIN (data), - GST_TYPE_X_OVERLAY)); + GstVideoOverlay *overlay = + GST_VIDEO_OVERLAY (gst_bin_get_by_interface (GST_BIN (data), + GST_TYPE_VIDEO_OVERLAY)); - gst_x_overlay_set_gtk_window (overlay, widget); + gst_video_overlay_set_gtk_window (overlay, widget); return FALSE; } @@ -149,7 +151,7 @@ main (gint argc, gchar * argv[]) if (source_desc == NULL) { source_desc = g_strdup - ("videotestsrc ! video/x-raw-rgb, width=352, height=288 ! identity"); + ("videotestsrc ! video/x-raw, width=352, height=288 ! identity"); } sourcebin = diff --git a/tests/examples/gtk/fxtest/pixbufdrop.c b/tests/examples/gtk/fxtest/pixbufdrop.c index d9a951228c..d68fde1fb8 100644 --- a/tests/examples/gtk/fxtest/pixbufdrop.c +++ b/tests/examples/gtk/fxtest/pixbufdrop.c @@ -18,6 +18,8 @@ * Boston, MA 02111-1307, USA. */ +#define GLIB_DISABLE_DEPRECATION_WARNINGS + #include #include #include @@ -25,7 +27,7 @@ #include "../gstgtk.h" -#include +#include static gint delay = 0; static gint saveddelay = 0; @@ -42,15 +44,15 @@ typedef struct _SourceData SourceData; static GstBusSyncReply create_window (GstBus * bus, GstMessage * message, GtkWidget * widget) { - // ignore anything but 'prepare-xwindow-id' element messages + // ignore anything but 'prepare-window-handle' element messages if (GST_MESSAGE_TYPE (message) != GST_MESSAGE_ELEMENT) return GST_BUS_PASS; - if (!gst_structure_has_name (message->structure, "prepare-xwindow-id")) + if (!gst_is_video_overlay_prepare_window_handle_message (message)) return GST_BUS_PASS; - gst_x_overlay_set_gtk_window (GST_X_OVERLAY (GST_MESSAGE_SRC (message)), - widget); + gst_video_overlay_set_gtk_window (GST_VIDEO_OVERLAY (GST_MESSAGE_SRC + (message)), widget); gst_message_unref (message); @@ -80,7 +82,7 @@ realize_cb (GtkWidget * widget, GstElement * pipeline) static gboolean expose_cb (GtkWidget * widget, GdkEventExpose * event, GstElement * videosink) { - gst_x_overlay_expose (GST_X_OVERLAY (videosink)); + gst_video_overlay_expose (GST_VIDEO_OVERLAY (videosink)); return FALSE; } @@ -230,7 +232,7 @@ main (gint argc, gchar * argv[]) if (source_desc == NULL) { source_desc = g_strdup - ("videotestsrc ! video/x-raw-rgb, width=352, height=288 ! identity"); + ("videotestsrc ! video/x-raw, width=352, height=288 ! identity"); } sourcebin = diff --git a/tests/examples/gtk/gstgtk.c b/tests/examples/gtk/gstgtk.c index 7ee2461b2f..069d8e00b9 100644 --- a/tests/examples/gtk/gstgtk.c +++ b/tests/examples/gtk/gstgtk.c @@ -32,17 +32,18 @@ void -gst_x_overlay_set_gtk_window (GstXOverlay * xoverlay, GtkWidget * window) +gst_video_overlay_set_gtk_window (GstVideoOverlay * videooverlay, + GtkWidget * window) { #if defined(GDK_WINDOWING_WIN32) - gst_x_overlay_set_window_handle (xoverlay, + gst_video_overlay_set_window_handle (videooverlay, (gulong) GDK_WINDOW_HWND (window->window)); #elif defined(GDK_WINDOWING_QUARTZ) - gst_x_overlay_set_window_handle (xoverlay, + gst_video_overlay_set_window_handle (videooverlay, (gulong) gdk_quartz_window_get_nswindow (window->window)); #elif defined(GDK_WINDOWING_X11) - gst_x_overlay_set_window_handle (xoverlay, + gst_video_overlay_set_window_handle (videooverlay, GDK_WINDOW_XWINDOW (window->window)); #else #error unimplemented GTK backend diff --git a/tests/examples/sdl/sdlshare.c b/tests/examples/sdl/sdlshare.c index 8f3064f2ec..872fa3351c 100644 --- a/tests/examples/sdl/sdlshare.c +++ b/tests/examples/sdl/sdlshare.c @@ -293,7 +293,7 @@ main (int argc, char **argv) pipeline = GST_PIPELINE (gst_parse_launch - ("videotestsrc ! video/x-raw-yuv, width=320, height=240, framerate=(fraction)30/1 ! " + ("videotestsrc ! video/x-raw, width=320, height=240, framerate=(fraction)30/1 ! " "glupload ! gleffects effect=5 ! fakesink sync=1", NULL)); bus = gst_pipeline_get_bus (GST_PIPELINE (pipeline));