diff --git a/libs/random/include/psemek/random/uniform.hpp b/libs/random/include/psemek/random/uniform.hpp index 4446fd25..4bcf82cc 100644 --- a/libs/random/include/psemek/random/uniform.hpp +++ b/libs/random/include/psemek/random/uniform.hpp @@ -3,6 +3,8 @@ #include #include +#include + #include namespace psemek::random @@ -23,4 +25,10 @@ namespace psemek::random return uniform(rng, {min, max}); } + template + T uniform_angle(RNG && rng) + { + return uniform(rng, T{0}, T{2 * geom::pi}); + } + }