Open aapcuk opened 6 years ago
I think the solution is simply changing the containsAttribute() for Constants.FORCED in MasterPlaylistTagWriter.java:
HANDLERS.put(Constants.FORCED, new AttributeWriter<MediaData>() {
@Override
public boolean containsAttribute(MediaData mediaData) {
return mediaData.getType() == MediaType.SUBTITLES;
}
// ...
});
(I couldn't yet made a pull request, I'm new here.)
According to the HLS specification, also linked in the documentation, the FORCED attribute should only be present with subtitles: "The FORCED attribute MUST NOT be present unless the TYPE is SUBTITLES." https://tools.ietf.org/html/draft-pantos-http-live-streaming-16
However, when writing an m3u8 file, it is present with audio as well:
EXT-X-MEDIA:LANGUAGE="eng",AUTOSELECT=YES,FORCED=NO,TYPE=AUDIO,URI="...",GROUP-ID="audio_aac",DEFAULT=YES,NAME="eng"
Version: 0.2.6