Release Subscene.com with Black Background or Opaque Box
#1
For Hiding foreign Hardsub. Addon Subscene.com with Black Background or Opaque Box is modified version of http://forum.kodi.tv/showthread.php?tid=184854

source code and zip: from https://github.com/ewwink/kodi-addon-sub...background

Demo: https://www.youtube.com/watch?v=9ZXTBHqG6CA
Reply
#2
Thanks this work really good.

Any way to increase font size?

Enviado desde mi SM-N920G mediante Tapatalk
Reply
#3
(2017-05-09, 20:28)ElGabo Wrote: Thanks this work really good.

Any way to increase font size?

Enviado desde mi SM-N920G mediante Tapatalk

edit ..../service.subtitles.subtitleBackground/resources/lib/srt2ass.py line 40

Code:
Style: SubStyle,Arial,20,&H0300FFFF,.......10,1
20 is font size and 10 is vertical margin
Reply
#4
Tks I will

Enviado mediante Tapatalk
Reply
#5
Does exactly what I need, so Thank you!
Instead of the usual .srt file; this add-on introduced me to .ass files; which are easily editable on linux with aegisub.
Cheers
Reply
#6
Thank you for an amazing feature!

Question, is it possible to make a service out of it? meaning, that you can apply it to any subtitle service?
Reply
#7
yes, you can apply it to any subtitle service, just find the code where .srt will be appended to playlist then convert it.
example:
Code:
from resources.lib.srt2ass import srt2ass
......
for sub in subs:
    sub = srt2ass(sub) # convert .srt to .ass
    listitem = xbmcgui.ListItem(label=sub)
    xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]), url=sub, listitem=listitem, isFolder=False)
Reply
#8
I would really appreciate it when this can be done in Opensubtitles addon
Reply
#9
(2017-06-08, 16:23)ewwink Wrote: yes, you apply it to any subtitle service, just find the code where .srt will be appended to playlist then convert it.
example:
Code:
from resources.lib.srt2ass import srt2ass
......
for sub in subs:
    sub = srt2ass(sub) # convert .srt to .ass
    listitem = xbmcgui.ListItem(label=sub)
    xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]), url=sub, listitem=listitem, isFolder=False)

Thanks a lot, mate. It works well!
Another question I have, Is the color code is ASCII? What code should I use for white subtitle color? and what is the right parameter I need to change to in order to set the subtitles to be at the bottom of the screen instead of the video?
Reply
#10
Hello Ewwink

I was looking for a solution to show a shadow behind subtitles in Kodi because VLC wouldnt work on my Android Mini MX player. Now I found your script here and installed it as add-on to Kodi 17.3 but I can't find where to activate or set it up...Can you help me? Thanks,

Ewoud


Edit:
Also can you make this work with .srt files external or inside .mkv videofiles and edit it like the colour is white and not bold?
Reply
#11
(2017-07-25, 14:21)FuZira Wrote: Thanks a lot, mate. It works well!
Another question I have, Is the color code is ASCII? What code should I use for white subtitle color? and what is the right parameter I need to change to in order to set the subtitles to be at the bottom of the screen instead of the video?
you're welcome. you can create style with subtitle edit or here the color: white -> &H00FFFFFF and yellow -> &H0300FFFF

(2017-07-31, 22:40)Ewoud Wrote: Hello Ewwink

I was looking for a solution to show a shadow behind subtitles in Kodi because VLC wouldnt work on my Android Mini MX player. Now I found your script here and installed it as add-on to Kodi 17.3 but I can't find where to activate or set it up...Can you help me? Thanks,

Ewoud


Edit:
Also can you make this work with .srt files external or inside .mkv videofiles and edit it like the colour is white and not bold?

maybe it can help you to activate subtitle service https://www.youtube.com/watch?v=yPKdDrV8czM
in next release I will try to add that feature.
Reply
#12
Thank you very much!

Can you also release a OpenSubtitles mod with this?
Reply
#13
I get fall on many TV series it works with original subscene the log shows this
line 252, in getallsubs
line 320, in search_tvshow
line 356, in search
any tips what can be wrong?
got it working with the updated service.py
Reply
#14
Can this option work with subtitles from my hard disc, offline?

Because, i have lots of movies with subtitle which I edited.



I would like this option in kodi, if they made in settings.
Reply
#15
(2017-06-08, 16:23)ewwink Wrote: yes, you can apply it to any subtitle service, just find the code where .srt will be appended to playlist then convert it.
example:
Code:
from resources.lib.srt2ass import srt2ass
......
for sub in subs:
sub = srt2ass(sub) # convert .srt to .ass
listitem = xbmcgui.ListItem(label=sub)
xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]), url=sub, listitem=listitem, isFolder=False)
 Thanks, can confirm it works great with OpenSubtitles plugin in Kodi v18 (Leia) alpha.

For those requesting OpenSubtitles version, you can do this quite easily by e.g. copying (or preferably symlinking) srt2ass.py from the folder "service.subtitles.subtitleBackground/resources/lib/" to "service.subtitles.opensubtitles/" in your Kodi addon folder. Then in the file service.py in "service.subtitles.opensubtitles/", find near the end:

python:
elif params['action'] == 'download':
  subs = Download(params["ID"], params["link"],params["format"])
  for sub in subs:
    listitem = xbmcgui.ListItem(label=sub)
    xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]),url=sub,listitem=listitem,isFolder=False)

and change it to

python:
elif params['action'] == 'download':
  from srt2ass import srt2ass
  subs = Download(params["ID"], params["link"],params["format"])
  for sub in subs:
    sub = srt2ass(sub) # convert .srt to .ass
    listitem = xbmcgui.ListItem(label=sub)
    xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]),url=sub,listitem=listitem,isFolder=False)

Not taking any responsibility for this, this is just what I did a few minutes ago.
Reply

Logout Mark Read Team Forum Stats Members Help
Subscene.com with Black Background or Opaque Box1