FLImaging 6.5.13.1
RandomGenerator.h
1#pragma once
2
11#include "FLBase.h"
12#include "FLArray.h"
13
15namespace FLImaging
16{
18 namespace Base
19 {
27 class FL_EXPORT CRandomGenerator : public CFLBase
28 {
29 protected:
38
39 public:
40
54 static int32_t Int32(int32_t i32RangeStart = 0x80000000, int32_t i32RangeEnd = 0x7fffffff);
55
69 static uint32_t UInt32(uint32_t u32RangeStart = 0, uint32_t u32RangeEnd = 0xffffffff);
70
84 static int64_t Int64(int64_t i64RangeStart = 0x8000000000000000ull, int64_t i64RangeEnd = 0x7fffffffffffffffull);
85
99 static uint64_t UInt64(uint64_t u64RangeStart = 0, uint64_t u64RangeEnd = 0xffffffffffffffffull);
100
114 static float Float(float f32RangeStart = 0.f, float f32RangeEnd = 1.f);
115
129 static double Double(double f64RangeStart = 0., double f64RangeEnd = 1.);
130
131
149 static const CResult GenerateNoConflictRandom(const uint32_t u32Count, CFLArray<uint32_t>& flaResult, uint32_t u32Seed = 0);
150
151 DeclareGetClassType();
152 };
153 }
154}
155
Template type array class.
Definition RangeTree.h:19
Top-level base class of FLImaging.
Definition FLBase.h:36
random generator class
Definition RandomGenerator.h:28
static float Float(float f32RangeStart=0.f, float f32RangeEnd=1.f)
Generates Mersenne Twister random numbers of 32-bit floating point type.
static double Double(double f64RangeStart=0., double f64RangeEnd=1.)
Generates Mersenne Twister random numbers of 64-bit floating point type.
static uint32_t UInt32(uint32_t u32RangeStart=0, uint32_t u32RangeEnd=0xffffffff)
Generates Mersenne Twister random numbers of 32-bit unsigned integer type.
static const CResult GenerateNoConflictRandom(const uint32_t u32Count, CFLArray< uint32_t > &flaResult, uint32_t u32Seed=0)
Generates non-repeating random numbers.
static int64_t Int64(int64_t i64RangeStart=0x8000000000000000ull, int64_t i64RangeEnd=0x7fffffffffffffffull)
Generates Mersenne Twister random numbers of 64-bit integer type.
static uint64_t UInt64(uint64_t u64RangeStart=0, uint64_t u64RangeEnd=0xffffffffffffffffull)
Generates Mersenne Twister random numbers of 64-bit unsigned integer type.
static int32_t Int32(int32_t i32RangeStart=0x80000000, int32_t i32RangeEnd=0x7fffffff)
Generates Mersenne Twister random numbers of 32-bit integer type.
FLImaging module execution result object.
Definition ResultsDef.h:1514