Log in

View Full Version : x264 settings to preserve detail.


Chengbin
14th May 2009, 04:15
I'm using CRF 24, and this is the setting I'm using

--keyint 250 --bframes 4 --qpmin 10 --qpmax 51 --no-psnr --no-fast-pskip --mixed-refs --trellis 2 --ref 6 --filter 0,0 --subme 9 --direct auto --me umh --no-ssim --level 4.1 --merange 32 --qcomp 0.8 --weightb --b-adapt 2 --b-pyramid --partitions p8x8,b8x8,i4x4,i8x8 --threads 3 --aq-mode 2 --aq-strength 1 --psy-rd 1.0:0.4

Keep in mind that I can't use any high profile feature, so no 8x8dct (unforunately). I'm also using MVDegrain 3.

I did a comparison between CRF 24 and 18 of the movie The Matrix on my Archos 5's 5'' internal screen. The main scene I focused on is the lobby shootout scene at the end of the movie (around 1:42:00). Lots and lots of detail with lots of debris flying from bullets, making it a perfect (and very tough) scene for testing detail. The walls are very detailed too. CRF 18 looked a lot better, far sharper detailed. Artifacts were visible on Neo, and the highly detailed scenes. The CRF 18 encode just pops at you with stunning detail.

Is there any way to tweak encoding (and maybe preprocessing settings) to aim for detail? Or should I just use more bitrates? The CRF 18 encode was almost 2.5x the bitrate from CRF 24.

I'm gonna try 2 encodes with CRF 22 and 20 to see if I can approach the CRF 18 quality.

Many thanks.

martinfrombern
14th May 2009, 11:41
lower deblock values can help in preserving details. e.g. -1,-1 or -1, -2 (or even -3,-3 with very grainy sources). also, such higher bitrate is no surprise. decreasing QP by 6 should increase bitrate by 100% (H264 specifications). you can try with a bit lower psy-trellis. also, decreasing aq to 0.9 or 0.8 can sometimes be helpful.

Sagekilla
14th May 2009, 20:32
Seeing as you're just about maxed on settings, there's not much you can really do to increase detail retention. Lower deblock will help slightly, but it probably wouldn't be too huge of a difference. The only other thing you could do is to lower the crf value and then try to stabilize the grain as much as possible (i.e. some more denoising) or -maybe- use the nr option of x264. Try doing something like --nr 300 and see if it helps any. If you're using nr, try something like crf 22.

Forteen88
14th May 2009, 20:38
--no-dct-decimate saves some details, but that requires a bit more bitrate.

Sagekilla
15th May 2009, 07:02
I really wouldn't recommend --no-dct-decimate with crf mode. The only thing it seems to do is raise the bitrate at a given crf, with no appreciable difference in quality or sharpness.

LoRd_MuldeR
15th May 2009, 13:53
Chengbin, what are "--aq-mode 2" and "--aq-strength 1" supposed to do?

There is no AQ mode 2 in x264 currently (although this may change soon) and AQ strength 1.0 is simply the default. Hence you can remove both parameters.

Tack
15th May 2009, 17:16
My eyes have a problem with trellis, even the new psy-trellis stuff. You could try disabling trellis altogether and see what that does to the quality.