VideoHelp Forum
+ Reply to Thread
Results 1 to 9 of 9
Thread
  1. Well......I guess I'm just going to have to confess that I'm not getting it and need help. I have been reading, researching and have asked help on forum before but frustration has taken over

    WHAT I'M TRYING TO DO IS:

    I have a video called loop.mov. The video is 1920x1080 with alpha channel set to YES.

    I want to resize loop.mov to 1280 wide by 720 high and still keep the alpha channel.

    Others have given me some info on ffmpeg but not enough for me to understand. The documentation did not help.

    So can anyone please give me the ffmpeg code letter by letter, number by number so I can resize a 1920x1080 video to 1280 wide by 720 high and still keep the alpha channel.

    Just in case you need to see the file, here is a link to download the loop.mov file

    https://www.dropbox.com/s/rku0pj0805xtjr8/loop.zip?dl=0


    Thank You in advance for your help.
    Quote Quote  
  2. This worked for me:

    Code:
    "c:\program files\ffmpeg\bin\ffmpeg.exe" -i "d:\downloads\loop.mov" -vf scale=1280:720 -vcodec png "d:\downloads\loop2.mov"
    Change the path to ffmpeg.exe if it's located elsewhere on your system. Change the input and output file specs to where your source is located and where you want the output file to be created. The default behavior was to retain the alpha channel.
    Image Attached Files
    Quote Quote  
  3. Wow...thanks a million. That worked. I wanted to take it a step further to see if I could batch convert more than one file.

    Below is what I used to convert one file

    "D:\1-PROG\ffmpeg\bin\ffmpeg.exe" -i "d:\In\loop.mov" -vf scale=1280:720 -vcodec png "d:\Out\loop2.mov"

    Since the above worked. I thought the line below would work to convert more than one .mov file in the same folder

    "D:\1-PROG\ffmpeg\bin\ffmpeg.exe" -i "d:\In\*.mov" -vf scale=1280:720 -vcodec png "d:\Out\*.mov"

    But it didn't work. I got an error. What did I do wrong?

    Thanks
    Quote Quote  
  4. To batch convert with ffmpeg on windows, you can do it with a FOR command

    Code:
    for %a in ("*.mov") do "D:\1-PROG\ffmpeg\bin\ffmpeg.exe" -i "d:\In\%a" -vf scale=1280:720 -vcodec png -acodec copy "d:\Out\%~na.mov"
    Quote Quote  
  5. Hmmm, did not work.....when I entered the line at the ffmpeg command prompt, nothing happen.
    Quote Quote  
  6. Did you open the prompt at the level of the input folder ?

    Eg. navigate to the input folder, hold shift key, right click => open command window here

    Otherwise, post the error message if any
    Quote Quote  
  7. That was it..........thank you so much for your patience and helping me out.
    Quote Quote  
  8. Just so you don't mix up the files (since they are both MOV's), it might be a good idea to rename them slightly differently. e.g. you might add "720p" to the name, or some other distinguishing name

    Another reason to get in the habit of doing this (at least in the future) is it's another layer of protection against overwriting files if you forget to specify different pathways for input/output files since the way it's currently done is it takes on the name of the input file (normally ffmpeg will ask if you want to overwrite, but many people automatically bypass that by putting -y to say "yes" automatically - not a good idea IMO)

    Code:
    for %a in ("*.mov") do "D:\1-PROG\ffmpeg\bin\ffmpeg.exe" -i "d:\In\%a" -vf scale=1280:720 -vcodec png -acodec copy "d:\Out\%~na.720p.mov"
    Quote Quote  
  9. Also be careful when you put the output files in the same folder as the input files. The batch file may see the output files as more mov files to be processed. You will end up in a vicious loop until your hard drive fills up or the file names exceed the maximum allowable length. For example, if your folder only contains loop.mov and the batch file creates loop_1280x720.mov it may then create loop_1280x720_1280x720.mov. Then loop_1280x720_1280x720_1280x720.mov. Etc. You have to construct your wildcards and file names appropriately to avoid that.

    If you have an on-going need to convert files like this it's nice to put a batch file that handles individual files in your SendTo folder. That way you can right click on a video and select Send To -> FileName.bat to process that file. For example, put this in a file named Downscale_to_720p.bat in your SendTo folder:

    Code:
    "D:\1-PROG\ffmpeg\bin\ffmpeg.exe"  -i %1 -vf scale=1280:720 -vcodec png "%~dpn1_1280x720.mov"
    Then right click on a mov file and select Send To -> Downscale_to_720p.bat.

    Hint: in Win 7, 8, and 10 you can open the SendTo folder by searching for
    Code:
    shell:sendto
    .
    Quote Quote  



Similar Threads

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