Browse Source

dashenc: replace attribute id with contentType for the AdaptationSet element

id should be an integer, not a string. It is also optional, so use
contentType instead which is the proper attribute for these values.

This fixes an MPD validation error.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
tags/n2.7
James Almer Martin Storsjö 10 years ago
parent
commit
ac1a1cb948
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      libavformat/dashenc.c

+ 2
- 2
libavformat/dashenc.c View File

@@ -503,7 +503,7 @@ static int write_manifest(AVFormatContext *s, int final)
}

if (c->has_video) {
avio_printf(out, "\t\t<AdaptationSet id=\"video\" segmentAlignment=\"true\" bitstreamSwitching=\"true\">\n");
avio_printf(out, "\t\t<AdaptationSet contentType=\"video\" segmentAlignment=\"true\" bitstreamSwitching=\"true\">\n");
for (i = 0; i < s->nb_streams; i++) {
AVStream *st = s->streams[i];
OutputStream *os = &c->streams[i];
@@ -516,7 +516,7 @@ static int write_manifest(AVFormatContext *s, int final)
avio_printf(out, "\t\t</AdaptationSet>\n");
}
if (c->has_audio) {
avio_printf(out, "\t\t<AdaptationSet id=\"audio\" segmentAlignment=\"true\" bitstreamSwitching=\"true\">\n");
avio_printf(out, "\t\t<AdaptationSet contentType=\"audio\" segmentAlignment=\"true\" bitstreamSwitching=\"true\">\n");
for (i = 0; i < s->nb_streams; i++) {
AVStream *st = s->streams[i];
OutputStream *os = &c->streams[i];


Loading…
Cancel
Save