fix random device
This commit is contained in:
@@ -44,6 +44,7 @@ public:
|
|||||||
|
|
||||||
void randomize_phase()
|
void randomize_phase()
|
||||||
{
|
{
|
||||||
|
std::random_device random;
|
||||||
std::mt19937 gen(random());
|
std::mt19937 gen(random());
|
||||||
std::uniform_real_distribution<> dis(0.0, 1.0);
|
std::uniform_real_distribution<> dis(0.0, 1.0);
|
||||||
phase = dis(gen);
|
phase = dis(gen);
|
||||||
@@ -54,7 +55,6 @@ private:
|
|||||||
float phase_resolution;
|
float phase_resolution;
|
||||||
float phase;
|
float phase;
|
||||||
float history;
|
float history;
|
||||||
std::random_device random;
|
|
||||||
|
|
||||||
float sine(float x)
|
float sine(float x)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user