This documentation is automatically generated from the openFrameworks source code using doxygen and refers to the most recent release, version 0.12.0.
ofRandomEngine.h
Go to the documentation of this file.
13// https://stackoverflow.com/questions/25360241/using-random-number-generator-multiple-instances-or-singleton-approach
26 std::seed_seq seq_{ rd_(), rd_(), rd_(), rd_() }; // 4 is considered fine for non-cryptographic needs
Definition ofRandomEngine.h:23
void seed(unsigned long new_seed)
passes a value to seed the mt19937 generator
Definition ofRandomEngine.h:42
Definition ofSingleton.hpp:15
Definition ofRandomDistributions.h:14
void seed(unsigned long seed)
Passes a value to seed the mt19937 generator within the ending instance.
Definition ofRandomEngine.h:62
void shuffle(T &values)
Shuffles the order of the elements within the passed container, using the centralized random engine.
Definition ofRandomEngine.h:68
void ofSeedRandom()
Seeds the random number generator with a unique value.
Definition ofMath.cpp:19