OpenMesh
|
Generate a random number between 0.0 and 1.0 with a guaranteed resolution. More...
#include <OpenMesh/Core/Utils/RandomNumberGenerator.hh>
Public Member Functions | |
RandomNumberGenerator (const double _resolution) | |
Constructor. | |
double | getRand () const |
returns a random double between 0.0 and 1.0 with a guaranteed resolution | |
double | resolution () const |
Generate a random number between 0.0 and 1.0 with a guaranteed resolution.
Especially useful on windows, as there MAX_RAND is often only 32k which is not enough resolution for a lot of applications
RandomNumberGenerator::RandomNumberGenerator | ( | const double | _resolution | ) |
Constructor.
_resolution | specifies the desired resolution for the random number generated |