VTK  9.0.2
vtkMinimalStandardRandomSequence.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkMinimalStandardRandomSequence.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 =========================================================================*/
35 #ifndef vtkMinimalStandardRandomSequence_h
36 #define vtkMinimalStandardRandomSequence_h
37 
38 #include "vtkCommonCoreModule.h" // For export macro
39 #include "vtkRandomSequence.h"
40 
41 class VTKCOMMONCORE_EXPORT vtkMinimalStandardRandomSequence : public vtkRandomSequence
42 {
43 public:
45 
50  void PrintSelf(ostream& os, vtkIndent indent) override;
52 
57  void Initialize(vtkTypeUInt32 seed) override { this->SetSeed(seed); }
58 
73  void SetSeed(int value);
74 
86  void SetSeedOnly(int value);
87 
92  int GetSeed();
93 
98  double GetValue() override;
99 
103  void Next() override;
104 
117  virtual double GetRangeValue(double rangeMin, double rangeMax);
118 
119 protected:
122 
123  int Seed;
124 
125 private:
127  void operator=(const vtkMinimalStandardRandomSequence&) = delete;
128 };
129 
130 #endif // #ifndef vtkMinimalStandardRandomSequence_h
a simple class to control print indentation
Definition: vtkIndent.h:34
Park and Miller Sequence of pseudo random numbers.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void Initialize(vtkTypeUInt32 seed) override
Satisfy general API of vtkRandomSequence superclass.
double GetValue() override
Current value.
void Next() override
Move to the next number in the random sequence.
virtual double GetRangeValue(double rangeMin, double rangeMax)
Convenient method to return a value in a specific range from the range [0,1.
void SetSeed(int value)
Set the seed of the random sequence.
int GetSeed()
Get the seed of the random sequence.
static vtkMinimalStandardRandomSequence * New()
Standard methods for instantiation, type information, and printing.
void SetSeedOnly(int value)
Set the seed of the random sequence.
Generate a sequence of random numbers.
@ value
Definition: vtkX3D.h:226