MayaFlux 0.1.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ Random()

MayaFlux::Nodes::Generator::Stochastics::Random::Random ( Utils::distribution  type = Utils::distribution::UNIFORM)

Constructor for the stochastic generator.

Parameters
typeDistribution type to use (default: uniform distribution)

Creates a stochastic generator with the specified probability distribution. The generator is initialized with entropy from the system's random device for non-deterministic behavior across program executions.

Definition at line 5 of file Stochastic.cpp.

6 : m_random_engine(std::random_device {}())
7 , m_current_start(-1.0F)
8 , m_current_end(1.0F)
9 , m_normal_spread(4.0F)
10 , m_type(type)
11{
12}
Utils::distribution m_type
Current probability distribution algorithm.
double m_normal_spread
Variance parameter for normal distribution.
std::mt19937 m_random_engine
Mersenne Twister entropy generator.
double m_current_start
Lower bound of the current output range.
double m_current_end
Upper bound of the current output range.