VTK
vtkImageClip.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageClip.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 =========================================================================*/
33 #ifndef __vtkImageClip_h
34 #define __vtkImageClip_h
35 
36 // I did not make this a subclass of in place filter because
37 // the references on the data do not matter. I make no modifications
38 // to the data.
39 #include "vtkImageAlgorithm.h"
40 
42 {
43 public:
44  static vtkImageClip *New();
46  void PrintSelf(ostream& os, vtkIndent indent);
47 
49 
50  void SetOutputWholeExtent(int extent[6], vtkInformation *outInfo=0);
51  void SetOutputWholeExtent(int minX, int maxX, int minY, int maxY,
52  int minZ, int maxZ);
53  void GetOutputWholeExtent(int extent[6]);
54  int *GetOutputWholeExtent() {return this->OutputWholeExtent;}
56 
57  void ResetOutputWholeExtent();
58 
60 
63  vtkSetMacro(ClipData, int);
64  vtkGetMacro(ClipData, int);
65  vtkBooleanMacro(ClipData, int);
67 
69  void SetOutputWholeExtent(int piece, int numPieces);
70 
71 protected:
72  vtkImageClip();
74 
75  // Time when OutputImageExtent was computed.
76  vtkTimeStamp CTime;
77  int Initialized; // Set the OutputImageExtent for the first time.
78  int OutputWholeExtent[6];
79 
80  int ClipData;
81 
82  virtual int RequestInformation (vtkInformation *,
85 
86  void CopyData(vtkImageData *inData, vtkImageData *outData, int *ext);
87 
88  virtual int RequestData(vtkInformation *,
91 
92 private:
93  vtkImageClip(const vtkImageClip&); // Not implemented.
94  void operator=(const vtkImageClip&); // Not implemented.
95 };
96 
97 
98 
99 #endif
100 
101 
102 
Store vtkAlgorithm input/output information.
record modification and/or execution time
Definition: vtkTimeStamp.h:33
int * GetOutputWholeExtent()
Definition: vtkImageClip.h:54
a simple class to control print indentation
Definition: vtkIndent.h:37
Reduces the image extent of the input.
Definition: vtkImageClip.h:41
#define VTK_IMAGING_EXPORT
topologically and geometrically regular array of data
Definition: vtkImageData.h:43
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
void PrintSelf(ostream &os, vtkIndent indent)
static vtkAlgorithm * New()
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)