Kodi Community Forum
[RELEASE] Cinema Experience - the new Home Theater Experience Script - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Program Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=151)
+---- Thread: [RELEASE] Cinema Experience - the new Home Theater Experience Script (/showthread.php?tid=87563)



- jitterjames - 2011-11-10

jingai Wrote:I haven't actually looked at the code for the plugin, but I presume these Pause/Resume events are different than the ones XBMC sends out. We're talking specifically for the Home Automation scripting that gets called when the video is Paused, which he has said occurs after that 1.5 second delay.

-j
I'm just saying you could use the XBMC triggers to control your lights and then this wouldn't be a problem for you. But I guess there could be reasons why you wouldn't want to do that.


- jitterjames - 2011-11-10

giftie Wrote:The pause trigger is somewhat separate from the other triggers. It tests to see if there has been any change in the video time, if there is not a change for about 1.5 seconds the script thinks it is paused. Are your intro/outdo videos stored on a network share? If so, that would explain it, as it can take a short time to start playback. I could add a setting that would allow the user to select this time(still have the default @ 1.5 seconds, just allow for a change ie sensitivity)

And the resume trigger always follows the pause, so fixing the delay before a pause is triggered will fix that as well.

Giftie, why not use http command GetCurrentlyPlaying to check if PlayStatus = Paused before sending that event?


- jingai - 2011-11-10

jitterjames Wrote:I'm just saying you could use the XBMC triggers to control your lights and then this wouldn't be a problem for you. But I guess there could be reasons why you wouldn't want to do that.

Ah, I see what you mean. Honestly I'd just assumed Giftie had a reason for doing it this way, but we'll see when he responds.

-j


- giftie - 2011-11-11

jitterjames Wrote:Giftie, why not use http command GetCurrentlyPlaying to check if PlayStatus = Paused before sending that event?

I try to keep as much HTTP API out of the script as possible and at the time there was not a JSON RPC command(now there is for Eden). Python has access to certain aspects(ie is video playing) but XBMC does not show a difference between stopped and paused(both show as stopped) A true stop will respond with Playback ended.


- jubilex - 2011-11-11

Hi, having a problem getting CE to work using MPC as an external player with 10-30 nightly build. The problem seems to be at the playlist creation, here is what I think is the relevant bit (can pastebin full log if needed):

Code:
01:36:47 T:1408   DEBUG: Connecting to sqlite:C:\Program Files (x86)\XBMC port2 nightly\portable_data\userdata\Database\:MyVideos57.db
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Queued Movie Information
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] ----------------------------------------------------------------------
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Title: 13 Assassins
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Path: 13 Assassins 2010 1080p BluRay x264-EbP
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Genre: Action / Adventure / Drama
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - MPAA: R
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Audio: ac3
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ]  ----------------------------------------------------------------------
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Feature - 13 Assassins
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Storing Playlist
01:36:47 T:3036   DEBUG: [script.cinema.experience] - JSONRPC -
                                            {"error":{"code":-32601,"message":"Method not found."},"id":1,"jsonrpc":"2.0"}
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Error - Playlist Empty



- giftie - 2011-11-12

I should really stop answering these questions about problems when a much needed full debug log is asked for

I think you are trying to run version 1.0.53 on a Eden Version of XBMC(I'm guessing since I don't have a debug log.) 2.0.53 is for Eden, 1.0.53 is for Dharma.

jubilex Wrote:Hi, having a problem getting CE to work using MPC as an external player with 10-30 nightly build. The problem seems to be at the playlist creation, here is what I think is the relevant bit (can pastebin full log if needed):

Code:
01:36:47 T:1408   DEBUG: Connecting to sqlite:C:\Program Files (x86)\XBMC port2 nightly\portable_data\userdata\Database\:MyVideos57.db
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Queued Movie Information
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] ----------------------------------------------------------------------
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Title: 13 Assassins
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Path: 13 Assassins 2010 1080p BluRay x264-EbP
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Genre: Action / Adventure / Drama
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - MPAA: R
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ] - Audio: ac3
01:36:47 T:3036   DEBUG: [ script.cinema.experience ] - [ ce_playlist.py ]  ----------------------------------------------------------------------
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Feature - 13 Assassins
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Storing Playlist
01:36:47 T:3036   DEBUG: [script.cinema.experience] - JSONRPC -
                                            {"error":{"code":-32601,"message":"Method not found."},"id":1,"jsonrpc":"2.0"}
01:36:47 T:3036  NOTICE: [script.cinema.experience] - Error - Playlist Empty



CinEx is the bomb - boblinds - 2011-11-12

Giftie:

I should have sent you this report sooner but....

My friend visited last weekend and was absolutely delighted when I showed him CinEx. He works at Universal (one of his scripts was just filmed as a cable TV movie). He was so impressed that I could sequence an entire movie experience with a single button press. (He used to do this in his home theater--which I installed for him--using multiple DVD/BD players.)


- JonSnow - 2011-11-13

Does anyone know where I can download the Pearl and Dean intro video from. I really want this as part of my Cinema Experience but I cant seem to find it.


- JonSnow - 2011-11-13

Never mind. I downloaded it from the Pearl and Dean website.


Problem solved - darkzone - 2011-11-13

Thanks, my problem is now solved.

Haven't faced any other problems with the new version so far but I'll be sure to post if something comes up.

giftie Wrote:About two pages back there is a post about the test versions. I want these tested out as there can be problems. You'll need the 2.0.53 version as you are on Eden

Here are some new test versions...

Dharma Version 1.0.53 -> http://www.mediafire.com/file/6r7d1pqnfeib7xx/script.cinema.experience.1.0.53.zip
Eden Version 2.0.53 -> http://www.mediafire.com/file/3s3l2g3pvmenk02/script.cinema.experience.2.0.53.zip



- Invincer - 2011-11-14

giftie Wrote:That is why the file is pretty much empty, for users to build upon it.

Any chance you can post the full file to pastebin, as the code posted is incomplete(probably due to forum rules)? I'm sure others would want to use it, or build from it.

Thanks

Sorry about that Giftie,

I had not realized the script had cut off when I posted it. i now have it working grade A perfect, at least for what I want it to. I will post a couple videos to demonstrate the effects (not the greatest video I ever shot, but needed it to be dark to see the lights etc). It also shows off what a little planning can do for the fluidity in your script as an experience on the whole. So bear through it if you want to see something a "little" different with the home automation.

I have two Rock Gear spotlights under the TV that are on X10 A1 settings for the script to be be turned on and off at certain points. The lights dance changing intensity based on the sounds which is kid of cool (got it for Rock Band but will use it more for this). The A2 setting is the lamp which I have at either on 30%, off, or on 100% when it flashes before movie starts.

For something new you may not have seen or heard of which I have been working on I have found a way to match up my old Betabrite sign to your python code called as a subprocess. If anyone wants to try it i can point them in the general direction, and there has to be easier ways to go about it, but hey, documentation is sketchy at best out there on the betabrite and I got it working thanks to making some autohotkey exe files and calling them at trigger points in your script.

The ambient lights behind the TV is the ARFX module, and presently is not linked to the script. i may or may not link it, but will probably just leave it on throughout at this lesser intensity for less distractions during actual shows.

Okay, so here are the vids... http://youtu.be/74Jn9nObOMU and part 2 http://youtu.be/mPpNlO2scz0 ;
they are dark, bear through them; if they are too hard to see I may try to reshoot them with my iPad, haven't tried the video on it but it has to be better than my phone I would think...

Will post the working code for the home auto script in a few short minutes, had to change computers after uploading vids to youtube


- giftie - 2011-11-14

All I can say is Wow! Nice work...


- Invincer - 2011-11-14

...and here is my working code as promised...

http://pastebin.com/GH8yEkfG


- timdog82001 - 2011-11-14

very cool, invincer! any chance you might upload the video files you used in your cinema experience? at least the modified ones?


- m0v1em4n - 2011-11-14

Invincer Wrote:...and here is my working code as promised...

http://pastebin.com/GH8yEkfG

Hi Invincer

Thanks for posting your script.

If I could ask you a few questions
At the moment I am using another xbmc plugin and Homeseer to control my light when a movie is played and paused, But the problem with it is when CE goes from trailers to intros etc. the light raise and lower, presume because of the pauses between them, would this script do the same?
.
also if I wanted to edit the script to say have nothing happen under Trivia intro would I change "true" for none

Code:
# Trivia Intro
    elif trigger == _L_( 32609 ) and _S_( "ha_trivia_intro" ) == "true":
        xbmc.log( "[script.cinema.experience] - [ home_automation.py ] - %s Triggered" % _L_( 32609 ), level=xbmc.LOGNOTICE )
        # place code below this line
        urllib2.urlopen('http://localhost:8086/?x10command=DEVICE~sendrf~"A1 ON"')

or would it be ok to just delete

Quote:urllib2.urlopen('http://localhost:8086/?x10command=DEVICE~sendrf~"A1 ON"')

Also when a movie is paused presume the lights would come on to dim?

hope you don't mind the questions I am a script new B Huh