Auto download Subtitle

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
EZ1976 Offline
Senior Member
Posts: 263
Joined: Apr 2012
Reputation: 1
Post: #1
Hi everyone.
love this plugin so thanks a bunch for it.

i have a question: my plugin is set to autodownload "sync" version but is it possible to tell him to autodownload as soon as the movie or tv series starts?
for example if the show or movie doesnt have a subtitle file present, it should check and see if there is one available?
thanks
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #2
(2012-04-16 10:37)EZ1976 Wrote:  Hi everyone.
love this plugin so thanks a bunch for it.

i have a question: my plugin is set to autodownload "sync" version but is it possible to tell him to autodownload as soon as the movie or tv series starts?
for example if the show or movie doesnt have a subtitle file present, it should check and see if there is one available?
thanks

Not possible atm, there is no way to run the script when the movie starts... Might look into it at some point
find quote
EZ1976 Offline
Senior Member
Posts: 263
Joined: Apr 2012
Reputation: 1
Post: #3
thank you for the quick reply.
is it possible to assign a keyboard key or a remote key to the script?
that way i can just press on key and have the subtitle downloaded (even a better idea than the original)
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #4
(2012-04-16 10:48)EZ1976 Wrote:  thank you for the quick reply.
is it possible to assign a keyboard key or a remote key to the script?
that way i can just press on key and have the subtitle downloaded (even a better idea than the original)

Yes, add "Runscript(script.xbmc.subtitles)" in your remote keymap, google that and you'll find how to do it
find quote
brunoga Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #5
While we are at it, I have a quick question: I do have the subtitle add-on set to download the first sync subtitle, but this does not seem to work. When i click on the subtitles icon in the OSD, I simply get the window to select the subtitle (after a couple of seconds). Even when the first one listed is marked as async. Am i missing something?
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #6
Only first language is matched against sync
find quote
akiaki Offline
Member
Posts: 52
Joined: Sep 2008
Reputation: 0
Post: #7
Hi, I'm bringing this up again because I come from MediaPortal, and there a plugin is configured that if no subtitle is found, upon selecting play, plugin looks for subtitles.
Can this be coded somehow here? If no subtitle found, search and download if found, if not found show select screen, and if subtitle exists, don't do anything?
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #8
sure, it shouldn't be too difficult... create service addon to monitor for playback start using Player() class and on start if there is no subs for a given file run XBMC Subtitles. set up subtitle addon to auto download "sync" files and you will get what you described above.

Python Docs have everything you need.

if you dont get anywhere with it i'll see if i can do something about it ...
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #9
here try this ... no guaranties ... https://github.com/downloads/amet/script..._0.0.2.zip

install using "install via zip" option under addon manager

source on github -> https://github.com/amet/script.autosubs
(This post was last modified: 2012-11-16 13:47 by amet.)
find quote
akiaki Offline
Member
Posts: 52
Joined: Sep 2008
Reputation: 0
Post: #10
thanks! I'l ltry it and report back when I get home from work!
find quote
akiaki Offline
Member
Posts: 52
Joined: Sep 2008
Reputation: 0
Post: #11
Thank you, after installing and relaunching xbmc it works perfectly!!!!!
You really should include this in the package as an option, I'm sure a lot of people would like this.
I tested on tv series only but I guess it will work for movies too
find quote
akiaki Offline
Member
Posts: 52
Joined: Sep 2008
Reputation: 0
Post: #12
Ok, so its working too good Wink
It looks for subtitles on every video, including youtube, i can live with it if i have to, but can it be enabled somehow only for local files?
find quote
amet Offline
Retired Team-Kodi Member
Posts: 4,111
Joined: Jul 2009
Reputation: 41
Location: Novi Sad / Dubai
Post: #13
https://github.com/downloads/amet/script..._0.0.3.zip

source on the same link ... no more requests Smile
find quote
schumi2004 Offline
Posting Freak
Posts: 1,377
Joined: Aug 2011
Reputation: 14
Post: #14
@amet
Thanks, this makes my XBMC experience even more complete Wink

Edit:
Just 1 minor request, Can it be disabled for Live TV section?
I'm willing to fix it myself if i knew it's possible?

Edit2:
I think i found out how.

On line 37
Change it to:
Code:
if (not xbmc.getCondVisibility("VideoPlayer.HasSubtitles")) and (not movieFullPath.find("http") > -1 ) and (not movieFullPath.find("pvr") > -1 ):

That should do it.
(This post was last modified: 2012-11-19 01:28 by schumi2004.)
find quote
zilexa Offline
Fan
Posts: 319
Joined: Nov 2008
Reputation: 0
Location: Amsterdam
Post: #15
This is soo great, should be included in XBMC by default, inside the subtitle addon! Just a checkbox would do it.
find quote
Post Reply