Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues related to iframe playlist and bytes ranges #46

Closed
AyliD opened this issue May 2, 2016 · 4 comments · Fixed by #51
Closed

Issues related to iframe playlist and bytes ranges #46

AyliD opened this issue May 2, 2016 · 4 comments · Fixed by #51
Assignees
Labels

Comments

@AyliD
Copy link

AyliD commented May 2, 2016

In Reader.Go:
in the following line:
case !state.tagIframeStreamInf && strings.HasPrefix(line, "#EXT-X-I-FRAME-STREAM-INF:"):
you use only the first iframe manifest found and not all.

also, the playlist iframe segments has no offset and linit due to lin "} else if state.tagRange { " in:

case !strings.HasPrefix(line, "#"):
if state.tagInf {
p.Append(line, state.duration, title)
state.tagInf = false
} else if state.tagRange {

because i have state.tagInf and state.tagRange so "else if " isnt good enough and should be:

if state.tagInf {
p.Append(line, state.duration, title)
state.tagInf = false
}
if state.tagRange {

@grafov grafov added the bug label May 2, 2016
@bradleyfalzon
Copy link
Collaborator

Thanks @AyliD can you show me the broken and working playlist? Just so I better understand the issue

@AyliD
Copy link
Author

AyliD commented May 4, 2016

The first issue:
in the master playlist i have few iframe manifests, in current code all ignored but the first.

#EXTM3U
#-----------------------------------------------------------
#--Created with VIDFX Streamer version 3.8.1.0 build 67361
#-----------------------------------------------------------
#EXT-X-VERSION:5
#EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="AACL",NAME="audio_483_und",LANGUAGE="und",AUTOSELECT=YES,DEFAULT=NO,URI="2.m3u8/Alter-audio_483_und(483)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="AACL",NAME="audio_482_und",LANGUAGE="und",AUTOSELECT=YES,DEFAULT=YES,URI="2.m3u8/Alter-audio_482_und(482)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=262144,CODECS="mp4a.40.2,avc1.4d400d",RESOLUTION=320x240,AUDIO="AACL"
2.m3u8/Level(262144)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z
#EXT-X-I-FRAME-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=42412,CODECS="avc1.4d400d",URI="2.m3u8/Iframe(262144)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=629145,CODECS="mp4a.40.2,avc1.4d4015",RESOLUTION=480x360,AUDIO="AACL"
2.m3u8/Level(629145)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z
#EXT-X-I-FRAME-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=74688,CODECS="avc1.4d4015",URI="2.m3u8/Iframe(629145)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=1363148,CODECS="mp4a.40.2,avc1.4d401e",RESOLUTION=640x480,AUDIO="AACL"
2.m3u8/Level(1363148)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z
#EXT-X-I-FRAME-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=102763,CODECS="avc1.4d401e",URI="2.m3u8/Iframe(1363148)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=2202009,CODECS="mp4a.40.2,avc1.4d401f",RESOLUTION=720x576,AUDIO="AACL"
2.m3u8/Level(2202009)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z
#EXT-X-I-FRAME-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=117825,CODECS="avc1.4d401f",URI="2.m3u8/Iframe(2202009)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=3670016,CODECS="mp4a.40.2,avc1.4d4020",RESOLUTION=1280x720,AUDIO="AACL"
2.m3u8/Level(3670016)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z
#EXT-X-I-FRAME-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=184144,CODECS="avc1.4d4020",URI="2.m3u8/Iframe(3670016)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z"
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=32000,CODECS="mp4a.40.2",AUDIO="AACL"
2.m3u8/Level(482)?start=2016-05-04T08%3A49%3A30Z&end=2016-05-04T08%3A59%3A30Z

For Second issue, this is the manifest (the begining of it), but i have byte ranges and duration to each segment:

#EXTM3U
#-----------------------------------------------------------
#--Created with VIDFX Streamer version 3.8.1.0 build 67361
#-----------------------------------------------------------
#EXT-X-VERSION:5
#EXT-X-TARGETDURATION:2
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-PLAYLIST-TYPE:VOD
#EXT-X-I-FRAMES-ONLY
#EXT-X-MAP:URI="Iframe(3670016)/ISeg(0).ts",BYTERANGE="376@188"
#EXTINF:2,
#EXT-X-BYTERANGE:40232@256075928
Iframe(3670016)/Seg(0).ts
#EXTINF:2,
#EXT-X-BYTERANGE:35344@256798036
Iframe(3670016)/Seg(0).ts
#EXTINF:2,
#EXT-X-BYTERANGE:45496@257707392
Iframe(3670016)/Seg(0).ts
#EXTINF:2,
#EXT-X-BYTERANGE:31208@258626336
Iframe(3670016)/Seg(0).ts
#EXTINF:2,
#EXT-X-BYTERANGE:141376@259522532
Iframe(3670016)/Seg(0).ts
#EXTINF:2,

@bradleyfalzon
Copy link
Collaborator

See #50 for your first issue.

@bradleyfalzon
Copy link
Collaborator

See #51 for your second issue.

@grafov grafov removed the in progress label May 5, 2016
bradleyfalzon added a commit that referenced this issue May 5, 2016
decodeLineOfMasterPlaylist is process a I-Frame line expecting the
URI to be located on the next line, however, the
EXT-X-I-FRAME-STREAM-INF attribute contains the URI as a tag (unlike
EXT-X-STREAM-INF.

This changes produces a test which reproduces the issue and also
removes the state tracking for this attribute as it's not required.
grafov pushed a commit that referenced this issue Nov 22, 2016
decodeLineOfMasterPlaylist is process a I-Frame line expecting the
URI to be located on the next line, however, the
EXT-X-I-FRAME-STREAM-INF attribute contains the URI as a tag (unlike
EXT-X-STREAM-INF.

This changes produces a test which reproduces the issue and also
removes the state tracking for this attribute as it's not required.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants