View Full Version : x264: 720x400 @ ~1800 kbit/s blocky
moviefan
24th August 2007, 11:09
Hey guys,
I would like to encode a 25 minutes video of good source quality at about 1800 kbit/s. I used AutoMKV and x264 at Encoding-Highprofile-Mode, but flat areas tend to have almost no details and become pretty blocky. Detailed areas look very good. I don't really care about encoding speed. Is there a way to improve picture quality since the bitrate for a H.264 encoding is pretty high I would say... For information: the picture is pretty clean, little noise or dithering.
I hope, you can help!
Regards, moviefan
homerpez
24th August 2007, 12:29
From what little I know (about your size project), 1800 should be good enough bitrate, if not overkill for 720x400. I've heard 1200 or so is more like it for DVD resolutions, but I haven't done too many.
But I think I'm suffering from a similar issue (which hopefully has a similar solution):
Mine was a 1080p-resolution encode from Blu-Ray, and I used a bitrate of roughly 9000k so it would fit onto a dual layer DVD.
I also found that detail and motion scenes were completely great looking, but when there were washed-out backgrounds that didn't move much (clouds, etc), they would just turn to blocks while the foreground detail stayed crisp.
I would have expected the action scenes would show the first signs of "not enough bitrate", but no... it was ONLY in the background scenes, where you could see faded clouds barely moving in the background. The rest of the film (an action one, with LOTS of detail) was just fine.
These cloud scenes weren't dark either (I have had trouble with dark scenes and x264 also)... these were nice and brightly colored clouds. Just faded in the background, barely moving, and they went blocky almost every time.
Can anyone offer any insight into how to improve backgrounds?
Here's what I'm using now (been using it for everything so far) on x264 VFW:
Min QP: 10
Max QP :51
Max QP Step: 4
Keyframe Boost: 40%
B Frames Reduction: 40%
Chroma Offset: 0
Scene Cut Threshhold: 40
Min/Max IDR Frame Interval: 24/240 (sources are 23.976 for me)
Partitions: (all the multiples like 8x8, 4x4 etc are checked)
Max Consecutive B Frames: 3
Adaptive, Use As References, Weighted biprediction and Bidirectional ME: CHECKED
Uneven Multi-Hexagonal
Precision: 6 (RDO-Slow)
Max Ref Frames: 8
RDO for B-Frame: Checked
Mixed Refs: Checked
Chroma ME: Checked
...and even the "Deblocking Filter" is checked...
Thanks in advance, hopefully we figure out both our issues...
Shinjite
24th August 2007, 21:13
have you checked the No-Fast P-skip tickbox?
homerpez
24th August 2007, 21:43
have you checked the No-Fast P-skip tickbox?
For me? No. Moviefan will have to answer on his. What does this do?
ToS_Maverick
24th August 2007, 23:13
@moviefan: i think you mean the standard x264 blocking problem in no-detailed areas.
have a look at this:
http://forum.doom9.org/showthread.php?p=996829#post996829
and try AQ (adaptive quantization).
buzzqw
25th August 2007, 07:06
@moviefan
Hi!
in 0.89 i have added the AQ patch to profile
check "All Profiles" you should see "AQ_2pass_Balanced/extreme"...
try using one of ther AQ profile
BHH
homerpez
26th August 2007, 10:33
@Shinjite: I just tried one using that box checked this time, and it looks like it may have done the trick for me. Thanks!
(Personally I don't care about encoding time, always always do 2-pass... apparently this one setting eluded me)
steve77
28th August 2007, 14:29
I don't know, 1800kbps is the lowest I'd use for that type of resolution, ,with a really clean source... I'm assuming you're doing some denoising before encoding? That could help compressibility... maybe something light like degrainmedian()... (though I'm a FFT3DFilter addict myself, w/ low sigma).
Anyway, even the cleanest sources for those resolutions I use 2000+.
Do a couple of 1 minute encodes and see where quality starts tapering off.
moviefan
2nd September 2007, 15:29
I have tried the AQ profile and it doesn't change anything. Flat areas are still full of blocks. Also encoding with AQ in CQ Mode on CQ=18 or CQ=17 ist satisfying and I use very much cleaning Avisynth preprocessing. Any ideas what's wrong?
My command line from AutoMKV:
--pass 1 --crf 18 --stats "C:\Programme\AutoMKV089\.stats" --progress --keyint 250 --bframes 3 --qpmin 10 --qpmax 51 --no-psnr --mixed-refs --ref 3 --filter 1,1 --direct auto --vbv-maxrate 25000 --me umh --no-ssim --weightb --b-pyramid --b-rdo --bime --analyse p8x8,b8x8,i4x4,i8x8,p4x4 --8x8dct --threads auto --thread-input --aq-strength 0.5 --aq-sensitivity 11
Sagekilla
2nd September 2007, 16:29
I have tried the AQ profile and it doesn't change anything. Flat areas are still full of blocks. Also encoding with AQ in CQ Mode on CQ=18 or CQ=17 ist satisfying and I use very much cleaning Avisynth preprocessing. Any ideas what's wrong?
My command line from AutoMKV:
--pass 1 --crf 18 --stats "C:\Programme\AutoMKV089\.stats" --progress --keyint 250 --bframes 3 --qpmin 10 --qpmax 51 --no-psnr --mixed-refs --ref 3 --filter 1,1 --direct auto --vbv-maxrate 25000 --me umh --no-ssim --weightb --b-pyramid --b-rdo --bime --analyse p8x8,b8x8,i4x4,i8x8,p4x4 --8x8dct --threads auto --thread-input --aq-strength 0.5 --aq-sensitivity 11
You can safely remove --keyint 250, --qpmin 10, ---qpmax 51 and replace --analyse p8x8,b8x8,i4x4,i8x8,p4x4 with --anaylse all. Try setting --aq-sensitivity to 15, and increasing --aq-strength a bit (Like 0.6 or 0.7). Then run the encode again and see if you have any problems.
Hope that helps any.
moviefan
2nd September 2007, 16:48
Okay, I'll try. By the way, is 2-pass better or CQ because CQ is only 1 pass... said under the condition that both methods would result in the same target size...
Sagekilla
2nd September 2007, 16:55
Well, using CRF you'd get a constant quality. In high motion scenes it'd allocate a bucket load more bits then in low motion scenes. Using 2-pass though, you'd be able to hit a target file size more accurately, at the cost of the quality being POSSIBLY erratic. The only situation I could imagine it would be erratic is the high motion scenes, where quality might degrade.
To summarize:
CRF
+ Good quality throughout
- Can be excessively big
- No real "target file size"
2-pass
+ Has a target file size
- Can take slightly longer
Draw your own conclusions. If you're space constrained (I.e. a 4.7 GB DVD) then it would be a better idea to do a 2-pass. If you're not, I prefer CRF because of the uniform quality. --crf 19.5 suits me perfectly :) Yes, you can use a floating point number, it's not limited to whole integers.
Manao
2nd September 2007, 17:17
CRF and 2 passes have the same amount of constness in the quality. The main difference between both is that one targets a defined quality while the other targets a bitrate ( but use the first pass to estimate the target quality that will allow to target the bitrate )
Said otherwise, if you do a CRF encoding, then a two passes encoding targetting the size obtained by the CRF encoding, you'll get - almost - the same result.
Atak_Snajpera
2nd September 2007, 17:27
@movie fan
I suggest --aq-strength 0.5 --aq-sensitivity 5
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.