Added webm output

This commit is contained in:
Zen 2020-12-18 21:32:21 +02:00
parent 04818f9eb1
commit a55ff9baf4
3 changed files with 10 additions and 1 deletions

View file

@ -81,6 +81,7 @@ class Args:
io_group.add_argument('--resume', '-r', help='Resuming previous session', action='store_true')
io_group.add_argument('--keep', help='Keep temporally folder after encode', action='store_true')
io_group.add_argument('--config', '-c', type=str, default=None, help="Path to config file, create if doesn't exists")
io_group.add_argument('--webm', default=False, action='store_true', help="Output to webm")
# Splitting
split_group = parser.add_argument_group('Splitting')

View file

@ -18,6 +18,7 @@ class Project(object):
self.output_file: Path = None
self.mkvmerge: bool = None
self.config = None
self.webm = None
# Splitting
self.chunk_method: str = None
@ -105,7 +106,11 @@ class Project(object):
:param project: the Project
"""
suffix = '.mkv'
if self.webm:
suffix = '.webm'
else:
suffix = '.mkv'
self.output_file = Path(self.output_file).with_suffix(suffix) if self.output_file \
else Path(f'{self.input.stem}_{self.encoder}{suffix}')

View file

@ -76,6 +76,9 @@ With your own parameters:
Options provided to cli overwrite config values.
All options excepth in/out/vmaf/log/temp/config paths are saved.
--webm Outputs webm file.
Use only if you're sure source video and audio is compatible.
<h3 align="center">FFmpeg options</h3>
-a --audio_params FFmpeg audio settings (Default: copy audio from source to output)