00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00032 #ifndef __vtkImageMandelbrotSource_h
00033 #define __vtkImageMandelbrotSource_h
00034
00035 #include "vtkImageAlgorithm.h"
00036
00037 class VTK_IMAGING_EXPORT vtkImageMandelbrotSource : public vtkImageAlgorithm
00038 {
00039 public:
00040 static vtkImageMandelbrotSource *New();
00041 vtkTypeRevisionMacro(vtkImageMandelbrotSource,vtkImageAlgorithm);
00042 void PrintSelf(ostream& os, vtkIndent indent);
00043
00045
00046 void SetWholeExtent(int extent[6]);
00047 void SetWholeExtent(int minX, int maxX, int minY, int maxY,
00048 int minZ, int maxZ);
00049 vtkGetVector6Macro(WholeExtent,int);
00051
00053
00055 vtkSetMacro(ConstantSize, int);
00056 vtkGetMacro(ConstantSize, int);
00057 vtkBooleanMacro(ConstantSize, int);
00059
00061
00064 void SetProjectionAxes(int x, int y, int z);
00065 void SetProjectionAxes(int a[3]) {this->SetProjectionAxes(a[0],a[1],a[2]);}
00066 vtkGetVector3Macro(ProjectionAxes, int);
00068
00070
00072 vtkSetVector4Macro(OriginCX, double);
00073
00074 vtkGetVector4Macro(OriginCX, double);
00076
00078
00080 vtkSetVector4Macro(SampleCX, double);
00081
00082 vtkGetVector4Macro(SampleCX, double);
00084
00086
00089 void SetSizeCX(double cReal, double cImag, double xReal, double xImag);
00090 double *GetSizeCX();
00091 void GetSizeCX(double s[4]);
00093
00095
00096 vtkSetClampMacro(MaximumNumberOfIterations, unsigned short, 1, 5000);
00097 vtkGetMacro(MaximumNumberOfIterations, unsigned short);
00099
00101
00103 void Zoom(double factor);
00104 void Pan(double x, double y, double z);
00106
00109 void CopyOriginAndSample(vtkImageMandelbrotSource *source);
00110
00112
00113 vtkSetClampMacro(SubsampleRate, int, 1, VTK_LARGE_INTEGER);
00114 vtkGetMacro(SubsampleRate, int);
00116
00117 protected:
00118 vtkImageMandelbrotSource();
00119 ~vtkImageMandelbrotSource();
00120
00121 int ProjectionAxes[3];
00122
00123
00124 int WholeExtent[6];
00125
00126
00127 double OriginCX[4];
00128
00129 double SampleCX[4];
00130 unsigned short MaximumNumberOfIterations;
00131
00132
00133
00134 double SizeCX[4];
00135
00136
00137 int ConstantSize;
00138
00139 int SubsampleRate;
00140
00141
00142 virtual int RequestData(vtkInformation *request,
00143 vtkInformationVector** inputVector,
00144 vtkInformationVector* outputVector);
00145
00146 virtual int RequestInformation (vtkInformation *,
00147 vtkInformationVector**,
00148 vtkInformationVector *);
00149 double EvaluateSet(double p[4]);
00150 private:
00151 vtkImageMandelbrotSource(const vtkImageMandelbrotSource&);
00152 void operator=(const vtkImageMandelbrotSource&);
00153 };
00154
00155
00156 #endif
00157
00158