Mercurial > MadButterfly
comparison src/mb_types.h @ 28:604bc90d509d
Refactory
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Mon, 04 Aug 2008 20:08:37 +0800 |
parents | d50f33040de6 |
children | e06a4a667ce2 |
comparison
equal
deleted
inserted
replaced
27:19c603dd6ff9 | 28:604bc90d509d |
---|---|
48 extern void geo_from_positions(geo_t *g, int n_pos, co_aix pos[][2]); | 48 extern void geo_from_positions(geo_t *g, int n_pos, co_aix pos[][2]); |
49 extern void geo_mark_overlay(geo_t *g, int n_others, geo_t **others, | 49 extern void geo_mark_overlay(geo_t *g, int n_others, geo_t **others, |
50 int *n_overlays, geo_t **overlays); | 50 int *n_overlays, geo_t **overlays); |
51 #define geo_get_shape(g) ((g)->shape) | 51 #define geo_get_shape(g) ((g)->shape) |
52 #define geo_set_shape(g, sh) do {(g)->shape = sh;} while(0) | 52 #define geo_set_shape(g, sh) do {(g)->shape = sh;} while(0) |
53 #define _geo_is_in(a, s, w) ((a) >= (s) && (a) < ((s) + (w))) | |
54 #define geo_pos_is_in(g, _x, _y) \ | |
55 (_geo_is_in(_x, (g)->cur_area.x, (g)->cur_area.w) && \ | |
56 _geo_is_in(_y, (g)->cur_area.y, (g)->cur_area.h)) | |
53 | 57 |
54 | 58 |
55 /*! \brief A coordination system. | 59 /*! \brief A coordination system. |
56 * | 60 * |
57 * It have a transform function defined by matrix to transform | 61 * It have a transform function defined by matrix to transform |