• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

dox/Imaging/vtkImageStencil.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkImageStencil.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00025 #ifndef __vtkImageStencil_h
00026 #define __vtkImageStencil_h
00027 
00028 #include "vtkThreadedImageAlgorithm.h"
00029 
00030 class vtkImageStencilData;
00031 
00032 class VTK_IMAGING_EXPORT vtkImageStencil : public vtkThreadedImageAlgorithm
00033 {
00034 public:
00035   static vtkImageStencil *New();
00036   vtkTypeRevisionMacro(vtkImageStencil, vtkThreadedImageAlgorithm);
00037   void PrintSelf(ostream& os, vtkIndent indent);
00038 
00040 
00042   virtual void SetStencil(vtkImageStencilData *stencil);
00043   vtkImageStencilData *GetStencil();
00045 
00047 
00048   vtkSetMacro(ReverseStencil, int);
00049   vtkBooleanMacro(ReverseStencil, int);
00050   vtkGetMacro(ReverseStencil, int);
00052 
00054 
00058   virtual void SetBackgroundInput(vtkImageData *input);
00059   vtkImageData *GetBackgroundInput();
00061 
00063 
00064   void SetBackgroundValue(double val) {
00065     this->SetBackgroundColor(val,val,val,val); };
00066   double GetBackgroundValue() {
00067     return this->BackgroundColor[0]; };
00069 
00071 
00073   vtkSetVector4Macro(BackgroundColor, double);
00074   vtkGetVector4Macro(BackgroundColor, double);
00076 
00077 protected:
00078   vtkImageStencil();
00079   ~vtkImageStencil();
00080   
00081   virtual int RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00082 
00083   void ThreadedRequestData(vtkInformation *request,
00084                            vtkInformationVector **inputVector,
00085                            vtkInformationVector *outputVector,
00086                            vtkImageData ***inData, vtkImageData **outData,
00087                            int extent[6], int id);
00088   
00089   int ReverseStencil;
00090   double BackgroundColor[4];
00091 
00092   virtual int FillInputPortInformation(int, vtkInformation*);
00093 
00094 private:
00095   vtkImageStencil(const vtkImageStencil&);  // Not implemented.
00096   void operator=(const vtkImageStencil&);  // Not implemented.
00097 };
00098 
00099 #endif

Generated by  doxygen 1.7.1