src/pyams_media/converter.py
changeset 59 4d725464e237
parent 44 09b5df1481d9
equal deleted inserted replaced
58:05898b7a0a73 59:4d725464e237
   197     label = _("MP4 (HTML5) video converter")
   197     label = _("MP4 (HTML5) video converter")
   198     format = 'mp4'
   198     format = 'mp4'
   199     require_temp_file = True
   199     require_temp_file = True
   200 
   200 
   201     def add_common_filters(self, document):
   201     def add_common_filters(self, document):
       
   202         super(Mp4VideoConverter, self).add_common_filters(document)
   202         effects = document.__effects__
   203         effects = document.__effects__
   203         effects['filter:v'] = 'setsar=1/1'
   204         effects['filter:v'] = 'setsar=1/1'
   204         effects['pix_fmt'] = 'yuv420p'
   205         effects['pix_fmt'] = 'yuv420p'
   205         effects['preset:v'] = 'slow'
   206         effects['preset:v'] = 'slow'
   206         effects['profile:v'] = 'baseline'
   207         effects['profile:v'] = 'baseline'
   225     label = _("WebM video converter")
   226     label = _("WebM video converter")
   226     format = 'webm'
   227     format = 'webm'
   227     require_temp_file = True
   228     require_temp_file = True
   228 
   229 
   229     def add_common_filters(self, document):
   230     def add_common_filters(self, document):
       
   231         super(WebmVideoConverter, self).add_common_filters(document)
   230         effects = document.__effects__
   232         effects = document.__effects__
   231         effects['filter:v'] = 'setsar=1/1'
   233         effects['filter:v'] = 'setsar=1/1'
   232         effects['pix_fmt'] = 'yuv420p'
   234         effects['pix_fmt'] = 'yuv420p'
   233         effects['r:v'] = '25/1'
   235         effects['r:v'] = '25/1'
   234 
   236