summaryrefslogtreecommitdiff
path: root/gst-libs/gst
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian.droege@collabora.co.uk>2011-11-28 19:29:13 +0100
committerSebastian Dröge <sebastian.droege@collabora.co.uk>2011-11-29 12:18:19 +0100
commit209ea84ef4c8127b48f6fafe1e554d1a4d219b66 (patch)
tree279f42f794db105a4bc3e43ba5cb7d17ebef4eef /gst-libs/gst
parent54cb226009a09c5b10a085c8c19ea9a3f07cdfb3 (diff)
downloadgstreamer-plugins-bad-209ea84ef4c8127b48f6fafe1e554d1a4d219b66.tar.gz
basevideoencoder: Don't push an upstream force-keyunit event downstream
Diffstat (limited to 'gst-libs/gst')
-rw-r--r--gst-libs/gst/video/gstbasevideoencoder.c20
-rw-r--r--gst-libs/gst/video/gstbasevideoencoder.h1
2 files changed, 2 insertions, 19 deletions
diff --git a/gst-libs/gst/video/gstbasevideoencoder.c b/gst-libs/gst/video/gstbasevideoencoder.c
index 6f0932713..d36f7a964 100644
--- a/gst-libs/gst/video/gstbasevideoencoder.c
+++ b/gst-libs/gst/video/gstbasevideoencoder.c
@@ -184,10 +184,6 @@ gst_base_video_encoder_reset (GstBaseVideoEncoder * base_video_encoder)
base_video_encoder->min_latency = 0;
base_video_encoder->max_latency = 0;
- if (base_video_encoder->force_keyunit_event) {
- gst_event_unref (base_video_encoder->force_keyunit_event);
- base_video_encoder->force_keyunit_event = NULL;
- }
gst_buffer_replace (&base_video_encoder->headers, NULL);
g_list_foreach (base_video_encoder->current_frame_events,
@@ -534,9 +530,6 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
&base_video_encoder->force_keyframe_headers))
base_video_encoder->force_keyframe_headers = FALSE;
- if (base_video_encoder->force_keyunit_event)
- gst_event_unref (base_video_encoder->force_keyunit_event);
- base_video_encoder->force_keyunit_event = gst_event_copy (event);
GST_DEBUG_OBJECT (base_video_encoder, "GstForceKeyUnit, all-headers %d",
base_video_encoder->force_keyframe_headers);
GST_OBJECT_UNLOCK (base_video_encoder);
@@ -919,17 +912,8 @@ gst_base_video_encoder_finish_frame (GstBaseVideoEncoder * base_video_encoder,
(base_video_encoder)->segment, GST_FORMAT_TIME,
frame->presentation_timestamp);
- /* re-use upstream event if any so it also conveys any additional
- * info upstream arranged in there */
- GST_OBJECT_LOCK (base_video_encoder);
- if (base_video_encoder->force_keyunit_event) {
- ev = base_video_encoder->force_keyunit_event;
- base_video_encoder->force_keyunit_event = NULL;
- } else {
- ev = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM,
- gst_structure_new ("GstForceKeyUnit", NULL));
- }
- GST_OBJECT_UNLOCK (base_video_encoder);
+ ev = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM,
+ gst_structure_new ("GstForceKeyUnit", NULL));
gst_structure_set (ev->structure,
"timestamp", G_TYPE_UINT64, frame->presentation_timestamp,
diff --git a/gst-libs/gst/video/gstbasevideoencoder.h b/gst-libs/gst/video/gstbasevideoencoder.h
index 951863f44..d8d578ef6 100644
--- a/gst-libs/gst/video/gstbasevideoencoder.h
+++ b/gst-libs/gst/video/gstbasevideoencoder.h
@@ -95,7 +95,6 @@ struct _GstBaseVideoEncoder
gint64 min_latency;
gint64 max_latency;
- GstEvent *force_keyunit_event;
GList *current_frame_events;
GstBuffer *headers;