Seeking in M3U8 file results in 20 seconds delay or more











up vote
0
down vote

favorite












I have a list of ts files. For each ts file I have an m3u8 file. But for some ts files I don't have m3u8 files. My m3u8 file is in the below format(showing the already existed file).



This file already in my system, I don't know how it was created(may be with a command or manually)



#EXTM3U
#EXT-X-VERSION:4
#EXT-X-TARGETDURATION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3.000000,
#EXT-X-BYTERANGE:332196@0
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:352124@332196
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:92684@684320
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:195708@777004
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:178600@972712
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:204356@1151312
video.ts
......
......
......
......
#EXT-X-ENDLIST


I have created the m3u8 file for the missing files according to slhck's answer. After creation of file, it played well, but when I navigate video stops for sometime it is taking 20 sec delay. Look at the below file I created manually.



#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-ALLOW-CACHE:YES
#EXT-X-TARGETDURATION:61
#EXTINF:3600.080000,
mysecondvideo.ts
#EXT-X-ENDLIST


But when I played the above file through browser, It is not at all playing. I read the articles about m3u8. But It didn't work for me.



Please help me with creating the m3u8 file, so that I can play on the browser without any delays.



P.S: I don't want to re encode my video. I am not streaming the video live



Thanks in advance.










share|improve this question









New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • Target duration must be larger that the largest segment size. It’s documented in the specification.
    – szatmary
    Nov 14 at 16:50










  • "below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
    – slhck
    Nov 14 at 18:48












  • The title was changed to ask a completely different question.
    – szatmary
    Nov 14 at 22:32










  • @slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
    – emb-pro
    Nov 15 at 7:00










  • @slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
    – emb-pro
    Nov 15 at 7:09















up vote
0
down vote

favorite












I have a list of ts files. For each ts file I have an m3u8 file. But for some ts files I don't have m3u8 files. My m3u8 file is in the below format(showing the already existed file).



This file already in my system, I don't know how it was created(may be with a command or manually)



#EXTM3U
#EXT-X-VERSION:4
#EXT-X-TARGETDURATION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3.000000,
#EXT-X-BYTERANGE:332196@0
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:352124@332196
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:92684@684320
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:195708@777004
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:178600@972712
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:204356@1151312
video.ts
......
......
......
......
#EXT-X-ENDLIST


I have created the m3u8 file for the missing files according to slhck's answer. After creation of file, it played well, but when I navigate video stops for sometime it is taking 20 sec delay. Look at the below file I created manually.



#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-ALLOW-CACHE:YES
#EXT-X-TARGETDURATION:61
#EXTINF:3600.080000,
mysecondvideo.ts
#EXT-X-ENDLIST


But when I played the above file through browser, It is not at all playing. I read the articles about m3u8. But It didn't work for me.



Please help me with creating the m3u8 file, so that I can play on the browser without any delays.



P.S: I don't want to re encode my video. I am not streaming the video live



Thanks in advance.










share|improve this question









New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • Target duration must be larger that the largest segment size. It’s documented in the specification.
    – szatmary
    Nov 14 at 16:50










  • "below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
    – slhck
    Nov 14 at 18:48












  • The title was changed to ask a completely different question.
    – szatmary
    Nov 14 at 22:32










  • @slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
    – emb-pro
    Nov 15 at 7:00










  • @slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
    – emb-pro
    Nov 15 at 7:09













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I have a list of ts files. For each ts file I have an m3u8 file. But for some ts files I don't have m3u8 files. My m3u8 file is in the below format(showing the already existed file).



This file already in my system, I don't know how it was created(may be with a command or manually)



#EXTM3U
#EXT-X-VERSION:4
#EXT-X-TARGETDURATION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3.000000,
#EXT-X-BYTERANGE:332196@0
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:352124@332196
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:92684@684320
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:195708@777004
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:178600@972712
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:204356@1151312
video.ts
......
......
......
......
#EXT-X-ENDLIST


I have created the m3u8 file for the missing files according to slhck's answer. After creation of file, it played well, but when I navigate video stops for sometime it is taking 20 sec delay. Look at the below file I created manually.



#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-ALLOW-CACHE:YES
#EXT-X-TARGETDURATION:61
#EXTINF:3600.080000,
mysecondvideo.ts
#EXT-X-ENDLIST


But when I played the above file through browser, It is not at all playing. I read the articles about m3u8. But It didn't work for me.



Please help me with creating the m3u8 file, so that I can play on the browser without any delays.



P.S: I don't want to re encode my video. I am not streaming the video live



Thanks in advance.










share|improve this question









New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











I have a list of ts files. For each ts file I have an m3u8 file. But for some ts files I don't have m3u8 files. My m3u8 file is in the below format(showing the already existed file).



This file already in my system, I don't know how it was created(may be with a command or manually)



#EXTM3U
#EXT-X-VERSION:4
#EXT-X-TARGETDURATION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3.000000,
#EXT-X-BYTERANGE:332196@0
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:352124@332196
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:92684@684320
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:195708@777004
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:178600@972712
video.ts
#EXTINF:3.000000,
#EXT-X-BYTERANGE:204356@1151312
video.ts
......
......
......
......
#EXT-X-ENDLIST


I have created the m3u8 file for the missing files according to slhck's answer. After creation of file, it played well, but when I navigate video stops for sometime it is taking 20 sec delay. Look at the below file I created manually.



#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-ALLOW-CACHE:YES
#EXT-X-TARGETDURATION:61
#EXTINF:3600.080000,
mysecondvideo.ts
#EXT-X-ENDLIST


But when I played the above file through browser, It is not at all playing. I read the articles about m3u8. But It didn't work for me.



Please help me with creating the m3u8 file, so that I can play on the browser without any delays.



P.S: I don't want to re encode my video. I am not streaming the video live



Thanks in advance.







video ffmpeg hls






share|improve this question









New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited Nov 15 at 14:28





















New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked Nov 14 at 14:57









emb-pro

12




12




New contributor




emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






emb-pro is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












  • Target duration must be larger that the largest segment size. It’s documented in the specification.
    – szatmary
    Nov 14 at 16:50










  • "below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
    – slhck
    Nov 14 at 18:48












  • The title was changed to ask a completely different question.
    – szatmary
    Nov 14 at 22:32










  • @slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
    – emb-pro
    Nov 15 at 7:00










  • @slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
    – emb-pro
    Nov 15 at 7:09


















  • Target duration must be larger that the largest segment size. It’s documented in the specification.
    – szatmary
    Nov 14 at 16:50










  • "below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
    – slhck
    Nov 14 at 18:48












  • The title was changed to ask a completely different question.
    – szatmary
    Nov 14 at 22:32










  • @slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
    – emb-pro
    Nov 15 at 7:00










  • @slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
    – emb-pro
    Nov 15 at 7:09
















Target duration must be larger that the largest segment size. It’s documented in the specification.
– szatmary
Nov 14 at 16:50




Target duration must be larger that the largest segment size. It’s documented in the specification.
– szatmary
Nov 14 at 16:50












"below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
– slhck
Nov 14 at 18:48






"below file I created" — is that the file you created manually, or did ffmpeg create that for you? Please show the exact command you were using to create the file, and show the entire command line output from ffmpeg as well. And I'm still confused: In your first example, you have a M3U8 that is working, and it references video.ts, but you say the file is missing? Or is video.ts just an example? Please use the actual file names so it's clear which one you are referring to.
– slhck
Nov 14 at 18:48














The title was changed to ask a completely different question.
– szatmary
Nov 14 at 22:32




The title was changed to ask a completely different question.
– szatmary
Nov 14 at 22:32












@slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
– emb-pro
Nov 15 at 7:00




@slhck The first m3u8 file was created by ffmpeg. The second file was written by me as you suggested.
– emb-pro
Nov 15 at 7:00












@slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
– emb-pro
Nov 15 at 7:09




@slhck I don't have any logs, files to show how the m3u8 file was created. Technically I don't know the exact command used to implement the m3u8 file.
– emb-pro
Nov 15 at 7:09















active

oldest

votes











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});






emb-pro is a new contributor. Be nice, and check out our Code of Conduct.










 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1375352%2fseeking-in-m3u8-file-results-in-20-seconds-delay-or-more%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes








emb-pro is a new contributor. Be nice, and check out our Code of Conduct.










 

draft saved


draft discarded


















emb-pro is a new contributor. Be nice, and check out our Code of Conduct.













emb-pro is a new contributor. Be nice, and check out our Code of Conduct.












emb-pro is a new contributor. Be nice, and check out our Code of Conduct.















 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1375352%2fseeking-in-m3u8-file-results-in-20-seconds-delay-or-more%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Plaza Victoria

Brian Clough

Cáceres