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 =========================================================================*/
27 #ifndef __vtkReflectionFilter_h
28 #define __vtkReflectionFilter_h
29 
30 #include "vtkDataObjectAlgorithm.h"
32 class vtkDataSet;
33 
35 {
36 public:
37  static vtkReflectionFilter *New();
38 
40  void PrintSelf(ostream &os, vtkIndent indent);
41 
42 //BTX
44  {
45  USE_X_MIN = 0,
46  USE_Y_MIN = 1,
47  USE_Z_MIN = 2,
48  USE_X_MAX = 3,
49  USE_Y_MAX = 4,
50  USE_Z_MAX = 5,
51  USE_X = 6,
52  USE_Y = 7,
53  USE_Z = 8
54  };
55 //ETX
56 
58 
59  vtkSetClampMacro(Plane, int, 0, 8);
60  vtkGetMacro(Plane, int);
61  void SetPlaneToX() { this->SetPlane(USE_X); };
62  void SetPlaneToY() { this->SetPlane(USE_Y); };
63  void SetPlaneToZ() { this->SetPlane(USE_Z); };
64  void SetPlaneToXMin() { this->SetPlane(USE_X_MIN); };
65  void SetPlaneToYMin() { this->SetPlane(USE_Y_MIN); };
66  void SetPlaneToZMin() { this->SetPlane(USE_Z_MIN); };
67  void SetPlaneToXMax() { this->SetPlane(USE_X_MAX); };
68  void SetPlaneToYMax() { this->SetPlane(USE_Y_MAX); };
69  void SetPlaneToZMax() { this->SetPlane(USE_Z_MAX); };
71 
73 
75  vtkSetMacro(Center, double);
76  vtkGetMacro(Center, double);
78 
80 
82  vtkSetMacro(CopyInput, int);
83  vtkGetMacro(CopyInput, int);
84  vtkBooleanMacro(CopyInput, int);
86 
87 protected:
90 
92 
94  virtual int RequestDataObject(vtkInformation*,
98 
100 
101  virtual int RequestDataInternal(vtkDataSet* input, vtkUnstructuredGrid* output,
102  double bounds[6]);
104 
106  virtual int ComputeBounds(vtkDataObject* input, double bounds[6]);
107 
110 
111  int Plane;
112  double Center;
114 
115  void FlipVector(double tuple[3], int mirrorDir[3]);
116 
117 private:
118  vtkReflectionFilter(const vtkReflectionFilter&); // Not implemented
119  void operator=(const vtkReflectionFilter&); // Not implemented
120 };
121 
122 #endif
123 
124