mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-14 03:54:11 +00:00
ext/lame/gstlame.*: Added new media support to lame
Original commit message from CVS: 2004-08-26 Zaheer Abbas Merali <zaheerabbas at merali dot org> * ext/lame/gstlame.c: (gst_lame_init), (gst_lame_chain): * ext/lame/gstlame.h: Added new media support to lame
This commit is contained in:
parent
e160c96393
commit
a05b0279c2
3 changed files with 25 additions and 0 deletions
|
@ -1,3 +1,9 @@
|
|||
2004-08-26 Zaheer Abbas Merali <zaheerabbas at merali dot org>
|
||||
|
||||
* ext/lame/gstlame.c: (gst_lame_init), (gst_lame_chain):
|
||||
* ext/lame/gstlame.h:
|
||||
Added new media support to lame
|
||||
|
||||
2004-08-25 Arwed v. Merkatz <v.merkatz@gmx.net>
|
||||
|
||||
* gst/matroska/matroska-demux.c: (gst_matroska_demux_parse_blockgroup),
|
||||
|
|
|
@ -581,6 +581,7 @@ gst_lame_init (GstLame * lame)
|
|||
|
||||
id3tag_init (lame->lgf);
|
||||
|
||||
lame->newmediacount = 0;
|
||||
GST_DEBUG_OBJECT (lame, "done initializing");
|
||||
}
|
||||
|
||||
|
@ -950,6 +951,21 @@ gst_lame_chain (GstPad * pad, GstData * _data)
|
|||
g_assert_not_reached ();
|
||||
}
|
||||
gst_pad_event_default (pad, GST_EVENT (buf));
|
||||
break;
|
||||
case GST_EVENT_DISCONTINUOUS:
|
||||
if (GST_EVENT_DISCONT_NEW_MEDIA (GST_EVENT (buf))) {
|
||||
/* do not re-initialise if it is first new media discont */
|
||||
if (lame->newmediacount++ > 0) {
|
||||
lame_close (lame->lgf);
|
||||
lame->lgf = lame_init ();
|
||||
lame->initialized = FALSE;
|
||||
lame->last_ts = GST_CLOCK_TIME_NONE;
|
||||
|
||||
gst_lame_setup (lame);
|
||||
}
|
||||
}
|
||||
gst_pad_event_default (pad, GST_EVENT (buf));
|
||||
|
||||
break;
|
||||
default:
|
||||
gst_pad_event_default (pad, GST_EVENT (buf));
|
||||
|
|
|
@ -100,6 +100,9 @@ struct _GstLame {
|
|||
|
||||
/* time tracker */
|
||||
guint64 last_ts, last_offs, last_duration;
|
||||
|
||||
/* new media count */
|
||||
gint16 newmediacount;
|
||||
};
|
||||
|
||||
struct _GstLameClass {
|
||||
|
|
Loading…
Reference in a new issue