VTK  9.3.1
vtkMinimalStandardRandomSequence.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
30 #ifndef vtkMinimalStandardRandomSequence_h
31 #define vtkMinimalStandardRandomSequence_h
32 
33 #include "vtkCommonCoreModule.h" // For export macro
34 #include "vtkRandomSequence.h"
35 
36 VTK_ABI_NAMESPACE_BEGIN
37 class VTKCOMMONCORE_EXPORT vtkMinimalStandardRandomSequence : public vtkRandomSequence
38 {
39 public:
41 
46  void PrintSelf(ostream& os, vtkIndent indent) override;
48 
53  void Initialize(vtkTypeUInt32 seed) override { this->SetSeed(seed); }
54 
69  void SetSeed(int value);
70 
82  void SetSeedOnly(int value);
83 
88  int GetSeed();
89 
94  double GetValue() override;
95 
99  void Next() override;
100 
113  virtual double GetRangeValue(double rangeMin, double rangeMax);
114 
120  double GetNextRangeValue(double rangeMin, double rangeMax);
121 
122 protected:
125 
126  int Seed;
127 
128 private:
130  void operator=(const vtkMinimalStandardRandomSequence&) = delete;
131 };
132 
133 VTK_ABI_NAMESPACE_END
134 #endif // #ifndef vtkMinimalStandardRandomSequence_h
Generate a sequence of random numbers.
virtual void Next()=0
Move to the next number in the random sequence.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for type information and printing.
virtual double GetValue()=0
Return the current value.
void Initialize(vtkTypeUInt32 seed) override
Satisfy general API of vtkRandomSequence superclass.
a simple class to control print indentation
Definition: vtkIndent.h:28
Park and Miller Sequence of pseudo random numbers.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...