commit | author | age
|
d7639a
|
1 |
#include<general.h> |
SP |
2 |
#include "vesicle.h" |
|
3 |
ts_bool vesicle_translate(ts_vesicle *vesicle,ts_double x, ts_double y, ts_double z){ |
|
4 |
ts_uint i; |
|
5 |
ts_vertex *vtx=vesicle->vlist.vertex; |
|
6 |
ts_uint nn=vesicle->vlist.n; |
|
7 |
for(i=0;i<nn;i++){ |
|
8 |
vtx[i].x+=x; |
|
9 |
vtx[i].y+=y; |
|
10 |
vtx[i].z+=z; |
|
11 |
} |
|
12 |
return TS_SUCCESS; |
|
13 |
} |
|
14 |
|
|
15 |
ts_bool vesicle_free(ts_vesicle *vesicle){ |
|
16 |
vertex_list_free(&vesicle->vlist); |
|
17 |
bond_list_free(&vesicle->blist); |
|
18 |
triangle_list_free(&vesicle->tlist); |
|
19 |
cell_list_free(&vesicle->clist); |
|
20 |
return TS_SUCCESS; |
|
21 |
} |