• 1
  • 4
  • 5
  • 6(current)
  • 7
  • 8
  • 60
[RELEASE] Home Theater Experience (Script)
#76
CyberMaxX Wrote:Söder and to others who may find this reply useful:
From the First Post of this Thread



So, if you want your "Home Theater Experince" Script to emulate how the Apple Movies Trailers LITE script gathers it's information (meaning use of no database and only listing current movies) then Change the Scraper Settings to "Apple Movie Trailers (current)"

BUT: I deduced the following from looking at the code and from how the feature set is worded above.
I can see how this may lead to some confusion as I was confused a bit myself until I dug into it.

1) If you select - "Apple Move Trailers (database)" note the keyword "requires" the AMT script in the Features list above.
This means that you MUST have the Regular AMT Script installed, and that you ran the AMT Script at least once to poplulat the database. You also need to set the correct path to where the AMT.db is located.

2) If you select - "Apple Movie Trailers (current)" note the keyword "same source" in the Features list above.
This means that the Home Theater Experince script will use the same source to get the information but it DOES NOT need The Apple Movies Trailer LITE Plugin to be installed to do so. The script literally uses the same "type of coding process" in it's own scipts to generate the information needed from the Apple Site.

I confirmed #2 by just comparing the code between the Home Theater Experince Script and Apple Movies Trailer LITE plugin.

I'm pretty sure this is what NUKA1195 meant by "same source", but anyone feel free to correct me.

Now "Are you Experinced?" for those of you who are having problems with railers playing.

Based on this thread I was able to get the Home Theater Experince Script working again with selecting and showing trailers do to the recent changes that the Apple Site had made. The XBMC Team is aware of what is needed and you can follow this trac if you are interested. For the exact cause of the issue at hand read this.

In the mean time, if you want your "Experience" back you will need to make some changes: (or wait until the XBMC Team patches it all up)

For those who like and selected the setting Apple Movies Trailers (current) do this:
Locate and edit the scraper.py file in \scripts\Home Theater Experience\resources\scrapers\amt_current

Change the following block of code near line 96:
Code:
trailer = re.findall( "<large[^>]*>(.*?)</large>", preview[ 0 ] )[ 0 ]
# replace with 1080p if quality == 1080p
if ( self.settings[ "trailer_quality" ] == 3 ):
    trailer = trailer.replace( "a720p.m4v", "h1080p.mov" )

by adding to the block the below line which is in bold
Code:
trailer = re.findall( "<large[^>]*>(.*?)</large>", preview[ 0 ] )[ 0 ]
[b][size=small]trailer = trailer.replace( "movies.apple.com", "www.apple.com") [/size][/b]
# replace with 1080p if quality == 1080p
if ( self.settings[ "trailer_quality" ] == 3 ):
    trailer = trailer.replace( "a720p.m4v", "h1080p.mov" )

For those who like and selected the setting: Apple Movie Trailers (database) do this:
Locate and edit the scrapers.py file in \scripts\Home Theater Experience\resources\scrapers\amt_database

Change the following block of code near line 129:
Code:
# if there was a valid trailer set it
url = ""
if ( choice >= 0 ):
url = trailers[ choice ]
# return choice
return url

by adding to the block the below line which is in bold
Code:
# if there was a valid trailer set it
url = ""
if ( choice >= 0 ):
url = trailers[ choice ]
[b][size=small]url = url.replace( "movies.apple.com", "www.apple.com" )[/size][/b]
# return choice
return url

Enjoy your "Experince" everyone Big Grin
CyberMaxX

I will try this. Thank you.

I have problem with my AMT Lite at the moment also, dont know why... I hope this work for this script then.

/Söder
Vero 4K with unRAID server and mysql (mariadb)
#77
soder Wrote:I will try this. Thank you.

I have problem with my AMT Lite at the moment also, dont know why... I hope this work for this script then.

/Söder

Söder
Read this Thread post #114 to fix AMT Lite.

Cheers
CyberMaxX
#78
CyberMaxX Wrote:Söder
Read this Thread post #114 to fix AMT Lite.

Cheers
CyberMaxX

Thanks. I now got the AMT Lite to work, a little bit. It seems like the server is to slow for stream, and it takes some time to download the trailer. Like 3-5 min. I use 720p.

BTW, your PM, I dont understand if I should give an answer or not...or if it was a question or a statement. =)

/Söder
Vero 4K with unRAID server and mysql (mariadb)
#79
Yeah I think the streaming issue may be more on the server end than ours, seems that Apple's not as generous with the bandwidth and streaming these large HD-size trailers isn't as instant as it used to be. Still, I'd rather wait for the trailer to start and play thru smooth all the way than have it start instantly then stop 10/15 seconds in to buffer.
#80
Thanks for the PM -- I got it to work by putting the xml in the same folder as the slides. Wish there was better documentation, simple solution but just not explained anywhere.

I have the slides working now but it looks to be just showing them in question order, like 1, 2, 3, etc...I was hoping it would pull randomly but I've tested it 5 times now and same sequence every time (with the 5 slides I added). I tried skipping a number to, using a Q200.jpg and a Q1.jpg (thinking I could use number ranges to classify slide types) and that didn't like it at all. I think if a number in the sequence is missing, it stops.

Maybe there is a random option in the code or something I need to dig for, I don't see any option in the onscreen settings to randomize slides.

Progress though.
#81
BDPNA Wrote:Thanks for the PM -- I got it to work by putting the xml in the same folder as the slides. Wish there was better documentation, simple solution but just not explained anywhere.

I have the slides working now but it looks to be just showing them in question order, like 1, 2, 3, etc...I was hoping it would pull randomly but I've tested it 5 times now and same sequence every time

Odd - after figuring out that the slides.xml goes into the folder with the slides, mine display in a random order as a group.

So If I have a 3 slides per group and 8 groupings the order they appear would be something like

#8question, #8clue, #8answer
#3question, #3clue, #3answer
#7question, #7clue, #7answer
#1question, #1clue, #1answer
etc etc

check you slides.xml file, I thought I saw in the Post that it uses REGEX so insure that the strings you are checking match the slide names.

For me having my slides named in this convention -
q1.jpg (for question), q1c.jpg (for clue), q1a.jpg (for answer)

This slides.xml produced a random grouping selection

Code:
<slides>
  <slide>
      <question format="q[0-9].jpg" />
      <clue format="q[0-9]+c.jpg" />
      <answer format="q[0-9]+a.jpg" />
  </slide>
</slides>


Hope this helps
Cheers
CyberMaxX
#82
soder Wrote:BTW, your PM, I dont understand if I should give an answer or not...or if it was a question or a statement. =)

/Söder


I think it was more of a statement Blush
#83
Here's my slides.xml:

Quote:<slides>
<slide>
<question format="Q[0-9].jpg" />
<clue format="n/a" />
<answer format="Q[0-9]+a.jpg" />
</slide>
</slides>
Slides named as follows:

Q1.jpg Q1a.jpg , Q2.jpg Q2a.jpg, etc.

Slides always play in same order...1, then 2, then 3, etc...
#84
Got it randomizing now, but I am up to around 90 or so slides (Q&A) and they are no longer matching the A with the Q for some reason...Gonna drop it back down to 10 slides and see if it's the sheer amount causing the problem.

Yeah, that did it -- As soon as I went above 10 slides it started scrambling Q&As. I assume I need to change the regex from something different than 0-9 when I am going into double digits...Maybe it's the fact I am not using the +q after my [0-9] for the question type and RE only allows for a single digit number in that case? Just grasping. I dunno.
#85
Can anyone else with this plugin test something for me?

I am trying to run it with local trailers. Turned off all other features and just tried to have it play a random trailer from a folder local (well, a network folder, but you get the idea). Anyway, it's not working. Turned off all other options so it should ONLY play the trailer when I run the script.

Can anyone else try this and tell me if it's working for them? The trailer folder contains all HD MOV files downloaded from apple quicktime site.

Thanks.
#86
BDNA:
In the first page post it tells us.
- "Local folder" trailer recursive scraper (local network also eg smb://, trailers must be named with "-trailer in the name).
this means your trailer will be changed from something.mov to something-trailer.mov then it will play. i am running ver 1.4 with transparency v2 on build 22905 and it works fine with the theatre button in movie info.
regards
#87
BDPNA Wrote:.......

Yeah, that did it -- As soon as I went above 10 slides it started scrambling Q&As. I assume I need to change the regex from something different than 0-9 when I am going into double digits...Maybe it's the fact I am not using the +q after my [0-9] for the question type and RE only allows for a single digit number in that case? Just grasping. I dunno.

Correct the REGEX format needs to be changed within the slides.xml file that is located in the same folder where you have placed all of your slides.

The following slides.xml will increase your slide count to 1000.
Starting from 000 ending at 999

Your slide groupings need to follow this naming convention.
Note: The use of leading zeros are optional.
This REGEX string will work with or without them. For the OCD type's like me, I would use them to keep the file names looking consistent within the folder.
  • q###q.jpg for question slides
  • q###c.jpg for clue slides
  • q###a.jpg for answer slides

slides.xml
Code:
<slides>
    <slide>
        <question format="q([0-9]{1,3})q\.jpg" />
        <clue format="q([0-9]{1,3})c\.jpg" />
        <answer format="(q[0-9]{1,3})a\.jpg" />
    </slide>
</slides>

If you wish to change the total # of slides in a group.
Change {1,3} to {1,2} and this will change the slide count from 000-999 to 00-99.

Cheers
CyberMaxX
#88
Hi guys, but there isn't a way to play trailer from link in the .nfo file? Instead of dowload them all, can be done something like this? However my trailer doesn't start or better it start but only the first trailer and only for about 3 second... Then start film... Why? Someone know this trouble? Thank you. Bye bye
#89
CyberMaxx,

Thanks for the updated regex. Here is the current format I have my files in.

I do not use clues.

Q10q.jpg Q10a.jpg
Q1q.jpg Q1a.jpg
Q100q.jpg Q100a.jpg

I am finding that my original regex that I posted is scrambling slides up. However, there is a gap in the sequence in some spots. Is the gap what is causing the scramble or is it my regex? So you are basically saying if I want hundreds of slides, I need to rename my questions to Q001q.jpg and Q001a.jpg and use your regex? There is no way, with the default regex, to use the format I am using now?

Thanks for any advice. Also curious on the gap in sequence thing, I find it hard to believe it gets the script messed up but it's possible (I guess I can just test by removing the gaps but I'd rather not if I didn't have to, for groupings sake).
#90
Anyone using this with m3u playlists for the coming attractions or feature pre-show? I have two vids I want it to play. Tried one, works fine, as soon as I try an m3u, it bombs. Playlist it builds looks perfect too, yet it just skips right over my coming attractions videos and before feature videos, plays my local trailers, and that's it. Weird. It's like it doesn't like playlists or something.

Dang thing works perfect if I do random, or select 1 video, but as soon as I try m3u playlist, boom. No dice. Can anyone else test with m3u and let me know if you have better luck?
  • 1
  • 4
  • 5
  • 6(current)
  • 7
  • 8
  • 60

Logout Mark Read Team Forum Stats Members Help
[RELEASE] Home Theater Experience (Script)4