38 #ifndef AMINO_CT_TRAJ_H
39 #define AMINO_CT_TRAJ_H
51 #define AA_CT_SEG_IN 1
52 #define AA_CT_SEG_OUT 0
54 #define AA_CT_LIN_SEG 1
55 #define AA_CT_PB_SEG 2
56 #define AA_CT_ACCL_SEG 3
74 struct aa_ct_seg_list;
207 struct aa_ct_pt_list *list,
220 struct aa_ct_pt_list *list,
234 struct aa_ct_pt_list *list,
247 struct aa_ct_pt_list *list,
265 int (*
function)(
void *cx,
double t,
const struct aa_ct_state *state ),
281 double tol,
double eps );
292 struct aa_ct_pt_list *list );
struct aa_ct_pt * next
Links to next and previous points.
struct aa_ct_state state
Description of state at waypoint.
State description of a robot.
size_t n_q
Number of configuration variables.
Data Structure for Region-Based memory allocation.
int aa_ct_seg_list_eval_dq(struct aa_ct_seg_list *list, double t, size_t n, double *q, double *dq)
Evaluate trajectory and fill configuration and velocity arrays.
struct aa_ct_seg_list * aa_ct_tjq_trap_generate(struct aa_mem_region *reg, struct aa_ct_pt_list *list, struct aa_ct_limit *limits)
Generate a trapezoidal blend trajectory from a point list.
struct aa_ct_seg_list * aa_ct_tjx_slerp_generate(struct aa_mem_region *reg, struct aa_ct_pt_list *list)
Generate a SLERP trajectory from a point list.
void aa_ct_pt_list_dump(FILE *stream, struct aa_ct_pt_list *list)
Print out a list of points to a file.
void aa_ct_pt_list_add_front(struct aa_ct_pt_list *list, struct aa_ct_state *state)
Add a reference to a waypoint to the front of a point list.
void aa_ct_pt_list_add_qutr(struct aa_ct_pt_list *list, const double E[7])
Add a quaternion-translation pose to the point list.
double aa_ct_seg_list_duration(const struct aa_ct_seg_list *list)
Return duration (time) of segment list.
int aa_ct_seg_list_eval_q(struct aa_ct_seg_list *list, double t, size_t n, double *q)
Evaluate trajectory and fill configuration array.
struct aa_ct_seg_list * aa_ct_tjq_pb_generate(struct aa_mem_region *reg, struct aa_ct_pt_list *list, struct aa_ct_limit *limits)
Generate a parabolic blend trajectory from a point list.
void aa_ct_pt_list_add_q(struct aa_ct_pt_list *list, size_t n_q, const double *q)
Add a quaternion-translation position the point list.
const struct aa_ct_state * aa_ct_pt_list_final_state(const struct aa_ct_pt_list *list)
Return the final state of the point list.
void aa_ct_seg_list_destroy(struct aa_ct_seg_list *list)
Destroys an allocated segment list.
int aa_ct_seg_list_check(struct aa_ct_seg_list *segs, double dt, int(*function)(void *cx, double t, const struct aa_ct_state *state), void *cx)
Check the trajectory by evaluting function at points along the trajectory.
struct aa_ct_seg_list * aa_ct_tjX_pb_generate(struct aa_mem_region *reg, struct aa_ct_pt_list *list, struct aa_ct_limit *limits)
Generate a parabolic blend trajectory in the workspace from a point list.
int aa_ct_seg_list_check_c0(struct aa_ct_seg_list *segs, double dt, double tol, double eps)
Check C0 (position) continuity of the trajectory.
size_t aa_ct_pt_list_size(const struct aa_ct_pt_list *list)
Return the number of points in the point list.
int aa_ct_seg_list_eval(struct aa_ct_seg_list *list, struct aa_ct_state *state, double t)
Evaluates a segment list at a given time.
struct aa_ct_seg_list * aa_ct_tjq_lin_generate(struct aa_mem_region *reg, struct aa_ct_pt_list *list, struct aa_ct_limit *limits)
Generate a linear trajectory from a point list.
const struct aa_ct_state * aa_ct_pt_list_start_state(const struct aa_ct_pt_list *list)
Return the initial state of the point list.
void aa_ct_pt_list_add(struct aa_ct_pt_list *list, struct aa_ct_state *state)
Add a reference to a waypoint to the back of a point list.
size_t aa_ct_seg_list_n_q(const struct aa_ct_seg_list *list)
Return segment list configuration count.
void aa_ct_seg_list_plot(struct aa_ct_seg_list *list, size_t n_q, double dt)
Plots a segment list with a given resolution.
void aa_ct_pt_list_destroy(struct aa_ct_pt_list *list)
Destroys an allocated point list.
struct aa_ct_pt_list * aa_ct_pt_list_create(struct aa_mem_region *reg)
Initialize and construct a point list from a memory region.