diff options
author | dan miller | 2007-10-19 05:22:50 +0000 |
---|---|---|
committer | dan miller | 2007-10-19 05:22:50 +0000 |
commit | 0d2e078eebb2827e0ed49e55dd10df406c4e3af1 (patch) | |
tree | 6a6be07e1db2854c843ee8e39f4163ed5cc7a165 /libraries/ode-0.9\/OPCODE/Ice/IceRandom.cpp | |
parent | trying to fix my screwup, please hold on (diff) | |
download | opensim-SC-0d2e078eebb2827e0ed49e55dd10df406c4e3af1.zip opensim-SC-0d2e078eebb2827e0ed49e55dd10df406c4e3af1.tar.gz opensim-SC-0d2e078eebb2827e0ed49e55dd10df406c4e3af1.tar.bz2 opensim-SC-0d2e078eebb2827e0ed49e55dd10df406c4e3af1.tar.xz |
trying to fix my screwup part deux
Diffstat (limited to '')
-rwxr-xr-x | libraries/ode-0.9\/OPCODE/Ice/IceRandom.cpp | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/libraries/ode-0.9\/OPCODE/Ice/IceRandom.cpp b/libraries/ode-0.9\/OPCODE/Ice/IceRandom.cpp deleted file mode 100755 index cc63a04..0000000 --- a/libraries/ode-0.9\/OPCODE/Ice/IceRandom.cpp +++ /dev/null | |||
@@ -1,35 +0,0 @@ | |||
1 | /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | ||
2 | /** | ||
3 | * Contains code for random generators. | ||
4 | * \file IceRandom.cpp | ||
5 | * \author Pierre Terdiman | ||
6 | * \date August, 9, 2001 | ||
7 | */ | ||
8 | /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | ||
9 | |||
10 | /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | ||
11 | // Precompiled Header | ||
12 | #include "Stdafx.h" | ||
13 | |||
14 | using namespace IceCore; | ||
15 | |||
16 | void IceCore:: SRand(udword seed) | ||
17 | { | ||
18 | srand(seed); | ||
19 | } | ||
20 | |||
21 | udword IceCore::Rand() | ||
22 | { | ||
23 | return rand(); | ||
24 | } | ||
25 | |||
26 | |||
27 | static BasicRandom gRandomGenerator(42); | ||
28 | |||
29 | udword IceCore::GetRandomIndex(udword max_index) | ||
30 | { | ||
31 | // We don't use rand() since it's limited to RAND_MAX | ||
32 | udword Index = gRandomGenerator.Randomize(); | ||
33 | return Index % max_index; | ||
34 | } | ||
35 | |||