Commit 51a630d4 authored by Ronald S. Bultje's avatar Ronald S. Bultje
Browse files

gst/: Uncomment metadata and codec-name handling.

Original commit message from CVS:
* gst/avi/gstavidemux.c: (gst_avi_demux_parse_stream),
(gst_avi_demux_stream_header):
* gst/qtdemux/qtdemux.c: (gst_qtdemux_change_state),
(gst_qtdemux_add_stream), (qtdemux_parse_tree):
Uncomment metadata and codec-name handling.
parent b0100569
2005-08-16 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* gst/avi/gstavidemux.c: (gst_avi_demux_parse_stream),
(gst_avi_demux_stream_header):
* gst/qtdemux/qtdemux.c: (gst_qtdemux_change_state),
(gst_qtdemux_add_stream), (qtdemux_parse_tree):
Uncomment metadata and codec-name handling.
2005-08-16 Wim Taymans <wim@fluendo.com>
 
* configure.ac:
......
......@@ -1057,6 +1057,14 @@ gst_avi_demux_parse_stream (GstElement * element, GstBuffer * buf)
gst_element_add_pad (GST_ELEMENT (avi), pad);
GST_LOG_OBJECT (element, "Added pad %s", gst_pad_get_name (pad));
if (codec_name) {
GstTagList *list = gst_tag_list_new ();
gst_tag_list_add (list, GST_TAG_MERGE_APPEND, tag_name, codec_name, NULL);
gst_element_found_tags_for_pad (GST_ELEMENT (avi), pad, list);
g_free (codec_name);
}
return TRUE;
fail:
......@@ -1879,8 +1887,9 @@ gst_avi_demux_stream_header (GstAviDemux * avi)
sub = gst_buffer_create_sub (buf, 4, GST_BUFFER_SIZE (buf) - 4);
gst_riff_parse_info (GST_ELEMENT (avi), sub, &t);
if (t)
gst_tag_list_free (t);
if (t) {
gst_element_found_tags (GST_ELEMENT (avi), t);
}
gst_buffer_unref (buf);
}
/* gst_riff_read_chunk() has already advanced avi->offset */
......
......@@ -476,10 +476,6 @@ gst_qtdemux_change_state (GstElement * element)
qtdemux->last_ts = GST_CLOCK_TIME_NONE;
qtdemux->need_discont = TRUE;
qtdemux->need_flush = FALSE;
if (qtdemux->tag_list) {
gst_tag_list_free (qtdemux->tag_list);
qtdemux->tag_list = NULL;
}
for (n = 0; n < qtdemux->n_streams; n++) {
gst_element_remove_pad (element, qtdemux->streams[n]->pad);
g_free (qtdemux->streams[n]->samples);
......@@ -788,11 +784,7 @@ gst_qtdemux_add_stream (GstQTDemux * qtdemux,
gst_pad_get_name (stream->pad), stream->pad, qtdemux);
gst_element_add_pad (GST_ELEMENT (qtdemux), stream->pad);
if (list) {
gst_tag_list_free (list);
/*
gst_element_found_tags_for_pad (GST_ELEMENT (qtdemux),
stream->pad, 0, list);
*/
gst_element_found_tags_for_pad (GST_ELEMENT (qtdemux), stream->pad, list);
}
}
......@@ -1860,17 +1852,10 @@ qtdemux_parse_tree (GstQTDemux * qtdemux)
qtdemux_parse_udta (qtdemux, udta);
if (qtdemux->tag_list) {
GstEvent *event;
gchar *t;
event = gst_event_new_tag (gst_tag_list_copy (qtdemux->tag_list));
gst_pad_event_default (qtdemux->sinkpad, event);
t = gst_structure_to_string (qtdemux->tag_list);
GST_DEBUG ("calling gst_element_found_tags with %s", t);
g_free (t);
/*
GST_DEBUG ("calling gst_element_found_tags with %" GST_PTR_FORMAT,
qtdemux->tag_list);
gst_element_found_tags (GST_ELEMENT (qtdemux), qtdemux->tag_list);
*/
qtdemux->tag_list = NULL;
}
} else {
GST_LOG ("No udta node found.");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment