paysages3d/src/system/RandomGenerator.h

23 lines
350 B
C
Raw Normal View History

2013-11-03 14:46:39 +00:00
#ifndef RANDOMGENERATOR_H
#define RANDOMGENERATOR_H
#include "system_global.h"
2013-11-19 11:16:33 +00:00
2013-11-03 14:46:39 +00:00
#include <cstdlib>
namespace paysages {
namespace system {
class SYSTEMSHARED_EXPORT RandomGenerator {
public:
2013-11-03 14:46:39 +00:00
RandomGenerator();
static inline double random() {
2013-11-03 14:46:39 +00:00
return ((double)rand()) / (double)RAND_MAX;
}
};
}
}
#endif // RANDOMGENERATOR_H