Beast - Music Synthesizer and Composer  0.11.1+10.g2da35
gxkspline.hh
Go to the documentation of this file.
1  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
2 #ifndef __GXK_SPLINE_H__
3 #define __GXK_SPLINE_H__
4 
5 #include <gxk/gxkglobals.hh>
6 
7 typedef struct _GxkSpline GxkSpline;
8 typedef struct {
9  double x, y;
11 typedef struct {
12  double x, y, yd2;
13  double ymin, ymax;
14  double ex1, ex2;
16 struct _GxkSpline {
17  guint n_segs; /* == n_points */
18  GxkSplineSegment segs[0]; /* last segment always has NAN extrema */
19 };
20 GxkSpline* gxk_spline_new_natural (guint n_points,
21  const GxkSplinePoint *points);
22 GxkSpline* gxk_spline_new (guint n_points,
23  const GxkSplinePoint *points,
24  double dy_start,
25  double dy_end);
26 double gxk_spline_eval (const GxkSpline *spline,
27  double x,
28  double *yd1);
29 double gxk_spline_y (const GxkSpline *spline,
30  double x);
31 double gxk_spline_findx (const GxkSpline *spline,
32  double y);
33 void gxk_spline_dump (GxkSpline *spline);
34 GxkSpline* gxk_spline_copy (GxkSpline *spline);
35 void gxk_spline_free (GxkSpline *spline);
36 
37 
38 
39 #endif /* __GXK_SPLINE_H__ */
double gxk_spline_eval(const GxkSpline *spline, double x, double *yd1)
Definition: gxkspline.cc:186
GxkSpline * gxk_spline_copy(GxkSpline *spline)
Definition: gxkspline.cc:61
Definition: gxkspline.hh:11
GxkSpline * gxk_spline_new(guint n_points, const GxkSplinePoint *points, double dy_start, double dy_end)
Definition: gxkspline.cc:85
double gxk_spline_findx(const GxkSpline *spline, double y)
Definition: gxkspline.cc:243
Definition: gxkspline.hh:8
double gxk_spline_y(const GxkSpline *spline, double x)
Definition: gxkspline.cc:215
GxkSpline * gxk_spline_new_natural(guint n_points, const GxkSplinePoint *points)
Definition: gxkspline.cc:49
void gxk_spline_dump(GxkSpline *spline)
Definition: gxkspline.cc:393
void gxk_spline_free(GxkSpline *spline)
Definition: gxkspline.cc:381
Definition: gxkspline.hh:16