Mercurial > MadButterfly
diff include/mb_types.h @ 448:16116d84bc5e
Replace Cairo with a abstract layer mb_graph_engine.
mb_graph_engine is a layer to separate MadButterfly from Cairo.
It is only a set of macro mapping to cairo implementation, now.
But, it provides a oppotunities to replace cairo with other engines;
likes skia.
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Tue, 04 Aug 2009 23:35:41 +0800 |
parents | 27774b93521e |
children | bb4f651090bf |
line wrap: on
line diff
--- a/include/mb_types.h Sun Aug 02 11:00:37 2009 +0800 +++ b/include/mb_types.h Tue Aug 04 23:35:41 2009 +0800 @@ -1,7 +1,7 @@ #ifndef __MB_TYPES_H_ #define __MB_TYPES_H_ -#include <cairo.h> +#include "mb_graph_engine.h" #include "mb_tools.h" #include "mb_observer.h" #include "mb_prop.h" @@ -14,8 +14,8 @@ typedef struct _paint paint_t; typedef struct _mb_obj mb_obj_t; typedef struct _mb_sprite mb_sprite_t; -/*! \todo Replace cairo_t with canvas_t. */ -typedef cairo_t canvas_t; +/*! \todo Replace mbe_t with canvas_t. */ +typedef mbe_t canvas_t; struct _redraw_man; @@ -81,7 +81,7 @@ struct _paint { int pnt_type; int flags; - void (*prepare)(paint_t *paint, cairo_t *cr); + void (*prepare)(paint_t *paint, mbe_t *cr); void (*free)(struct _redraw_man *rdman, paint_t *paint); STAILQ(shnode_t) members; paint_t *pnt_next; /*!< \brief Collect all paints of a rdman. */