- removed Theora support

- removed --context
- added Opus support (now default)
- added VP9 support (now default)
- added WebM support
This commit is contained in:
Martinez 2018-05-07 01:21:48 +02:00
parent fa9b3fe790
commit da0d60eecf
3 changed files with 32 additions and 59 deletions

31
aux.py
View file

@ -31,37 +31,6 @@ def to_Path(raw_path):
# --------------------------------------------------
context_file_header = """# Context file for %s-%s
# This file stores configuration valid for this directory.
# It is updated automatically with options you use.
"""
def update_cfg_context(main, ignore=[]):
"""
All main.options that are sourced from either the cfg file or defaults get overridden by those in .over-video.
Those that are from command line get saved into .over-video.
File format:
name=value
"""
options_to_consider = [option for option in main.options.values() if option.name not in ignore and option.in_cfg_file]
options_to_write = {option.name: option for option in options_to_consider if option.source == over.app.Option_sources.command_line}
options_to_read = {option.name: option for option in options_to_consider if option.source != over.app.Option_sources.command_line}
context_file_read = over.app.ConfigFile(options_to_read, ".over-video", ignore_unknown=True)
restored = context_file_read.read_config()
if restored:
main.print("restored from <m>.over-video<.>: %s" %(", ".join("<g>%s<.>" %(o.name) for o in restored)), main.print.tl.note)
context_file_write = over.app.ConfigFile(options_to_write, ".over-video")
added = context_file_write.update_config(context_file_header, (main.name, main.version))
if added:
main.print("added to <m>.over-video<.>: %s" %(", ".join("<g>%s<.>" %(o.name) for o in added)))
# --------------------------------------------------
def float_or_string(a):
try:
return float(a)