From kde-kimageshop Wed Dec 24 01:38:56 2008 From: Matthew Woehlke Date: Wed, 24 Dec 2008 01:38:56 +0000 To: kde-kimageshop Subject: Re: PRNG proposal Message-Id: X-MARC-Message: https://marc.info/?l=kde-kimageshop&m=123008281412702 Moritz Moeller wrote: > Sorry for the blunt comment and I might be missing something obvious > here, but: why not just use something proven and fast like mersenne > twister? :) No worries, it's a legitamite question. I actually looked at it briefly, but AFAICT it's an iterative generator with no obvious way to make it procedural (and I'm also not sure how fast it is). Krita needs a procedural PRNG, that is prng(x, y, seed) must always give the same result for the same values of x, y, seed, and must also generate results over a region (x, y changing, seed constant) that both provides a reasonable distribution and is free of obvious visual artifacts. (I guess that qualifies as "something obvious"? ;-) ) If we needed an iterative PRNG I'd be advocating plain old *rand48 (which is actually permuteWhole from my algorithm), as it's extremely simple, and generally adequate for moderate-quality PRNG, which I think is all we need. Mersenne Twister, to my understanding, is a higher-quality PRNG that is possibly overkill :-). -- Matthew Please do not quote my e-mail address unobfuscated in message bodies. -- このテキストを翻訳する時間の無駄だばかばかしい _______________________________________________ kimageshop mailing list kimageshop@kde.org https://mail.kde.org/mailman/listinfo/kimageshop