VideoHelp Forum
+ Reply to Thread
Results 1 to 9 of 9
Thread
  1. Member
    Join Date
    Jan 2018
    Location
    Warsaw
    Search PM
    Hi!

    I am new to encoding, but already used Handjob and Moulders x264 succesfully for more than year. Now I am tring to improve quality of my mkv's by changing params. This is somehow exhaustive in GUI if you test same file again and again. I tried to write a command on windows powershell which could be used to create mkv from my avs file. Then I planned to build Python script with that cmd which changes parameters I want.

    I saw in Moulders x264 event log that it sends following commands:
    Code:
    "C:\Program Files (x86)\MuldeR\Simple x264 Launcher v2\toolset\x86\avs2yuv_x86.exe" E:\movies\movie1.avs -
    
    "C:\Program Files (x86)\MuldeR\Simple x264 Launcher v2\toolset\x86\x264_8bit_x86.exe" --crf 16.0 --preset placebo --profile high --aq-mode 2 --merange 32 --sar 16:9 --output "E:\movies\test_movie.mkv" --frames 600 --demuxer y4m --stdin y4m -
    I tried to build my own commands based on above in windows power shell:

    Code:
    ./avs2yuv_x86.exe E:\movies\movie1.avs - | ./x264_8bit_x86.exe --crf 16.0 --preset placebo --profile high --aq-mode 2 --merange 32 --sar 16:9 --output "E:\movies\test_movie.mkv" --frames 600 --demuxer y4m --stdin y4m -
    but it results in memory exception System.OutOfMemoryException, but I sam process manager and there is lot of free memory.

    When I execute the same in cmd.exe I get error for missing MSVCR71.dll (although I added this to system32).

    I must be doing something wrong, probably I miss the basics. Tried to look for answers or some tutorials on that for 3 days but I am only getting more frustrated. Tutorials are usually details and I cant move on.

    Greets,
    amonowy
    Last edited by amonowy; 4th Jan 2018 at 01:13.
    Quote Quote  
  2. Is it a typo or did you forgot to actually put input from avs2yuv_x86.exe? That missing "-" at the end of command line.
    Quote Quote  
  3. Member
    Join Date
    Jan 2018
    Location
    Warsaw
    Search PM
    Thanks for the reply, it was a typo I edited my post.
    Quote Quote  
  4. x264.exe can load avs script directly:
    x264.exe --crf 16.0 --preset placebo --profile high --aq-mode 2 --merange 32 --sar 16:9 --frames 600 --output "E:\movies\test_movie.mkv" "E:\movies\movie1.avs"
    you have not set buffers in your command line, do not leave it default, by including them, you sort of select max. bit rates, and because of crf 16 it could be very high
    --vbv-maxrate 40000 --vbv-bufsize 40000
    unless you do not care about max. bitrates
    Last edited by _Al_; 4th Jan 2018 at 16:09.
    Quote Quote  
  5. Member
    Join Date
    Jan 2018
    Location
    Warsaw
    Search PM
    Thanks for the reply, I did it the way you proposed and it encoded well! Good starting point to excel my encode skills Thanks
    Quote Quote  
  6. that value --sar 16:9 is kind of weird, that value does not suppose to be ratio between width and height

    if it is movie it should be --sar 1:1 , which is default, you do not have to set it, for whatever movie aspect ratio (1920x800, 1920x1080) because it is square pixel,

    --sar x:y is set only in case if video is anamorphic, like camcorder HDV videos, VHS, DV , DVD:
    Code:
    if %ar%==4:3 if %h%==480 if %w%==720 (set sar=8:9)
    if %ar%==4:3 if %h%==576 if %w%==720 (set sar=16:15)
    if %ar%==16:9 if %h%==480 if %w%==720 (set sar=32:27)
    if %ar%==16:9 if %h%==576 if %w%==720 (set sar=64:45)
    
    if %ar%==4:3 if %h%==480 if %w%==704 (set sar=10:11)
    if %ar%==4:3 if %h%==576 if %w%==704 (set sar=12:11)
    if %ar%==16:9 if %h%==480 if %w%==704 (set sar=40:33)
    if %ar%==16:9 if %h%==576 if %w%==704 (set sar=16:11)
    
    if %ar%==16:9 if %h%==1080 if %w%==1440 (set sar=4:3)
    Quote Quote  
  7. Member
    Join Date
    Jan 2018
    Location
    Warsaw
    Search PM
    --sar 16:9 was randomly typed just to make the cmd works. In case of movie I am currently working on sar is 65:45 and I took it from AviSynth.
    Quote Quote  
  8. if --sar 16:9 works on screen at the end, you are getting correct proportions on screen, that means, that something went wrong along the way, there is a better way how to sort it out, you'd need to provide more details.
    Quote Quote  
  9. Member
    Join Date
    Jan 2018
    Location
    Warsaw
    Search PM
    with --sar 16:9 video was too wide. When I use information provided by AviSynth (65:45) video looks just fine, as it should. It is my DVD rip. The value 16:9 was just placed for purpose of making this command to execute, it was not part of real encoding.
    Quote Quote  



Similar Threads

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