VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkKochanekSpline.h 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 =========================================================================*/ 00050 #ifndef vtkKochanekSpline_h 00051 #define vtkKochanekSpline_h 00052 00053 #include "vtkCommonComputationalGeometryModule.h" // For export macro 00054 #include "vtkSpline.h" 00055 00056 class VTKCOMMONCOMPUTATIONALGEOMETRY_EXPORT vtkKochanekSpline : public vtkSpline 00057 { 00058 public: 00059 vtkTypeMacro(vtkKochanekSpline,vtkSpline); 00060 void PrintSelf(ostream& os, vtkIndent indent); 00061 00064 static vtkKochanekSpline *New(); 00065 00067 void Compute (); 00068 00070 double Evaluate (double t); 00071 00073 00074 vtkSetMacro(DefaultBias,double); 00075 vtkGetMacro(DefaultBias,double); 00077 00079 00080 vtkSetMacro(DefaultTension,double); 00081 vtkGetMacro(DefaultTension,double); 00083 00085 00086 vtkSetMacro(DefaultContinuity,double); 00087 vtkGetMacro(DefaultContinuity,double); 00089 00091 virtual void DeepCopy(vtkSpline *s); 00092 00093 protected: 00094 vtkKochanekSpline(); 00095 ~vtkKochanekSpline() {} 00096 00097 void Fit1D (int n, double *x, double *y, double tension, double bias, 00098 double continuity, double coefficients[][4], int leftConstraint, 00099 double leftValue, int rightConstraint, double rightValue); 00100 00101 double DefaultBias; 00102 double DefaultTension; 00103 double DefaultContinuity; 00104 00105 private: 00106 vtkKochanekSpline(const vtkKochanekSpline&); // Not implemented. 00107 void operator=(const vtkKochanekSpline&); // Not implemented. 00108 }; 00109 00110 #endif 00111