[FFmpeg-cvslog] r18420 - trunk/libavformat/timefilter.c

Diego Biurrun diego
Fri Apr 10 20:22:23 CEST 2009


On Fri, Apr 10, 2009 at 08:15:48PM +0200, Diego Biurrun wrote:
> On Fri, Apr 10, 2009 at 07:03:01PM +0100, M?ns Rullg?rd wrote:
> > diego <subversion at mplayerhq.hu> writes:
> > >
> > > Log:
> > > Replace rand() usage by av_lfg_get().
> > >
> > > --- trunk/libavformat/timefilter.c	Fri Apr 10 17:16:11 2009	(r18419)
> > > +++ trunk/libavformat/timefilter.c	Fri Apr 10 19:12:36 2009	(r18420)
> > > @@ -76,9 +76,12 @@ double ff_timefilter_update(TimeFilter *
> > >
> > >  #ifdef TEST
> > > -#undef rand
> > > +#include "libavutil/lfg.h"
> > > +#define LFG_MAX ((1LL << 32) - 1)
> > 
> > Why not UINT32_MAX?
> 
> I (blindly) followed Reimar's suggestion, I'll change it in a moment.

Hmm, output differs considerably if I make the change you suggest:

 [0.800000 0.000800  0.000000] [1.021025 0.998922  0.000000] [1.021025 0.998922  0.000000] [1.021025 0.998922  0.000000]
 [0.001040 0.000018  2.254569] [0.019313 0.000002  0.137725] [0.055696 0.000005  0.083131] [0.120869 0.000011  0.095409]
 [0.001040 0.000018 20.291122] [0.005740 0.000002  2.778077] [0.019313 0.000002  1.239529] [0.044186 0.000004  0.794707]
 [0.001040 0.000018 110.473887] [0.002286 0.000000 30.334177] [0.007911 0.000002 12.433695] [0.019313 0.000002  6.748546]
 [0.001040 0.000018 507.278054] [0.000975 0.000000 264.432916] [0.003086 0.000002 105.469708] [0.008405 0.000002 53.599990]
 [0.001040 0.000018 2166.640935] [0.000819 0.000000 1651.862313] [0.001024 0.000000 827.609691] [0.003499 0.000002 406.794817]

before:

 [0.800000 0.000800  0.000000] [1.021025 0.998922  0.000000] [1.021025 0.998922  0.000000] [1.021025 0.998922  0.000000]
 [0.001003 0.000000  0.004341] [0.041562 0.000996  0.045245] [0.081175 0.002874  0.074431] [0.118380 0.006568  0.108913]
 [0.001003 0.000000  0.039073] [0.013619 0.000455  0.224390] [0.041562 0.000996  0.407205] [0.068719 0.002305  0.600848]
 [0.001003 0.000000  0.212729] [0.022518 0.000060  0.941262] [0.015889 0.000507  1.391585] [0.041562 0.000996  2.217003]
 [0.001003 0.000000  0.976818] [0.014412 0.000021  2.712350] [0.013691 0.000370  4.648765] [0.018915 0.000542  6.709646]
 [0.001003 0.000000  4.172097] [0.010677 0.000007  7.809261] [0.018915 0.000032 14.578784] [0.013619 0.000387 20.628496]

Diego



More information about the ffmpeg-cvslog mailing list