# HG changeset patch # User renatofilho # Date 1165238497 0 # Node ID d9628018e9f7157d11a116af8a768d1ee5240e4b # Parent 60033c7d3babe241c109586d517c7b6968d1ad2a [svn r182] diff -r 60033c7d3bab -r d9628018e9f7 gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c --- a/gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c Sat Dec 02 04:23:43 2006 +0000 +++ b/gst-plugins-nuvdemux/nuvdemux/gstnuvdemux.c Mon Dec 04 13:21:37 2006 +0000 @@ -264,8 +264,10 @@ static void gst_nuv_demux_update_duration (GstNuvDemux *nuv, guint64 current_timestamp); static gint64 gst_nuv_demux_get_bytes_duration (GstNuvDemux *nuv); static gint64 gst_nuv_demux_get_time_duration (GstNuvDemux *nuv); + +#if (GST_VERSION_MINOR == 10) && (GST_VERSION_MICRO < 6) GstBuffer * gst_nuv_demux_adapter_take_buffer (GstAdapter * adapter, guint nbytes); - +#endif GST_BOILERPLATE (GstNuvDemux, gst_nuv_demux, GstElement, GST_TYPE_ELEMENT); @@ -328,6 +330,8 @@ gst_element_class_add_pad_template (element_class, gst_static_pad_template_get (&sink_template)); gst_element_class_set_details (element_class, &gst_nuv_demux_details); + + g_debug ("GST VER: %d.%d", GST_VERSION_MINOR, GST_VERSION_MAJOR); } static void @@ -1058,7 +1062,7 @@ return GST_FLOW_ERROR_NO_DATA; if (move) { - *buffer = gst_nuv_demux_adapter_take_buffer (nuv->priv->adapter, size); + *buffer = gst_adapter_take_buffer (nuv->priv->adapter, size); } else { guint8 *data = NULL; data = (guint8 *) gst_adapter_peek (nuv->priv->adapter, size); @@ -1349,8 +1353,9 @@ return nuv->priv->duration_time; } +#if (GST_VERSION_MINOR == 10) && (GST_VERSION_MICRO < 6) GstBuffer * -gst_nuv_demux_adapter_take_buffer (GstAdapter * adapter, guint nbytes) +gst_adapter_take_buffer (GstAdapter * adapter, guint nbytes) { GstBuffer *buffer; GstBuffer *cur; @@ -1390,6 +1395,7 @@ return buffer; } +#endif static gboolean