VTK  9.4.20250114
vtkKochanekSpline.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
85#ifndef vtkKochanekSpline_h
86#define vtkKochanekSpline_h
87
88#include "vtkCommonComputationalGeometryModule.h" // For export macro
89#include "vtkSpline.h"
90
91VTK_ABI_NAMESPACE_BEGIN
92class VTKCOMMONCOMPUTATIONALGEOMETRY_EXPORT vtkKochanekSpline : public vtkSpline
93{
94public:
96 void PrintSelf(ostream& os, vtkIndent indent) override;
97
103
107 void Compute() override;
108
112 double Evaluate(double t) override;
113
115
118 vtkSetMacro(DefaultBias, double);
119 vtkGetMacro(DefaultBias, double);
121
123
126 vtkSetMacro(DefaultTension, double);
127 vtkGetMacro(DefaultTension, double);
129
131
134 vtkSetMacro(DefaultContinuity, double);
135 vtkGetMacro(DefaultContinuity, double);
137
141 void DeepCopy(vtkSpline* s) override;
142
143protected:
145 ~vtkKochanekSpline() override = default;
146
147 void Fit1D(int size, double* x, double* y, double tension, double bias, double continuity,
148 double coefficients[][4], int leftConstraint, double leftValue, int rightConstraint,
149 double rightValue);
150
154
155private:
156 vtkKochanekSpline(const vtkKochanekSpline&) = delete;
157 void operator=(const vtkKochanekSpline&) = delete;
158};
159
160VTK_ABI_NAMESPACE_END
161#endif
a simple class to control print indentation
Definition vtkIndent.h:108
computes an interpolating spline using a Kochanek basis.
double Evaluate(double t) override
Evaluate a 1D Kochanek spline.
void Fit1D(int size, double *x, double *y, double tension, double bias, double continuity, double coefficients[][4], int leftConstraint, double leftValue, int rightConstraint, double rightValue)
void Compute() override
Compute Kochanek Spline coefficients.
~vtkKochanekSpline() override=default
void DeepCopy(vtkSpline *s) override
Deep copy of cardinal spline data.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkKochanekSpline * New()
Construct a KochanekSpline with the following defaults: DefaultBias = 0, DefaultTension = 0,...
spline abstract class for interpolating splines
Definition vtkSpline.h:52