[Ffmpeg-devel] video post processing filters

Michael Niedermayer michaelni
Thu Apr 21 18:24:47 CEST 2005


On Thursday 21 April 2005 05:24, Nagendra Rao wrote:
> hai all,
>  this is nagendra, a student from National Institute OF Technology Calicut,
> India.i am having problem with postprocessing that was included in ffmpeg
> project.i've posted three-four times regarding the same issue without
> getting any reply hope this time some one will attend my request.

IIRC your past questions have been answered, IIRC it was something about 
having to allocate arrays in c before something can be stored in them

> after going thru the code i felt deblocking and deringing have been
> implemented according to ISO/IEC spec.but i've confusion at threshold
> values.
> ISO/IEC specs says that for simulation *THR1=2* AND *THR2=6* but in
> ffmpeg's "libavcodec\libpostproc\postprocess.c" these r defined as
>   THR1 ------------ * dcThreshold*= dcOffset*2 + 1;
>  where dcOffset= ((nonBQP*baseDcDiff)>>8) + 1; (baseDcDiff=32 large=>more
> deblocking)
>  THR2 ------------ * flatnessThreshold* (default=32 less=> more deblocking)
>  could anybody pls give a link that describes the theory behind selecting
> these threshold values.
>  what is "*nonBQP*" ? if i do not use B frames at all will it be same as
> *QP * ??

it will contain the same values

>  similarly deringing filter also seems to be implemented from ISO/IEC spec
> but i can't able to understand the code at index aquisition part i think
> its been implemented differently from iso/iec spec,i don't know if iam
> wrong. could anybody pls tell me the significance of *deringThreshold
> *being selected as *20*
> **
> *i hope this time i'll get a solution or atleast a reply to my mail*
> thanx in advance

the postprocessing code in ffmpeg supports several different deblock and 
dering filters, some of them are based on the non-normative postprocessing 
filters described in the iso-mpeg4 spec others are not, the filters have also 
been optimized and finetuned, so none matches absolutely exactly whats 
written in the spec, allthough the "accurate" filters should be pretty close, 
IIRC only the threshold calculation has been replaced by a much more advanced 
if you want to know the exact differences, the source code really is the best 
place to look at



"nothing is evil in the beginning. Even Sauron was not so." -- Elrond

More information about the ffmpeg-devel mailing list