# play single big .ts mpeg-ts h264 file in roku

**URL:** <https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182>\
**Category:** Archived\
**Tags:** roku-developer-program\
**Created:** [August 3, 2016, 6:33pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182 "2016-08-03T18:33:25Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [August 3, 2016, 6:33pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/1 "2016-08-03T18:33:25Z")

</div>

Hi,  
i have single .ts file, which is large. Roku does not have feature to play such big file. it always tries to download full file before playing. and also RoKu does not support EXTINF HLS4 discontinuity option.  
So, i need to write in m3u8 with minimum 3 .ts files.

I was trying to convert but download is failing with all options i tried for ffmpeg.

Could you please help how can i play this in roku or how can i convert this to m3u8.

Error below.

./ffmpeg -re -i [http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts[/url:2ozwiwsq] -c copy chunklist.m3u8 -headers ‘User-Agent: “FMLE/3.0 (compatible; FMSc/1.0)”’](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts:2ozwiwsq)  
ffmpeg version N-63893-gc69defd Copyright (c) 2000-2014 the FFmpeg developers  
built on Jul 16 2014 05:38:01 with gcc 4.6 (Debian 4.6.3-1)  
configuration: --prefix=/root/ffmpeg-static/64bit --extra-cflags=‘-I/root/ffmpeg-static/64bit/include -static’ --extra-ldflags=‘-L/root/ffmpeg-static/64bit/lib -static’ --extra-libs=‘-lxml2 -lexpat -lfreetype’ --enable-static --disable-shared --disable-ffserver --disable-doc --enable-bzlib --enable-zlib --enable-postproc --enable-runtime-cpudetect --enable-libx264 --enable-gpl --enable-libtheora --enable-libvorbis --enable-libmp3lame --enable-gray --enable-libass --enable-libfreetype --enable-libopenjpeg --enable-libspeex --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-version3 --enable-libvpx  
libavutil 52. 89.100 / 52. 89.100  
libavcodec 55. 66.101 / 55. 66.101  
libavformat 55. 43.100 / 55. 43.100  
libavdevice 55. 13.101 / 55. 13.101  
libavfilter 4. 8.100 / 4. 8.100  
libswscale 2. 6.100 / 2. 6.100  
libswresample 0. 19.100 / 0. 19.100  
libpostproc 52. 3.100 / 52. 3.100  
Trailing options were found on the commandline.  
Input #0, mpegts, from ‘[http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)’:  
Duration: N/A, start: 37562.820100, bitrate: 179 kb/s  
Program 1  
Metadata:  
service\_name : Service01  
service\_provider: FFmpeg  
, 25 fps, 25 tbr, 90k tbn, 50 tbc  
/ 0x000F), 44100 Hz, stereo, fltp, 179 kb/s  
Output #0, hls, to ‘chunklist.m3u8’:  
Metadata:  
encoder : Lavf55.43.100  
, q=2-31, 25 fps, 90k tbn, 25 tbc  
/ 0x000F), 44100 Hz, stereo, 179 kb/s  
Stream mapping:  
Stream #0:0 → #0:0 (copy)  
Stream #0:1 → #0:1 (copy)  
for help  
frame= 700 fps= 25 q=-1.0 Lsize=N/A time=00:00:28.00 bitrate=N/A  
video:5604kB audio:444kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

---

<div class="post-metadata">

**Author:** ![atc98092](https://avatars.discourse-cdn.com/v4/letter/a/b3f665/32.png) [@atc98092](https://forum.developer.roku.com/u/atc98092)\
**Post date:** [August 3, 2016, 8:09pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/2 "2016-08-03T20:09:18Z")

</div>

Based on the ffmpeg information, this is not a local file, so I can guess that the Roku Media Player (which is what I’m assuming you are using to play it) wants to download the file before beginning playback. You might have better luck using a DLNA server to act as your supplier of the media, and let it stream the Internet file. That’s the only successful method I’ve used for non-local files that are coming from the Internet. Serviio is one such server that can stream from the Internet and feed your player.

---

<div class="post-metadata">

**Author:** ![Elijah\_Baley](https://avatars.discourse-cdn.com/v4/letter/e/eb9ed0/32.png) [@Elijah\_Baley](https://forum.developer.roku.com/u/Elijah_Baley)\
**Post date:** [August 3, 2016, 8:26pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/3 "2016-08-03T20:26:51Z")

</div>

> “atc98092” wrote:  
> Based on the ffmpeg information, this is not a local file, so I can guess that the Roku Media Player (which is what I’m assuming you are using to play it) wants to download the file before beginning playback. You might have better luck using a DLNA server to act as your supplier of the media, and let it stream the Internet file. That’s the only successful method I’ve used for non-local files that are coming from the Internet. Serviio is one such server that can stream from the Internet and feed your player.

I’ve had pretty good success with a good number of web based files using Plex’s “Watch later” feature. However for that to work you have to have a Plex server setup and running on your network and you have to enable the “Plex it” feature in your browser. Once you have done that all you must do in navigate to the video in your browser and click the “Plex it” button and if it is a compatible video Plex will add it to your “Watch later” queue and then you can navigate to it in your Plex channel and play it just like a local video.

---

<div class="post-metadata">

**Author:** ![RokuMarkn](https://avatars.discourse-cdn.com/v4/letter/r/ac8455/32.png) [@RokuMarkn](https://forum.developer.roku.com/u/RokuMarkn)\
**Post date:** [August 3, 2016, 8:47pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/4 "2016-08-03T20:47:08Z")

</div>

Roku never downloads a whole file before playing it. It has no place to put that much data. And it does support the #EXT-X-DISCONTINUITY m3u8 tag, if that’s what you mean by “discontinuity option”.

–Mark

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [August 6, 2016, 7:02am UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/5 "2016-08-06T07:02:00Z")

</div>

@RokuMarkn Team,  
I have written my own application video player using brightscript example simlevideoplayer.

if roku supports #EXT-X-DISCONTINUITY m3u8 tag option then why below is not working. I am using roku 2 latest version box.  
Please tell why below is not working. I want to play this live HLS ts single file, please help how can i play. Below i tried but not working.

#EXTM3U  
#EXT-X-VERSION:3  
#EXT-X-ALLOW-CACHE:NO  
#EXT-X-MEDIA-SEQUENCE:444  
#EXT-X-DISCONTINUITY-SEQUENCE:444  
#EXT-X-DISCONTINUITY  
#EXTINF:1.337,  
[http://ns3045782.ip-5-135-142.eu:8000/l … hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [August 6, 2016, 7:06am UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/6 "2016-08-06T07:06:51Z")

</div>

@atc98092 , @Elijah_Baley ,  
I want to play directly this HLS .ts file in my roku simplevideoplayer application.  
I am developing a application to play HLS stream, but unable to play only this single .ts file.

Please tell me how to play.  
[http://ns3045782.ip-5-135-142.eu:8000/l … hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)

as unable t play directly, while converting to m3u8, It is downloading for few seconds and then got error.  
Please help. Anyway to play this single .ts HLS stream file.

---

<div class="post-metadata">

**Author:** ![belltown](https://avatars.discourse-cdn.com/v4/letter/b/8edcca/32.png) [@belltown](https://forum.developer.roku.com/u/belltown)\
**Post date:** [August 6, 2016, 4:38pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/7 "2016-08-06T16:38:53Z")

</div>

> “sarada” wrote:
> 
> I want to play directly this HLS .ts file in my roku simplevideoplayer application.  
> I am developing a application to play HLS stream, but unable to play only this single .ts file.
> 
> Please tell me how to play.  
> [http://ns3045782.ip-5-135-142.eu:8000/l … hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)
> 
> as unable t play directly, while converting to m3u8, It is downloading for few seconds and then got error.  
> Please help. Anyway to play this single .ts HLS stream file.  
> You can’t. It’s not an HLS stream, just a single segment file. You need the manifest file (.m3u8) for the live stream. You can’t convert a .ts file into a .m3u8 file.

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [August 6, 2016, 5:08pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/8 "2016-08-06T17:08:48Z")

</div>

> “belltown” wrote:
> 
> > “sarada” wrote:
> > 
> > I want to play directly this HLS .ts file in my roku simplevideoplayer application.  
> > I am developing a application to play HLS stream, but unable to play only this single .ts file.
> > 
> > Please tell me how to play.  
> > [http://ns3045782.ip-5-135-142.eu:8000/l … hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)
> > 
> > as unable t play directly, while converting to m3u8, It is downloading for few seconds and then got error.  
> > Please help. Anyway to play this single .ts HLS stream file.  
> > You can’t. It’s not an HLS stream, just a single segment file. You need the manifest file (.m3u8) for the live stream. You can’t convert a .ts file into a .m3u8 file.

The .ts file is a mpegts live streaming file. any way to convert to m3u8 using ffmpeg command.

---

<div class="post-metadata">

**Author:** ![RokuDale](https://avatars.discourse-cdn.com/v4/letter/r/9e8a1a/32.png) [@RokuDale](https://forum.developer.roku.com/u/RokuDale)\
**Post date:** [August 7, 2016, 4:05am UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/9 "2016-08-07T04:05:43Z")

</div>

There are a couple different ways to play it.  
Easiest for me was to create a test.m3u file on a usb stick and put that link in there and let rmp play it.  
Easiest for you is to probably just make sure you set the streamformat to “ts” and play it.  
rokudale

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [August 7, 2016, 11:41am UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/10 "2016-08-07T11:41:53Z")

</div>

> “RokuDale” wrote:  
> There are a couple different ways to play it.  
> Easiest for me was to create a test.m3u file on a usb stick and put that link in there and let rmp play it.  
> Easiest for you is to probably just make sure you set the streamformat to “ts” and play it.  
> rokudale

Hi RokuDale,  
when i tried to run by changing streamformat, it is playing only few seconds 20 or 30 seconds and then exiting automatically with below error.  
I am using samplevideoplayer example.

XML File:

Live StarPlus TV Channel19movieHDtruetsHD0[http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts](http://ns3045782.ip-5-135-142.eu:8000/live/sYKADDaJs2/SnoQc6v4hZ/3900.ts)StarPlusStarPlus0

Console error log:

showHomeScreen | msg = Stream started. | index = 0  
Unexpected event type: 20  
showHomeScreen | msg = Format Detected | index = 1  
Unexpected event type: 33  
showHomeScreen | msg = | index = 0  
showHomeScreen | msg = An unexpected problem (but not server timeout or HTTP error) has been detected. | index = -3  
Video request failure: -3 0  
showHomeScreen | msg = | index = 0  
Screen closed  
Button pressed: 2 0

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [October 16, 2016, 2:44pm UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/11 "2016-10-16T14:44:57Z")

</div>

I did not able to proceed, not seen any response. Please help me how to play this in my roku application.

---

<div class="post-metadata">

**Author:** ![sarada](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sarada](https://forum.developer.roku.com/u/sarada)\
**Post date:** [November 5, 2016, 7:40am UTC](https://forum.developer.roku.com/t/play-single-big-ts-mpeg-ts-h264-file-in-roku/7182/12 "2016-11-05T07:40:40Z")

</div>

Hi Roku Team,  
I am unable to proceed, please help. i am still waiting for your response from long time.
