Avidemux Forum

Avidemux => Windows => Topic started by: Zoli on May 07, 2016, 05:06:48 PM

Title: Batch processing multiple files with two-pass video size
Post by: Zoli on May 07, 2016, 05:06:48 PM
Greetings,

I have hundreds of videos I want to encode using H264 with very slow settings and in a two-pass way using video size. But I want to do it so that the encoded video size is p% (p<100) of the original (so it depends on the original file size). It is very daunting to do that from the GUI. How could I solve it in an automatized way?

Thank you,
Zoli
Title: Re: Batch processing multiple files with two-pass video size
Post by: mean on May 07, 2016, 08:06:57 PM
you can get the filesize of the original file using tinypy and

size=get_file_size("your_original_file.mkv")

Title: Re: Batch processing multiple files with two-pass video size
Post by: Zoli on May 07, 2016, 08:11:38 PM
I cannot use Python. Could you provide an example?
Title: Re: Batch processing multiple files with two-pass video size
Post by: Jan Gruuthuse on May 08, 2016, 08:06:53 AM
https://wiki.python.org/moin/BeginnersGuide/NonProgrammers
http://www.hlevkin.com/Shell_progr/hellopython.htm
https://www.python.org/about/gettingstarted/
Title: Re: Batch processing multiple files with two-pass video size
Post by: mean on May 08, 2016, 07:51:49 PM
That one should be a good starting point
https://github.com/mean00/avidemux2/blob/master/autononreg/py/sample_script/convert_avi_to_x264_mkv.py