[17276] | 1 | /* |
---|
| 2 | rsvg-bpath-util.h: Data structure and convenience functions for creating bezier paths. |
---|
| 3 | |
---|
| 4 | Copyright (C) 2000 Eazel, Inc. |
---|
| 5 | |
---|
| 6 | This program is free software; you can redistribute it and/or |
---|
[18274] | 7 | modify it under the terms of the GNU Library General Public License as |
---|
[17276] | 8 | published by the Free Software Foundation; either version 2 of the |
---|
| 9 | License, or (at your option) any later version. |
---|
| 10 | |
---|
| 11 | This program is distributed in the hope that it will be useful, |
---|
| 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
[18274] | 14 | Library General Public License for more details. |
---|
[17276] | 15 | |
---|
[18274] | 16 | You should have received a copy of the GNU Library General Public |
---|
[17276] | 17 | License along with this program; if not, write to the |
---|
| 18 | Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
---|
| 19 | Boston, MA 02111-1307, USA. |
---|
| 20 | |
---|
| 21 | Author: Raph Levien <raph@artofcode.com> |
---|
| 22 | */ |
---|
| 23 | |
---|
| 24 | #ifndef RSVG_BPATH_UTIL_H |
---|
| 25 | #define RSVG_BPATH_UTIL_H |
---|
| 26 | |
---|
| 27 | #include <libart_lgpl/art_bpath.h> |
---|
| 28 | |
---|
| 29 | #ifdef __cplusplus |
---|
| 30 | extern "C" { |
---|
| 31 | #endif /* __cplusplus */ |
---|
| 32 | |
---|
| 33 | typedef struct _RsvgBpathDef RsvgBpathDef; |
---|
| 34 | |
---|
| 35 | struct _RsvgBpathDef { |
---|
| 36 | int ref_count; |
---|
| 37 | ArtBpath *bpath; |
---|
| 38 | int n_bpath; |
---|
| 39 | int n_bpath_max; |
---|
| 40 | int moveto_idx; |
---|
| 41 | }; |
---|
| 42 | |
---|
| 43 | |
---|
| 44 | RsvgBpathDef *rsvg_bpath_def_new (void); |
---|
| 45 | RsvgBpathDef *rsvg_bpath_def_new_from (ArtBpath *bpath); |
---|
| 46 | RsvgBpathDef *rsvg_bpath_def_ref (RsvgBpathDef *bpd); |
---|
| 47 | |
---|
| 48 | #define rsvg_bpath_def_unref rsvg_bpath_def_free |
---|
| 49 | void rsvg_bpath_def_free (RsvgBpathDef *bpd); |
---|
| 50 | |
---|
| 51 | void rsvg_bpath_def_moveto (RsvgBpathDef *bpd, |
---|
| 52 | double x, double y); |
---|
| 53 | void rsvg_bpath_def_lineto (RsvgBpathDef *bpd, |
---|
| 54 | double x, double y); |
---|
| 55 | void rsvg_bpath_def_curveto (RsvgBpathDef *bpd, |
---|
| 56 | double x1, double y1, |
---|
| 57 | double x2, double y2, |
---|
| 58 | double x3, double y3); |
---|
| 59 | void rsvg_bpath_def_closepath (RsvgBpathDef *bpd); |
---|
| 60 | |
---|
| 61 | void rsvg_bpath_def_art_finish (RsvgBpathDef *bpd); |
---|
| 62 | |
---|
| 63 | #ifdef __cplusplus |
---|
| 64 | } |
---|
| 65 | #endif /* __cplusplus */ |
---|
| 66 | |
---|
| 67 | #endif |
---|
| 68 | |
---|