VTK  9.1.0
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=========================================================================*/
123#ifndef vtkTensorGlyph_h
124#define vtkTensorGlyph_h
125
126#include "vtkFiltersCoreModule.h" // For export macro
127#include "vtkPolyDataAlgorithm.h"
128
129class VTKFILTERSCORE_EXPORT vtkTensorGlyph : public vtkPolyDataAlgorithm
130{
131public:
133
141 void PrintSelf(ostream& os, vtkIndent indent) override;
143
145
154
156
161 void SetSourceConnection(int id, vtkAlgorithmOutput* algOutput);
163 {
164 this->SetSourceConnection(0, algOutput);
165 }
167
169
172 vtkSetMacro(Scaling, vtkTypeBool);
173 vtkGetMacro(Scaling, vtkTypeBool);
174 vtkBooleanMacro(Scaling, vtkTypeBool);
176
178
182 vtkSetMacro(ScaleFactor, double);
183 vtkGetMacro(ScaleFactor, double);
185
187
190 vtkSetMacro(ThreeGlyphs, vtkTypeBool);
191 vtkGetMacro(ThreeGlyphs, vtkTypeBool);
192 vtkBooleanMacro(ThreeGlyphs, vtkTypeBool);
194
196
199 vtkSetMacro(Symmetric, vtkTypeBool);
200 vtkGetMacro(Symmetric, vtkTypeBool);
201 vtkBooleanMacro(Symmetric, vtkTypeBool);
203
205
209 vtkSetMacro(Length, double);
210 vtkGetMacro(Length, double);
212
214
217 vtkSetMacro(ExtractEigenvalues, vtkTypeBool);
218 vtkBooleanMacro(ExtractEigenvalues, vtkTypeBool);
219 vtkGetMacro(ExtractEigenvalues, vtkTypeBool);
221
223
228 vtkSetMacro(ColorGlyphs, vtkTypeBool);
229 vtkGetMacro(ColorGlyphs, vtkTypeBool);
230 vtkBooleanMacro(ColorGlyphs, vtkTypeBool);
232
233 enum
234 {
236 COLOR_BY_EIGENVALUES
237 };
238
240
250 vtkSetClampMacro(ColorMode, int, COLOR_BY_SCALARS, COLOR_BY_EIGENVALUES);
251 vtkGetMacro(ColorMode, int);
252 void SetColorModeToScalars() { this->SetColorMode(COLOR_BY_SCALARS); }
253 void SetColorModeToEigenvalues() { this->SetColorMode(COLOR_BY_EIGENVALUES); }
255
257
262 vtkSetMacro(ClampScaling, vtkTypeBool);
263 vtkGetMacro(ClampScaling, vtkTypeBool);
264 vtkBooleanMacro(ClampScaling, vtkTypeBool);
266
268
274 vtkSetMacro(MaxScaleFactor, double);
275 vtkGetMacro(MaxScaleFactor, double);
277
278protected:
280 ~vtkTensorGlyph() override;
281
285
286 vtkTypeBool Scaling; // Determine whether scaling of geometry is performed
287 double ScaleFactor; // Scale factor to use to scale geometry
288 vtkTypeBool ExtractEigenvalues; // Boolean controls eigenfunction extraction
289 vtkTypeBool ColorGlyphs; // Boolean controls coloring with input scalar data
290 int ColorMode; // The coloring mode to use for the glyphs.
291 vtkTypeBool ClampScaling; // Boolean controls whether scaling is clamped.
292 double MaxScaleFactor; // Maximum scale factor (ScaleFactor*eigenvalue)
293 vtkTypeBool ThreeGlyphs; // Boolean controls drawing 1 or 3 glyphs
294 vtkTypeBool Symmetric; // Boolean controls drawing a "mirror" of each glyph
295 double Length; // Distance, in x, from the origin to the end of the glyph
296private:
297 vtkTensorGlyph(const vtkTensorGlyph&) = delete;
298 void operator=(const vtkTensorGlyph&) = delete;
299};
300
301#endif
Proxy object to connect input/output ports.
a simple class to control print indentation
Definition: vtkIndent.h:113
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:195
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.
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
static vtkTensorGlyph * New()
Standard methods for instantiation, obtaining type information, and printing.Construct object with sc...
void SetSourceConnection(int id, vtkAlgorithmOutput *algOutput)
Specify a source object at a specified table location.
vtkTypeBool ClampScaling
vtkTypeBool ColorGlyphs
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
vtkPolyData * GetSource()
Specify the geometry to copy to each point.
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 *)