PseudoRandom< FLOAT > Class Template Reference Math Library

#include <lib_math.h>

详细描述

template<typename FLOAT>
class maxon::PseudoRandom< FLOAT >

Pseudo random value generator. Only left in for compatibility. The class will always produce the same output if the initialization seed was matching.

公共成员函数

  PseudoRandom ()
void  Init ( UInt32 seed )
FLOAT  Get01 ()
FLOAT  Get11 ()
Int32   GetRaw () const

Private Attributes

UInt32   seed

构造函数 & 析构函数文档编制

◆  PseudoRandom()

PseudoRandom ( )

成员函数文档编制

◆  Init()

void Init ( UInt32   seed )

Initialize the random class with a custom seed value.

参数
[in] seed Seed value.

◆  Get01()

FLOAT Get01 ( )

Returns the next random value in the range of 0..1.

◆  Get11()

FLOAT Get11 ( )

Returns the next random value in the range of -1..1.

◆  GetRaw()

Int32 GetRaw ( ) const

Returns the current seed value. Note that this is no longer the same value that the class was initialized with

Member Data Documentation

◆  seed

UInt32 seed
private