diff options
Diffstat (limited to 'lcmtype/laser_t.h')
-rw-r--r-- | lcmtype/laser_t.h | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/lcmtype/laser_t.h b/lcmtype/laser_t.h new file mode 100644 index 0000000..f3744ae --- /dev/null +++ b/lcmtype/laser_t.h | |||
@@ -0,0 +1,67 @@ | |||
1 | /** THIS IS AN AUTOMATICALLY GENERATED FILE. DO NOT MODIFY | ||
2 | * BY HAND!! | ||
3 | * | ||
4 | * Generated by lcm-gen | ||
5 | **/ | ||
6 | |||
7 | #include "lcm.h" | ||
8 | #include "lcmtype.h" | ||
9 | #include <stdint.h> | ||
10 | #include <stdlib.h> | ||
11 | |||
12 | #ifndef _laser_t_h | ||
13 | #define _laser_t_h | ||
14 | |||
15 | // 若为C++代码,需加上extern "C",表明以下按照C的方式进行编译 | ||
16 | // 否则会出现链接错误 | ||
17 | #ifdef __cplusplus | ||
18 | extern "C" { | ||
19 | #endif | ||
20 | |||
21 | typedef struct _laser_t laser_t; | ||
22 | struct _laser_t { | ||
23 | int64_t utime; | ||
24 | int32_t nranges; | ||
25 | float *ranges; | ||
26 | int32_t nintensities; | ||
27 | float *intensities; | ||
28 | float rad0; | ||
29 | float radstep; | ||
30 | }; | ||
31 | |||
32 | laser_t *laser_t_copy(const laser_t *p); | ||
33 | void laser_t_destroy(laser_t *p); | ||
34 | |||
35 | typedef struct _laser_t_subscription_t laser_t_subscription_t; | ||
36 | typedef void (*laser_t_handler_t)(const lcm_recv_buf_t *rbuf, | ||
37 | const char *channel, const laser_t *msg, | ||
38 | void *user); | ||
39 | |||
40 | int laser_t_publish(lcm_t *lcm, const char *channel, const laser_t *p); | ||
41 | laser_t_subscription_t *laser_t_subscribe(lcm_t *lcm, const char *channel, | ||
42 | laser_t_handler_t f, void *userdata); | ||
43 | int laser_t_unsubscribe(lcm_t *lcm, laser_t_subscription_t *hid); | ||
44 | int laser_t_subscription_set_queue_capacity(laser_t_subscription_t *subs, | ||
45 | int num_messages); | ||
46 | |||
47 | int laser_t_encode(void *buf, int offset, int maxlen, const laser_t *p); | ||
48 | int laser_t_decode(const void *buf, int offset, int maxlen, laser_t *p); | ||
49 | int laser_t_decode_cleanup(laser_t *p); | ||
50 | int laser_t_encoded_size(const laser_t *p); | ||
51 | |||
52 | // LCM support functions. Users should not call these | ||
53 | int64_t __laser_t_get_hash(void); | ||
54 | int64_t __laser_t_hash_recursive(const __lcm_hash_ptr *p); | ||
55 | int __laser_t_encode_array(void *buf, int offset, int maxlen, const laser_t *p, | ||
56 | int elements); | ||
57 | int __laser_t_decode_array(const void *buf, int offset, int maxlen, laser_t *p, | ||
58 | int elements); | ||
59 | int __laser_t_decode_array_cleanup(laser_t *p, int elements); | ||
60 | int __laser_t_encoded_array_size(const laser_t *p, int elements); | ||
61 | int __laser_t_clone_array(const laser_t *p, laser_t *q, int elements); | ||
62 | |||
63 | #ifdef __cplusplus | ||
64 | } | ||
65 | #endif | ||
66 | |||
67 | #endif | ||