VTK
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 =========================================================================*/
79 #ifndef vtkTensorGlyph_h
80 #define vtkTensorGlyph_h
81 
82 #include "vtkFiltersCoreModule.h" // For export macro
83 #include "vtkPolyDataAlgorithm.h"
84 
85 class VTKFILTERSCORE_EXPORT vtkTensorGlyph : public vtkPolyDataAlgorithm
86 {
87 public:
89  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
90 
96  static vtkTensorGlyph *New();
97 
99 
105  void SetSourceData(vtkPolyData *source);
106  vtkPolyData *GetSource();
108 
110 
115  void SetSourceConnection(int id, vtkAlgorithmOutput* algOutput);
117  {
118  this->SetSourceConnection(0, algOutput);
119  }
121 
123 
126  vtkSetMacro(Scaling,int);
127  vtkGetMacro(Scaling,int);
128  vtkBooleanMacro(Scaling,int);
130 
132 
136  vtkSetMacro(ScaleFactor,double);
137  vtkGetMacro(ScaleFactor,double);
139 
141 
144  vtkSetMacro(ThreeGlyphs,int);
145  vtkGetMacro(ThreeGlyphs,int);
146  vtkBooleanMacro(ThreeGlyphs,int);
148 
150 
153  vtkSetMacro(Symmetric,int);
154  vtkGetMacro(Symmetric,int);
155  vtkBooleanMacro(Symmetric,int);
157 
159 
163  vtkSetMacro(Length,double);
164  vtkGetMacro(Length,double);
166 
168 
171  vtkSetMacro(ExtractEigenvalues,int);
172  vtkBooleanMacro(ExtractEigenvalues,int);
173  vtkGetMacro(ExtractEigenvalues,int);
175 
177 
182  vtkSetMacro(ColorGlyphs,int);
183  vtkGetMacro(ColorGlyphs,int);
184  vtkBooleanMacro(ColorGlyphs,int);
186 
187  enum
188  {
190  COLOR_BY_EIGENVALUES
191  };
192 
194 
204  vtkSetClampMacro(ColorMode, int, COLOR_BY_SCALARS, COLOR_BY_EIGENVALUES);
205  vtkGetMacro(ColorMode, int);
207  {this->SetColorMode(COLOR_BY_SCALARS);};
209  {this->SetColorMode(COLOR_BY_EIGENVALUES);};
211 
213 
218  vtkSetMacro(ClampScaling,int);
219  vtkGetMacro(ClampScaling,int);
220  vtkBooleanMacro(ClampScaling,int);
222 
224 
230  vtkSetMacro(MaxScaleFactor,double);
231  vtkGetMacro(MaxScaleFactor,double);
233 
234 protected:
235  vtkTensorGlyph();
236  ~vtkTensorGlyph() VTK_OVERRIDE;
237 
240  int FillInputPortInformation(int port, vtkInformation *info) VTK_OVERRIDE;
241 
242  int Scaling; // Determine whether scaling of geometry is performed
243  double ScaleFactor; // Scale factor to use to scale geometry
244  int ExtractEigenvalues; // Boolean controls eigenfunction extraction
245  int ColorGlyphs; // Boolean controls coloring with input scalar data
246  int ColorMode; // The coloring mode to use for the glyphs.
247  int ClampScaling; // Boolean controls whether scaling is clamped.
248  double MaxScaleFactor; // Maximum scale factor (ScaleFactor*eigenvalue)
249  int ThreeGlyphs; // Boolean controls drawing 1 or 3 glyphs
250  int Symmetric; // Boolean controls drawing a "mirror" of each glyph
251  double Length; // Distance, in x, from the origin to the end of the glyph
252 private:
253  vtkTensorGlyph(const vtkTensorGlyph&) VTK_DELETE_FUNCTION;
254  void operator=(const vtkTensorGlyph&) VTK_DELETE_FUNCTION;
255 };
256 
257 #endif
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:79
Proxy object to connect input/output ports.
void SetColorModeToScalars()
Set the color mode to be used for the glyphs.
static vtkPolyDataAlgorithm * New()
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
void SetSourceConnection(vtkAlgorithmOutput *algOutput)
Specify a source object at a specified table location.
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
boost::graph_traits< vtkGraph *>::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
void SetColorModeToEigenvalues()
Set the color mode to be used for the glyphs.
scale and orient glyph(s) according to tensor eigenvalues and eigenvectors
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
Store zero or more vtkInformation instances.
vtkBooleanMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.