[REQUEST] BBC iPlayer (Video) Plugin or Script?

  Thread Rating:
  • 7 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Thread Closed
Strawp Offline
Member
Posts: 77
Joined: Apr 2004
Reputation: 0
Post: #41
BTW, I'll post a bit later what URL I'm trying out - see if anyone else can get it to open content or if I'm just getting it totally wrong.
find
PhilWilson Offline
Junior Member
Posts: 5
Joined: Dec 2007
Reputation: 0
Post: #42
mplayer will not play RTMP streams, nor will VLC.

You will have to use a separate tool to download, but you *will* end up with a DRM-free FLV file which will work in the player of your choice.
find
Strawp Offline
Member
Posts: 77
Joined: Apr 2004
Reputation: 0
Post: #43
Ah good, welcome to the thread Smile

I guess I don't really *get* what media is being streamed out here. I thought the RTMP stream was Real Media as opposed to whatever FLV is - or is FLV just a wrapper like AVI?

What tool did you use to download the media and how did you construct the stream URL to begin with?
find
Strawp Offline
Member
Posts: 77
Joined: Apr 2004
Reputation: 0
Post: #44
Re: The media format - helps if I read up on it. So the data streamed from RTMP is whatever the FLV is, but it's the actual connection that's protected rather than the data, as you would get from DRM protected formats.
find
cubicgarden Offline
Junior Member
Posts: 28
Joined: Apr 2006
Reputation: 0
Location: London
Thumbs Up  making it happen Post: #45
Good to see you Phil joining the thread.

So from my understanding we're still nicely on the legal side of everything.

If we can create a client/script which can talk to the streaming server, and parse the resulting stream. Nothing would have been reverse-engineered or broken.

Is the Xbox fast enough to do the pre-parsing of raw into flv? Then display the results from cache? Would we need to off-load this pre-parsing to a serverConfused? I would need to double check about rebroadcasting (as such) because that could be a slight problem (don't worry I can talk to legal if it comes to it and I wouldn't want that to stand in the way of this.)

Guys this is really bleeding edge development and the kind I believe Backstage was setup to encourage.
find
Strawp Offline
Member
Posts: 77
Joined: Apr 2004
Reputation: 0
Post: #46
Well, all the RTMP downloaders I'm seeing at the moment are closed source Windows ones like Orbit, however from what I've read it looks like the next version of curl might have RTMP support. It might be that initially this requires some middle step like you said which simply brings the media out of the RTMP session and into FLV which can be transferred under any protocol.

The Flash iPlayer client itself is built in with support for the Adobe streaming prtocols (RTMP, RTMPT and RTMPS) but there's basically a logic switch in loads of methods in there where they've accounted for the streaming content being just a straight FLV over HTTP. So the iPlayer authors are clearly aware that it's not always going to be about the RTMP streams.

So anyway, for this to work, any of these have to be true:

1. mplayer supports RTMP (not seeing this happening any time soon)
2. XBMC can use something like curl to pre-parse a stream and play it off HD cache. Not sure the original Xbox has enough oomph for that though
3. A man-in-the-middle style server is set up local to an XBMC install (e.g. another linux or windows server with curl or Orbit running on it) which can take stream URLs sent from XBMC and output FLV over a more open format. (I reckon this is doable).
4. The Beeb provides an FLV source instead of RTMP. (Seems like a sticky topic to me)
find
Gamester17 Offline
Team-XBMC Forum Moderator
Posts: 10,595
Joined: Sep 2003
Reputation: 9
Location: Sweden
Lightbulb  Just a suggestion that may make things easier... Post: #47
May I suggest that you guys writting the python script/plugin for XBMC talk to Elupus about the possibilities to add native RTMP/RTMPT/RTMPS support to XBMC via cURL (libcURL), either that or by hardcoding it into XBMC's DVDPlayer video-playback core and/or FFmpeg which the XBMC DVDPlayer uses).

Like Strawp notes; if native RTMP/RTMPT/RTMPS demux parsing support was added to XBMC somehow then you python scripters would not have hack around ways that may only lead you to ways to download those streams instead of just pasing the URL to XBMC.

You could try to PM Elupus here via the forums but you are probably better of trying to catch him on IRC.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
find
PhilWilson Offline
Junior Member
Posts: 5
Joined: Dec 2007
Reputation: 0
Post: #48
The most recent work I can find on curl support for RTMP is here: http://osdir.com/ml/gnu.gnash.devel2/200...00278.html but it is only RTMPT (RTMP over HTTP, which iPlayer doesn't support). Note it's more than a year old. I don't have the C necessary to get a patch into curl, that's for sure. Strawp - have you seen something more recent?

RTMP is not protected as such, it's a proprietary streaming protocol which was apparently only reverse-engineered last year. In the case of iPlayer it streams FLV, which is a proprietary file format, but can be played back in mplayer, VLC etc. and can be re-encoded to whatever you prefer using mencoder or ffmpeg.

As my blog post said, I used a closed-source Windows tool called Replay Media Catcher to get the .flv file. You run the tool (which sits there waiting), then load the iPlayer video in your browser as normal, and it catches the network traffic, removes the RTMP headers and glues together the FLV body packet by packet. You can then save it out to somewhere on your HDD.

I got a very useful comment from Reinould Elhorst from the WiimediaPlayer project here, which is worth reading.

The RTMP protocol seems sufficiently well documented to allow a client in any language, it just needs someone to sit down and actually write it.

On the other hand, after a couple of minutes of trying, I don't seem to be able to recreate my initial experiment - that is to say there used to be a file at the location http://www.bbc.co.uk/mediaselector/3/str...er?pid=PID where PID is something like b008l1fp (Robin Hood) which would give you two parameters necessary to construct the RTMP URL - I can't get it to work any more (although I'm not on my main PC so I can't access the notes I made until the 2nd Jan) - I just get

<?xml version="1.0" encoding="utf-8"?>
<stream version="0.1">
<error id="notavailable"/>
</stream>

boo.

and finally, just to clarify:

"4. The Beeb provides an FLV source instead of RTMP. (Seems like a sticky topic to me)"

The Beeb *do* provide an FLV, it's just streamed over RTMP, not available as a direct download. Even over RTMPT (RTMP over HTTP) it would require a special client. For the purposes of the streaming iPlayer client, RTMP seems like a sensible choice. We should be grateful it's not RealPlayer Smile
find
PhilWilson Offline
Junior Member
Posts: 5
Joined: Dec 2007
Reputation: 0
Post: #49
cubicgarden Wrote:I was thinking about using a Nabatzag as a internet connected radio the other day.

I think the Nabaztag-tag has radio playback doesn't it? My v1 Nabaztag doesn't, it just tells me when my code has failed to build Smile
find
Strawp Offline
Member
Posts: 77
Joined: Apr 2004
Reputation: 0
Post: #50
PhilWilson Wrote:Strawp - have you seen something more recent?

Yep, so far it's just a feature request from earlier in the month, but it looks like they're working on it: http://curl.haxx.se/mail/tracker-2007-12/0005.html
http://www.mail-archive.com/gnash@gnu.org/msg00896.html

Someone has it working but it isn't in the main source, is what I got from that.

PhilWilson Wrote:I got a very useful comment from Reinould Elhorst from the WiimediaPlayer project here, which is worth reading.

Cool, we're also a Wii household Wink

PhilWilson Wrote:On the other hand, after a couple of minutes of trying, I don't seem to be able to recreate my initial experiment - that is to say there used to be a file at the location http://www.bbc.co.uk/mediaselector/3/str...er?pid=PID where PID is something like b008l1fp (Robin Hood) which would give you two parameters necessary to construct the RTMP URL - I can't get it to work any more (although I'm not on my main PC so I can't access the notes I made until the 2nd Jan) - I just get

<?xml version="1.0" encoding="utf-8"?>
<stream version="0.1">
<error id="notavailable"/>
</stream>

It's definitely there. For /mediaselector/3/stream/check/iplayer?pid=b008lyxr I get:

<?xml version="1.0" encoding="utf-8"?>
<stream version="0.1">
<server>cp41752.edgefcs.net</server>
<identifier>secure/b0008lyxr-streaming67271525</identifier>
<subtitleUrl></subtitleUrl>
<token>daEdGata5brbncCcWbsbUddaJcybVaQc9bn-bhD9kT-cCp-DnuDHoDoIDvGvxK</token>
</stream>

Was it just an expired programme?


PhilWilson Wrote:and finally, just to clarify:

"4. The Beeb provides an FLV source instead of RTMP. (Seems like a sticky topic to me)"

The Beeb *do* provide an FLV, it's just streamed over RTMP, not available as a direct download. Even over RTMPT (RTMP over HTTP) it would require a special client. For the purposes of the streaming iPlayer client, RTMP seems like a sensible choice. We should be grateful it's not RealPlayer Smile

Right, yep. I guess I meant an FLV file sat on a web server somewhere as opposed to a different service. Let's see if we can't get a core XBMC or mplayer developer in the thread to comment then Smile Native RTMP support would definitely be the way to go, and it would benefit so many other people using other forms of mplayer.
find
Thread Closed