Torque2D Reference
Loading...
Searching...
No Matches
RandomPCG Class Reference

#include <mRandom.h>

Inheritance diagram for RandomPCG:

Public Member Functions

 RandomPCG ()
 RandomPCG (const S32 seed)
 RandomPCG (const S32 seed, const S32 stream)
void setSeed (const S32 seed)
void setSeed (const S32 seed, const S32 stream)
U32 randI (void)
U32 randI (U32 bound)
Public Member Functions inherited from RandomGeneratorBase
void resetSeed (void)
S32 getSeed (void) const
F32 randRangeF (const F32 from, const F32 to)
S32 randRangeI (const S32 from, const S32 to)
virtual F32 randF (void)

Additional Inherited Members

Protected Member Functions inherited from RandomGeneratorBase
 RandomGeneratorBase ()
Protected Attributes inherited from RandomGeneratorBase
S32 mSeed

Detailed Description

PCG Random Number Generator

Fast and statistically excellent random numbers

Period = 2^64

Copyright 2014 Melissa O'Neill oneil.nosp@m.l@pc.nosp@m.g-ran.nosp@m.dom..nosp@m.org

Licensed under the Apache License, Version 2.0

Constructor & Destructor Documentation

◆ RandomPCG() [1/3]

RandomPCG ( )

◆ RandomPCG() [2/3]

RandomPCG ( const S32 seed)

◆ RandomPCG() [3/3]

RandomPCG ( const S32 seed,
const S32 stream )

Member Function Documentation

◆ randI() [1/2]

U32 randI ( U32 bound)
inline

◆ randI() [2/2]

U32 randI ( void )
inlinevirtual

Implements RandomGeneratorBase.

◆ setSeed() [1/2]

void setSeed ( const S32 seed)
virtual

Implements RandomGeneratorBase.

◆ setSeed() [2/2]

void setSeed ( const S32 seed,
const S32 stream )

The documentation for this class was generated from the following files: