<br><br><div><span class="gmail_quote">On 19/11/2007, <b class="gmail_sendername">jakob kaiser</b> &lt;<a href="mailto:jakobala@hotmail.com">jakobala@hotmail.com</a>&gt; wrote:</span><div><br>&nbsp;</div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>
Is there an easy way to get something more unpredictable? I don&#39;t want to go deep into random generator programming. But the function does not really what you would expect of a random generator, does it? </div></blockquote>
<div><br><br>How about amping up your ADC by lots&amp;lots, casting to int and using that as a seed? Performance will depend on the bit-depth compared to quality of the analogue part of the ADC (I&#39;m seeing very &quot;good&quot; results on the  phono pre-amp of my EMU if I leave it open....).
<br><br>What you could also do is start a very fast counter at the start of your program and ask the user to hit the space-bar to stop it, then use the resultant value as a seed.<br></div><br>Not matter how deep you get into random number generators, if you want to get around your current problem you will have to come up with some way to get a seed that&#39;s not the same every time the program runs, once you get that the default one should be fine. Random number generators aren&#39;t very hard to implement anyway, at least not as long as you don&#39;t have and secret service agencies chasing you ;¬)
<br><br>Yours,<br>Kas.<br></div>