[YoutubeDL] Make postprocessors declarative

Instead of having to configure PPs in code, this allows us and embedding programs not to worry about imports or finer details, similarly to how we handle IEs.
This commit is contained in:
Philipp Hagemeister 2014-12-15 01:06:25 +01:00
parent 39f594d660
commit 4f026fafbc
5 changed files with 93 additions and 38 deletions

View file

@ -236,9 +236,9 @@ class FFmpegExtractAudioPP(FFmpegPostProcessor):
return self._nopostoverwrites, information
class FFmpegVideoConvertor(FFmpegPostProcessor):
class FFmpegVideoConvertorPP(FFmpegPostProcessor):
def __init__(self, downloader=None, preferedformat=None):
super(FFmpegVideoConvertor, self).__init__(downloader)
super(FFmpegVideoConvertorPP, self).__init__(downloader)
self._preferedformat = preferedformat
def run(self, information):