Merge branch 'nightly' of https://github.com/clinton-hall/nzbToMedia into nightly

This commit is contained in:
clinton-hall 2014-08-02 08:33:13 +09:30
commit cacc32020c

View file

@ -403,6 +403,7 @@ def extract_subs(file, newfilePath, bitbucket):
num = len(subStreams)
for n in range(num):
sub = subStreams[n]
idx = sub["index"]
try:
lan = sub["tags"]["language"]
except:
@ -417,7 +418,7 @@ def extract_subs(file, newfilePath, bitbucket):
if os.path.isfile(outputFile):
outputFile = os.path.join(subdir, "%s.%s.%s.srt" %(name, lan, n))
command = [nzbtomedia.FFMPEG, '-loglevel', 'warning', '-i', file, '-vn', '-an', '-codec:s:' + str(n), 'srt', outputFile]
command = [nzbtomedia.FFMPEG, '-loglevel', 'warning', '-i', file, '-vn', '-an', '-codec:' + str(idx), 'srt', outputFile]
if platform.system() != 'Windows':
command = nzbtomedia.NICENESS + command