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

Patented/vtkSweptSurface.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkSweptSurface.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 
00015      THIS CLASS IS PATENTED UNDER UNITED STATES PATENT NUMBER 5,542,036
00016      "Implicit Modeling of Swept Volumes and Swept Surfaces"
00017      Application of this software for commercial purposes requires 
00018      a license grant from GE. Contact:
00019 
00020          Carl B. Horton
00021          Sr. Counsel, Intellectual Property
00022          3000 N. Grandview Blvd., W-710
00023          Waukesha, WI  53188
00024          Phone:  (262) 513-4022
00025          E-Mail: Carl.Horton@med.ge.com
00026 
00027      for more information.
00028 
00029 =========================================================================*/
00057 #ifndef __vtkSweptSurface_h
00058 #define __vtkSweptSurface_h
00059 
00060 #include "vtkImageToImageFilter.h"
00061 
00062 class vtkDataArray;
00063 class vtkMatrix4x4;
00064 class vtkTransform;
00065 class vtkTransformCollection;
00066 
00067 class VTK_PATENTED_EXPORT vtkSweptSurface : public vtkImageToImageFilter
00068 {
00069 public:
00070   static vtkSweptSurface *New();
00071   vtkTypeRevisionMacro(vtkSweptSurface,vtkImageToImageFilter);
00072   void PrintSelf(ostream& os, vtkIndent indent);
00073 
00075 
00077   vtkSetVector3Macro(SampleDimensions,int);
00078   vtkGetVectorMacro(SampleDimensions,int,3);
00080 
00082 
00084   virtual void SetTransforms(vtkTransformCollection*);
00085   vtkGetObjectMacro(Transforms, vtkTransformCollection);
00087 
00089 
00092   vtkSetMacro(FillValue,double);
00093   vtkGetMacro(FillValue,double);
00095 
00097 
00107   vtkSetMacro(NumberOfInterpolationSteps,int);
00108   vtkGetMacro(NumberOfInterpolationSteps,int);
00110 
00112 
00115   vtkSetMacro(MaximumNumberOfInterpolationSteps,int);
00116   vtkGetMacro(MaximumNumberOfInterpolationSteps,int);
00118 
00120 
00125   vtkSetMacro(Capping,int);
00126   vtkGetMacro(Capping,int);
00127   vtkBooleanMacro(Capping,int);
00129   
00131 
00136   vtkSetVectorMacro(ModelBounds,double,6);
00137   vtkGetVectorMacro(ModelBounds,double,6);
00138   void SetModelBounds(double xmin, double xmax, double ymin, double ymax, 
00139                       double zmin, double zmax);
00141 
00143 
00147   vtkSetMacro(AdjustBounds,int);
00148   vtkGetMacro(AdjustBounds,int);
00149   vtkBooleanMacro(AdjustBounds,int);
00151   
00153 
00156   vtkSetClampMacro(AdjustDistance,double,-1.0,1.0);
00157   vtkGetMacro(AdjustDistance,double);
00159 
00160   //overload to check transformation matrices
00161   unsigned long int GetMTime();
00162 
00163 protected:
00164   vtkSweptSurface();
00165   ~vtkSweptSurface();
00166 
00167   virtual void ExecuteData(vtkDataObject *);
00168   virtual void ExecuteInformation(vtkImageData *inData, vtkImageData *outData);
00169   void ExecuteInformation(){
00170     this->vtkImageToImageFilter::ExecuteInformation();};
00171   void ComputeInputUpdateExtent(int inExt[6], int outExt[6]);
00172 
00173   void ComputeBounds(double origin[3], double ar[3], double bbox[24]);
00174   int ComputeNumberOfSteps(vtkTransform *t1, vtkTransform *t2, double bbox[24]);
00175   void SampleInput(vtkMatrix4x4 *m, int inDim[3], double inOrigin[3],
00176                    double inAr[3], vtkDataArray *in, vtkDataArray *out);
00177   void ComputeFootprint (vtkMatrix4x4 *m, int inDim[3], double inOrigin[3],
00178                          double inSpacing[3], int Indicies[6]);
00179   void Cap(vtkDataArray *s);
00180   void GetRelativePosition(vtkTransform &t, double *origin, double *position);
00181   vtkMatrix4x4* GetActorMatrixPointer(vtkTransform &t,
00182                                       double origin[3],
00183                                      double position[3], double orientation[3]);
00184   virtual void InterpolateStates(double *pos1, double *pos2, double *euler1, 
00185                                  double *euler2, double t, double *posOut,
00186                                  double *eulerOut);
00187 
00188   int SampleDimensions[3];
00189   double FillValue;
00190   double ModelBounds[6];
00191   int NumberOfInterpolationSteps;
00192   int MaximumNumberOfInterpolationSteps;
00193   int Capping;
00194   int AdjustBounds;
00195   double AdjustDistance;
00196 
00197   vtkTransformCollection *Transforms;
00198 
00199 private:
00200   //used to perform computations
00201   vtkTransform *T;
00202 private:
00203   vtkSweptSurface(const vtkSweptSurface&);  // Not implemented.
00204   void operator=(const vtkSweptSurface&);  // Not implemented.
00205 };
00206 
00207 #endif