[FFmpeg-user] How to use ffmpeg in batch mode?

Goran Obal obal.goran at gmail.com
Mon Oct 21 11:44:47 EEST 2019


Silly me, it's the other way around (mkv to mp4)...
ffmpeg -i %1 -y %~n1.mp4
or
ffmpeg -i %1 -y -c copy %~n1.mp4

On Mon, Oct 21, 2019 at 10:34 AM Goran Obal <obal.goran at gmail.com> wrote:

> Sorry, forgot the extensions for output. ;)
> ffmpeg -i %1 -y %~n1.mkv
> or
> ffmpeg -i %1 -y -c copy %~n1.mkv
>
> On Mon, Oct 21, 2019 at 10:33 AM Goran Obal <obal.goran at gmail.com> wrote:
>
>> Michael, you could use this:
>> %~ni <- this means the filename without the extension, so instead of
>> renaming, just use:
>> ffmpeg -i %1 -y %~n1
>> or
>> ffmpeg -i %1 -y -c copy %~n1
>>
>> On Mon, Oct 21, 2019 at 10:28 AM Michael Koch <
>> astroelectronic at t-online.de> wrote:
>>
>>>
>>> >
>>> > set OUT=%IN:mkv=mp4%
>>>
>>> please note that this renaming will give unexpected results if "mkv" is
>>> also part of the filename, for example
>>> aamkv.mkv will be renamed to
>>> aamp4.mp4
>>>
>>> If someone knows a solution to this problem, please let us know.
>>>
>>> Michael
>>> _______________________________________________
>>> ffmpeg-user mailing list
>>> ffmpeg-user at ffmpeg.org
>>> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>>>
>>> To unsubscribe, visit link above, or email
>>> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
>>
>>


More information about the ffmpeg-user mailing list