94 free((
void *)target_cs);
107 target_cs->
theta = theta;
115 if (!target_cs || !on_cs)
127 xx = -(*x) * cos(-(*theta)) + (*y) * sin(-(*theta));
128 yy = -(*x) * sin(-(*theta)) - (*y) * cos(-(*theta));
140 if (!target_cs || !now_cs)
144 if (target_cs == now_cs)
178 xx = *x * cos(target_cs->
theta) - *y * sin(target_cs->
theta) + target_cs->
x;
179 yy = *x * sin(target_cs->
theta) + *y * cos(target_cs->
theta) + target_cs->
y;
182 *theta += target_cs->
theta;
192 xx = (*x - target_cs->
x) * cos(-target_cs->
theta) - (*y - target_cs->
y) * sin(-target_cs->
theta);
193 yy = (*x - target_cs->
x) * sin(-target_cs->
theta) + (*y - target_cs->
y) * cos(-target_cs->
theta);
196 *theta -= target_cs->
theta;
203 if (target_cs == CSroot_ptr)
void inv_trans_cs(CSptr target_cs, double *x, double *y, double *theta)
void trace_trans_cs(CSptr target_cs, double *x, double *y, double *theta)
int CS_set(CSptr target_cs, double x, double y, double theta)
CSptr CS_add(CSptr parent_cs, double x, double y, double theta)
int CS_set_on_CS(CSptr target_cs, CSptr on_cs, double x, double y, double theta)
void trans_cs(CSptr target_cs, double *x, double *y, double *theta)
void CS_recursive_trans(CSptr target_cs, CSptr now_cs, double *x, double *y, double *theta)
int CS_delete(CSptr target_cs)
void CS_turn_base(double *x, double *y, double *theta)