[FFmpeg-devel] [PATCH] Box-Muller gaussian generator

Stefano Sabatini stefano.sabatini-lala
Sat Dec 12 17:27:05 CET 2009


On date Saturday 2009-12-12 16:38:53 +0100, Michael Niedermayer encoded:
> On Sat, Dec 12, 2009 at 03:01:44PM +0100, Stefano Sabatini wrote:
> > On date Friday 2009-12-11 22:09:20 +0100, Michael Niedermayer encoded:
> > > On Fri, Dec 11, 2009 at 08:38:35PM +0100, Stefano Sabatini wrote:
> > [...]
> > > > Updated patch.
> > > [...]
> > > 
> > > 
> > > > +#undef printf
> > > > +
> > > [...]
> > > >      }
> > > >      av_log(NULL, AV_LOG_ERROR, "final value:%X\n", x);
> > > [...]
> > > > +            printf("%f\n%f\n",
> > > 
> > > please dont do this
> > 
> > Fixed. 
> > 
> > > [...]
> > > > Index: libavfilter-soc/ffmpeg/libavutil/lfg.h
> > > > ===================================================================
> > > > --- libavfilter-soc.orig/ffmpeg/libavutil/lfg.h	2009-12-11 20:28:37.000000000 +0100
> > > > +++ libavfilter-soc/ffmpeg/libavutil/lfg.h	2009-12-11 20:35:26.000000000 +0100
> > > > @@ -51,4 +51,12 @@
> > > >      return c->state[c->index++ & 63] = 2*a*b+a+b;
> > > >  }
> > > >  
> > > > +/**
> > > > + * Returns the next number generated by a Box-Muller generator using
> > > > + * the random number issued by lfg.
> > > > + *
> > > > + * @param out[2] array where are placed the two generated numbers
> > > 
> > > I think you should mention something about gaussian distributions
> > 
> > Done.
> > 
> > Regards.
> > -- 
> > FFmpeg = Freak & Faboulous Moronic Philosophical Entertaining Geek
> 
> >  lfg.c |   33 +++++++++++++++++++++++++++++++++
> >  lfg.h |    8 ++++++++
> >  2 files changed, 41 insertions(+)
> > a8d8c1cf5bab58fa500804992878c19a4ff82b44  implement-bmg.patch
> 
> ok with a minor version bump

Applied.
-- 
FFmpeg = Faboulous and Fundamentalist Mystic Practical Exploitable Glue



More information about the ffmpeg-devel mailing list