]> git.mxchange.org Git - simgear.git/blobdiff - simgear/math/sg_random.h
cppbind.Ghost: clean up a bit
[simgear.git] / simgear / math / sg_random.h
index 1fed733d3aa5c683d8903177350ab70a0643c126..aa084a6362439b50063ec9a94bd6ab8552bc8fb5 100644 (file)
@@ -40,13 +40,20 @@ extern "C" {
  * Structure to hold MT algorithm state to easily allow independant
  * sets of random numbers with different seeds.
  */
-struct {unsigned int array[MT_N]; int index; } typedef mt;
+typedef struct {unsigned int array[MT_N]; int index; } mt;
 
 /**
  * Initialize a new MT state with a given seed.
  */
 void mt_init(mt *mt, unsigned int seed);
 
+/**
+ * Initialize a new MT state with a seed that only
+ * changes every 10 minutes.  Used to synchronize
+ * multi-process deployments.
+ */
+void mt_init_time_10(mt *mt);
+
 /**
  * Generate a new 32-bit random number based on the given MT state.
  */