Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
monettes
Visitor

Start playing movie delay

Hi,

Is there a way to tell the video player to start playing an HLS file as soon as it received the first MPEG-TS file with 10 seconds of video?

I think the player downloads 30 seconds (or more) worth of video before starting to play the content. For someone who wants to broadcast live video feeds, it takes too long for the customers to zap through channels.

If we want this box to compete against the CableTV, Satellite providers and others, we need to make the channel zapping way faster.

If we could setup the box to start playing the MPEG-TS file once the first 5 or 10 seconds are downloaded, the box would start playing the movie content within a few seconds on ADSL2+, regular ADSL links and Cable Internet. Customer could adjust this value (start delay) in their Roku setup.

Also, we should be able to config the box to setup the internet download speed so the box would know immediately which MPEG-TS file to download if they have multiple files with different bitrate available. This alone would also reduce the delay to start playing the movie.

Thanks,

Stephan Monette
Unlimitel Inc.
0 Kudos
5 REPLIES 5
RokuKevin
Visitor

Re: Start playing movie delay

The player requires three segments of HLS video to be delivered. However, the length of the segments is configurable... So if you wanted to start playing after less than 10 seconds, you could set the segment length to 3 seconds in the .m3u8 and start playing after 9 seconds:

#EXT-X-TARGETDURATION:3

Of course, your whole encoding / segmenting process would be working with the same 3 second segment duration.

--Kevin
0 Kudos
renojim
Community Streaming Expert

Re: Start playing movie delay

Would it be acceptable to have EXT-X-TARGETDURATION be 10 and then the first three segments to have EXTINFs of 3? Like:

#EXTM3U
#EXT-X-TARGETDURATION:10
#EXT-X-MEDIA-SEQUENCE:1
#EXTINF:3
http://192.168.1.103:8001/seg0001.ts
#EXTINF:3
http://192.168.1.103:8001/seg0002.ts
#EXTINF:3
http://192.168.1.103:8001/seg0003.ts
#EXTINF:10
http://192.168.1.103:8001/seg0004.ts
#EXTINF:10
http://192.168.1.103:8001/seg0005.ts

I didn't see anything in the spec that didn't allow something like that and I have to admit it would be a pain to encode that way, or just plain impossible for a live stream sent to many different players. And, I'm also still trying to fully understand the whole HLS thing, so excuse me if this is just plain stupid.

Or, are you saying the player requires 3 times the length specified in EXT-X-MEDIA-SEQUENCE and/or expects each segment to be that length?

-JT
Roku Community Streaming Expert

Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.

I am not a Roku employee.
0 Kudos
monettes
Visitor

Re: Start playing movie delay

Kevin,

Why does the unit has to wait to completely download 3 segments before starting to play the video?

I can modify the segments time, but I feel that 3 seconds is way too short and I'm not sure how much bandwidth tax will be added with 3x times more headers to download.

Could Roku add a config item for the users to setup how many segments needs to be downloaded before the video starts playing? Or better, setup how many seconds of video needs to be in the cache before the unit starts playing the video?

I'm just trying to find a solution to increase the user's satisfaction with this product for every channels, not just my channels.

Thanks,

Stephan Monette
Unlimitel Inc.
0 Kudos
monettes
Visitor

Re: Start playing movie delay

Hi,

I did some testing between my Roku and my local http server as the streaming server. I create the m3u8 index file with just one file into it in a live broadcast mode. The Roku plays the file perfectly and does so without any issues.

But I'm discovering the Roku has a delay of about 5 seconds between the time it finishes downloading the transport stream file and when it starts playing the video file.

Why such a big delay? By starting the video as soon as the file has downloaded, it would make the whole experience much better for the customers using the Roku units.

We're running on version 2.5.

Thanks,

Stephan Monette
Unlimitel Inc.
0 Kudos
RokuKevin
Visitor

Re: Start playing movie delay

We calculate how much buffer we need to reduce the risk of showing any buffering screens to the user. We may currently be a bit conservative on this calculation, but will continue to look at this tradeoff.

One thing channel developers can do to help make this pre-buffer calculation more accurate for us is to specify accurate bitrates for your streams.

--Kevin
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.