QGIS API Documentation  2.2.0-Valmiera
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Macros | Functions
mersenne-twister.h File Reference
#include <stdint.h>
#include <limits>
Include dependency graph for mersenne-twister.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MD_RAND_MAX   std::numeric_limits<int32_t>::max()

Functions

void mt_srand (unsigned seed_value)
int mt_rand ()
uint32_t rand_u32 ()
uint64_t rand_u64 ()
void seed (uint32_t seed_value)
float randf_cc ()
float randf_co ()
float randf_oo ()
double randd_cc ()
double randd_co ()
double randd_oo ()

Macro Definition Documentation

#define MD_RAND_MAX   std::numeric_limits<int32_t>::max()

Function Documentation

int mt_rand ( )

Definition at line 168 of file mersenne-twister.cpp.

References rand_u32().

Referenced by QgsPointSample::addSamplePoints(), and QgsTransectSample::createSample().

void mt_srand ( unsigned  seed_value)

Definition at line 188 of file mersenne-twister.cpp.

References seed().

Referenced by QgsPointSample::createRandomPoints(), and QgsTransectSample::createSample().

uint32_t rand_u32 ( )

Definition at line 149 of file mersenne-twister.cpp.

References generate_numbers(), index, MT, and SIZE.

Referenced by mt_rand(), rand_u64(), randd_cc(), randd_co(), randd_oo(), randf_cc(), randf_co(), and randf_oo().

uint64_t rand_u64 ( )

Definition at line 223 of file mersenne-twister.cpp.

References rand_u32().

double randd_cc ( )

Definition at line 208 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

double randd_co ( )

Definition at line 213 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

double randd_oo ( )

Definition at line 218 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

float randf_cc ( )

Definition at line 193 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

float randf_co ( )

Definition at line 198 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

float randf_oo ( )

Definition at line 203 of file mersenne-twister.cpp.

References MD_UINT32_MAX, and rand_u32().

void seed ( uint32_t  seed_value)

Definition at line 108 of file mersenne-twister.cpp.

References index, MT, and SIZE.

Referenced by mt_srand().