Mercurial > MadButterfly
comparison tools/mb_c_header.m4 @ 64:c668c5c3ceae
M4 macro for C binding.
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Wed, 13 Aug 2008 02:07:40 +0800 |
parents | f4b792afa74e |
children | 3f2872a1a2fe |
comparison
equal
deleted
inserted
replaced
63:f4b792afa74e | 64:c668c5c3ceae |
---|---|
18 [ coord_t *$1; | 18 [ coord_t *$1; |
19 ]]) | 19 ]]) |
20 define([COLOR_STOP],[ ]) | 20 define([COLOR_STOP],[ ]) |
21 | 21 |
22 define([REF_STOPS],) | 22 define([REF_STOPS],) |
23 define([FILL_SHAPE],) | 23 define([FILL_SHAPE],[[ |
24 define([STROKE_SHAPE],) | 24 paint_t *$1_fill; |
25 ]]) | |
26 define([STROKE_SHAPE],[[ | |
27 paint_t *$1_stroke; | |
28 ]]) | |
25 define([FILL_SHAPE_WITH_PAINT],) | 29 define([FILL_SHAPE_WITH_PAINT],) |
26 define([STROKE_SHAPE_WITH_PAINT],) | 30 define([STROKE_SHAPE_WITH_PAINT],) |
27 | 31 |
28 define([MADBUTTERFLY],[dnl | 32 define([MADBUTTERFLY],[dnl |
29 [#ifndef __$1_H_ | 33 [#ifndef __$1_H_ |
30 #define __$1_H_] | 34 #define __$1_H_] |
31 | 35 |
32 [typedef struct $1 $1_t;] | 36 [typedef struct $1 $1_t;] |
33 | 37 |
34 struct [$1] { | 38 struct [$1] { |
39 coord_t *root_coord; | |
35 $2[]dnl | 40 $2[]dnl |
36 }; | 41 }; |
37 | 42 |
38 [#endif /* __$1_H_ */] | 43 [#endif /* __$1_H_ */] |
39 ]) | 44 ]) |