diff options
| author | Sebastian Dröge <slomo@circular-chaos.org> | 2008-08-02 17:18:47 +0000 | 
|---|---|---|
| committer | Sebastian Dröge <slomo@circular-chaos.org> | 2008-08-02 17:18:47 +0000 | 
| commit | a53866ddc1bec3ebccc13dedfaefb6a94b1d381f (patch) | |
| tree | 01d5db097854069616b828c8de42cfe6d94ac89b | |
| parent | f96e226aa828729e1e1184d5daa2ff2c759ee706 (diff) | |
ext/flac/gstflacdec.c: Always post the audio-codec tag, not only if other tags are present.
Original commit message from CVS:
* ext/flac/gstflacdec.c: (gst_flac_dec_setup_seekable_decoder),
(gst_flac_dec_setup_stream_decoder),
(gst_flac_dec_update_metadata):
Always post the audio-codec tag, not only if other tags are present.
| -rw-r--r-- | ChangeLog | 7 | ||||
| -rw-r--r-- | ext/flac/gstflacdec.c | 21 | 
2 files changed, 19 insertions, 9 deletions
| @@ -1,3 +1,10 @@ +2008-08-02  Sebastian Dröge  <sebastian.droege@collabora.co.uk> + +	* ext/flac/gstflacdec.c: (gst_flac_dec_setup_seekable_decoder), +	(gst_flac_dec_setup_stream_decoder), +	(gst_flac_dec_update_metadata): +	Always post the audio-codec tag, not only if other tags are present. +  2008-08-02  Jan Schmidt  <jan.schmidt@sun.com>  	* configure.ac: diff --git a/ext/flac/gstflacdec.c b/ext/flac/gstflacdec.c index a7149aeb9..5d65c837f 100644 --- a/ext/flac/gstflacdec.c +++ b/ext/flac/gstflacdec.c @@ -338,6 +338,10 @@ gst_flac_dec_setup_seekable_decoder (GstFlacDec * dec)  {    gst_flac_dec_reset_decoders (dec); +  dec->tags = gst_tag_list_new (); +  gst_tag_list_add (dec->tags, GST_TAG_MERGE_REPLACE, +      GST_TAG_AUDIO_CODEC, "FLAC", NULL); +  #ifdef LEGACY_FLAC    dec->seekable_decoder = FLAC__seekable_stream_decoder_new (); @@ -375,6 +379,10 @@ gst_flac_dec_setup_stream_decoder (GstFlacDec * dec)  {    gst_flac_dec_reset_decoders (dec); +  dec->tags = gst_tag_list_new (); +  gst_tag_list_add (dec->tags, GST_TAG_MERGE_REPLACE, +      GST_TAG_AUDIO_CODEC, "FLAC", NULL); +    dec->adapter = gst_adapter_new ();    dec->stream_decoder = FLAC__stream_decoder_new (); @@ -421,7 +429,10 @@ gst_flac_dec_update_metadata (GstFlacDec * flacdec,    guint num, i; -  list = gst_tag_list_new (); +  if (flacdec->tags) +    list = flacdec->tags; +  else +    flacdec->tags = list = gst_tag_list_new ();    num = metadata->data.vorbis_comment.num_comments;    GST_DEBUG ("%u tag(s) found", num); @@ -442,14 +453,6 @@ gst_flac_dec_update_metadata (GstFlacDec * flacdec,      g_free (vc);    } -  gst_tag_list_add (list, GST_TAG_MERGE_REPLACE, -      GST_TAG_AUDIO_CODEC, "FLAC", NULL); - -  if (flacdec->tags) -    gst_tag_list_free (flacdec->tags); -  flacdec->tags = list; - -    return TRUE;  } | 
