Browse code

dashenc: move UTCTiming element to the end of the manifest

Required by comformance XSD [1].

[1] https://github.com/Dash-Industry-Forum/Conformance-and-reference-source/blob/master/conformance/MPDValidator/schemas/DASH-MPD.xsd

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>

Peter Große authored on 2017/10/28 04:18:47
Showing 1 changed files
... ...
@@ -627,8 +627,6 @@ static int write_manifest(AVFormatContext *s, int final)
627 627
         av_free(escaped);
628 628
     }
629 629
     avio_printf(out, "\t</ProgramInformation>\n");
630
-    if (c->utc_timing_url)
631
-        avio_printf(out, "\t<UTCTiming schemeIdUri=\"urn:mpeg:dash:utc:http-xsdate:2014\" value=\"%s\"/>\n", c->utc_timing_url);
632 630
 
633 631
     if (c->window_size && s->nb_streams > 0 && c->streams[0].nb_segments > 0 && !c->use_template) {
634 632
         OutputStream *os = &c->streams[0];
... ...
@@ -646,6 +644,10 @@ static int write_manifest(AVFormatContext *s, int final)
646 646
             return ret;
647 647
     }
648 648
     avio_printf(out, "\t</Period>\n");
649
+
650
+    if (c->utc_timing_url)
651
+        avio_printf(out, "\t<UTCTiming schemeIdUri=\"urn:mpeg:dash:utc:http-xsdate:2014\" value=\"%s\"/>\n", c->utc_timing_url);
652
+
649 653
     avio_printf(out, "</MPD>\n");
650 654
     avio_flush(out);
651 655
     ff_format_io_close(s, &out);