• 1
  • 10
  • 11
  • 12(current)
  • 13
  • 14
  • 20
[Request] TVNZ OnDemand
Thumbs Up 
+1 more interested person for this!
Reply
I've promised to spend today with the wife and kids (and obviously tomorrow as well), but will try to get the plugin updated (with merging dteirney's changes) before the 30th - when I'm off camping for a few days.
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
Family first, take your time. It is ready when it's ready. Those that can't handle that can look at the code themselves.
Reply
Hey Mark,

Any news on an update?
ZOTAC IONITX-D-E Intel Atom N330 Dual Core 1.6 GHz NVIDIA ION with LIVE on SSD (now updated to Nvidia Shield Pro (P2897)
Reply
I'm currently in the process of gutting the plugin and re-writing it to make it more robust and easier to work on. The old code was a bit of a mess, as it grew very organically. The new version uses classes and other snazzy tricks, and may even have code comments once I'm finished! So far the TVNZ part is nearly done (just a couple of bugs to squash), and converting the other channels to use the new plugin structure should be pretty quick.

Fingers crossed there'll be a new release for Eden for the weekend.
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
Hmmm, so TVNZ seem to have changed their streaming for new videos - I'm in the process of trying to figure out how the new RTMP URLs are generated, so this may take some time.

Here's a URL for Criminal Minds:

rtmpe://cp133145.edgefcs.net/ondemand/&mp4:videos/963482467001/963482467001_1382289295001_4683600.mp4

I'm currently searching for edgefcs.net to see if I can find out more about them, and if anyone has already figured out their URL scheme already. Fingers crossed!
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
It looks like edgefcs is a stream caching service from akamai, and URL schemes vary depending on the corporate user - so it's back to the drawing board.

I'm currently trawling through the following different entry points for TVNZ's OnDemand service, looking for clues as to how to build the URLs:

http://tvnz.co.nz/video
http://tvnz.co.nz/ondemand/xl
http://tvnz.co.nz/content/ps3_navigation...l_skin.xml

If anyone has any bright ideas or insights, please let me know!
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
Dude...I sure wish I could offer some help...but I'm a programming ignoramus Oo I'm not even sure those last three posts of yours where in English Laugh

All I can do is offer energetic support - you know...the stuff from the cosmic realms. Cool When I re-incarnate next time, I'm going to be more knowledgeable on puters and stuff!

Hope you can sort it out.

Regards...
ZOTAC IONITX-D-E Intel Atom N330 Dual Core 1.6 GHz NVIDIA ION with LIVE on SSD (now updated to Nvidia Shield Pro (P2897)
Reply
Perhaps the flash player on the tvnz ondemand site might hold some clues?
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.


Image
Reply
jmarshall, that's one of the places I'm looking, although I'd rather not have to try to decompile the player. Hopefully everything I need is in the HTML or JS somewhere.

For the example RTMP URL I've posted earlier in this thread (rtmpe://cp133145.edgefcs.net/ondemand/&mp4:videos/963482467001/963482467001_1382289295001_4683600.mp4), I can grab one of the identifying numbers pretty easily from JS embedded in the HTML:

Code:
jsTVNZ.Common().setGlobal('articleId', '4683600');

This just leaves 963482467001 and 1382289295001

It's weird that both of these end in 001, and the second one, once you've knocked the 001 off the end, looks like a UNIX date. To be precise, it's:

Sun, 20 Oct 2013 17:14:55 GMT

I reckon this is probably coincidence, but who knows! I'll keep poking around until I find something useful.
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
Hi Mark,

It is great you are working on this addon. If you could ask a list of questions of the TVNZ Ondemand developers, which would help you develop this addon, what would they be?

Cheers!

Philos
Reply
Hmmm, good question. I'll get back to you on that one, once I've had a chance to do some more digging around.
Author of the NZ OnDemand and ZoneMinder addons, and caretaker of the pyamf script. Contributor to fanart.tv, TheMovieDB and TheTVDB.
Reply
@philos: I'll let markhoney describe what he needs specifically, but as far as XBMC goes basically what it needs for any plugin is a playable URL. If they're sticking with flash video players, then that would be a playable rtmp(e):// URL, i.e. everything the flashplayer itself needs to playback the video. IIRC for the original tvnz plugin this meant that in addition the stuff fed to the flash player, we also needed to know the magic timezone offset that was embedded in the player itself (for obfuscation reasons?) Now that things have changed, there's obviously further obfuscation going on.

This means we need:

1. An easily parseable feed with which to get the available shows etc. (already have this pretty much via the PS3 xml feeds).

2. An easy way, given an episode from 1 to obtain the rtmp(e):// URL(s) for playback (with adverts would be good - IIRC it was a huge hassle to get the ads in the first version of the addon - much easier without the ads, which I suspect tvnz would not be keen on!).

If you have a contact at TVNZ (or at the company that does their development), then I'd be more than happy to chat with them in a more official capacity (or in an unofficial capacity) as the president of the XBMC foundation in case that impressed them (I'm guessing not!) Wink

After all, what other app let's you play tvnz ondemand on your iPad?

Cheers,
Jonathan
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.


Image
Reply
I threw that PS3 flash player into http://www.showmycode.com/

They are using a service called Brightcove Player, which looks to have an API that is generating the URLs (can't see it being done in the flash code)

When I get some more time I'll try running a packet sniffer and see the communication that is going on to Brightcove API. There are a few other topics on this site that mention brightCove..

http://www.brightcove.com/brightcoveplayerapi
http://c.brightcove.com/services

Code:
_local2.playerKey = "AQ~~,AAAA4FQHurk~,l-y-mylVvQmMeQArl3N6WrFttyxCZNYX";
_local2.playerID = 1257248093001;
Reply
Those numbers you pulled out of the URL, the first number is the SitePublisherID - so is probably the same for all TVNZ stuff.
SitePublisherID = 963482467001
EDIT - digging around in the federatedVideo/BrightcovePlayer.swf, there may be several TVNZ publisher IDs.
TVNZ_PUBLISHER_IDS:Array = [963482464001, 963482467001, 945142951001, 742378304001, 1101631991001]

The other number is the SiteVideoID which seems to be very mysterious to generate.
SiteVideoID = 1461543813001

Here is a URL which will let you play any TVNZ video
Where you see 'videoPlayer=ref%3A' - just replace 4732141 with the episode ID (which can be found in the URL to any specific episode), or the XML files you identified earlier.

If you put that URL into RTMPDump it seems to extract an FLV file successfully, but not sure if that is helpful.

Code:
http://admin.brightcove.com/viewer/us20120221.1317/BrightcoveBootloader.swf?playerID=1257248093001&playerKey=AQ~~%2CAAAA4FQHurk~%2Cl-y-mylVvQmMeQArl3N6WrFttyxCZNYX&%40videoPlayer=ref%3A4732141&autoStart=&bgcolor=%23FFFFFF&debuggerID=&flashID=myPlayer&height=412&isVid=true&showNoContentMessage=&width=486


The BrightcoveBootloader.swf then passes a bunch of parameters through to
Code:
http://admin.brightcove.com/viewer/us20120221.1317/federatedVideo/BrightcovePlayer.swf

I think that BrightcovePlayer.swf is where it works out the RTMP URL. I've had a look through the decompiled code but haven't managed to spot anything too exciting.. it seems like it may have to set a special cookie or something which then allows the flash player to access the Brightcove API and get the RTMP URL.



FYI, if it helps anyone else investigating, this code will let you embed any video in an html file. Just change the number in the @videoPlayer field to change to a different video.
Code:
<html>
<head></head>
<body>
<script  language="JavaScript" type="text/javascript" src="
http://admin.brightcove.com/js/BrightcoveExperiences.js"></script>
<object id="myPlayer"  class="BrightcoveExperience">
<param name="bgcolor" value="#FFFFFF" />
<param name="playerID" value="1257248093001" />
<param name="playerKey" value="AQ~~,AAAA4FQHurk~,l-y-mylVvQmMeQArl3N6WrFttyxCZNYX" />
<param name="isVid" value="true" />
<param name="overrideAds" value="true" />
<param value="ref:4732141" name="@videoPlayer" />
</object>
</body>
</html>


There are some other calls going off to Tubemogul with Cookies and JSON but not sure if they are important or just for some sort of metrics.
Reply
  • 1
  • 10
  • 11
  • 12(current)
  • 13
  • 14
  • 20

Logout Mark Read Team Forum Stats Members Help
[Request] TVNZ OnDemand2