Mercurial > MadButterfly
comparison src/graph_engine_skia.cpp @ 473:ba64f928542b Android_Skia
Remove mbe_matrix_t type.
The struct mbe_matrix_t is defined in a layout accoriding definition
of Cairo. It is not feasible for all graphic engine. Now, we start
supporting of other graphic engine; Skia, so use type of (co_aix[6])
defined and used by MadButterfly intead of mbe_matrix_t. And, bridges
of graphic engines are responsible for translate matrics into the
matrix type of the graphic enigne.
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Thu, 12 Nov 2009 21:32:58 +0800 |
parents | 4254eaa699d0 |
children | 9a867333018b |
comparison
equal
deleted
inserted
replaced
472:4254eaa699d0 | 473:ba64f928542b |
---|---|
11 #include "mb_graph_engine_skia.h" | 11 #include "mb_graph_engine_skia.h" |
12 #include "mb_shapes.h" | 12 #include "mb_shapes.h" |
13 | 13 |
14 struct _mbe_scaled_font_t { | 14 struct _mbe_scaled_font_t { |
15 struct _mb_font_face_t *face; | 15 struct _mb_font_face_t *face; |
16 mbe_matrix_t fnt_mtx; | 16 co_aix fnt_mtx[6]; |
17 mbe_matrix_t ctm; | 17 co_aix ctm[6]; |
18 } | 18 } |
19 struct _mbe_font_face_t {}; | 19 struct _mbe_font_face_t {}; |
20 struct _mbe_t { | 20 struct _mbe_t { |
21 SkCanvas *canvas; | 21 SkCanvas *canvas; |
22 SkShader *shader; | 22 SkShader *shader; |
37 co_aix cx1, co_aix cy1, | 37 co_aix cx1, co_aix cy1, |
38 co_aix radius1) {} | 38 co_aix radius1) {} |
39 mbe_pattern_t *mbe_pattern_create_linear(co_aix x0, co_aix y0, | 39 mbe_pattern_t *mbe_pattern_create_linear(co_aix x0, co_aix y0, |
40 co_aix x1, co_aix y1) {} | 40 co_aix x1, co_aix y1) {} |
41 void mbe_pattern_set_matrix(mbe_pattern_t *ptn, | 41 void mbe_pattern_set_matrix(mbe_pattern_t *ptn, |
42 const mbe_matrix_t *matrix) {} | 42 const co_aix matrix[6]) {} |
43 void mbe_pattern_destroy(mbe_pattern_t *canvas) {} | 43 void mbe_pattern_destroy(mbe_pattern_t *canvas) {} |
44 | 44 |
45 int mbe_image_surface_get_stride(mbe_surface_t *surface) {} | 45 int mbe_image_surface_get_stride(mbe_surface_t *surface) {} |
46 int mbe_image_surface_get_height(mbe_surface_t *surface) {} | 46 int mbe_image_surface_get_height(mbe_surface_t *surface) {} |
47 int mbe_image_surface_get_width(mbe_surface_t *surface) {} | 47 int mbe_image_surface_get_width(mbe_surface_t *surface) {} |
58 | 58 |
59 mbe_scaled_font_t *mbe_scaled_font_reference(mbe_scaled_font_t *scaled) {} | 59 mbe_scaled_font_t *mbe_scaled_font_reference(mbe_scaled_font_t *scaled) {} |
60 void mbe_scaled_font_destroy(mbe_scaled_font_t *scaled) {} | 60 void mbe_scaled_font_destroy(mbe_scaled_font_t *scaled) {} |
61 mbe_font_face_t *mbe_font_face_reference(mbe_font_face_t *face) {} | 61 mbe_font_face_t *mbe_font_face_reference(mbe_font_face_t *face) {} |
62 mbe_scaled_font_t * | 62 mbe_scaled_font_t * |
63 mbe_scaled_font_create(mbe_font_face_t *face, mbe_matrix_t *fnt_mtx, | 63 mbe_scaled_font_create(mbe_font_face_t *face, co_aix fnt_mtx[6], |
64 mbe_matrix_t *ctm) {} | 64 co_aix ctm[6]) {} |
65 mbe_scaled_font_t *mbe_get_scaled_font(mbe_t *canvas) {} | 65 mbe_scaled_font_t *mbe_get_scaled_font(mbe_t *canvas) {} |
66 void mbe_scaled_font_text_extents(mbe_scaled_font_t *scaled, | 66 void mbe_scaled_font_text_extents(mbe_scaled_font_t *scaled, |
67 const char *txt, | 67 const char *txt, |
68 mbe_text_extents_t *extents) {} | 68 mbe_text_extents_t *extents) {} |
69 | 69 |
126 int slant, int weight) {} | 126 int slant, int weight) {} |
127 void mbe_free_font_face(mbe_font_face_t *face) {} | 127 void mbe_free_font_face(mbe_font_face_t *face) {} |
128 | 128 |
129 void mbe_clear(mbe_t *canvas) {} | 129 void mbe_clear(mbe_t *canvas) {} |
130 void mbe_copy_source(mbe_t *canvas) {} | 130 void mbe_copy_source(mbe_t *canvas) {} |
131 void mbe_transform(mbe_t *mbe, mbe_matrix_t *matrix) {} | 131 void mbe_transform(mbe_t *mbe, co_aix matrix[6]) {} |
132 void mbe_arc(mbe_t *mbe, co_aix x, co_aix y, co_aix radius, | 132 void mbe_arc(mbe_t *mbe, co_aix x, co_aix y, co_aix radius, |
133 co_aix angle_start, co_aix angle_stop) {} | 133 co_aix angle_start, co_aix angle_stop) {} |
134 | 134 |
135 | 135 |
136 C_END | 136 C_END |