VTK  9.2.6
vtkTensorGlyph.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkTensorGlyph.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 =========================================================================*/
126 #ifndef vtkTensorGlyph_h
127 #define vtkTensorGlyph_h
128 
129 #include "vtkFiltersCoreModule.h" // For export macro
130 #include "vtkPolyDataAlgorithm.h"
131 
132 class VTKFILTERSCORE_EXPORT vtkTensorGlyph : public vtkPolyDataAlgorithm
133 {
134 public:
136 
142  static vtkTensorGlyph* New();
144  void PrintSelf(ostream& os, vtkIndent indent) override;
146 
148 
157 
159 
164  void SetSourceConnection(int id, vtkAlgorithmOutput* algOutput);
166  {
167  this->SetSourceConnection(0, algOutput);
168  }
170 
172 
175  vtkSetMacro(Scaling, vtkTypeBool);
176  vtkGetMacro(Scaling, vtkTypeBool);
177  vtkBooleanMacro(Scaling, vtkTypeBool);
179 
181 
185  vtkSetMacro(ScaleFactor, double);
186  vtkGetMacro(ScaleFactor, double);
188 
190 
193  vtkSetMacro(ThreeGlyphs, vtkTypeBool);
194  vtkGetMacro(ThreeGlyphs, vtkTypeBool);
195  vtkBooleanMacro(ThreeGlyphs, vtkTypeBool);
197 
199 
202  vtkSetMacro(Symmetric, vtkTypeBool);
203  vtkGetMacro(Symmetric, vtkTypeBool);
204  vtkBooleanMacro(Symmetric, vtkTypeBool);
206 
208 
212  vtkSetMacro(Length, double);
213  vtkGetMacro(Length, double);
215 
217 
220  vtkSetMacro(ExtractEigenvalues, vtkTypeBool);
221  vtkBooleanMacro(ExtractEigenvalues, vtkTypeBool);
222  vtkGetMacro(ExtractEigenvalues, vtkTypeBool);
224 
226 
231  vtkSetMacro(ColorGlyphs, vtkTypeBool);
232  vtkGetMacro(ColorGlyphs, vtkTypeBool);
233  vtkBooleanMacro(ColorGlyphs, vtkTypeBool);
235 
236  enum
237  {
239  COLOR_BY_EIGENVALUES
240  };
241 
243 
253  vtkSetClampMacro(ColorMode, int, COLOR_BY_SCALARS, COLOR_BY_EIGENVALUES);
254  vtkGetMacro(ColorMode, int);
255  void SetColorModeToScalars() { this->SetColorMode(COLOR_BY_SCALARS); }
256  void SetColorModeToEigenvalues() { this->SetColorMode(COLOR_BY_EIGENVALUES); }
258 
260 
265  vtkSetMacro(ClampScaling, vtkTypeBool);
266  vtkGetMacro(ClampScaling, vtkTypeBool);
267  vtkBooleanMacro(ClampScaling, vtkTypeBool);
269 
271 
277  vtkSetMacro(MaxScaleFactor, double);
278  vtkGetMacro(MaxScaleFactor, double);
280 
281 protected:
283  ~vtkTensorGlyph() override;
284 
288 
289  vtkTypeBool Scaling; // Determine whether scaling of geometry is performed
290  double ScaleFactor; // Scale factor to use to scale geometry
291  vtkTypeBool ExtractEigenvalues; // Boolean controls eigenfunction extraction
292  vtkTypeBool ColorGlyphs; // Boolean controls coloring with input scalar data
293  int ColorMode; // The coloring mode to use for the glyphs.
294  vtkTypeBool ClampScaling; // Boolean controls whether scaling is clamped.
295  double MaxScaleFactor; // Maximum scale factor (ScaleFactor*eigenvalue)
296  vtkTypeBool ThreeGlyphs; // Boolean controls drawing 1 or 3 glyphs
297  vtkTypeBool Symmetric; // Boolean controls drawing a "mirror" of each glyph
298  double Length; // Distance, in x, from the origin to the end of the glyph
299 private:
300  vtkTensorGlyph(const vtkTensorGlyph&) = delete;
301  void operator=(const vtkTensorGlyph&) = delete;
302 };
303 
304 #endif
Proxy object to connect input/output ports.
a simple class to control print indentation
Definition: vtkIndent.h:119
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:200
scale and orient glyph(s) according to eigenvalues and eigenvectors of symmetrical part of tensor
void SetSourceData(vtkPolyData *source)
Specify the geometry to copy to each point.
void SetColorModeToScalars()
Set the color mode to be used for the glyphs.
vtkPolyData * GetSource()
Specify the geometry to copy to each point.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
void SetColorModeToEigenvalues()
Set the color mode to be used for the glyphs.
vtkTypeBool ThreeGlyphs
void SetSourceConnection(int id, vtkAlgorithmOutput *algOutput)
Specify a source object at a specified table location.
vtkTypeBool ClampScaling
vtkTypeBool ColorGlyphs
static vtkTensorGlyph * New()
Standard methods for instantiation, obtaining type information, and printing.Construct object with sc...
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkTypeBool Scaling
vtkTypeBool Symmetric
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for instantiation, obtaining type information, and printing.Construct object with sc...
~vtkTensorGlyph() override
void SetSourceConnection(vtkAlgorithmOutput *algOutput)
Specify a source object at a specified table location.
vtkTypeBool ExtractEigenvalues
@ info
Definition: vtkX3D.h:382
@ port
Definition: vtkX3D.h:453
int vtkTypeBool
Definition: vtkABI.h:69
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)