comparison src/shape_rect.c @ 40:e292beec12d4

-
author Thinker K.F. Li <thinker@branda.to>
date Wed, 06 Aug 2008 21:34:53 +0800
parents 51a20f240ce3
children 9ab15ebc9061
comparison
equal deleted inserted replaced
39:db2aa914e14b 40:e292beec12d4
33 return (shape_t *)rect; 33 return (shape_t *)rect;
34 } 34 }
35 35
36 void sh_rect_free(shape_t *shape) { 36 void sh_rect_free(shape_t *shape) {
37 free(shape); 37 free(shape);
38 }
39
40 void sh_rect_set(shape_t *shape, co_aix x, co_aix y,
41 co_aix w, co_aix h, co_aix rx, co_aix ry) {
42 sh_rect_t *rect = (sh_rect_t *)shape;
43
44 rect->x = x;
45 rect->y = y;
46 rect->w = w;
47 rect->h = h;
48 rect->rx = rx;
49 rect->ry = ry;
38 } 50 }
39 51
40 void sh_rect_transform(shape_t *shape) { 52 void sh_rect_transform(shape_t *shape) {
41 sh_rect_t *rect = (sh_rect_t *)shape; 53 sh_rect_t *rect = (sh_rect_t *)shape;
42 co_aix x, y, w, h, rx, ry; 54 co_aix x, y, w, h, rx, ry;