00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00028
#ifndef __vtkImageStencil_h
00029
#define __vtkImageStencil_h
00030
00031
#include "vtkImageToImageFilter.h"
00032
00033
class vtkImageStencilData;
00034
00035 class VTK_IMAGING_EXPORT vtkImageStencil :
public vtkImageToImageFilter
00036 {
00037
public:
00038
static vtkImageStencil *
New();
00039 vtkTypeRevisionMacro(vtkImageStencil,
vtkImageToImageFilter);
00040
void PrintSelf(ostream& os,
vtkIndent indent);
00041
00043
00045
virtual void SetStencil(
vtkImageStencilData *stencil);
00046
vtkImageStencilData *GetStencil();
00048
00050
00051 vtkSetMacro(ReverseStencil,
int);
00052 vtkBooleanMacro(ReverseStencil,
int);
00053 vtkGetMacro(ReverseStencil,
int);
00055
00057
00061
virtual void SetBackgroundInput(
vtkImageData *input);
00062
vtkImageData *GetBackgroundInput();
00064
00066
00067 void SetBackgroundValue(
double val) {
00068 this->SetBackgroundColor(val,val,val,val); };
00069 double GetBackgroundValue() {
00070
return this->BackgroundColor[0]; };
00072
00074
00076 vtkSetVector4Macro(BackgroundColor,
double);
00077 vtkGetVector4Macro(BackgroundColor,
double);
00079
00080
protected:
00081 vtkImageStencil();
00082 ~vtkImageStencil();
00083
00084 void ExecuteInformation() {
00085 this->
vtkImageToImageFilter::ExecuteInformation(); };
00086
void ExecuteInformation(
vtkImageData *inData,
vtkImageData *outData);
00087
00088
void ThreadedExecute(
vtkImageData *inData,
vtkImageData *outData,
00089
int extent[6],
int id);
00090
00091 int ReverseStencil;
00092 double BackgroundColor[4];
00093
private:
00094 vtkImageStencil(
const vtkImageStencil&);
00095
void operator=(
const vtkImageStencil&);
00096 };
00097
00098
#endif
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111