VTK
vtkReflectionFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkReflectionFilter.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 =========================================================================*/
25 #ifndef vtkReflectionFilter_h
26 #define vtkReflectionFilter_h
27 
28 #include "vtkFiltersGeneralModule.h" // For export macro
29 #include "vtkDataObjectAlgorithm.h"
31 class vtkDataSet;
32 
33 class VTKFILTERSGENERAL_EXPORT vtkReflectionFilter : public vtkDataObjectAlgorithm
34 {
35 public:
36  static vtkReflectionFilter *New();
37 
39  void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE;
40 
42  {
43  USE_X_MIN = 0,
44  USE_Y_MIN = 1,
45  USE_Z_MIN = 2,
46  USE_X_MAX = 3,
47  USE_Y_MAX = 4,
48  USE_Z_MAX = 5,
49  USE_X = 6,
50  USE_Y = 7,
51  USE_Z = 8
52  };
53 
55 
58  vtkSetClampMacro(Plane, int, 0, 8);
59  vtkGetMacro(Plane, int);
60  void SetPlaneToX() { this->SetPlane(USE_X); };
61  void SetPlaneToY() { this->SetPlane(USE_Y); };
62  void SetPlaneToZ() { this->SetPlane(USE_Z); };
63  void SetPlaneToXMin() { this->SetPlane(USE_X_MIN); };
64  void SetPlaneToYMin() { this->SetPlane(USE_Y_MIN); };
65  void SetPlaneToZMin() { this->SetPlane(USE_Z_MIN); };
66  void SetPlaneToXMax() { this->SetPlane(USE_X_MAX); };
67  void SetPlaneToYMax() { this->SetPlane(USE_Y_MAX); };
68  void SetPlaneToZMax() { this->SetPlane(USE_Z_MAX); };
70 
72 
76  vtkSetMacro(Center, double);
77  vtkGetMacro(Center, double);
79 
81 
85  vtkSetMacro(CopyInput, int);
86  vtkGetMacro(CopyInput, int);
87  vtkBooleanMacro(CopyInput, int);
89 
90 protected:
92  ~vtkReflectionFilter() VTK_OVERRIDE;
93 
99  int RequestDataObject(vtkInformation*,
101  vtkInformationVector*) VTK_OVERRIDE;
102 
106  virtual int RequestDataInternal(vtkDataSet* input, vtkUnstructuredGrid* output,
107  double bounds[6]);
108 
112  virtual int ComputeBounds(vtkDataObject* input, double bounds[6]);
113 
117  virtual vtkIdType ReflectNon3DCell(vtkDataSet* input, vtkUnstructuredGrid* output,
118  vtkIdType cellId, vtkIdType numInputPoints);
119 
120  int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) VTK_OVERRIDE;
121  int FillInputPortInformation(int port, vtkInformation *info) VTK_OVERRIDE;
122 
123  int Plane;
124  double Center;
125  int CopyInput;
126 
127  void FlipVector(double tuple[3], int mirrorDir[3]);
128 
129 private:
130  vtkReflectionFilter(const vtkReflectionFilter&) VTK_DELETE_FUNCTION;
131  void operator=(const vtkReflectionFilter&) VTK_DELETE_FUNCTION;
132 };
133 
134 #endif
135 
136 
void SetPlaneToYMin()
Set the normal of the plane to use as mirror.
reflects a data set across a plane
void SetPlaneToXMax()
Set the normal of the plane to use as mirror.
Store vtkAlgorithm input/output information.
void SetPlaneToY()
Set the normal of the plane to use as mirror.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
static vtkDataObjectAlgorithm * New()
void SetPlaneToZMax()
Set the normal of the plane to use as mirror.
int vtkIdType
Definition: vtkType.h:345
a simple class to control print indentation
Definition: vtkIndent.h:33
void SetPlaneToXMin()
Set the normal of the plane to use as mirror.
dataset represents arbitrary combinations of all possible cell types
void SetPlaneToZMin()
Set the normal of the plane to use as mirror.
void SetPlaneToYMax()
Set the normal of the plane to use as mirror.
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
void SetPlaneToX()
Set the normal of the plane to use as mirror.
Superclass for algorithms that produce only data object as output.
void SetPlaneToZ()
Set the normal of the plane to use as mirror.
Store zero or more vtkInformation instances.
vtkBooleanMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
general representation of visualization data
Definition: vtkDataObject.h:58
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.