Environment: FFmpeg Batch AV Converter v4.3.1, Win 8.1 x64
Using the 2-pass Wizard.The program complains 'Parameters "-pass 1" and "-f" are required for first pass' though they are both included.
[Attachment 58774 - Click to enlarge]
The parameters work fine in a batch file for both passes.
There's also something flaky about entering the individual arguments: the entry box splits off the leading dash character if extra spaces aren't inserted before "-pass 1".
+ Reply to Thread
Results 1 to 21 of 21
-
-
I don't know the program you're using. But -f is the ffmpeg option for container format (matroska, mp4, etc.). This ffmpeg command line worked for me with ffmpeg.exe:
Code:ffmpeg -i input.mkv -c:v libx265 -b:v 700k -vsync 1 -max_muxing_queue_size 1024 -an -sn -pass 1 output1.mkv ffmpeg -i input.mkv -c:v libx265 -b:v 700k -vsync 1 -max_muxing_queue_size 1024 -c:a copy -c:s copy -pass 2 output2.mkv
-
This is not the issue. My command lines work work correctly unconditionally. BUT, I can not get FF Batch Converter to accept them.
How can your command line work ? There is no output file for pass 1 ! -
The pass-1 command line MUST end with ..."-pass 1 -y -f AVI NUL". "-y" overwrites any leftover "ffmpeg2pass-0.log" file. The "-f AVI NUL" args specify the one-and-only-one mandatory and acceptable file type that allows pass-1 FFmpeg X265 processing to proceed. Inclusion of this, and only this is absolutely necessary !
-
-
I played with the GUI, it's a buggy GUI
You need to explicitly enter -x265-params with the log path and name, otherwise it does not work properly - it becomes 1pass VBR .
(IMO - A GUI should do some of that for you, otherwise you're better off using a bat file)
You can verify with mediainfo, the 2nd pass should say stats-write=0 / stats-read=2 for 2pass. If it says stats-write=0 / stats-read=0, that's not 2pass (that indicates no stats file is read)
-pass is required by the GUI, otherwise it complains - it does not look for it in the -x265-params string. I left it in the example
It should look something like this
[Attachment 58777 - Click to enlarge] -
No joy, same error message as with my command params.
What version of FFBatch are you using ?
[Attachment 58778 - Click to enlarge] -
2.3.8 portable win x64
https://www.videohelp.com/software/FFmpeg-Batch
I noticed it says v4.3.1 in the 1st post, but I don't see that version - maybe you were referring to ffmpeg version ? -
-
Ah, I see. ffmpeg doesn't automatically pass its "-pass n" argument to x265. So you have to use x265-params to specify it. You don't even have to specify "-pass n" to ffmpeg (though it doesn't hurt). You don't really have to specify a name for the log files, x265 will use it's defaults. You don't have to specify NUL output, you can send the video to a file (you probably want to use NUL in a large batch process, obviously). And -y is only necessary to avoid being prompted when files already exist (again, useful in a batch process).
Last edited by jagabo; 8th May 2021 at 22:57.
-
I think it does, I just left it in there, because that's the way I do it using cmd or batch
You don't even have to specify "-pass n" to ffmpeg (though it doesn't hurt).
You don't really have to specify a name for the log files, x265 will use it's defaults. -
I used:
Code:ffmpeg -i input.mkv -an -sn -c:v libx265 -b:v 700k -vsync 1 -max_muxing_queue_size 1024 -x265-params pass=1 -f Matroska NUL -y ffmpeg -i input.mkv -c:a copy -c:s copy -c:v libx265 -b:v 700k -vsync 1 -max_muxing_queue_size 1024 -x265-params pass=2 output2.mkv -y
-
-
-
The problems were caused by using an outdated version of FFmpeg. Since then such parameters such as "c:a?" are no longer acceptable.
Thanks to jagabo for going off-topic and segwaying into a private conversation with poisondeathray. My question was left unanswered without giving any useful pointers. -
-c:a copy works for many years, it works here too
You've been using incorrect command lines.
It tells you the errors you're making.
Also ffmpeg libx265 doesn't use the 1st pass stats unless you use -x265-params with pass=1 or 2 . How is that not a useful pointer ? Your 2pass encodes have been unconditionally incorrect . You're welcome BTW . The GUI makes the pass, but doesn't actually use them either unless you use -x265-params, you can check with -report and mediainfo
Check the boxes, to see if the GUI has pasted additional information at the end of the line. Scroll down in the box. It only displays 2 lines, but there can be a 3rd hidden line with garbage not shown. It's a buggy GUI -
I removed args "-x265-params stats" to simplify debugging. It seemed to have no effects at all in either pass.
My problems were caused by using an outdated version of FFmpeg. Parameter syntaxes such as "c:a" are no longer supported. I am guessing that now "c:a" implies "all audio streams". I haven't yet had the need to check this out.
When you say "Check the boxes to see if the GUI has pasted additional information at the end of the line", what boxes and lines do you mean ? -
-c:a means codec:audio ; it used to be "-acodec" many years ago
So -c:a copy means copy the audio stream . It's the same thing as -acodec copy , but ffmpeg complains if you use -acodec now, and it will soon be removed
When you say "Check the boxes to see if the GUI has pasted additional information at the end of the line", what boxes and lines do you mean ?
It only displays 2 lines, but when I tested it, the GUI posts garbage at the end of the line on the 3rd line which isn't shown in the screenshot. And there is no way to resize or enlarge the window that I could find. So delete all the garbage entries
It's not a very good GUI
Similar Threads
-
Staxrip 1st pass x265 2nd pass Nvenc is it possible?
By dennisbgi7 in forum Video ConversionReplies: 6Last Post: 7th Jan 2021, 13:41 -
FFMPEG - X265 - Help for correct commands and syntax
By AllThatEvil in forum Video ConversionReplies: 16Last Post: 22nd Mar 2017, 17:04 -
Two-Pass Encoding using AVS2YUV with FFmpeg
By wwaag in forum Video ConversionReplies: 10Last Post: 9th Mar 2017, 17:33 -
would it make more sense to use 1 pass encoding instead of 2 with x265?
By zanzar in forum Newbie / General discussionsReplies: 19Last Post: 15th Dec 2016, 19:41 -
FFMPEG x265 10bit and virtualdub x265 10bit settings
By lilycarolyn in forum Video ConversionReplies: 11Last Post: 6th Jun 2016, 13:44