VTK  9.0.20210121
vtkGridSynchronizedTemplates3D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkGridSynchronizedTemplates3D.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 
14 =========================================================================*/
30 #ifndef vtkGridSynchronizedTemplates3D_h
31 #define vtkGridSynchronizedTemplates3D_h
32 
33 #include "vtkContourValues.h" // Because it passes all the calls to it
34 #include "vtkFiltersCoreModule.h" // For export macro
35 #include "vtkPolyDataAlgorithm.h"
36 
37 class vtkStructuredGrid;
38 
39 class VTKFILTERSCORE_EXPORT vtkGridSynchronizedTemplates3D : public vtkPolyDataAlgorithm
40 {
41 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45 
49  vtkMTimeType GetMTime() override;
50 
52 
58  vtkSetMacro(ComputeNormals, vtkTypeBool);
59  vtkGetMacro(ComputeNormals, vtkTypeBool);
60  vtkBooleanMacro(ComputeNormals, vtkTypeBool);
62 
64 
72  vtkSetMacro(ComputeGradients, vtkTypeBool);
73  vtkGetMacro(ComputeGradients, vtkTypeBool);
74  vtkBooleanMacro(ComputeGradients, vtkTypeBool);
76 
78 
81  vtkSetMacro(ComputeScalars, vtkTypeBool);
82  vtkGetMacro(ComputeScalars, vtkTypeBool);
83  vtkBooleanMacro(ComputeScalars, vtkTypeBool);
85 
87 
91  vtkSetMacro(GenerateTriangles, vtkTypeBool);
92  vtkGetMacro(GenerateTriangles, vtkTypeBool);
93  vtkBooleanMacro(GenerateTriangles, vtkTypeBool);
95 
100  void SetValue(int i, double value) { this->ContourValues->SetValue(i, value); }
101 
105  double GetValue(int i) { return this->ContourValues->GetValue(i); }
106 
111  double* GetValues() { return this->ContourValues->GetValues(); }
112 
118  void GetValues(double* contourValues) { this->ContourValues->GetValues(contourValues); }
119 
125  void SetNumberOfContours(int number) { this->ContourValues->SetNumberOfContours(number); }
126 
130  vtkIdType GetNumberOfContours() { return this->ContourValues->GetNumberOfContours(); }
131 
136  void GenerateValues(int numContours, double range[2])
137  {
138  this->ContourValues->GenerateValues(numContours, range);
139  }
140 
145  void GenerateValues(int numContours, double rangeStart, double rangeEnd)
146  {
147  this->ContourValues->GenerateValues(numContours, rangeStart, rangeEnd);
148  }
149 
153  void ThreadedExecute(
154  vtkStructuredGrid* input, vtkInformationVector** inputVector, vtkInformation* outInfo);
155 
160  void SetInputMemoryLimit(long limit);
161 
163 
168  vtkSetClampMacro(OutputPointsPrecision, int, SINGLE_PRECISION, DEFAULT_PRECISION);
169  vtkGetMacro(OutputPointsPrecision, int);
171 
172 protected:
174  ~vtkGridSynchronizedTemplates3D() override;
175 
178  int FillInputPortInformation(int port, vtkInformation* info) override;
179 
184 
186 
187  int MinimumPieceSize[3];
189 
190 private:
192  void operator=(const vtkGridSynchronizedTemplates3D&) = delete;
193 };
194 
195 #endif
vtkGridSynchronizedTemplates3D::ComputeNormals
vtkTypeBool ComputeNormals
Definition: vtkGridSynchronizedTemplates3D.h:180
vtkGridSynchronizedTemplates3D::ContourValues
vtkContourValues * ContourValues
Definition: vtkGridSynchronizedTemplates3D.h:185
vtkX3D::value
Definition: vtkX3D.h:226
vtkIdType
int vtkIdType
Definition: vtkType.h:330
vtkGridSynchronizedTemplates3D::ComputeScalars
vtkTypeBool ComputeScalars
Definition: vtkGridSynchronizedTemplates3D.h:182
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:35
vtkPolyDataAlgorithm::RequestUpdateExtent
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
vtkX3D::range
Definition: vtkX3D.h:244
vtkStructuredGrid
topologically regular array of data
Definition: vtkStructuredGrid.h:57
vtkGridSynchronizedTemplates3D::GetValues
double * GetValues()
Get a pointer to an array of contour values.
Definition: vtkGridSynchronizedTemplates3D.h:111
vtkGridSynchronizedTemplates3D
generate isosurface from structured grids
Definition: vtkGridSynchronizedTemplates3D.h:39
vtkPolyDataAlgorithm::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkGridSynchronizedTemplates3D::GenerateValues
void GenerateValues(int numContours, double range[2])
Generate numContours equally spaced contour values between specified range.
Definition: vtkGridSynchronizedTemplates3D.h:136
vtkGridSynchronizedTemplates3D::GetValue
double GetValue(int i)
Get the ith contour value.
Definition: vtkGridSynchronizedTemplates3D.h:105
vtkPolyDataAlgorithm.h
vtkX3D::port
Definition: vtkX3D.h:453
vtkGridSynchronizedTemplates3D::SetNumberOfContours
void SetNumberOfContours(int number)
Set the number of contours to place into the list.
Definition: vtkGridSynchronizedTemplates3D.h:125
vtkPolyDataAlgorithm::RequestData
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
vtkObject::GetMTime
virtual vtkMTimeType GetMTime()
Return this object's modified time.
vtkGridSynchronizedTemplates3D::GetNumberOfContours
vtkIdType GetNumberOfContours()
Get the number of contours in the list of contour values.
Definition: vtkGridSynchronizedTemplates3D.h:130
vtkContourValues
helper object to manage setting and generating contour values
Definition: vtkContourValues.h:35
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkPolyDataAlgorithm::FillInputPortInformation
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
vtkContourValues.h
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkX3D::info
Definition: vtkX3D.h:382
vtkGridSynchronizedTemplates3D::GenerateValues
void GenerateValues(int numContours, double rangeStart, double rangeEnd)
Generate numContours equally spaced contour values between specified range.
Definition: vtkGridSynchronizedTemplates3D.h:145
vtkGridSynchronizedTemplates3D::OutputPointsPrecision
int OutputPointsPrecision
Definition: vtkGridSynchronizedTemplates3D.h:188
vtkGridSynchronizedTemplates3D::GenerateTriangles
vtkTypeBool GenerateTriangles
Definition: vtkGridSynchronizedTemplates3D.h:183
vtkGridSynchronizedTemplates3D::ComputeGradients
vtkTypeBool ComputeGradients
Definition: vtkGridSynchronizedTemplates3D.h:181
vtkGridSynchronizedTemplates3D::GetValues
void GetValues(double *contourValues)
Fill a supplied list with contour values.
Definition: vtkGridSynchronizedTemplates3D.h:118
vtkGridSynchronizedTemplates3D::SetValue
void SetValue(int i, double value)
Set a particular contour value at contour number i.
Definition: vtkGridSynchronizedTemplates3D.h:100
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69
vtkPolyDataAlgorithm::New
static vtkPolyDataAlgorithm * New()
vtkMTimeType
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:285
vtkPolyDataAlgorithm
Superclass for algorithms that produce only polydata as output.
Definition: vtkPolyDataAlgorithm.h:41