Javanaut 8 months ago
parent ff6bacb0d5
commit a4e25b5ec8

@ -16,6 +16,8 @@ class FileProperties():
SEASON_EPISODE_INDICATOR_MATCH = '[sS]([0-9]+)[eE]([0-9]+)' SEASON_EPISODE_INDICATOR_MATCH = '[sS]([0-9]+)[eE]([0-9]+)'
EPISODE_INDICATOR_MATCH = '[eE]([0-9]+)' EPISODE_INDICATOR_MATCH = '[eE]([0-9]+)'
CROPDETECT_PATTERN = 'crop=[0-9]+:[0-9]+:[0-9]+:[0-9]+$'
DEFAULT_INDEX_DIGITS = 3 DEFAULT_INDEX_DIGITS = 3
def __init__(self, context, sourcePath): def __init__(self, context, sourcePath):
@ -228,9 +230,15 @@ class FileProperties():
errorLines = ffprobeError.split('\n') errorLines = ffprobeError.split('\n')
cropHistogram = {}
for el in errorLines: for el in errorLines:
print(el) cropdetect_match = re.search(FileProperties.CROPDETECT_PATTERN, el)
if cropdetect_match is not None:
print(cropdetect_match.group(0))
# return json.loads(ffprobeOutput)['streams'] # return json.loads(ffprobeOutput)['streams']

Loading…
Cancel
Save