Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-4 AVC / H.264

Reply
 
Thread Tools Search this Thread Display Modes
Old 13th August 2008, 20:24   #1  |  Link
Tartz
Registered User
 
Join Date: Aug 2008
Posts: 5
Automated x264 CLI Encoder (with vars)

Hi guys.

First of all, I’m totally new on this forum and an encoder newbie so excuse me for any mistakes.

I've done some research in x264 encoder and found out I needed to use MeGui or CLI.
Since I’m kind of a geek CLI had my preference.
I noticed the many steps it takes to start converting a video, so I created a batch.

This batch does the following things:
- Scan input file (location given in the commandline) and generates a stats file which contains all the video specifications, using Mplayer
- Calculate aspect ratio (using vars given in the commandline and stats file from Mplayer) and FPS
- Encode audio using Nero AcEnc
- Encode video using x264 and predefined parameters (2pass)
- Create Mp4box
- Output the video (location given in the command line)

This batch is very useful for people who want to automate their encoding.

Everything is in the .rar file except AviSynth.
This needs to be installed before the batch works.

The .bat file uses the following parameters:
b_encode.bat InputFilename+ext OutPutFilename SizeX SizeY

E.g.:
b_encode.bat input.avi my_output 800 600

All the input files need to be in the input folder.
Output goes to the output folder

I hope you guys find it useful too.

Download link:
http://rapidshare.com/files/137104844/Encoder.rar



I would also really appreciate some help in the x264 parameters.

I currently use the following code for all video's:
--bitrate 1200 --qcomp 7 --stats "temp/input.stats" --ref 6 --bframes 3 --b-pyramid --weightb --direct auto --filter 1:1 --analyse all --8x8dct --subme 6 --me umh --trellis 2 --progress --threads auto --no-psnr --no-ssim --thread-input --output "temp/video.264" "input.avs"

Which gives about 10 mb / minute files at high quality.
If anyone has some pointers in keeping this quality but with less MB's/minute it would be very appreciated.
Tartz is offline   Reply With Quote
Old 14th August 2008, 03:44   #2  |  Link
Sagekilla
x264aholic
 
Join Date: Jul 2007
Location: New York
Posts: 1,752
Easy, incease subme to 7, use b-rdo, bime, and mixed refs. That should increase compression at the cost of speed.
__________________
You can't call your encoding speed slow until you start measuring in seconds per frame.
Sagekilla is offline   Reply With Quote
Old 14th August 2008, 07:33   #3  |  Link
bob0r
Pain and suffering
 
bob0r's Avatar
 
Join Date: Jul 2002
Posts: 1,337
--filter 1:1, can be removed, i think the default is just fine.
--qcomp 7, why use that? Remove it and let AQ do its job.

If this is something people want, ill put the file on a mirror.
Next time use version numbers in the filename!
bob0r is offline   Reply With Quote
Old 14th August 2008, 09:13   #4  |  Link
audyovydeo
Registered User
 
audyovydeo's Avatar
 
Join Date: Apr 2007
Posts: 464
Good initiative !

I also use a set of batch files under windows, to automate operations to a maximum. Works as follows :

Usage :
x_av profile mode crf sar video audio [shutdown]
... or ...
x_wrap profile mode crf sar directory\*.avi [noaudio / same] [ td ]
... or ...
x_av profile mode crf sar video estimate


profile : base, main, high, [ intra ]
mode : fast, good, best, blast, [ none ]
sar : 11 43 54 169 6445 3227
video : .avi or .avs
audio : noaudio, audiosource.avi, same



You'll surmise that I *only* use crf. I used to support the other modes but I never used them so dumped them.

x_wrap is a "wrapper" to the main batch that allows to specify a directory, rather than a single file, and optionally passes a "deinterlace" parameter to the avs script.
I use it when I want to encode quick'n'easy the whole bunch of DV files captured from my camcorder.

My scripts use / require :

cygwin
mp4box
avi2wavcmd
(optionally wavi)
neroAacEnc_SSE
avisynth (optionally TDeint)

if anyone's interested, say so or PM me.

cheers
audyovydeo

Last edited by audyovydeo; 14th August 2008 at 09:15.
audyovydeo is offline   Reply With Quote
Old 14th August 2008, 11:45   #5  |  Link
Tartz
Registered User
 
Join Date: Aug 2008
Posts: 5
Thanks for the pointers
Also thanks for the support on the x264 script

@ Audyovydeo
That seems like a good idea!
I might incorporate the same multiple file batching idea in mine
Tartz is offline   Reply With Quote
Reply

Tags
automated, batch, cli, encoder, x264

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 10:08.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.