summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2014-10-04 23:09:19 +0300
committerSebastian Dröge <sebastian@centricular.com>2014-10-14 09:42:27 +0200
commit2f825e1e95410f57aaa9578e45bb01a8b944f945 (patch)
tree79091131184ca9f7173d4316fef4deee9b0f392e
parentb8af6d73895a5641bef50bcd9d14eff25290b14e (diff)
videoencoder: Stop storing if we received EOS
This was never reset when going from PAUSED->READY and resulted in encoders being not reusable after EOS. They just rejected any buffer because they received EOS in their previous life. The flag wasn't used anywhere except for rejecting buffers after EOS, and this is now handled by GstPad directly.
-rw-r--r--gst-libs/gst/video/gstvideoencoder.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/gst-libs/gst/video/gstvideoencoder.c b/gst-libs/gst/video/gstvideoencoder.c
index 2f42bb44e..684f5567e 100644
--- a/gst-libs/gst/video/gstvideoencoder.c
+++ b/gst-libs/gst/video/gstvideoencoder.c
@@ -137,7 +137,6 @@ struct _GstVideoEncoderPrivate
/* FIXME : (and introduce a context ?) */
gboolean drained;
- gboolean at_eos;
gboolean do_caps;
gint64 min_latency;
@@ -454,7 +453,6 @@ gst_video_encoder_init (GstVideoEncoder * encoder, GstVideoEncoderClass * klass)
g_rec_mutex_init (&encoder->stream_lock);
- priv->at_eos = FALSE;
priv->headers = NULL;
priv->new_headers = FALSE;
@@ -991,7 +989,6 @@ gst_video_encoder_sink_event_default (GstVideoEncoder * encoder,
GstFlowReturn flow_ret;
GST_VIDEO_ENCODER_STREAM_LOCK (encoder);
- encoder->priv->at_eos = TRUE;
if (encoder_class->finish) {
flow_ret = encoder_class->finish (encoder);
@@ -1034,8 +1031,6 @@ gst_video_encoder_sink_event_default (GstVideoEncoder * encoder,
break;
}
- encoder->priv->at_eos = FALSE;
-
encoder->input_segment = segment;
ret = TRUE;
GST_VIDEO_ENCODER_STREAM_UNLOCK (encoder);
@@ -1378,11 +1373,6 @@ gst_video_encoder_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
gst_buffer_get_size (buf), GST_TIME_ARGS (pts),
GST_TIME_ARGS (GST_BUFFER_DTS (buf)), GST_TIME_ARGS (duration));
- if (priv->at_eos) {
- ret = GST_FLOW_EOS;
- goto done;
- }
-
start = pts;
if (GST_CLOCK_TIME_IS_VALID (duration))
stop = start + duration;