1 //----------------------------------------------------------------------------
2 // Anti-Grain Geometry - Version 2.4
3 // Copyright (C) 2002-2005 Maxim Shemanarev (http://www.antigrain.com)
5 // Permission to copy, use, modify, sell and distribute this software
6 // is granted provided this copyright notice appears in all copies.
7 // This software is provided "as is" without express or implied
8 // warranty, and with no claim as to its suitability for any purpose.
10 //----------------------------------------------------------------------------
11 // Contact: mcseem@antigrain.com
12 // mcseemagg@yahoo.com
13 // http://www.antigrain.com
14 //----------------------------------------------------------------------------
16 #ifndef AGG_VCGEN_BSPLINE_INCLUDED
17 #define AGG_VCGEN_BSPLINE_INCLUDED
19 #include "agg_basics.h"
20 #include "agg_array.h"
21 #include "agg_bspline.h"
27 //==========================================================vcgen_bspline
40 typedef pod_bvector
<point_d
, 6> vertex_storage
;
44 void interpolation_step(double v
) { m_interpolation_step
= v
; }
45 double interpolation_step() const { return m_interpolation_step
; }
47 // Vertex Generator Interface
49 void add_vertex(double x
, double y
, unsigned cmd
);
51 // Vertex Source Interface
52 void rewind(unsigned path_id
);
53 unsigned vertex(double* x
, double* y
);
56 vcgen_bspline(const vcgen_bspline
&);
57 const vcgen_bspline
& operator = (const vcgen_bspline
&);
59 vertex_storage m_src_vertices
;
62 double m_interpolation_step
;
65 unsigned m_src_vertex
;
66 double m_cur_abscissa
;
67 double m_max_abscissa
;