ext, gst: only activate in pull mode if upstream is seekable
authorMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
Tue, 11 Sep 2012 15:36:51 +0000 (17:36 +0200)
committerMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
Tue, 11 Sep 2012 15:44:51 +0000 (17:44 +0200)
ext/dv/gstdvdemux.c
gst/avi/gstavidemux.c
gst/debugutils/rndbuffersize.c
gst/flv/gstflvdemux.c
gst/isomp4/qtdemux.c
gst/matroska/matroska-demux.c
gst/wavparse/gstwavparse.c

index c6e0bf1..15ad1d9 100644 (file)
@@ -1804,7 +1804,8 @@ gst_dvdemux_sink_activate (GstPad * sinkpad, GstObject * parent)
     goto activate_push;
   }
 
-  pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+  pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+      GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   gst_query_unref (query);
 
   if (!pull_mode)
index 6786bf8..7cd1a0e 100644 (file)
@@ -5415,7 +5415,8 @@ gst_avi_demux_sink_activate (GstPad * sinkpad, GstObject * parent)
     goto activate_push;
   }
 
-  pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+  pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+      GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   gst_query_unref (query);
 
   if (!pull_mode)
index 243b1c7..68a2705 100644 (file)
@@ -237,7 +237,8 @@ gst_rnd_buffer_size_activate (GstPad * pad, GstObject * parent)
   query = gst_query_new_scheduling ();
 
   if (gst_pad_peer_query (pad, query))
-    pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+    pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+        GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   else
     pull_mode = FALSE;
 
index 74ff1b7..30a3254 100644 (file)
@@ -2875,7 +2875,8 @@ gst_flv_demux_sink_activate (GstPad * sinkpad, GstObject * parent)
     goto activate_push;
   }
 
-  pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+  pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+      GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   gst_query_unref (query);
 
   if (!pull_mode)
index 1b316ad..afff96e 100644 (file)
@@ -4496,7 +4496,8 @@ qtdemux_sink_activate (GstPad * sinkpad, GstObject * parent)
     goto activate_push;
   }
 
-  pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+  pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+      GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   gst_query_unref (query);
 
   if (!pull_mode)
index 819c97f..fff354b 100644 (file)
@@ -4848,7 +4848,8 @@ gst_matroska_demux_sink_activate (GstPad * sinkpad, GstObject * parent)
   query = gst_query_new_scheduling ();
 
   if (gst_pad_peer_query (sinkpad, query))
-    pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+    pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+        GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
 
   gst_query_unref (query);
 
index 82dbc05..7304387 100644 (file)
@@ -2923,7 +2923,8 @@ gst_wavparse_sink_activate (GstPad * sinkpad, GstObject * parent)
     goto activate_push;
   }
 
-  pull_mode = gst_query_has_scheduling_mode (query, GST_PAD_MODE_PULL);
+  pull_mode = gst_query_has_scheduling_mode_with_flags (query,
+      GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
   gst_query_unref (query);
 
   if (!pull_mode)