[REQUEST] CTV/TSN/Comedy Network Plugin?

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
pmcd Offline
Fan
Posts: 305
Joined: May 2008
Reputation: 0
Post: #51
Eldorado Wrote:Woo hoo!

Maybe a new repository should be setup specifically for Canadian content addons?

There is one that works for Plex. I wonder if it would also work for XBMC? It has a lot of options including the Food network, Global, etc ....

philip
find quote
andre_pl Offline
Senior Member
Posts: 103
Joined: Aug 2009
Reputation: 0
Post: #52
bolverk Wrote:Check out a quick Perl hack at http://pastebin.com/bk25b575 and you'll see you're doing it right except you have to pass swfUrl as well, otherwise the other end shoots back an access denied. I don't know how to do that in python or XBMC's plugins library, but I hope that's as straightforward as it is with rtmpdump.
-Dan

Thanks Dan,
That works perfectly, new version of the plugin is ready to be pulled to your repository.
find quote
bolverk Offline
Junior Member
Posts: 14
Joined: Mar 2011
Reputation: 0
Post: #53
Version 1.1.3 is up with working ComedyNetwork. Thanks, andre_pl!
find quote
andre_pl Offline
Senior Member
Posts: 103
Joined: Aug 2009
Reputation: 0
Post: #54
I've started a thread for my CTV Properties plugin, please direct support/feature requests there.

http://forum.xbmc.org/showthread.php?tid=96076
find quote
andre_pl Offline
Senior Member
Posts: 103
Joined: Aug 2009
Reputation: 0
Post: #55
I can't believe I didn't notice this earlier!! I just spent two hours playing around with it, and only managed to figure out about half of that.

Thanks a ton. I'm definitely planning to implement CBC and Global, at which point I'll probably have to rename the plugin.

teefer22 Wrote:Wow, that sure didn't take you long. Good work andre_pl. I was working on the TSN.ca one a little bit yesterday but definitely didn't finish.

Since you were so good at that, I'm going to post how to get the links for cbc.ca and globaltv.ca.. Just in case you feel like making any more plugins. Smile


Here is how to get the rtmp for globaltv.com:
First, we need the link from your browser:
http://www.globaltv.com/video/full+episo...1812768546

Inside the html of that page you will find this piece of code. What we want is the PID:
<script type="text/javascript">
var embed_vars = {
pid: "_X8TGqDQ62nnBowQOnYA5kcHIuS58lRv",
contentID: "1812768546",
show: "Survivor",
season: "22",
episode: "2",
se: "S22E2:",
cliptitle: "you+own+my+vote"
};
</script>


Put the pid into this link:
http://release.theplatform.com/content.s...cHIuS58lRv

and that will return a document with this in it:
<switch>
<video src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_lowest_16x9.mp4" system-bitrate="447277" width="400" height="224" type="video/mp4"/>
<video src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_low_16x9.mp4" system-bitrate="647304" width="400" height="224" type="video/mp4"/>
<video src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_medium_16x9.mp4" system-bitrate="850244" width="852" height="480" type="video/mp4"/>
<video src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_high_16x9.mp4" system-bitrate="1252684" width="852" height="480" type="video/mp4"/>
<video src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_highest_16x9.mp4" system-bitrate="2419958" width="1280" height="720" type="video/mp4"/>
<ref src="rtmp://cp90709.edgefcs.net/ondemand/video/Survivor2202_lowest_16x9.mp4" title="You Own My Vote" author="Global" abstract="On Ometepe, Phillip tries to repair the damage after his outburst at the last Tribal Council. So he tells Rob that he will do whatever and vote for whoever he says. Later, Rob sees Matt with Andrea and plans to break up the duo knowing how powerful a couple can go." copyright="© Canwest Broadcast Entertainment" dur="2579736ms" width="400" height="224" guid="h1OBBD79dDfp345_knDVPM5y4KT5ebY7" provider="Canwest Broadcast Entertainment" categories="GlobalTV,GLOBVC3,GLOBVC3/Shows/Survivor/Full Episodes,MOBGLOB/Survivor%3A Redemption Island,MOBGLOB/Survivor%3A Redemption Island/Full Episodes,z/Global Show - Survivor,z/Global Video Centre,z/Mobile GlobalTV" keywords="Entertainment;Programming" type="video/mp4" tp:ChapterEndTimes="00:07:36,00:12:39,00:21:49,00:31:17,00:42:12" tp:ChapterStartTimes="00:07:36,00:12:39,00:21:49,00:31:17,00:42:12" tp:Clip_Type="episode" tp:Episode="2" tp:MobileRotatorActionType="Show" tp:Network="Global" tp:Season="22" tp:Show="Survivor" tp:Subject="Entertainment" tp:Web_Exclusive="No" tp:dpcjobid="142304" tp:isHD="true" tp:mDialogIngestSuccess="true" tp:syndRODO="true"/>
</switch>
<switch>

The rtmp links are right there for you, no auth codes or anything tricky. And those links will stay valid for months (even after globaltv.com removes the link from their website).


Here is how to get the rtmp for cbc.ca/video

we will use this link as an example:
http://www.cbc.ca/video/#/Shows/12212543...1817810978

first we need to get the "ID" (1817810978 in this example) from the original http browser location. Then we need to put that ID in the next link. This will give us the real PID.
NOTE: the PID below (_DyE_l....) is the same for every cbc.ca link, it does not identify the video
http://cbc.feeds.theplatform.com/ps/JSON...1817810978

that will return this line: (What we want is the PID (this is the real PID this time))
{"context":"","listInfo":{"itemCount":1,"totalCount":1},"items":[{"PID":"MBboAGCCmaL97NWHlbkucTYjEVwfC5Uz","title":"Episode 102"}],"removedIDs":[]}

#We now have the real PID, we can now enter that PID into the url below to get the rtmp and playpath locations
http://release.theplatform.com/content.s...YjEVwfC5Uz

That will give us this:
<meta base="rtmp://cp37429.edgefcs.net/ondemand/?auth=daFaEaBa6cXdxd2bKaHbwbvdFcPcvcrccaz-bnz8oN-b4-lks_Ksw1xmGpDAy&amp;aifp=v0001&amp;slist=netstorage" />
</head>
<body>
<ref src="netstorage/George_Strombo_Tonight_102_2155-2-24-2011.flv" title="Episode 102" author="George Stroumboulopoulos Tonight" abstract="Best of Show with Jim Parsons and John Leguizamo." copyright="© CBC Production" dur="1467104ms" width="640" height="360" guid="7I3gl5O1DHC9GcYIp3WGiLju3upag8NV" provider="CBC Production" categories="Shows/George Stroumboulopoulos Tonight,Shows/George Stroumboulopoulos Tonight/Guests,Shows/George Stroumboulopoulos Tonight/Season 7" keywords="George Stroumboulopoulos, George, George Tonight, Strombo, George Stroumboulopoulos Tonight, Jim Parsons, John Leguizamo," tp:Account="Entertainment" tp:AdCategory="george" tp:AdSite="cbc.george.ca" tp:Aired="true" tp:AudioVideo="Video" tp:AvailableInHD="(not specified)" tp:BylineCredit="CBC/Radio-Canada" tp:CBCPersonalities="George Stroumboulopoulos" tp:Camera="(not specified)" tp:ChapterStartTimes="10:01, 13:41" tp:ClipType="Full Program" tp:CommentsEnabled="Yes" tp:EpisodeNumber="102" tp:FeatureImage="http://thumbnails.cbc.ca/maven_legacy/thumbnails/George_Strombo_Tonight_102_2155-2-24-2011_444x250__559856.jpg" tp:Genre="Entertainment" tp:LiveOnDemand="On-Demand" tp:Region="(not specified)" tp:RelatedURL1="George Stroumboulopoulos Tonight website|http://cbc.ca/strombo/|_blank" tp:SeasonNumber="7" tp:Show="George Tonight" tp:Sport="(not specified)" tp:Subtitles="No" tp:adRules="2_2_0"/>
</body>
</smil>

what we want is:
rtmp://cp37429.edgefcs.net/ondemand/?auth=daFaEaBa6cXdxd2bKaHbwbvdFcPcvcrccaz-bnz8oN-b4-lks_Ksw1xmGpDAy&amp;aifp=v0001&amp;slist=netstorage

netstorage/George_Strombo_Tonight_102_2155-2-24-2011.flv

transform that into (notice i removed the ampWink:
rtmp://cp37429.edgefcs.net/ondemand/?auth=daFaEaBa6cXdxd2bKaHbwbvdFcPcvcrccaz-bnz8oN-b4-lks_Ksw1xmGpDAy&aifp=v0001&slist=netstorage playpath=netstorage/George_Strombo_Tonight_102_2155-2-24-2011
find quote
teefer22 Offline
Member
Posts: 97
Joined: Dec 2010
Reputation: 27
Post: #56
andre_pl Wrote:I can't believe I didn't notice this earlier!! I just spent two hours playing around with it, and only managed to figure out about half of that.

Thanks a ton. I'm definitely planning to implement CBC and Global, at which point I'll probably have to rename the plugin.

Awesome! Great work on the CTV+ plugin. I'm so pumped to hear you are going to work on global and cbc next. Just a heads up on the CBC, any of the live sports have an oddball rtmp string.. If I get a chance next time there is a live streaming hockey game, I'll see if I can figure out how to get it to play in xbmc and post back.

I actually figured out the how to find the rtmp for ctv, global and cbc because I wrote a processors for navi-x for global, cbc, and ctv's family but then realized that making a scraper for navi-x was too hard (for me) and had a serious lack of documentation and examples so I then started looking at making a plugin like this in xbmc (also hard (for me at least) but at least there is tons of examples).

Again, thanks for doing this. Great work.
find quote
bolverk Offline
Junior Member
Posts: 14
Joined: Mar 2011
Reputation: 0
Post: #57
teefer22, maybe you can help with this one:

I'm trying to get the rtmp URL to use for live streams on TSN. There's one today at 2:30pm Eastern under Championship Curling on Demand / Tim Horton's Brier Live.

Here's what I've captured that flash sends:
Code:
app: live?ovpfv=2.1.4
flashVer: WIN 10,2,152,26
swfUrl: http://watch.tsn.ca/Flash/player.swf?themeURL=http://watch.tsn.ca/themes/TSN/player/theme.aspx
tcUrl: rtmp://cp52820.live.edgefcs.net:1935/live?ovpfv=2.1.4
pageUrl: http://watch.tsn.ca/#clip428645
Playpath: TSN-LIVE33-FLASH@37547

But I'm having no luck. I've got the following rtmpdump commandline to send *exactly* that, but it's not finding the stream...

Code:
rtmpdump -z -r 'rtmp://cp52820.live.edgefcs.net/live?ovpfv=2.1.4' -y 'TSN-LIVE33-FLASH@37547' -s 'http://watch.tsn.ca/Flash/player.swf?themeURL=http://watch.tsn.ca/themes/TSN/player/theme.aspx' -o out.flv -t 'rtmp://cp52820.live.edgefcs.net:1935/live?ovpfv=2.1.4' -p 'http://watch.tsn.ca/#clip428645' -f 'WIN 10,2,152,26' -a 'live?ovpfv=2.1.4'

The key error seems to be here from the server:
Code:
DEBUG: Property: <Name:              level, STRING:     error>
DEBUG: Property: <Name:               code, STRING:     NetStream.Play.StreamNotFound>
DEBUG: Property: <Name:        description, STRING:     Failed to play TSN-LIVE33-FLASH@37547; stream not found.>
DEBUG: Property: <Name:            details, STRING:     TSN-LIVE33-FLASH@37547>
DEBUG: Property: <Name:           clientid, STRING:     5ILYZHdG>

Can you see anything that stands out at you? I'm at the beating my head against a wall stage.

-Dan
(This post was last modified: 2011-03-07 19:18 by bolverk.)
find quote
teefer22 Offline
Member
Posts: 97
Joined: Dec 2010
Reputation: 27
Post: #58
bolverk Wrote:Can you see anything that stands out at you? I'm at the beating my head against a wall stage.

-Dan

Put this in an strm file (with notepad) and load it with xbmc:
rtmp://cp52820.live.edgefcs.net:443/live?ovpfv=2.1.4 playpath=TSN-LIVE33-FLASH@37547 live=true

for andre_pl:

I'm 90% sure the "live=true" at the end is what we need to add to get the live streams from tsn (such as the curling that's live on TSN right now) and the cbc live streams working in your plugin. There doesn't appear to be any auth codes with the live video.
(I haven't done a ton of testing, but the rtmp string above plays the live curling for me right now)
(This post was last modified: 2011-03-08 00:32 by teefer22.)
find quote
andre_pl Offline
Senior Member
Posts: 103
Joined: Aug 2009
Reputation: 0
Post: #59
Thanks teefer22, I've implemented it, but I have nothing to test with at the moment, the brier is still listed on TSN but its not working even on their webpage. if anyone knows when the next live stream will be available for testing let me know.
find quote
bolverk Offline
Junior Member
Posts: 14
Joined: Mar 2011
Reputation: 0
Post: #60
andre_pl Wrote:Thanks teefer22, I've implemented it, but I have nothing to test with at the moment, the brier is still listed on TSN but its not working even on their webpage. if anyone knows when the next live stream will be available for testing let me know.

The Brier will air live on the web again at 9:30am tomorrow until Draw 9 ends, then again at 2:30pm until Draw 10 ends. (Eastern time).

Thank you very much teefer for the live tip!

-Dan
find quote
Post Reply