1 #define MAIN(x) trajpoly5##x
3 #include "a/trajpoly5.h"
5 int main(int argc
, char *argv
[]) /* NOLINT(misc-definitions-in-headers) */
7 a_float arg
[8] = {0, 0, 0, 0, 0, 0, 0, 0};
14 char *endptr
= A_NULL
;
15 (void)strtonum(argv
[1], &endptr
);
16 if (argv
[1] == endptr
)
18 main_init(argc
, argv
, 1);
23 for (i
= start
; i
< argc
; ++i
)
25 arg
[i
- start
] = strtonum(argv
[i
], A_NULL
);
27 a_trajpoly5_gen(&ctx
, arg
[1] - arg
[0], arg
[2], arg
[3], arg
[4], arg
[5], arg
[6], arg
[7]);
28 for ((void)(x
= arg
[0]), delta
= (arg
[1] - arg
[0]) / 1000; x
< arg
[1]; x
+= delta
) /* NOLINT */
30 debug(A_FLOAT_PRI("+", "f,") A_FLOAT_PRI("+", "f,") A_FLOAT_PRI("+", "f,") A_FLOAT_PRI("+", "f\n"),
31 x
, a_trajpoly5_pos(&ctx
, x
), a_trajpoly5_vel(&ctx
, x
), a_trajpoly5_acc(&ctx
, x
));
34 #if defined(__cplusplus) && (__cplusplus > 201100L)
35 A_BUILD_ASSERT(std::is_pod
<a_trajpoly5
>::value
);
36 #endif /* __cplusplus */