View Full Version : x264 CLI Syntax Problems
Shinji-kun
7th October 2010, 19:46
I want to encode a 22 min. toon clip using 2pass and set the file size to 250 MB with according bitrate.
One question before my main question, how do I set the file size to 250 MB like the bitrate calculator in MeGUI, in CLI?
I tried:
x264 --pass 2 --bitrate 1800 --stats "C:\Users\Videos\Ed Eddn eddy Episode 1.stats"
--output "C:\Users\Videos\Ed Edd n Eddy Episode 1.mkv" "C:\Users\Videos\Ed Edd n Eddy Episode 1.avs"
I received the errors:
avs [error]: failed to load avisynth
x264 [error]: could not open input file `C:\Users\Videos\Ed Edd n Eddy Episode 1.avs'
What is the problem?
I keep having problems with the input and people on other forums keep giving contradictory advice.
LoRd_MuldeR
7th October 2010, 19:49
1) FileSizeInMegabytes = ((DurationInSeconds * BitrateInKilobitsPerSecond) / 8192) + AudioData + ContainerOverhead
2) If you want to use Avisynth input, you must install Avisynth on your system. If you are using x64 x264, you must install x64 Avisynth!
3) If you want to run a 2-Pass encode, which is a good idea to hit a specific size, you must run both, a first and a second pass.
Blue_MiSfit
7th October 2010, 22:17
Indeed.
If you MUST hit a specific filesize (why?) then 2 pass mode is for you. Otherwise, use CRF (try maybe CRF24 as a starting point, and adjust down for higher quality and up for lower quality / lower bitrate)
You seem to be having problems with AviSynth input. Does your script render correctly in AvsP or VirtualDub? As Lord_Mulder said, if you're using 64 bit x264, you need 64 bit avisynth.
Derek
CarlEdman
8th October 2010, 15:39
As Lord_Mulder said, if you're using 64 bit x264, you need 64 bit avisynth.
Not necessarily. 64-bit avisynth is still a bit of a work in progress, while 64-bit x264 is already clearly superior (in particular for HD resolutions, but also for SD). Fortunately, you can use 32-bit avisynth to pre-process your video and then just pipe the uncompressed 32-bit avisynth output to the 64-bit x264. I have been doing that for a while with great success.
hydra3333
12th October 2010, 10:33
Fortunately, you can use 32-bit avisynth to pre-process your video and then just pipe the uncompressed 32-bit avisynth output to the 64-bit x264. I have been doing that for a while with great success.
How (what windows commandlines) ?
J_Darnley
12th October 2010, 14:48
avs2yuv file.avs -o - | x264 - --demuxer y4m ...
LoRd_MuldeR
12th October 2010, 22:07
avs2yuv file.avs -o - | x264 - --demuxer y4m ...
How (what windows commandlines) ?
...or if you need a GUI ;)
http://forum.doom9.org/showthread.php?t=144140
hydra3333
12th October 2010, 23:44
Wonderful. Thanks to both of you.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.