From de514c63d1c07110ddf57f28c9a43115530c85e5 Mon Sep 17 00:00:00 2001 From: Mark Nauwelaerts Date: Wed, 8 Jun 2011 18:22:36 +0200 Subject: [PATCH] filesrc/fdsrc: indicate dynamic size handling to basesrc --- plugins/elements/gstfdsrc.c | 3 +++ plugins/elements/gstfilesrc.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/plugins/elements/gstfdsrc.c b/plugins/elements/gstfdsrc.c index 6d7f0f9..3d38c6c 100644 --- a/plugins/elements/gstfdsrc.c +++ b/plugins/elements/gstfdsrc.c @@ -275,6 +275,8 @@ gst_fd_src_update_fd (GstFdSrc * src, guint64 size) GST_INFO_OBJECT (src, "marking fd %d as seekable", src->fd); src->seekable_fd = TRUE; + + gst_base_src_set_dynamic_size (GST_BASE_SRC (src), TRUE); } return; @@ -282,6 +284,7 @@ not_seekable: { GST_INFO_OBJECT (src, "marking fd %d as NOT seekable", src->fd); src->seekable_fd = FALSE; + gst_base_src_set_dynamic_size (GST_BASE_SRC (src), FALSE); } } diff --git a/plugins/elements/gstfilesrc.c b/plugins/elements/gstfilesrc.c index cc07a72..f8dbfe2 100644 --- a/plugins/elements/gstfilesrc.c +++ b/plugins/elements/gstfilesrc.c @@ -1019,6 +1019,8 @@ gst_file_src_start (GstBaseSrc * basesrc) * don't know their length, so seeking isn't useful/meaningful */ src->seekable = src->seekable && src->is_regular; + gst_base_src_set_dynamic_size (basesrc, src->seekable); + return TRUE; /* ERROR */ -- 2.7.4