aboutsummaryrefslogtreecommitdiff
path: root/src/stable/random.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/stable/random.cpp')
-rw-r--r--src/stable/random.cpp19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/stable/random.cpp b/src/stable/random.cpp
index 725948a..63416bf 100644
--- a/src/stable/random.cpp
+++ b/src/stable/random.cpp
@@ -20,13 +20,28 @@ Bu::Random::~Random()
20 pGen = NULL; 20 pGen = NULL;
21} 21}
22 22
23void Bu::Random::seed( int32_t iSeed )
24{
25 getInstance().pGen->seed( iSeed );
26}
27
23int32_t Bu::Random::rand() 28int32_t Bu::Random::rand()
24{ 29{
25 return getInstance().pGen->rand(); 30 return getInstance().pGen->rand();
26} 31}
27 32
28void Bu::Random::seed( int32_t iSeed ) 33int32_t Bu::Random::rand( int32_t iMax )
29{ 34{
30 getInstance().pGen->seed( iSeed ); 35 return getInstance().pGen->rand( iMax );
36}
37
38int32_t Bu::Random::rand( int32_t iMin, int32_t iMax )
39{
40 return getInstance().pGen->rand( iMin, iMax );
41}
42
43double Bu::Random::randNorm()
44{
45 return getInstance().pGen->randNorm();
31} 46}
32 47