summaryrefslogtreecommitdiffstats
path: root/core/math/random_pcg.h
diff options
context:
space:
mode:
Diffstat (limited to 'core/math/random_pcg.h')
-rw-r--r--core/math/random_pcg.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/math/random_pcg.h b/core/math/random_pcg.h
index 974dbbfc2e..65fcf67664 100644
--- a/core/math/random_pcg.h
+++ b/core/math/random_pcg.h
@@ -129,7 +129,7 @@ public:
return p_mean + p_deviation * (cos(Math_TAU * randd()) * sqrt(-2.0 * log(randd()))); // Box-Muller transform
}
_FORCE_INLINE_ float randfn(float p_mean, float p_deviation) {
- return p_mean + p_deviation * (cos(Math_TAU * randf()) * sqrt(-2.0 * log(randf()))); // Box-Muller transform
+ return p_mean + p_deviation * (cos((float)Math_TAU * randf()) * sqrt(-2.0 * log(randf()))); // Box-Muller transform
}
double random(double p_from, double p_to);