grafov / m3u8

Parser and generator of M3U8-playlists for Apple HLS. Library for Go language. :cinema:
http://tools.ietf.org/html/draft-pantos-http-live-streaming
BSD 3-Clause "New" or "Revised" License
1.22k stars 312 forks source link

thought of how to address "alternatives" to fix inconsistency #192

Open sjpotter opened 1 year ago

sjpotter commented 1 year ago

currently, what m3u8 package calls alternatives seem to be handled inconsistently. Namely, only the first "variant" after the set of alternatives gets the alternative and if the altneratives are at the end of the file, none get them.

sjpotter commented 1 year ago

the breaks somethings (i.e. is not complete), but is pushed as a POC in terms of perhaps a better API.

With that said, even with that, I'm not sure how it should work with multiple groups of alternatives, I'm not sure it matters so much (the end user can figure it out via group tag), but the current code doesn't work for real life cases at the moment either.