VideoHelp Forum




+ Reply to Thread
Results 1 to 4 of 4
  1. Member
    Join Date
    Nov 2002
    Location
    United States
    Search Comp PM
    I'm trying to learn how to use ffmpeg.

    I found out how to put ffmpeg in my user folder and run a command promp to convert files. Now I need to know how to create a batch file to convert the whole folder instead of converting one file at a time.

    I have a bunch of files that are VP6/MP3 in MKV container that I need to copy back into FLV container. I used the copy command which works fine but I can't do more than one file at a time. I can make a batch file that works by putting...

    ffmpeg -i video_1.mkv -vcodec copy -acodec copy video_1.flv
    ffmpeg -i video_2.mkv -vcodec copy -acodec copy video_2.flv
    ffmpeg -i video_3.mkv -vcodec copy -acodec copy video_3.flv

    but that is very time consuming.

    I'd appreciate it if someone familiar with ffmpeg could help me write a script to batch copy all my FLV/MKV to FLV without having to type the names of every single file in the folder.
    Quote Quote  
  2. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    for %%a in ("*.mkv") do ffmpeg -i %%a command_line_parameters %%~na.flv

    and put it in a .bat file in the folder with all the mkv files.
    Quote Quote  
  3. Member
    Join Date
    Nov 2002
    Location
    United States
    Search Comp PM
    Thanks, Baldrick.
    Quote Quote  
  4. Opening a very old thread but this describes what I want to do.

    I would like to try to do the same technique as Baldrick mentioned but it does not want to work for me, need help.

    ffmpeg -genpts 1 -i ES_Video_1.m2v -i ES_Audio_1A.mp2 -i ES_Audio_1B.mp2 -vcodec copy -acodec copy -f vob ES_Video_1.mpg -newaudio
    ffmpeg -genpts 1 -i ES_Video_2.m2v -i ES_Audio_2A.mp2 -i ES_Audio_2B.mp2 -vcodec copy -acodec copy -f vob ES_Video_2.mpg -newaudio
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!