ImFusion SDK 4.3
Pcg64Engine Class Reference

#include <ImFusion/Core/RandomEngine.h>

Wrapper class for a 64-bit PCG engine. More...

Detailed Description

Wrapper class for a 64-bit PCG engine.

Auto-seeded by default (with a relatively high quality seed), but can be explicitly seeded for reproducibility. Used by Generator.

See also
https://www.pcg-random.org/

Public Types

using result_type = uint64_t
 

Public Member Functions

 Pcg64Engine ()
 Default constructor, automatically seeds itself.
 
 Pcg64Engine (result_type seed)
 Constructor with a low quality seed.
 
 Pcg64Engine (const Pcg64Engine &other)
 
Pcg64Engineoperator= (const Pcg64Engine &other)
 
void reseed ()
 Re-seeds the engine with an automatically generated seed.
 
void reseed (result_type seed)
 Re-seeds the engine with a low quality seed.
 
result_type operator() ()
 Returns a number between min() and max().
 
void discard (unsigned long long z)
 Discards an arbitrary number of results.
 
void makeThreadSafe ()
 Makes the current engine instance thread safe.
 

Static Public Member Functions

static constexpr result_type min ()
 Returns the minimum number that this engine can generate.
 
static constexpr result_type max ()
 Returns the maximum number that this engine can generate.
 

The documentation for this class was generated from the following file:
Search Tab / S to search, Esc to close