mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
avfvideosrc: Don't pretend to support reconfiguration
We will run into an assertion in set_caps() if we try to change caps while the source is already running. Don't try to find new caps in GstBaseSrc::negotiate() to prevent caps changes.
This commit is contained in:
parent
6b5e950236
commit
98b856d630
1 changed files with 13 additions and 0 deletions
|
@ -921,6 +921,7 @@ static gboolean gst_avf_video_src_unlock (GstBaseSrc * basesrc);
|
||||||
static gboolean gst_avf_video_src_unlock_stop (GstBaseSrc * basesrc);
|
static gboolean gst_avf_video_src_unlock_stop (GstBaseSrc * basesrc);
|
||||||
static GstFlowReturn gst_avf_video_src_create (GstPushSrc * pushsrc,
|
static GstFlowReturn gst_avf_video_src_create (GstPushSrc * pushsrc,
|
||||||
GstBuffer ** buf);
|
GstBuffer ** buf);
|
||||||
|
static gboolean gst_avf_video_src_negotiate (GstBaseSrc * basesrc);
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -945,6 +946,7 @@ gst_avf_video_src_class_init (GstAVFVideoSrcClass * klass)
|
||||||
gstbasesrc_class->unlock = gst_avf_video_src_unlock;
|
gstbasesrc_class->unlock = gst_avf_video_src_unlock;
|
||||||
gstbasesrc_class->unlock_stop = gst_avf_video_src_unlock_stop;
|
gstbasesrc_class->unlock_stop = gst_avf_video_src_unlock_stop;
|
||||||
gstbasesrc_class->decide_allocation = gst_avf_video_src_decide_allocation;
|
gstbasesrc_class->decide_allocation = gst_avf_video_src_decide_allocation;
|
||||||
|
gstbasesrc_class->negotiate = gst_avf_video_src_negotiate;
|
||||||
|
|
||||||
gstpushsrc_class->create = gst_avf_video_src_create;
|
gstpushsrc_class->create = gst_avf_video_src_create;
|
||||||
|
|
||||||
|
@ -1198,3 +1200,14 @@ gst_avf_video_src_create (GstPushSrc * pushsrc, GstBuffer ** buf)
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
gst_avf_video_src_negotiate (GstBaseSrc * basesrc)
|
||||||
|
{
|
||||||
|
/* FIXME: We don't support reconfiguration yet */
|
||||||
|
if (gst_pad_has_current_caps (GST_BASE_SRC_PAD (basesrc)))
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
|
return GST_BASE_SRC_CLASS (parent_class)->negotiate (basesrc);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue