update for probe api changes

This commit is contained in:
Wim Taymans 2011-11-08 11:28:41 +01:00
parent 3f8af6f511
commit 95cd0b3ba8
4 changed files with 17 additions and 21 deletions

View file

@ -100,7 +100,7 @@ static void dvb_base_bin_dispose (GObject * object);
static void dvb_base_bin_finalize (GObject * object);
static GstPadProbeReturn dvb_base_bin_ts_pad_probe_cb (GstPad * pad,
GstPadProbeType type, gpointer data, gpointer user_data);
GstPadProbeInfo * info, gpointer user_data);
static GstStateChangeReturn dvb_base_bin_change_state (GstElement * element,
GstStateChange transition);
static void dvb_base_bin_handle_message (GstBin * bin, GstMessage * message);
@ -528,8 +528,8 @@ dvb_base_bin_reset_pmtlist (DvbBaseBin * dvbbasebin)
}
static GstPadProbeReturn
dvb_base_bin_ts_pad_probe_cb (GstPad * pad, GstPadProbeType type,
gpointer data, gpointer user_data)
dvb_base_bin_ts_pad_probe_cb (GstPad * pad, GstPadProbeInfo * info,
gpointer user_data)
{
DvbBaseBin *dvbbasebin = GST_DVB_BASE_BIN (user_data);

View file

@ -179,8 +179,7 @@ static gboolean setup_add_pad_probe (GstElement * elem, const gchar * pad_name,
*/
static GstPadProbeReturn
pad_has_buffer (GstPad * pad, GstPadProbeType type, gpointer type_data,
gpointer user_data)
pad_has_buffer (GstPad * pad, GstPadProbeInfo * info, gpointer user_data)
{
gboolean *signal_sink = (gboolean *) user_data;
gboolean print_and_restart = FALSE;

View file

@ -312,8 +312,8 @@ create_host_window (void)
}
static GstPadProbeReturn
camera_src_get_timestamp_probe (GstPad * pad, GstPadProbeType type,
GstMiniObject * obj, gpointer udata)
camera_src_get_timestamp_probe (GstPad * pad, GstPadProbeInfo * info,
gpointer udata)
{
CaptureTiming *timing;
@ -323,8 +323,8 @@ camera_src_get_timestamp_probe (GstPad * pad, GstPadProbeType type,
return GST_PAD_PROBE_REMOVE;
}
static gboolean
viewfinder_get_timestamp_probe (GstPad * pad, GstMiniObject * obj,
static GstPadProbeReturn
viewfinder_get_timestamp_probe (GstPad * pad, GstPadProbeInfo * info,
gpointer udata)
{
CaptureTiming *timing;
@ -332,9 +332,7 @@ viewfinder_get_timestamp_probe (GstPad * pad, GstMiniObject * obj,
timing = (CaptureTiming *) g_list_first (capture_times)->data;
timing->precapture = gst_util_get_timestamp ();
gst_pad_remove_probe (pad, viewfinder_probe_id);
return TRUE;
return GST_PAD_PROBE_REMOVE;
}
static GstBusSyncReply
@ -375,8 +373,7 @@ sync_bus_callback (GstBus * bus, GstMessage * message, gpointer data)
viewfinder_probe_id =
gst_pad_add_probe (pad, GST_PAD_PROBE_TYPE_BUFFER,
(GstPadProbeCallback) viewfinder_get_timestamp_probe, NULL,
NULL);
viewfinder_get_timestamp_probe, NULL, NULL);
gst_object_unref (pad);
}
@ -950,7 +947,7 @@ run_pipeline (gpointer user_data)
pad = gst_element_get_static_pad (video_source, "imgsrc");
camera_probe_id = gst_pad_add_probe (pad, GST_PAD_PROBE_TYPE_BUFFER,
(GstPadProbeCallback) camera_src_get_timestamp_probe, NULL, NULL);
camera_src_get_timestamp_probe, NULL, NULL);
gst_object_unref (pad);
}

View file

@ -69,9 +69,9 @@ no_pipeline (DemoPlayer * player)
}
static GstPadProbeReturn
demo_player_event_listener (GstPad * pad, GstPadProbeType type,
GstEvent * event, gpointer data)
demo_player_event_listener (GstPad * pad, GstPadProbeInfo * info, gpointer data)
{
GstEvent *event = GST_PAD_PROBE_INFO_EVENT (info);
DemoPlayer *player = DEMO_PLAYER (data);
DemoPlayerPrivate *priv = DEMO_PLAYER_GET_PRIVATE (player);
@ -175,8 +175,8 @@ demo_player_build_pipeline (DemoPlayer * player)
LINK_ELEMENTS (resample, asink);
gst_pad_add_probe (gst_element_get_static_pad (asink, "sink"),
GST_PAD_PROBE_TYPE_EVENT,
(GstPadProbeCallback) demo_player_event_listener, player, NULL);
GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM,
demo_player_event_listener, player, NULL);
ghostpad = gst_element_get_static_pad (filter, "sink");
gst_element_add_pad (audioline, gst_ghost_pad_new ("sink", ghostpad));
@ -198,8 +198,8 @@ demo_player_build_pipeline (DemoPlayer * player)
MAKE_ELEMENT (NULL, priv->scalerate_line, audiosink_name,
"scaling_audio_sink");
gst_pad_add_probe (gst_element_get_static_pad (priv->scalerate_line,
"sink"), GST_PAD_PROBE_TYPE_EVENT,
(GstPadProbeCallback) demo_player_event_listener, player, NULL);
"sink"), GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM,
demo_player_event_listener, player, NULL);
g_object_ref (priv->scaletempo_line);
g_object_ref (priv->scalerate_line);
}