summaryrefslogtreecommitdiffstats
path: root/ext/mpeg2enc/gstmpeg2enc.cc
diff options
context:
space:
mode:
authorRonald S. Bultje <rbultje@ronald.bitfreak.net>2004-01-16 14:14:58 +0000
committerRonald S. Bultje <rbultje@ronald.bitfreak.net>2004-01-16 14:14:58 +0000
commit0afd3d77334fac3654fa433abf3dab611ea95493 (patch)
tree4eceb4609c92648309858682a669c7fddd5682ab /ext/mpeg2enc/gstmpeg2enc.cc
parenta9904a33bcd273aebd3000c793c2da51ed48d31a (diff)
downloadgst-plugins-bad-0afd3d77334fac3654fa433abf3dab611ea95493.tar.gz
gst-plugins-bad-0afd3d77334fac3654fa433abf3dab611ea95493.tar.bz2
gst-plugins-bad-0afd3d77334fac3654fa433abf3dab611ea95493.zip
ext/mpeg2enc/: Bugfix with respect to EOS handling.
Original commit message from CVS: 2004-01-16 Ronald Bultje <rbultje@ronald.bitfreak.net> * ext/mpeg2enc/Makefile.am: * ext/mpeg2enc/gstmpeg2enc.cc: * ext/mpeg2enc/gstmpeg2encpicturereader.cc: Bugfix with respect to EOS handling.
Diffstat (limited to 'ext/mpeg2enc/gstmpeg2enc.cc')
-rw-r--r--ext/mpeg2enc/gstmpeg2enc.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/mpeg2enc/gstmpeg2enc.cc b/ext/mpeg2enc/gstmpeg2enc.cc
index 902497ab..e3af35bb 100644
--- a/ext/mpeg2enc/gstmpeg2enc.cc
+++ b/ext/mpeg2enc/gstmpeg2enc.cc
@@ -205,6 +205,8 @@ gst_mpeg2enc_init (GstMpeg2enc *enc)
GstElement *element = GST_ELEMENT (enc);
GstElementClass *klass = GST_ELEMENT_GET_CLASS (element);
+ GST_FLAG_SET (element, GST_ELEMENT_EVENT_AWARE);
+
enc->sinkpad = gst_pad_new_from_template (
gst_element_class_get_pad_template (klass, "sink"), "sink");
gst_pad_set_link_function (enc->sinkpad, gst_mpeg2enc_sink_link);
@@ -258,6 +260,7 @@ gst_mpeg2enc_loop (GstElement *element)
}
enc->encoder->encodePicture ();
+ gst_pad_event_default (enc->sinkpad, gst_event_new (GST_EVENT_EOS));
}
static GstPadLinkReturn