retrotom
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
08:25 PM
Re: HLS streaming questions
"dynamitemedia" wrote:
yes they are encoded correctly because if i hard code the playlist they work.
also Chris is able to play my .php file, but i cant.
Its not an encoding issue for playback. its some sort if issue with the playlist. It works for Chris but not for Endless or I
Yeah, that makes sense. I will try to play your stream and get back to you.
dynamitemedia
Binge Watcher
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
08:33 PM
Re: HLS streaming questions
not seeing any of those issues, what i meant strangely with VLC is it will play them as you say and pause for a milisecond before then next one plays.
If you have been following the thread you will see that when i make the playlist with all the files they stream like they are supposed to. so they must be encoded and segmented correctly.
the issue is that the .php file is not playing in my player, BUT will work on Chris's Roku.
now do you mean here that these issues in VLC. I don't seem to be having these issues in VLC, no.
but i have had some issues even with the playlist that video is playing faster than the audio, in the Roku box.
But either way you should add what you did just in case that is the issue and share it with us all. Thanks
If you have been following the thread you will see that when i make the playlist with all the files they stream like they are supposed to. so they must be encoded and segmented correctly.
the issue is that the .php file is not playing in my player, BUT will work on Chris's Roku.
If you're seeing different behavior like video/audio out of sync, video playing really fast, video doesn't show for a second or two when playback starts, or video followed by audio -- then you're (probably) not segmenting the files correctly. I spent about 3-4 days on this issue myself, so I might be able to help you
now do you mean here that these issues in VLC. I don't seem to be having these issues in VLC, no.
but i have had some issues even with the playlist that video is playing faster than the audio, in the Roku box.
But either way you should add what you did just in case that is the issue and share it with us all. Thanks
Twitter: iptvmyway facebook: iptvmyay
Channels: Warriors of War, Go Fight Live, Heading Outdoorz, IPTVmyway
Channels: Warriors of War, Go Fight Live, Heading Outdoorz, IPTVmyway
retrotom
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
08:49 PM
Re: HLS streaming questions
"dynamitemedia" wrote:
not seeing any of those issues, what i meant strangely with VLC is it will play them as you say and pause for a milisecond before then next one plays.
If you have been following the thread you will see that when i make the playlist with all the files they stream like they are supposed to. so they must be encoded and segmented correctly.
the issue is that the .php file is not playing in my player, BUT will work on Chris's Roku.If you're seeing different behavior like video/audio out of sync, video playing really fast, video doesn't show for a second or two when playback starts, or video followed by audio -- then you're (probably) not segmenting the files correctly. I spent about 3-4 days on this issue myself, so I might be able to help you
now do you mean here that these issues in VLC. I don't seem to be having these issues in VLC, no.
but i have had some issues even with the playlist that video is playing faster than the audio, in the Roku box.
But either way you should add what you did just in case that is the issue and share it with us all. Thanks
Hey, just tried your stream in VLC and on the Roku. VLC works OK -- but on Roku I get the same error as you. The only reason I haven't listed my steps is because they are only useful if you're segmenting the files like we are (customized version of the open source segmenter, not using intermediate files, etc.) -- it would deviate from what you're specifically trying to solve. That being said, in order to get the files to actually play in sync, we had to write the TS service information at the beginning of each segment. The open source segmenter (using libavformat) does not do that -- it split on key frames and does not write the header to each segment. That's good and everything, but the Roku kept getting out whack without the service information. The service info describes the format of each stream in the file. Without, we saw out sync playback and some instances where sound would play without video for a few seconds everytime it hit a new segment -- weird crap.
retrotom
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
08:53 PM
Re: HLS streaming questions
"dynamitemedia" wrote:
not seeing any of those issues, what i meant strangely with VLC is it will play them as you say and pause for a milisecond before then next one plays.
If you have been following the thread you will see that when i make the playlist with all the files they stream like they are supposed to. so they must be encoded and segmented correctly.
the issue is that the .php file is not playing in my player, BUT will work on Chris's Roku.If you're seeing different behavior like video/audio out of sync, video playing really fast, video doesn't show for a second or two when playback starts, or video followed by audio -- then you're (probably) not segmenting the files correctly. I spent about 3-4 days on this issue myself, so I might be able to help you
now do you mean here that these issues in VLC. I don't seem to be having these issues in VLC, no.
but i have had some issues even with the playlist that video is playing faster than the audio, in the Roku box.
But either way you should add what you did just in case that is the issue and share it with us all. Thanks
Here's the raw output of your stream:
HTTP/1.1 200 OK
Date: Mon, 11 Oct 2010 03:46:06 GMT
Server: Apache
X-Powered-By: PHP/5.2.12
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Transfer-Encoding: chunked
Content-Type: text/html
3a8
#EXTM3U
#EXT-X-TARGETDURATION:10
#EXT-X-MEDIA-SEQUENCE:1
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer1.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer2.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer3.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer4.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer5.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer6.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer7.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer8.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer9.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer10.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer11.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer12.ts
#EXTINF:10,
http://iptvmyway.com/roku/HLS/streaming/trailer13.ts
#EXT-X-ENDLIST
0
As you can see, your content-type is not correct. Also, you're sending via chunked encoding. The Roku should support this, but I've had issues with this with normal media files. I'm not sure how it would react to an HLS playlist. You're also using a keep-alive connection. I don't know if that hurts anything, but it doesn't make much sense -- you only use that if you want a persistent connection. Keep-alive and chunked encoding make sense if you don't know the length of your content -- but they might be hurting you here. The should work (in theory), but you never know.
dynamitemedia
Binge Watcher
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
09:40 PM
Re: HLS streaming questions
As you can see, your content-type is not correct.
i have the headers set for
header("Content-Type: application/vnd.apple.mpegurl");
maybe should go back to
header("Content-Type: application/x-mpegURL");
i have also added in my .htaccess
AddType application/x-mpegURL .m3u8
AddType video/MP2T .ts
as i have found on the internet to do. Is this incorrect? in fact i changed this header info from what i had to this because of your post. am i doing this incorrect and is why its coming thru as text/html?
Also, you're sending via chunked encoding. The Roku should support this, but I've had issues with this with normal media files. I'm not sure how it would react to an HLS playlist.
ok thats from using this I am assuming
<?php echo "\r\n"?>
You're also using a keep-alive connection. I don't know if that hurts anything, but it doesn't make much sense -- you only use that if you want a persistent connection.
This i have no idea how its being done, my php code is in this thread maybe you can see what is making these things happen
Keep-alive and chunked encoding make sense if you don't know the length of your content -- but they might be hurting you here. The should work (in theory), but you never know.
NOTE: i just looked at the playlist.php so that i could change to
header("Content-Type: application/x-mpegURL");
and noticed thatthe header info was still commented out... so maybe try now and see what you get.
also how are you getting that "Raw Output" ??
Twitter: iptvmyway facebook: iptvmyay
Channels: Warriors of War, Go Fight Live, Heading Outdoorz, IPTVmyway
Channels: Warriors of War, Go Fight Live, Heading Outdoorz, IPTVmyway
kbenson
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2010
10:12 PM
Re: HLS streaming questions
"dynamitemedia" wrote:
also how are you getting that "Raw Output" ??
There's lots of ways to get HTTP header info. There's extensions for firefox (and I assume other browsers), or some utilities to request and show the full output, or you can just request yourself with telnet. I only suggest telnet if you can easily to do the request as a post, and have a fairly lenient server such as Apache (which you already indicated you were using, I believe).
Using telnet, the greatly simplified instructions are to telnet to the webserver on port 80 (or whatever your port is), and type
GET /url/to/get.php?foo=bar HTTP/1.1
Note the second newline after the get request. That indicated the end of the request headers, and that the webserver should respond. If you are using name based virtualhosts (multiple domains sharing the same IP with different content based on domain name), you need to send a Host: header as well:
GET /url/to/get.php?foo=bar HTTP/1.1
HOST: edsdiscountsupercomputers.com
Again, don't forget the second newline after the last header line. Also, if you are using complex parameters, you will have to urlencode the get string. You can change GET to POST to simulate posts, but I don't suggest it.
If you need to connect to a HTTPS site, look up openssl's s_client command.
In the end, it's probably easier to use a utility that will show you the headers, but it is useful for testing to know how to fudge an HTTP request.
-- GandK Labs
Check out Reversi! in the channel store!
Check out Reversi! in the channel store!
retrotom
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2010
02:23 AM
Re: HLS streaming questions
I probably won't be able to check out you stream again until this afternoon. I think you're onto something with your "php echo" code. IIRC, there's a better/more direct way to write to the response stream.
EDIT: I was able to check out the response stream. It came across OK on my PC but I would need to test on the Roku to see if it plays now. The content type still isn't the "official" HLS one, but the spec say either one is fine, IIRC. Did you get it working on your end yet?
EDIT: I was able to check out the response stream. It came across OK on my PC but I would need to test on the Roku to see if it plays now. The content type still isn't the "official" HLS one, but the spec say either one is fine, IIRC. Did you get it working on your end yet?

RokuMarkn
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2010
09:10 AM
Re: HLS streaming questions
You can also use tools like curl or wget to retrieve URLs and look at the raw output, the headers, etc.
I'm pretty sure it's the chunked encoding that's causing your problem. I would try to get rid of that and see if it works better for you. The Roku player doesn't look at the Content-Type header so it doesn't matter what you send there.
--Mark
I'm pretty sure it's the chunked encoding that's causing your problem. I would try to get rid of that and see if it works better for you. The Roku player doesn't look at the Content-Type header so it doesn't matter what you send there.
--Mark

TheEndless
Channel Surfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2010
09:14 AM
Re: HLS streaming questions
On Windows, I find that Fiddler (http://www.fiddler2.com) is an invaluable tool for analyzing web requests.
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
retrotom
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2010
09:50 AM
Re: HLS streaming questions
"TheEndless" wrote:
On Windows, I find that Fiddler (http://www.fiddler2.com) is an invaluable tool for analyzing web requests.
I don't know if you're on Windows or not. I use Fiddler and Wireshark to look at http requests/responses. All the dumps I've posted on here are from Wireshark. I try to monitor the network traffic when developing my app. If you know it's not the content -- it must be how you're exposing it.