Log in

View Full Version : FFT3DFilter causing oversized bitrate on xvid encode?


crasus
26th August 2009, 15:51
Good afternoon! :)

As a follow up, on my original topic here : http://forum.doom9.org/showthread.php?p=1318524#post1318524

It seems that when I enable FFT3D, the bitrate gets oversized. 1850 -> 2200 for example. Tested on 3 different xvid builds. If FFT3D is disabled, there are no problems and the bitrate comes as configured.

I'm currently using the following script & settings to encode a file :

Profile : Advanced Simple@L5
Quantization : MPEG
Adaptive Quantization : OFF
B-VOPs : 1/1.62/0.00
Packed Bitstream/QP/GMC : OFF
Zones : None
Motion Search : 6 - Ultra High
VHQ Mode : 4 - Wide Search
Use VHQ for B-frames
Use Chroma Motion
Frame drop : 0
Maximum I-Frame : 240
Quantizer restrictions : 1/31/1/31/1/31
Trellis quantization

AviSynth Script :

TFM(slow=2).TDecimate()
Crop(18,8,-14,-8)
BicubicResize(640,480,0,0.5)
greyscale()
DeGrainMedian(limitY=2,limitUV=3,mode=1)
DeGrainMedian(limitY=2,limitUV=3,mode=1)
FFT3DFilter(sigma=3)

Encoding via VirtualDubMod.

Didée
26th August 2009, 17:20
There's little sense to activate "Use chroma motion" in Xvid, when you do "greyscale()" in your Avisynth script. ;)

I doubt it's a matter of FFT3D in particular. I guess Xvid's rate control being out of bound ... ~maybe~ because you overfiltered the source with too much noise filters. See your original thread.

MadRat
27th August 2009, 23:45
Having packed bitstream turned on shouldn't cause any problems for you. I'd change the quantization type from MPEG to H.263. My experience is that MPEG quantization type tends to add noise to the video which increases file size. XviD has the maximum consecutive VOPBs set to two (yours is set to one), the quantitizer ratio set to 1.50 (yours is set to 1.62) and quantitizer offset to 1 (yours is 0). I'm not sure how that would effect your file size but that's what I've always used.

The settings I normally use for FFT3DFilter are fft3dfilter(sigma=1.75,bt=4,plane=4,sharpen=0.4,bw=32,bh=32,ow=16,oh=16). You might say the sigma is the strength of the filtering, the plane is the part of the video that gets filtered (none, chroma only, luma only or both luma and chroma which is 4), sharpen is from 0.0 to 1.0. Personally I like lots of sharpening but I usually get jumped on because higher sharpening leads to halos (an optical illusion which makes the video look sharper and clearer) so I've kept it at 0.4. The chroma plane can be heavily filtered without loss of detail but you will get loss of color gradients, in other words color banding. On the other hand, color banding means smaller file size if you don't mind unwatchable video.

See if any of that helps. I'm sure if I've told you something wrong I'll be scolded about it.:scared: