Thanks for your help. I have released a new version, with some bug fixes, better translation, default or custom output folder selection, as well as some audio features like volume change, shifting, graphical waveform.
I think the most useful feature is the N-threads multi-file processing for audio conversion. Since all audio encoders are single-thread, by launching several files processes simultaneously you can take advantage of all your CPU cores, making audio encoding really fast, even faster than other professional applications like dBpoweramp or JRiver Media Center.
+ Reply to Thread
Results 151 to 178 of 178
New version 1.05 with stream mapping and mkv multiplexing, single stream mapping and encoding.
Basic features like the ones provided by the more powerful MKVToolNix.
Can you help me with this task? I want to convert dts audio to ac3 so I can play it on my tv. Also, I want to remove all the extras audio tracks and leave only the main one. Is it possible?
The code I'm using right now is this:
-vcodec copy -scodec copy -acodec ac3 -b:a 640k
Hi, there should be no problem doing that. Just go to the stream multiplex tab, open your video file, then double-click i, or right-click and add all streams to the tracks list.
Then remove the tracks and contents you don't want to mux, and in the audio track just add the audio coding parameters on the textbox: ac3 -b:a 640k
Note that -acodec or -c:a is not to be included, since it is already added when the track is not set to "copy. You can see it on the image below:
[Attachment 44109 - Click to enlarge]
Awesome. Thanks a lot and congrats again!
Isn't webm just a container? I want to only batch demux all .webm files and mux them as .mp4
Yes, both webm and mp4 are containers. The problem is: you probably want to convert webm to mp4 because your player doesn't support webm, correct? Chances are your player will not play the type of video and audio bitstreams typically found in webm (VP9, VP8, Opus, Vorbis) when remuxed to mp4. Your player will likely expect H.264/AVC and AAC in mp4 instead so you do need to convert the file. ffmpeg can do that but it will take a lot more time than just remuxing.
That's it, webm supported video codecs are not supported by mp4, so transcoding of video, audio or both is mandatory, a long time process depending on the computer, number and size of files, etc., and quality will be degraded depending on the compression level you use, which may lead to even bigger files than the original, with slightly less quality.
If you just want to have a second playable everywhuere version of the videos while keeping the original webm as your main source, you may use the processing power of Google/YouTube and upload them hidden, so YouTube does the processing effort much faster keeping decent quality, and then use the option to download the processed videos as MP4 files.
would it be possible to modify "ffmpeg batch converter" in order to have the output path same as input path except for disk letter in an automatic way ? For example if input file has a path:
have output path
I would like to maintain the original path (except for disk letter) since it indicates the timeline. In the output just a way to choose a new disk and the automatic path creation.
Thank you very much, I appreciate.
I hope it works as you need.
really thanks, it works; in this way it would be easier for me to make these bunch of conversions.
May I get more support about the ffmpeg settings (to have mp4 files) I should set for the type of files I would like to convert ?
Format HuffYUV, Codec HFYU, 720x576 pixels, DAR 5:4, Frame rate 25.000 FPS, Standard PAL, Color space YUV,
Chroma subsampling 4:2:2, Bit depth 8 bits, Scan type Interlaced
Format PCM, Bit rate mode Constant, Bit rate 1536 kb/s, 2 channels, Sampling rate 48.0 kHz, Bit depth 16 bits
-c:v libx264 -crf 20 -vf yadif -c:a aac -ac 2 -ar 48000 -ab 1536k
Format DV, Codec (dvsd), 720x576 pixels, DAR 4:3, Bit rate mode Constant, Frame rate mode Constant, Frame rate = 25.000 FPS
Standard PAL, Color space YUV, Chroma subsampling 4:2:0, Bit depth 8 bits, Scan type Interlaced
Format PCM, Bit rate mode Constant, Bit rate 1 024 kb/s, 2 channels, Sampling rate 32.0 kHz, Bit depth 16 bits
-c:v libx264 -crf 20 -vf yadif -pix_fmt yuv420p -c:a aac -ac 2 -ar 32000 -ab 1024k
Format AVC (Lite), Format profile High@L4, Bit rate mode Variable, 1280x720 pixels, DAR 16:9, Frame rate 25.000 FPS, Standard NTSC
Color space YUV, Chroma subsampling 4:2:0, Bit depth 8 bits, Scan type Progressive
Format AC-3, Bit rate mode Constant, Bit rate 192 kb/s, 2 channels, Sampling rate 48.0 kHz, Bit depth 16 bits
-c:v copy -c:a copy
Format AVC, Format profile High@L4.2, Bit rate mode Variable, 1920x1080 pixels, DAR 16:9, Frame rate 50.000 FPS, Color space YUV,
Chroma subsampling 4:2:0, Bit depth 8 bits, Scan type Progressive
Format AC-3, Bit rate mode Constant, Bit rate 256 kb/s, 2 channels, Sampling rate 48.0 kHz, Bit depth 16 bits
FFMPEG (here I want to convert frame rate from 50 to 25)
-c:v copy -r 25 -c:a copy
Well, I'm not actually an ffmpeg expert, but I can give you some suggestions within my knowledge, check below:
Suggestion: -c:v libx264 -crf 20 -c:a copy
Last edited by Eibol; 3rd Feb 2018 at 18:12. Reason: Highlight reply
Great thread...THANK YOU!!!
2 questions about syntax. I'm currently using the following in a batch file and it works great (I modifed your batch convert mkv to mp4 files):
for %%a in ("*.*") do "c:\ffmpeg\ffmpeg.exe" -i "%%a" -metadata:s:v rotate=90 -vcodec copy -acodec copy "%%~na~90.mkv"
Question#1 - Is there a way to modify the output files section so it includes the entire filename including extensions and then my modifier in case I have different extensions of the same name so it doesn't want to overwrite duplicate files?
For example right now in a directory I have:
If I run my batch file it wants to generate two files both named 1~90.mkv whereas I'd like it to generate two files:
or another and better option is
Question#2 - Is there a way to modify the output files section to not include a filetype (remove the .mkv from my script) and therefore convert all the files in the directory to their same original name and filetype just with the modifier amended to the end of the file name thus essentially achieving the same goal as question number 1.
In a directory I have
And after running the batch file the output would be
Thanks so much for any help if anyone can tell me this.
Last edited by bmcelvan; 8th May 2018 at 11:59. Reason: Removed smiley faces from -metadata:s:v section of text
Aha, I figured it out!!
In case anyone else wants to know, change the "%%~na~90.mkv"
for Question #1 to:
for Question #2 to:
Great you solved it by yourself.
I take note of your suggestions for the next version.
For the moment, with FFmpeg Batch you could check "Rename output", and "_FFB" is added to the file name automatically. I will add a text field so this can be customized.
Regarding keeping source extension, it is not possible yet, you could do it in two rounds, adding and processing all mkv and then clear the list and add the mp4 files. I will also allow to leave the Format field blank in next version, so extension is taken from source file.
Last edited by Eibol; 8th May 2018 at 15:13. Reason: Additions
Im having huge difficulties with an encoding file/batch encoding multiple files at once from source audio file which is a WAV file to an MP3 lossy format. I want to do a very specific thing.
Is it possible with ffmpeg libraries to encode WAV file to MP3 320cbr stereo or joint stereo with build in libmp3lame/lavformat? Every time output file is encoded using lavc instead lavf. If not using ffmpeg maybe some other way, actually any way that's its available to use.
Somehow it must be possible because google play store encodes that way i supose.
The reason im asking here is that its whats foobar2000 player displays. I hope you will be able to help me out.
Please have a look at the file i have attached. Tool: lavf | This is what foobar2000 says.
Its my fault, i didnt express myself as i should.
The file you see in the screenshot is some random file i obtained from google play (tool: lavf)
What i want to know is how to encode a WAV file i extracted from CD to MP3, and encode it same way as google does.
Ok, so i want to encode wav file to mp3 exactly the same way as google play does.
After i encode wav to mp3 i want to see Tool: lavf not lame 3.99...
If you convert to mp3 using for example this command: -c:a libmp3lame -b:a 224K
You obtain this metadata:
encoder : Lavf58.13.100
Duration: 00:03:37.60, start: 0.025057, bitrate: 128 kb/s
Stream #0:0: Audio: mp3, 44100 Hz, stereo, fltp, 128 kb/s
encoder : Lavc58.19
I often listen to conferences broadcast on youtube from which I extract the audio stream to listen to them while travelling
I'm not sure I can manage to use ffmpeg batch for this task ... (extract audio aac from mp4)
In ffmpeg batch, I went to the the stream multiplex tab and remove the video tracks, then pressed 'Mux' button
I get an error message because the video track is required for muxing
The code I'm manualy using is ffmpeg -i "video.mp4" -vn -acodec copy "audio.m4a"
Hi, the multiplex tab only allows to multiplex audio+video.
In your case, if your files just cotain one video and audio track, you can simply use in the main tab the next configuration:
Parameters: -map 0:1 -c:a copy
[Attachment 46827 - Click to enlarge]
Of course ! Oh yes, it works !
Thanks for your help and congratulations for the software
please help edit my bat file because it doesn’t create a video from pictures, but overwrites it
@echo off set work_dir=d:\mp4 for /d %%B in (%work_dir%\*) do ( for %%C in ("%%B\*") do ffmpeg -f image2 -i "%%C" "%%B.mp4")
[Attachment 47427 - Click to enlarge]
Iam trying to do a 2pass batch encode using example given earlier in this thread:
for %%a in ("*.mp4") do ffmpeg -y -i "%%a" -c:v h264 -b:v 2500k -pass 1 -f mp4 NUL for %%a in ("*.mp4") do ffmpeg -y -i "%%a" -c:v h264 -b:v 2500k -pass 2 -c:a copy "encoded\%%~na.mp4" pause DEL "*.temp" DEL "*.mbtree" DEL "*.log"
ffmpeg2pass-0 ffmpeg2pass-0.log NULL
For the sake of it did a 2pass encode as single file and got different file size and bitrate graph.
Please advice, not an ffmpeg user here
The use of brackets is the answer:
for %%a in ("*.mp4") do ( ffmpeg -y -i "%%a" -c:v h264 -b:v 2500k -pass 1 -f mp4 NULL ffmpeg -y -i "%%a" -c:v h264 -b:v 2500k -pass 2 -c:a copy "encoded\%%~na.mp4" )
Last edited by T0tum; 25th Dec 2018 at 04:44.