Mercurial > MadButterfly
comparison include/mb_graph_engine_openvg.h @ 593:ac942664fe86 openvg
stroke and fill for VG
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Wed, 30 Jun 2010 22:57:23 +0800 |
parents | de9d210e9c38 |
children | aaaaa03af04d |
comparison
equal
deleted
inserted
replaced
592:de9d210e9c38 | 593:ac942664fe86 |
---|---|
60 #define mbe_curve_to(canvas, x1, y1, x2, y2, x3, y3) | 60 #define mbe_curve_to(canvas, x1, y1, x2, y2, x3, y3) |
61 #define mbe_restore(canvas) | 61 #define mbe_restore(canvas) |
62 #define mbe_move_to(canvas, x, y) | 62 #define mbe_move_to(canvas, x, y) |
63 #define mbe_line_to(canvas, x, y) | 63 #define mbe_line_to(canvas, x, y) |
64 #define mbe_in_fill(canvas, x, y) (0) | 64 #define mbe_in_fill(canvas, x, y) (0) |
65 #define mbe_stroke(canvas) | |
66 #define mbe_clear(canvas) | 65 #define mbe_clear(canvas) |
67 #define mbe_paint(canvas) | 66 #define mbe_paint(canvas) |
68 #define mbe_save(canvas) | 67 #define mbe_save(canvas) |
69 #define mbe_fill(canvas) | |
70 #define mbe_arc(canvas, x, y, radius, angle_start, angle_stop) | 68 #define mbe_arc(canvas, x, y, radius, angle_start, angle_stop) |
71 | 69 |
72 typedef struct _mbe_text_extents_t mbe_text_extents_t; | 70 typedef struct _mbe_text_extents_t mbe_text_extents_t; |
73 typedef int mbe_scaled_font_t; | 71 typedef int mbe_scaled_font_t; |
74 typedef int mbe_font_face_t; | 72 typedef int mbe_font_face_t; |
170 free(surface); | 168 free(surface); |
171 } | 169 } |
172 | 170 |
173 extern mbe_t *mbe_create(mbe_surface_t *surface); | 171 extern mbe_t *mbe_create(mbe_surface_t *surface); |
174 extern void mbe_destroy(mbe_t *canvas); | 172 extern void mbe_destroy(mbe_t *canvas); |
173 static void | |
174 mbe_stroke(mbe_t *canvas) { | |
175 _MK_CURRENT_CTX(canvas); | |
176 | |
177 vgDrawPath(canvas->path, VG_STROKE_PATH); | |
178 vgClearPath(canvas->path, VG_PATH_CAPABILITY_ALL); | |
179 } | |
180 | |
181 static void | |
182 mbe_fill(mbe_t *canvas) { | |
183 _MK_CURRENT_CTX(canvas); | |
184 | |
185 vgDrawPath(canvas->path, VG_FILL_PATH); | |
186 vgClearPath(canvas->path, VG_PATH_CAPABILITY_ALL); | |
187 } | |
175 | 188 |
176 /* @} */ | 189 /* @} */ |
177 | 190 |
178 #endif /* __MB_GE_OPENVG_H_ */ | 191 #endif /* __MB_GE_OPENVG_H_ */ |