OWL
|
#include <random.h>
Public Member Functions | |
__both__ | LCG (unsigned int val0, unsigned int val1) |
__both__ | LCG (const vec2i &seed) |
__both__ | LCG (const vec2ui &seed) |
__both__ void | init (unsigned int val0, unsigned int val1) |
__both__ float | operator() () |
Public Attributes | |
uint32_t | state |
simple 24-bit linear congruence generator
|
inline |
Generate random unsigned int in [0, 2^24), then use that to generate random float in [0.f,1.f)