Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   Related Pages  

TNL::Random Namespace Reference

The Random namespace is an interface to a cryptographically secure pseudo random number generator (PRNG). More...


Functions

void * getState ()
 Returns an opaque pointer to the random number generator's internal state for use in certain encryption functions.

void addEntropy (const U8 *randomData, U32 dataLen)
 Adds random "seed" data to the random number generator.

void read (U8 *outBuffer, U32 randomLen)
 Reads random byte data from the random number generator.

U32 readI ()
 Reads a 0...U32_MAX random number from the random number generator.

U32 readI (U32 rangeStart, U32 rangeEnd)
 Reads a random number between rangeStart and rangeEnd inclusive from the random number generator.

F32 readF ()
 Reads a floating point value from 0 to 1 from the random number generator.

bool readB ()
 Returns a single random bit.


Detailed Description

The Random namespace is an interface to a cryptographically secure pseudo random number generator (PRNG).

Internally the Random namespace uses the Yarrow PRNG algorithm.


Generated on Thu Aug 18 16:03:39 2005 for Robin Hood: Thieves & Knights by doxygen1.2.18