VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
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 =========================================================================*/
81 #ifndef __vtkTensorGlyph_h
82 #define __vtkTensorGlyph_h
83 
84 #include "vtkFiltersCoreModule.h" // For export macro
85 #include "vtkPolyDataAlgorithm.h"
86 
88 {
89 public:
91  void PrintSelf(ostream& os, vtkIndent indent);
92 
96  static vtkTensorGlyph *New();
97 
99 
101  void SetSourceData(vtkPolyData *source);
102  vtkPolyData *GetSource();
104 
106 
109  void SetSourceConnection(int id, vtkAlgorithmOutput* algOutput);
111  {
112  this->SetSourceConnection(0, algOutput);
113  }
115 
117 
118  vtkSetMacro(Scaling,int);
119  vtkGetMacro(Scaling,int);
120  vtkBooleanMacro(Scaling,int);
122 
124 
126  vtkSetMacro(ScaleFactor,double);
127  vtkGetMacro(ScaleFactor,double);
129 
131 
132  vtkSetMacro(ThreeGlyphs,int);
133  vtkGetMacro(ThreeGlyphs,int);
134  vtkBooleanMacro(ThreeGlyphs,int);
136 
138 
139  vtkSetMacro(Symmetric,int);
140  vtkGetMacro(Symmetric,int);
141  vtkBooleanMacro(Symmetric,int);
143 
145 
147  vtkSetMacro(Length,double);
148  vtkGetMacro(Length,double);
150 
152 
153  vtkSetMacro(ExtractEigenvalues,int);
154  vtkBooleanMacro(ExtractEigenvalues,int);
155  vtkGetMacro(ExtractEigenvalues,int);
157 
159 
162  vtkSetMacro(ColorGlyphs,int);
163  vtkGetMacro(ColorGlyphs,int);
164  vtkBooleanMacro(ColorGlyphs,int);
166 
167 //BTX
168  enum
169  {
171  COLOR_BY_EIGENVALUES
172  };
173 //ETX
174 
176 
183  vtkSetClampMacro(ColorMode, int, COLOR_BY_SCALARS, COLOR_BY_EIGENVALUES);
184  vtkGetMacro(ColorMode, int);
186  {this->SetColorMode(COLOR_BY_SCALARS);};
188  {this->SetColorMode(COLOR_BY_EIGENVALUES);};
190 
192 
195  vtkSetMacro(ClampScaling,int);
196  vtkGetMacro(ClampScaling,int);
197  vtkBooleanMacro(ClampScaling,int);
199 
201 
205  vtkSetMacro(MaxScaleFactor,double);
206  vtkGetMacro(MaxScaleFactor,double);
208 
209 protected:
210  vtkTensorGlyph();
211  ~vtkTensorGlyph();
212 
216 
217  int Scaling; // Determine whether scaling of geometry is performed
218  double ScaleFactor; // Scale factor to use to scale geometry
219  int ExtractEigenvalues; // Boolean controls eigenfunction extraction
220  int ColorGlyphs; // Boolean controls coloring with input scalar data
221  int ColorMode; // The coloring mode to use for the glyphs.
222  int ClampScaling; // Boolean controls whether scaling is clamped.
223  double MaxScaleFactor; // Maximum scale factor (ScaleFactor*eigenvalue)
224  int ThreeGlyphs; // Boolean controls drawing 1 or 3 glyphs
225  int Symmetric; // Boolean controls drawing a "mirror" of each glyph
226  double Length; // Distance, in x, from the origin to the end of the glyph
227 private:
228  vtkTensorGlyph(const vtkTensorGlyph&); // Not implemented.
229  void operator=(const vtkTensorGlyph&); // Not implemented.
230 };
231 
232 #endif
virtual int FillInputPortInformation(int port, vtkInformation *info)
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
#define VTKFILTERSCORE_EXPORT
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:83
Proxy object to connect input/output ports.
void SetColorModeToScalars()
static vtkPolyDataAlgorithm * New()
void PrintSelf(ostream &os, vtkIndent indent)
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
void SetSourceConnection(vtkAlgorithmOutput *algOutput)
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:38
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
void SetColorModeToEigenvalues()
scale and orient glyph(s) according to tensor eigenvalues and eigenvectors
Store zero or more vtkInformation instances.