return ret;
}
-static GstFlowReturn
-gst_matroska_demux_parse_metadata_id_tag (GstMatroskaDemux * demux,
- GstEbmlRead * ebml, GstTagList ** p_taglist)
-{
- guint32 id;
- GstFlowReturn ret;
-
- DEBUG_ELEMENT_START (demux, ebml, "Tag");
-
- if ((ret = gst_ebml_read_master (ebml, &id)) != GST_FLOW_OK) {
- DEBUG_ELEMENT_STOP (demux, ebml, "Tag", ret);
- return ret;
- }
-
- while (ret == GST_FLOW_OK && gst_ebml_read_has_remaining (ebml, 1, TRUE)) {
- /* read all sub-entries */
-
- if ((ret = gst_ebml_peek_id (ebml, &id)) != GST_FLOW_OK)
- break;
-
- switch (id) {
- case GST_MATROSKA_ID_SIMPLETAG:
- ret =
- gst_matroska_read_common_parse_metadata_id_simple_tag
- (&demux->common, ebml, p_taglist);
- break;
-
- default:
- ret = gst_matroska_read_common_parse_skip (&demux->common, ebml,
- "Tag", id);
- break;
- }
- }
-
- DEBUG_ELEMENT_STOP (demux, ebml, "Tag", ret);
-
- return ret;
-}
-
static GstFlowReturn
gst_matroska_demux_parse_metadata (GstMatroskaDemux * demux, GstEbmlRead * ebml)
{
switch (id) {
case GST_MATROSKA_ID_TAG:
- ret = gst_matroska_demux_parse_metadata_id_tag (demux, ebml, &taglist);
+ ret = gst_matroska_read_common_parse_metadata_id_tag (&demux->common,
+ ebml, &taglist);
break;
default:
return ret;
}
-static GstFlowReturn
-gst_matroska_parse_parse_metadata_id_tag (GstMatroskaParse * parse,
- GstEbmlRead * ebml, GstTagList ** p_taglist)
-{
- guint32 id;
- GstFlowReturn ret;
-
- DEBUG_ELEMENT_START (parse, ebml, "Tag");
-
- if ((ret = gst_ebml_read_master (ebml, &id)) != GST_FLOW_OK) {
- DEBUG_ELEMENT_STOP (parse, ebml, "Tag", ret);
- return ret;
- }
-
- while (ret == GST_FLOW_OK && gst_ebml_read_has_remaining (ebml, 1, TRUE)) {
- /* read all sub-entries */
-
- if ((ret = gst_ebml_peek_id (ebml, &id)) != GST_FLOW_OK)
- break;
-
- switch (id) {
- case GST_MATROSKA_ID_SIMPLETAG:
- ret =
- gst_matroska_read_common_parse_metadata_id_simple_tag
- (&parse->common, ebml, p_taglist);
- break;
-
- default:
- ret = gst_matroska_read_common_parse_skip (&parse->common, ebml,
- "Tag", id);
- break;
- }
- }
-
- DEBUG_ELEMENT_STOP (parse, ebml, "Tag", ret);
-
- return ret;
-}
-
static GstFlowReturn
gst_matroska_parse_parse_metadata (GstMatroskaParse * parse, GstEbmlRead * ebml)
{
switch (id) {
case GST_MATROSKA_ID_TAG:
- ret = gst_matroska_parse_parse_metadata_id_tag (parse, ebml, &taglist);
+ ret = gst_matroska_read_common_parse_metadata_id_tag (&parse->common,
+ ebml, &taglist);
break;
default:
return ret;
}
-GstFlowReturn
+static GstFlowReturn
gst_matroska_read_common_parse_metadata_id_simple_tag (GstMatroskaReadCommon *
common, GstEbmlRead * ebml, GstTagList ** p_taglist)
{
return ret;
}
+GstFlowReturn
+gst_matroska_read_common_parse_metadata_id_tag (GstMatroskaReadCommon * common,
+ GstEbmlRead * ebml, GstTagList ** p_taglist)
+{
+ guint32 id;
+ GstFlowReturn ret;
+
+ DEBUG_ELEMENT_START (common, ebml, "Tag");
+
+ if ((ret = gst_ebml_read_master (ebml, &id)) != GST_FLOW_OK) {
+ DEBUG_ELEMENT_STOP (common, ebml, "Tag", ret);
+ return ret;
+ }
+
+ while (ret == GST_FLOW_OK && gst_ebml_read_has_remaining (ebml, 1, TRUE)) {
+ /* read all sub-entries */
+
+ if ((ret = gst_ebml_peek_id (ebml, &id)) != GST_FLOW_OK)
+ break;
+
+ switch (id) {
+ case GST_MATROSKA_ID_SIMPLETAG:
+ ret = gst_matroska_read_common_parse_metadata_id_simple_tag (common,
+ ebml, p_taglist);
+ break;
+
+ default:
+ ret = gst_matroska_read_common_parse_skip (common, ebml, "Tag", id);
+ break;
+ }
+ }
+
+ DEBUG_ELEMENT_STOP (common, ebml, "Tag", ret);
+
+ return ret;
+}
+
static const guint8 *
gst_matroska_read_common_peek_adapter (GstMatroskaReadCommon * common, guint
peek)
common, GstEbmlRead * ebml);
GstFlowReturn gst_matroska_read_common_parse_header (GstMatroskaReadCommon *
common, GstEbmlRead * ebml);
-GstFlowReturn gst_matroska_read_common_parse_metadata_id_simple_tag (
+GstFlowReturn gst_matroska_read_common_parse_metadata_id_tag (
GstMatroskaReadCommon * common, GstEbmlRead * ebml, GstTagList **
p_taglist);
GstFlowReturn gst_matroska_read_common_parse_skip (GstMatroskaReadCommon *