VTK  9.4.20241221
vtkCardinalSpline.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
58#ifndef vtkCardinalSpline_h
59#define vtkCardinalSpline_h
60
61#include "vtkCommonComputationalGeometryModule.h" // For export macro
62#include "vtkSpline.h"
63
64VTK_ABI_NAMESPACE_BEGIN
65class VTKCOMMONCOMPUTATIONALGEOMETRY_EXPORT vtkCardinalSpline : public vtkSpline
66{
67public:
69
71 void PrintSelf(ostream& os, vtkIndent indent) override;
72
76 void Compute() override;
77
81 double Evaluate(double t) override;
82
86 void DeepCopy(vtkSpline* s) override;
87
88protected:
90 ~vtkCardinalSpline() override = default;
91
92 void Fit1D(int size, double* x, double* y, double* w, double coefficients[][4],
93 int leftConstraint, double leftValue, int rightConstraint, double rightValue);
94
95 void FitClosed1D(int size, double* x, double* y, double* w, double coefficients[][4]);
96
97private:
98 vtkCardinalSpline(const vtkCardinalSpline&) = delete;
99 void operator=(const vtkCardinalSpline&) = delete;
100};
101
102VTK_ABI_NAMESPACE_END
103#endif
computes an interpolating spline using a a Cardinal basis.
void Fit1D(int size, double *x, double *y, double *w, double coefficients[][4], int leftConstraint, double leftValue, int rightConstraint, double rightValue)
static vtkCardinalSpline * New()
~vtkCardinalSpline() override=default
void Compute() override
Compute Cardinal Splines for each dependent variable.
double Evaluate(double t) override
Evaluate a 1D cardinal spline.
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.
void FitClosed1D(int size, double *x, double *y, double *w, double coefficients[][4])
a simple class to control print indentation
Definition vtkIndent.h:108
spline abstract class for interpolating splines
Definition vtkSpline.h:52