Clarisse 5.0 SP8 SDK  5.0.5.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | List of all members
GRandomPcg32 Class Reference

Public Member Functions

CORE_INLINE GRandomPcg32 (uint64_t initstate, uint64_t initseq=1u)
 Initialize the pseudorandom number generator with the seed() function.
 
CORE_INLINE void seed (uint64_t initstate, uint64_t initseq=1)
 Seed the pseudorandom number generator.
 
CORE_INLINE uint32_t next_uint () const
 Generate a uniformly distributed unsigned 32-bit random number.
 
CORE_INLINE uint32_t next_uint (uint32_t bound) const
 Generate a uniformly distributed number, r, where 0 <= r < bound.
 
CORE_INLINE float next_float () const
 Generate a single precision floating point value on the interval [0, 1)
 
template<typename REAL = double>
CORE_INLINE REAL rand () const
 

Member Function Documentation

CORE_INLINE void GRandomPcg32::seed ( uint64_t  initstate,
uint64_t  initseq = 1 
)

Seed the pseudorandom number generator.

Specified in two parts: a state initializer and a sequence selection constant (a.k.a. stream id)