[WIP] XBMC Flicks (Netflix Addon) Development Thread - Developers Only!
#16
Ok, while I'm sure there's a better way to tell it to use the external player and all that, i've got it working.

when it parses out the movies, it creates a local .html file in c:\netflixlinks, the name of the file is the title_id.html (so each movie/show has it's own link)
The link is just a redirect to the player
When I add the item to xbmc, the url is the local file, which redirects to the player

playercorefactory.xml has been defined with the iexplorer link for .html files
advanced settings has the videoextensions of .html added

(I used .html as it's not as common as .htm, and those "demos" that contain a file always use .htm, which i don't want associated with or opening in IE)

It works like a champ! I don't really like the implementation with writing out a .html redirect file for each item, but they are small files.

Now to figure out the loop issue in rc1 and rc2, then on to figuring out how to get the user auth done in a way that doesn't require you to open the .py files and mod them.
Reply
#17
Ok i've fixed the looping error and just have to sort the user token flow.

This is much better then just opening the web page to view the items or the initial idea of the windows form opening up.

Here's a preview (used fraps, so can't show the link opening, but it opens IE full screen, playing the movie)

http://www.youtube.com/watch?v=SK20ww9R2j4
Reply
#18
Hey fekker, nice work so far Smile I was actually thinking of the exact same idea about a week ago. My question is--how do you control IE/Netflix once it's been opened? Since it's Windows-only, my idea was that you'd have Eventghost wait for IE to launch and then remap the keys based on that. Not sure of a way to make Netflix auto-launch into fullscreen.
Reply
#19
maruchan Wrote:Hey fekker, nice work so far Smile I was actually thinking of the exact same idea about a week ago. My question is--how do you control IE/Netflix once it's been opened? Since it's Windows-only, my idea was that you'd have Eventghost wait for IE to launch and then remap the keys based on that. Not sure of a way to make Netflix auto-launch into fullscreen.

Not sure yet, I'll prob just map the xbmc keys to be the same as the netflix keys since xmbc has the option and silverlight doesn't.

here's some of the command i've found so far.

space OR enter = pause/play
ctrl+alt+shift+left arrow OR just F = full screen
esc = exit full screen
ctrl+spacebar = put it's into frame mode to allow ffwd and rwd using arrow keys
shift + left arrow = rwd
shift + right arrow = ffwd
ctrl+alt+shift+m = menu
alt+f4 = shutdown web page (forcefully)
Reply
#20
pretty much wrapped it up now, anyone care to give it a go?

it requires the following items
1) Must be running Windows - if not stop here
2) You'll need the files - http://rapidshare.com/files/434962835/pl...flicks.zip (updated link to 1.0.1)
3) You must create a folder on your C: drive called netflixlinks (yes, i hard coded that path)
4) Create an empty text file named userinfo.properties in the folder you created in step 3, make sure it's not .txt (i.e. turn off the option in Windows that "hide known file extensions" .. it's called something like that)
5) Need to add the options to playercore and advancedsettings as follows

playercorefactory.xml - Note change the path to IE if your running 32bit
Code:
<playercorefactory>
  <players>
    <player name="IE" type="ExternalPlayer">
     <filename>c:\Program Files (x86)\Internet Explorer\iexplore.exe</filename>
     <args>-k "{1}"</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
    </player>
  </players>

  <rules action="prepend">
    <rule name="html" filetypes="html" player="IE" />
  </rules>
</playercorefactory>

advancedsettings.xml
Code:
<advancedsettings>
  <videoextensions>
    <add>.html</add>
  </videoextensions>
</advancedsettings>

SideNote: (osx would just need the path changed for userinfo and redirects as silverlight works on osx as far as know, no way to test at the moment)
Reply
#21
Might give it a go here in a bit. I'm busy doing some other stuff but would love to see Netflix streaming integrated into xbmc.
Reply
#22
Version 1.0.1
- fixed bad regex, would skip first item in queue and everything would be offset, i.e. when you click on item 3, item 2 would play
- changed default to highest resolution for posters, note: settings lists options for poster quality, but they are not yet used.

http://rapidshare.com/files/434962835/pl...flicks.zip

If you want more then 25 results returned, change the following in iqueue.py
under the method getUserInfo(netflix,user):

change the following line
feeds = netflix.user.getInstantQueue()
to
feeds = netflix.user.getInstantQueue(None,None,500,None)

After testing with a bunch of queue items, it's pretty clear that metadata needs to go in as well, i'll have to see what options there are for that.
Reply
#23
fekker Wrote:Not sure yet, I'll prob just map the xbmc keys to be the same as the netflix keys since XBMC has the option and silverlight doesn't.

here's some of the command i've found so far.

space OR enter = pause/play
ctrl+alt+shift+left arrow OR just F = full screen
esc = exit full screen
ctrl+spacebar = put it's into frame mode to allow ffwd and rwd using arrow keys
shift + left arrow = rwd
shift + right arrow = ffwd
ctrl+alt+shift+m = menu
alt+f4 = shutdown web page (forcefully)


I currently use EventGhost and an AutoHotkey script (http://forums.sagetv.com/forums/showthread.php?t=38969) to accomplish this.
Reply
#24
Ok version 1.0.2

Settings now work - you can pick the quality of the poster, max number of queue items to retrieve, you can choose to add the year to the name, also you can choose to add the summary information to the name, with or without the actor name in there. Note: adding the summary to the name will slow it down as we are limited to 4 request per second by the app, the entire queue is just one request.

Want it fast - Don't add the summary (the year is ok to add as it comes from the queue information and will not slow down things)

it now uses xbmc special folders, instead of a hardcoded path on the c: drive
userinfo is now .txt, instead of .properties, no folders need to be created or text files

It requires the following items
1) Must be running Windows - (might work on OSX as well)
2) You'll need the files - http://rapidshare.com/files/435141501/pl...flicks.zip
3) Need to add the options to playercore and advancedsettings as follows

playercorefactory.xml - Note change the path to IE if your running 32bit
Code:
<playercorefactory>
  <players>
    <player name="IE" type="ExternalPlayer">
     <filename>c:\Program Files (x86)\Internet Explorer\iexplore.exe</filename>
     <args>-k "{1}"</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
    </player>
  </players>

  <rules action="prepend">
    <rule name="html" filetypes="html" player="IE" />
  </rules>
</playercorefactory>

advancedsettings.xml
Code:
<advancedsettings>
  <videoextensions>
    <add>.html</add>
  </videoextensions>
</advancedsettings>
Reply
#25
The add-on works on OSX too for the most part. It gets hung up in the initial authorization process when trying to make the webbrowser.open() call.
The log is here: http://pastebin.com/NpTp4mzg

If you manually authorize the script then it successfully gets the queue and launches shows from the queue.

Not being a python programmer, I'm not having much success figuring out why the webbrowser.open() call fails.
Reply
#26
not sure about the osx one, prob something with how it's locating the browser, need a scripter with osx to help with that one

i've got most the meta data loading now as well

http://www.youtube.com/watch?v=xIJFOw0Sgu4
Reply
#27
Does the API support drilling down to individual episodes in a TV series? Currently, selecting a series/season from the queue will cause it to play the from the first episode, but ideal it should display a list of episodes at that point. Otherwise, it's working great for me, and I was able to use Eventghost/Autohotkey to control playback with a remote.
Reply
#28
fade23 Wrote:Does the API support drilling down to individual episodes in a TV series? Currently, selecting a series/season from the queue will cause it to play the from the first episode, but ideal it should display a list of episodes at that point. Otherwise, it's working great for me, and I was able to use Eventghost/Autohotkey to control playback with a remote.

There are methods to get the list of the episodes for a series, just have to figure out how to work with the context menu's and passing arguments to them.

The API pretty much allows everything that's done on netflix.com site, but i'm not even attempting to match that level of details.

I'm trying to figure out how to remove an item from the queue, as well as find similar items, I've got the API calls done for both of those, keeping them in the user authenticated phase so the hit goes against the users max per day and not the apps. They work, now it's just a matter of figuring out the best way to make that call from the context menu. The tv show episodes are similar calls.

Here's what i've got left on the list
API Calls
- figure out why Directors doesn't return anything from the API

XBMC UI stuff
- figure out why Cast doesn't show up in the UI even when the InfoLabel has been set
- get the right click context menu done
- add the following features to it (maintaining specific details)
--- find similar movies (need moveid and all token info)
--- remove from queue (need movieid and all token info)
--- add to queue (need movieid and all token info)
--- for tv shows, expand episodes (need movieid and all token info)

As you can tell, movieid and token info (which is really all the user level stuff) has to be maintained, even after the script exits, or I just need to be able to pass the movieid to another script, and then re-auth the user
Reply
#29
Hey fekker, just wanted to say great work Smile The rapidshare links aren't working for me, unfortunately. Perhaps you could set up a googlecode page?
Reply
#30
maruchan Wrote:Hey fekker, just wanted to say great work Smile The rapidshare links aren't working for me, unfortunately. Perhaps you could set up a googlecode page?

I'll see what i can find for a place for this.
The link for 1.0.2 should be working, try http://rapidshare.com/#!download|402l32|...ks.zip|212

In other news, i've got the add/remove context menu's working Big Grin it's getting closer
Reply

Logout Mark Read Team Forum Stats Members Help
[WIP] XBMC Flicks (Netflix Addon) Development Thread - Developers Only!1