Log in

View Full Version : Blocking (blue sky) and Ringing with x264


CiNcH
23rd July 2005, 17:18
I have uploaded a sample, where you can spot two types of artefacts that x264 produces. Here are the settings:

AVScript:

LoadPlugin("C:\PROGRA~1\GORDIA~1\DGMPGDec\DGDecode.dll")
LoadPlugin("C:\PROGRA~1\GORDIA~1\AviSynthPlugins\UnDot.dll")
mpeg2source("C:\Codec Shoot-out\Source\scorpion.d2v")
crop(0,76,720,432)
LanczosResize(720,304)
Undot()


x264 Settings

820 kbps, 3 ref-frames, 1 b-frame, Always QPel MB partition decision mode, Diamond ME, deblocking -2


Download (4.5 MByte) (http://members.aon.at/cinch/scorpion.avi)


Problem 1: Blocking in the blue sky (there is a lot of noise in the blue sky of the source)

Problem 2: Pixels when the Annubis warrior appears (looks like ringing, that stays for the next few frames at the same position)

Only increasing bitrate seems to help out (I know that the chosen bitrate is quite low...). I am sorry that I cannot help more but I am running out of ideas. I have played around with various settings. The expample above is just one of my samples (tested with disabled deblocking, RDO, UMH ME, aso).

Sirber
23rd July 2005, 17:23
Try:
3 b-frames, Unheven Multi-Diamond ME, deblocking 0, all block types including DCT 8x8.

Try also:
Convolution3D

I see motion errors in the smoke. You need to fitler for grain and harder x264 options.

CiNcH
23rd July 2005, 18:12
LoadPlugin("C:\PROGRA~1\GORDIA~1\DGMPGDec\DGDecode.dll")
LoadPlugin("C:\PROGRA~1\GORDIA~1\AviSynthPlugins\UnDot.dll")
LoadPlugin("C:\PROGRA~1\GORDIA~1\AviSynthPlugins\Convolution3d.dll")
mpeg2source("C:\Codec Shoot-out\Source\scorpion.d2v")
crop(0,76,720,432)
LanczosResize(720,304)
Undot()
Convolution3d("movielq")



3 cons. b-frames, UMH (range 16), deblocking 0, all mb partitions + HP 8x8 DCT



Download (http://members.aon.at/cinch/scorpion_2.avi)


Blocking seems to stay the same as the noise/grain does not seem to get less with Convolution3D (checked out by playing back *.avs without further compression) (I assume that it is the noise/grain that is so heavy to be coded but I am not sure as others have problems with large blue area as well, see here (http://forum.doom9.org/showthread.php?t=97536)). Deblocking 0 does not seem to help as well.

The ringing-like artefacts got less, just a few single pixels appearing (not that much than before). Of course ringing gets less if compression is improved or bitrate is increased. I still think that this is a bug as the ringing artifacts (pixels) seem to be taken to the next few frames (if you watch the sample you will know what I mean, there are ringing artefacts where they do not belong).

CiNcH
24th July 2005, 22:17
I finally got rid of a lot of noise in the blue sky by applying different filters. Blocking seems to be still the same...

Sirber
25th July 2005, 03:01
Could you post your filters? Also, try increasing the inloop strength to +3 or +6.

CiNcH
25th July 2005, 10:58
TemporalSoften(5,2,2,scenechange=15,mode=2)

did quite a good job. I am still not very much into this denoising/removing grain stuff...

Deblocking 6 looks awful... besides that blocking is still clearly visible in the blue sky, even in the noise reduced version with deblocking strength at 6.

I have increased bitrate to 1000 kbps. Blocking is still pretty much visible. The second problem is almost gone as there is no ringing any longer (increased bitrate should result in less ringing).
Still I think that something is wrong with the ringing artefacts at 800 kbps (see above samples when the Annubis warrior appears, left shoulder).

akupenguin
25th July 2005, 16:39
I still think that this is a bug as the ringing artifacts (pixels) seem to be taken to the next few frames (if you watch the sample you will know what I mean, there are ringing artefacts where they do not belong).

That's to be expected. If you perform motion compensation and there are artifacts in the source frame, then those artifacts will be propogated. They only disappear when either (1) new data appears and covers them, (2) enough time passes that they get blurred away by multiple iterations of motion interpolation, or (3) a future frame gets low enough quantizer to fix the artifacts. Note that a sufficiently smart encoder could decide when to invoke (3), and we have discussed possible algorithms, but don't expect it in x264 soon.

CiNcH
11th November 2005, 17:58
Hi friends,

x264 with applied R-D pskip v1 patch seems to solve both problems and performs very well on my complex sample:

http://members.aon.at/cinch/multiplex.mkv

mgh
12th November 2005, 12:21
I have been having the same problem with couple of videos.
I switched to the latest x264 build-365b-which should have the patch incorporated as per the changelog-but the problem is not solved.
I have also tried almost all deblocking methods with avisynth-blindpp,coring and blockbuster along with the latest x264 build-CE High Profile
Any suggestions will be appreciated.

CiNcH
12th November 2005, 12:33
The ringing artefacts not sticking to the sharp edges are gone for my sample.

As for the blocking it is not as apparent as before.
In addition you can play around with "Adaptive Quantization" (--aq-strength and --aq-sensitivity). This will definitely work around the blocking problem if you set a high enough strength.

For the R-D pskip to take effect you have to at least use --subme 6.

mgh
12th November 2005, 13:19
I am not understanding-how to

"For the R-D pskip to take effect you have to at least use --subme 6."

CiNcH
12th November 2005, 13:24
Are you using the VfW codec? Then it's in the 'More...' tab 'Partition decision'. Set it to '6 (RDO - Slowest)'.
You can't set Adaptive Quanization via the VfW interface.

When using MeGUI with the CLI codec frontend, 'Subpixel Refinement' is the right option, set it to 6 or 7. With MeGUI you can also set things like Trellis, R-D optimized B-Pred., Adaptive Quantization. Those features are experimental though.

mgh
12th November 2005, 14:01
I am going thru MeGUI
Tried adaptive quantization-definite improvement is there, will try out your other suggestions and revert.
Thanx a ton:)

mgh
13th November 2005, 03:09
Adaptive quantization helped-others didn't.
Best results were by using MSU deblock filter in virtualdub to encode to lossless format avi and feeding that to MEGui.