Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
denimnani committed May 4, 2019
1 parent f20df7f commit e61d465
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 22 deletions.
26 changes: 20 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,23 @@
service.subloader
===============
# Sub Loader

Please be pacient the addon is currently in Alpha stage...

Auto trigger subtitle download if no subtitle (language) is found for a Movie/TV Show.<br>
> ### About Sub Loader
This addon is a fork from from the well known autosubs addon.
All credits to the original developers.
Sub Loader allow you to automatically load subtitles for your content.
It uses OpenSubtitles.org as subtitles source.
There are custom settings to trigger the service.


> ### Issues
Currently the addon is in Alpha stage, there are some bugs and a lot of features to add.
The subloader will not download any subtitles if your content don't provide a valid IMDBNumber.
So, most likly your episodes will not have IMDBNumber because Kodi scrapper do not provide it at episode level.
For the 3 party addons it will work if there is an IMDBNumber and the file name with the media quality.
It will be added in future an auto query search by name if no IMDBNumber was foud.

> ### Development
Sub Loader is a fork from the well known autosubs addon, all credits to the original developers.
It also contains some code from an jen base addon, all credits to the original developers.
I'm not a programmer, all i do is try and error to find a possible solution, so please if some one want's to help pushing this addon forward, be my guest.
25 changes: 18 additions & 7 deletions addon.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<addon id="service.subloader"
name="Sub Loader" version="0.0.6" provider-name="DenimNani">
name="Sub Loader" version="0.0.7" provider-name="DenimNani">
<requires>
<import addon="xbmc.python" version="2.14.0"/>
</requires>
Expand All @@ -13,15 +13,26 @@
<license>GPL</license>
<website></website>
<assets>
<icon>IconSubLoader.png</icon>
<fanart>FanartSubLoader.png</fanart>
<screenshot>resources/media/screenshots/Screenshot1SubLoader.jpg</screenshot>
<screenshot>FanartSubLoader.png</screenshot>
<icon>iconsubloader.png</icon>
<fanart>fanartsubloader.png</fanart>
<screenshot>resources/media/screenshots/screenshot1subLoader.jpg</screenshot>
<screenshot>fanartsubloader.png</screenshot>
</assets>
<source></source>
<forum></forum>
<email></email>
<news>0.0.1
<news>0.0.7
Added Portuguese language
Added ability to choose (subtitle search dialog) as a fallback

0.0.6
Added notifications if enabled

0.0.5
Massive improve on video release types detection
Added ability to choose strict subtitle matching

0.0.1
Sub Loader is a fork from the well known autosubs addon.
All credits to the original developers</news>
</extension>
Expand Down
10 changes: 7 additions & 3 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
0.0.6 - By Denim
- Added notifications if debug is enabled
0.0.7 - By Denim
- Added Portuguese language
- Added ability to choose (subtitle search dialog) as a fallback

0.0.6 - By Denim
- Added notifications if enabled

0.0.5 - By Denim
- Massive improve on video release types detection
- Added ability to choose between strict or flexible subtitle matching
- Added ability to choose strict subtitle matching

0.0.4 - By Denim
- Several fixes
Expand Down
Binary file added fanartsubloader.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added iconsubloader.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 5 additions & 6 deletions monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import hashlib,urllib,os,base64,codecs,xmlrpclib
import gzip, StringIO

from resources.lib.opensubtitles import loadsub#verificar...
from resources.lib.opensubtitles import loadsub


__addon__ = xbmcaddon.Addon()
Expand Down Expand Up @@ -61,8 +61,8 @@ def isExcluded(movieFullPath):
Debug("isExcluded(): Video is playing via Live TV, which is currently set as excluded location.")
return False

if (movieFullPath.find("http://") > -1) and getSettingAsBool('ExcludeHTTP'):
Debug("isExcluded(): Video is playing via HTTP source, which is currently set as excluded location.")
if (movieFullPath.find("http://") > -1 or movieFullPath.find("https://") > -1) and getSettingAsBool('ExcludeHTTP'):
Debug("isExcluded(): Video is playing via HTTP or HTTPS source, which is currently set as excluded location.")
return False

ExcludePath = getSetting('ExcludePath')
Expand Down Expand Up @@ -99,7 +99,7 @@ def isExcluded(movieFullPath):


class SubLoaderPlayer(xbmc.Player):
from resources.lib.opensubtitles import loadsub
#from resources.lib.opensubtitles import loadsub
def __init__(self, *args, **kwargs):
xbmc.Player.__init__(self)
Debug("Initalized")
Expand All @@ -122,7 +122,7 @@ def onAVStarted(self):
#file = xbmc.getInfoLabel('Player.Filenameandpath') #remover depois
#title = xbmc.Player().getVideoInfoTag().getIMDBNumber() #remover depois
#imdb = xbmc.Player().getVideoInfoTag().getIMDBNumber() #remover depois
st = int((__addon__.getSetting('wait_source')))*1000
st = int((__addon__.getSetting('delay')))*1000
# add --> self.run = True

if self.run:
Expand All @@ -141,7 +141,6 @@ def onAVStarted(self):
#xbmc.executebuiltin('XBMC.ActivateWindow(SubtitleSearch)')
#xbmc.executebuiltin('Notification("%s", "%s", "%s",)' % (file, movieFullPath, 40000))
loadsub()
#self.loadsub() na realidade assi a chamada existe
#xbmc.executebuiltin('XBMC.RunScript(special://home/addons/service.autosubs/resources/lib/OpenSubtitles.py)')
else:
Debug('Started: Subs found or Excluded')
Expand Down

0 comments on commit e61d465

Please sign in to comment.