VCV Rack API v2
|
xoroshiro128+. More...
#include <random.hpp>
Public Member Functions | |
void | seed (uint64_t s0, uint64_t s1) |
bool | isSeeded () |
uint64_t | operator() () |
constexpr uint64_t | min () const |
constexpr uint64_t | max () const |
Static Public Member Functions | |
static uint64_t | rotl (uint64_t x, int k) |
Public Attributes | |
uint64_t | state [2] = {} |
xoroshiro128+.
Very fast, not-cryptographic random number generator. From https://prng.di.unimi.it/ Example:
std::random_device rd; random::Xoroshiro128Plus rng(rd(), rd()); uint64_t r = rng(); std::uniform_real_distribution<float> uniform(0.f, 1.f); float r = uniform(rng); std::normal_distribution<> normal(0.0, 1.0); double r = normal(rng);
|
inline |
|
inline |
|
inlinestatic |
|
inline |
|
inlineconstexpr |
|
inlineconstexpr |
uint64_t rack::random::Xoroshiro128Plus::state[2] = {} |