Main Page | Directories | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

vtkImageGridSource.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkImageGridSource.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 =========================================================================*/
00036 #ifndef __vtkImageGridSource_h
00037 #define __vtkImageGridSource_h
00038 
00039 #include "vtkImageAlgorithm.h"
00040 
00041 class VTK_IMAGING_EXPORT vtkImageGridSource : public vtkImageAlgorithm
00042 {
00043 public:
00044   static vtkImageGridSource *New();
00045   vtkTypeRevisionMacro(vtkImageGridSource,vtkImageAlgorithm);
00046   void PrintSelf(ostream& os, vtkIndent indent);
00047 
00049 
00051   vtkSetVector3Macro(GridSpacing,int);
00052   vtkGetVector3Macro(GridSpacing,int);
00054   
00056 
00057   vtkSetVector3Macro(GridOrigin,int);
00058   vtkGetVector3Macro(GridOrigin,int);
00060 
00062 
00063   vtkSetMacro(LineValue,double);
00064   vtkGetMacro(LineValue,double);
00066 
00068 
00069   vtkSetMacro(FillValue,double);
00070   vtkGetMacro(FillValue,double);
00072 
00074 
00076   vtkSetMacro(DataScalarType,int);
00077   void SetDataScalarTypeToDouble(){this->SetDataScalarType(VTK_DOUBLE);}
00078   void SetDataScalarTypeToInt(){this->SetDataScalarType(VTK_INT);}
00079   void SetDataScalarTypeToShort(){this->SetDataScalarType(VTK_SHORT);}
00080   void SetDataScalarTypeToUnsignedShort()
00081     {this->SetDataScalarType(VTK_UNSIGNED_SHORT);}
00082   void SetDataScalarTypeToUnsignedChar()
00083     {this->SetDataScalarType(VTK_UNSIGNED_CHAR);}
00084   vtkGetMacro(DataScalarType, int);
00085   const char *GetDataScalarTypeAsString() { 
00086     return vtkImageScalarTypeNameMacro(this->DataScalarType); }
00088 
00090 
00092   vtkSetVector6Macro(DataExtent,int);
00093   vtkGetVector6Macro(DataExtent,int);
00095 
00097 
00098   vtkSetVector3Macro(DataSpacing,double);
00099   vtkGetVector3Macro(DataSpacing,double);
00101   
00103 
00104   vtkSetVector3Macro(DataOrigin,double);
00105   vtkGetVector3Macro(DataOrigin,double);
00107 
00108 protected:
00109   vtkImageGridSource();
00110   ~vtkImageGridSource() {};
00111 
00112   int GridSpacing[3];
00113   int GridOrigin[3];
00114 
00115   double LineValue;
00116   double FillValue;
00117 
00118   int DataScalarType;
00119 
00120   int DataExtent[6];
00121   double DataSpacing[3];
00122   double DataOrigin[3];
00123 
00124   virtual void ExecuteInformation (vtkInformation *, 
00125                                    vtkInformationVector *, 
00126                                    vtkInformationVector *);
00127   virtual void ExecuteData(vtkDataObject *data);
00128 
00129 private:
00130   vtkImageGridSource(const vtkImageGridSource&);  // Not implemented.
00131   void operator=(const vtkImageGridSource&);  // Not implemented.
00132 };
00133 
00134 
00135 #endif