[FFmpeg-devel] [PATCH] Implement pixdesctest filter

Stefano Sabatini stefano.sabatini-lala
Wed Jul 7 13:08:42 CEST 2010


On date Tuesday 2010-07-06 13:04:37 +0200, Michael Niedermayer encoded:
> On Sun, Jul 04, 2010 at 12:28:54AM +0200, Stefano Sabatini wrote:
> > On date Tuesday 2010-06-22 02:22:51 +0200, Michael Niedermayer encoded:
> > > On Mon, Jun 21, 2010 at 11:25:29PM +0200, Stefano Sabatini wrote:
[...]
> > > > diff --git a/tests/lavfi-regression.sh b/tests/lavfi-regression.sh
> > > > index ebbc0f3..42fba34 100755
> > > > --- a/tests/lavfi-regression.sh
> > > > +++ b/tests/lavfi-regression.sh
> > > > @@ -86,6 +86,19 @@ if [ -n "$do_lavfi_pix_fmts" ]; then
> > > >      done
> > > >  fi
> > > >  
> > > > +if [ -n "$do_lavfi_pixdesc" ]; then
> > > > +    pix_fmts="$($ffmpeg -pix_fmts list 2>/dev/null | sed -ne '9,$p' | grep '^IO' | cut -d' ' -f2)"
> > > > +
> > > > +    ref_file=tests/ref/lavfi/lavfi_pixdesc
> > > > +    rm -f $ref_file
> > > > +
> > > > +    for pix_fmt in $pix_fmts; do
> > > > +        cat $ref_file-$pix_fmt >> $ref_file
> > > > +        do_video_encoding "lavfi_pixdesc-${pix_fmt}.nut" "" \
> > > > +            "-vf slicify=random,format=$pix_fmt,pixdesctest -vcodec rawvideo -pix_fmt $pix_fmt"
> > > 
> > > shouldnt it be converted back and compared by tiny_psnr too?
> > 
> > Yes, found a much better solution which doesn't require the bundling
> > of the reference files at all.
[...]
> >  Makefile                     |    1 +
> >  doc/filters.texi             |   13 ++++
> >  libavfilter/Makefile         |    1 +
> >  libavfilter/allfilters.c     |    1 +
> >  libavfilter/vf_pixdesctest.c |  128 ++++++++++++++++++++++++++++++++++++++++++
> >  tests/lavfi-regression.sh    |   20 +++++++
> >  6 files changed, 164 insertions(+), 0 deletions(-)
> >  create mode 100644 libavfilter/vf_pixdesctest.c
> 
> no reference checksums?

No, as I said the reference are automatically generated, indeed the
purpose of the test is to check that the output is the very same with
and without the filter.

This is a little slower, but looks more robust, I'll change if you
prefer the other way.

Regards.
-- 
FFmpeg = Fancy and Fast Muttering Ponderous Explosive Gargoyle



More information about the ffmpeg-devel mailing list