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

# Imaging/vtkImageMandelbrotSource.h

Go to the documentation of this file.

    00001 /*=========================================================================
    00002
    00003   Program:   Visualization Toolkit
    00004   Module:    $RCSfile: vtkImageMandelbrotSource.h,v $
    00005   Language:  C++
    00006
    00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen
    00008   All rights reserved.
    00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
    00010
    00011      This software is distributed WITHOUT ANY WARRANTY; without even
    00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
    00013      PURPOSE.  See the above copyright notice for more information.
    00014
    00015 =========================================================================*/
    00049 #ifndef __vtkImageMandelbrotSource_h
    00050 #define __vtkImageMandelbrotSource_h
    00051
    00052 #include "vtkImageSource.h"
    00053
    00054 class VTK_IMAGING_EXPORT vtkImageMandelbrotSource : public vtkImageSource
    00055 {
    00056 public:
    00057   static vtkImageMandelbrotSource *New();
    00058   vtkTypeRevisionMacro(vtkImageMandelbrotSource,vtkImageSource);
    00059   void PrintSelf(ostream& os, vtkIndent indent);
    00060
    00062
    00063   void SetWholeExtent(int extent[6]);
    00064   void SetWholeExtent(int minX, int maxX, int minY, int maxY,
    00065                             int minZ, int maxZ);
    00066   vtkGetVector6Macro(WholeExtent,int);
    00068
    00070
    00072   vtkSetMacro(ConstantSize, int);
    00073   vtkGetMacro(ConstantSize, int);
    00074   vtkBooleanMacro(ConstantSize, int);
    00076
    00078
    00081   void SetProjectionAxes(int x, int y, int z);
    00082   void SetProjectionAxes(int a[3]) {this->SetProjectionAxes(a[0],a[1],a[2]);}
    00083   vtkGetVector3Macro(ProjectionAxes, int);
    00085
    00087
    00089   vtkSetVector4Macro(OriginCX, double);
    00090   //void SetOriginCX(double cReal, double cImag, double xReal, double xImag);
    00091   vtkGetVector4Macro(OriginCX, double);
    00093
    00095
    00097   vtkSetVector4Macro(SampleCX, double);
    00098   //void SetOriginCX(double cReal, double cImag, double xReal, double xImag);
    00099   vtkGetVector4Macro(SampleCX, double);
    00101
    00103
    00106   void SetSizeCX(double cReal, double cImag, double xReal, double xImag);
    00107   double *GetSizeCX();
    00108   void GetSizeCX(double s[4]);
    00110
    00112
    00113   vtkSetClampMacro(MaximumNumberOfIterations, unsigned short, 1, 5000);
    00114   vtkGetMacro(MaximumNumberOfIterations, unsigned short);
    00116
    00118
    00120   void Zoom(double factor);
    00121   void Pan(double x, double y, double z);
    00123
    00126   void CopyOriginAndSample(vtkImageMandelbrotSource *source);
    00127
    00128 protected:
    00129   vtkImageMandelbrotSource();
    00130   ~vtkImageMandelbrotSource();
    00131
    00132   int ProjectionAxes[3];
    00133
    00134   // WholeExtent in 3 space (after projection).
    00135   int WholeExtent[6];
    00136
    00137   // Complex constant/initial-value at origin.
    00138   double OriginCX[4];
    00139   // Initial complex value at origin.
    00140   double SampleCX[4];
    00141   unsigned short MaximumNumberOfIterations;
    00142
    00143   // A temporary vector that is computed as needed.
    00144   // It is used to return a vector.
    00145   double SizeCX[4];
    00146
    00147   // A flag for keeping size constant (vs. keeping the spacing).
    00148   int ConstantSize;
    00149
    00150   virtual void ExecuteData(vtkDataObject *outData);
    00151   virtual void ExecuteInformation();
    00152   float EvaluateSet(double p[4]);
    00153 private:
    00154   vtkImageMandelbrotSource(const vtkImageMandelbrotSource&);  // Not implemented.
    00155   void operator=(const vtkImageMandelbrotSource&);  // Not implemented.
    00156 };
    00157
    00158
    00159 #endif
    00160
    00161