Changes to engine file extensions structure

This commit is contained in:
Brett Williams
2024-08-03 20:21:26 -05:00
parent 7d633d97c2
commit d9201b5082
5 changed files with 23 additions and 17 deletions

View File

@@ -23,13 +23,15 @@ class FFMPEG(BaseRenderEngine):
@classmethod
def supported_extensions(cls):
help_text = (subprocess.check_output([cls().renderer_path(), '-h', 'full'], stderr=subprocess.STDOUT)
.decode('utf-8'))
found = re.findall(r'extensions that .* is allowed to access \(default "(.*)"', help_text)
found_extensions = set()
for match in found:
found_extensions.update(match.split(','))
return list(found_extensions)
if not cls.file_extensions:
help_text = (subprocess.check_output([cls().renderer_path(), '-h', 'full'], stderr=subprocess.STDOUT)
.decode('utf-8'))
found = re.findall(r'extensions that .* is allowed to access \(default "(.*)"', help_text)
found_extensions = set()
for match in found:
found_extensions.update(match.split(','))
cls.file_extensions = list(found_extensions)
return cls.file_extensions
def version(self):
version = None