Commit 8da7fc7d by aquilescanta Committed by kim-vde

Fix chunkless preparation for playlists with dangling EXT-X-MEDIA tags

We are not able to associate a codecs attribute to an EXT-X-MEDIA tag if
there is no variant with a matching AUDIO GROUP-ID. Lack of codecs string
prevents chunkless preparation from determining the track type.

Issue: #7678
PiperOrigin-RevId: 324822415
parent 0670782d
......@@ -459,12 +459,12 @@ public final class HlsPlaylistParser implements ParsingLoadable.Parser<HlsPlayli
}
}
formatBuilder.setSampleMimeType(sampleMimeType);
if (uri == null) {
// TODO: Remove muxedAudioFormat and add a Rendition with a null uri to audios.
muxedAudioFormat = formatBuilder.build();
} else {
if (uri != null) {
formatBuilder.setMetadata(metadata);
audios.add(new Rendition(uri, formatBuilder.build(), groupId, name));
} else if (variant != null) {
// TODO: Remove muxedAudioFormat and add a Rendition with a null uri to audios.
muxedAudioFormat = formatBuilder.build();
}
break;
case TYPE_SUBTITLES:
......
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 sign in to comment