VTK
vtkStructuredGridClip.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkStructuredGridClip.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 =========================================================================*/
28 #ifndef vtkStructuredGridClip_h
29 #define vtkStructuredGridClip_h
30 
31 // I did not make this a subclass of in place filter because
32 // the references on the data do not matter. I make no modifications
33 // to the data.
34 #include "vtkFiltersGeneralModule.h" // For export macro
36 
37 class VTKFILTERSGENERAL_EXPORT vtkStructuredGridClip : public vtkStructuredGridAlgorithm
38 {
39 public:
40  static vtkStructuredGridClip *New();
42  void PrintSelf(ostream& os, vtkIndent indent) override;
43 
45 
48  void SetOutputWholeExtent(int extent[6], vtkInformation *outInfo=nullptr);
49  void SetOutputWholeExtent(int minX, int maxX, int minY, int maxY,
50  int minZ, int maxZ);
51  void GetOutputWholeExtent(int extent[6]);
52  int *GetOutputWholeExtent() {return this->OutputWholeExtent;}
54 
55  void ResetOutputWholeExtent();
56 
58 
63  vtkSetMacro(ClipData, vtkTypeBool);
64  vtkGetMacro(ClipData, vtkTypeBool);
65  vtkBooleanMacro(ClipData, vtkTypeBool);
67 
68 protected:
70  ~vtkStructuredGridClip() override {}
71 
72  // Time when OutputImageExtent was computed.
74  int Initialized; // Set the OutputImageExtent for the first time.
75  int OutputWholeExtent[6];
76 
78 
81  vtkInformationVector *) override;
82 
83  void CopyData(vtkStructuredGrid *inData, vtkStructuredGrid *outData, int *ext);
84 
87  vtkInformationVector *) override;
88 
89 private:
91  void operator=(const vtkStructuredGridClip&) = delete;
92 };
93 
94 
95 
96 #endif
97 
98 
99 
vtkStructuredGridAlgorithm.h
vtkStructuredGridAlgorithm::RequestInformation
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkStructuredGridAlgorithm
Superclass for algorithms that produce only structured grid as output.
Definition: vtkStructuredGridAlgorithm.h:41
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:41
vtkStructuredGridAlgorithm::New
static vtkStructuredGridAlgorithm * New()
vtkTimeStamp
record modification and/or execution time
Definition: vtkTimeStamp.h:35
vtkStructuredGrid
topologically regular array of data
Definition: vtkStructuredGrid.h:63
vtkStructuredGridAlgorithm::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkStructuredGridAlgorithm::RequestData
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
vtkStructuredGridClip::ClipData
vtkTypeBool ClipData
Definition: vtkStructuredGridClip.h:77
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkStructuredGridClip::CTime
vtkTimeStamp CTime
Definition: vtkStructuredGridClip.h:73
vtkStructuredGridClip::Initialized
int Initialized
Definition: vtkStructuredGridClip.h:74
vtkStructuredGridClip
Reduces the image extent of the input.
Definition: vtkStructuredGridClip.h:37
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:70
vtkStructuredGridClip::~vtkStructuredGridClip
~vtkStructuredGridClip() override
Definition: vtkStructuredGridClip.h:70
vtkX3D::extent
Definition: vtkX3D.h:345
vtkStructuredGridClip::GetOutputWholeExtent
int * GetOutputWholeExtent()
Definition: vtkStructuredGridClip.h:52
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69