24 #ifndef __INTERFACES_VISUALDISPLAY2DINTERFACE_H_ 25 #define __INTERFACES_VISUALDISPLAY2DINTERFACE_H_ 27 #include <interface/interface.h> 28 #include <interface/message.h> 29 #include <interface/field_iterator.h> 73 typedef struct __attribute__((packed)) {
74 int64_t timestamp_sec;
75 int64_t timestamp_usec;
77 } VisualDisplay2DInterface_data_t;
79 VisualDisplay2DInterface_data_t *data;
89 typedef struct __attribute__((packed)) {
90 int64_t timestamp_sec;
91 int64_t timestamp_usec;
97 } AddCartLineMessage_data_t;
99 AddCartLineMessage_data_t *data;
104 AddCartLineMessage(
const float * ini_x,
const float * ini_y,
const LineStyle ini_style,
const uint8_t * ini_color);
111 float x(
unsigned int index)
const;
112 void set_x(
unsigned int index,
const float new_x);
113 void set_x(
const float * new_x);
114 size_t maxlenof_x()
const;
116 float y(
unsigned int index)
const;
117 void set_y(
unsigned int index,
const float new_y);
118 void set_y(
const float * new_y);
119 size_t maxlenof_y()
const;
120 LineStyle style()
const;
121 void set_style(
const LineStyle new_style);
122 size_t maxlenof_style()
const;
123 uint8_t * color()
const;
124 uint8_t color(
unsigned int index)
const;
125 void set_color(
unsigned int index,
const uint8_t new_color);
126 void set_color(
const uint8_t * new_color);
127 size_t maxlenof_color()
const;
128 virtual Message * clone()
const;
135 typedef struct __attribute__((packed)) {
136 int64_t timestamp_sec;
137 int64_t timestamp_usec;
143 } AddCartCircleMessage_data_t;
145 AddCartCircleMessage_data_t *data;
150 AddCartCircleMessage(
const float ini_x,
const float ini_y,
const float ini_radius,
const LineStyle ini_style,
const uint8_t * ini_color);
157 void set_x(
const float new_x);
158 size_t maxlenof_x()
const;
160 void set_y(
const float new_y);
161 size_t maxlenof_y()
const;
162 float radius()
const;
163 void set_radius(
const float new_radius);
164 size_t maxlenof_radius()
const;
165 LineStyle style()
const;
166 void set_style(
const LineStyle new_style);
167 size_t maxlenof_style()
const;
168 uint8_t * color()
const;
169 uint8_t color(
unsigned int index)
const;
170 void set_color(
unsigned int index,
const uint8_t new_color);
171 void set_color(
const uint8_t * new_color);
172 size_t maxlenof_color()
const;
173 virtual Message * clone()
const;
180 typedef struct __attribute__((packed)) {
181 int64_t timestamp_sec;
182 int64_t timestamp_usec;
189 } AddCartRectMessage_data_t;
191 AddCartRectMessage_data_t *data;
196 AddCartRectMessage(
const float ini_x,
const float ini_y,
const float ini_width,
const float ini_height,
const LineStyle ini_style,
const uint8_t * ini_color);
203 void set_x(
const float new_x);
204 size_t maxlenof_x()
const;
206 void set_y(
const float new_y);
207 size_t maxlenof_y()
const;
209 void set_width(
const float new_width);
210 size_t maxlenof_width()
const;
211 float height()
const;
212 void set_height(
const float new_height);
213 size_t maxlenof_height()
const;
214 LineStyle style()
const;
215 void set_style(
const LineStyle new_style);
216 size_t maxlenof_style()
const;
217 uint8_t * color()
const;
218 uint8_t color(
unsigned int index)
const;
219 void set_color(
unsigned int index,
const uint8_t new_color);
220 void set_color(
const uint8_t * new_color);
221 size_t maxlenof_color()
const;
222 virtual Message * clone()
const;
229 typedef struct __attribute__((packed)) {
230 int64_t timestamp_sec;
231 int64_t timestamp_usec;
239 } AddCartTextMessage_data_t;
241 AddCartTextMessage_data_t *data;
246 AddCartTextMessage(
const float ini_x,
const float ini_y,
const char * ini_text,
const Anchor ini_anchor,
const float ini_size,
const uint8_t * ini_color);
253 void set_x(
const float new_x);
254 size_t maxlenof_x()
const;
256 void set_y(
const float new_y);
257 size_t maxlenof_y()
const;
259 void set_text(
const char * new_text);
260 size_t maxlenof_text()
const;
261 Anchor anchor()
const;
262 void set_anchor(
const Anchor new_anchor);
263 size_t maxlenof_anchor()
const;
265 void set_size(
const float new_size);
266 size_t maxlenof_size()
const;
267 uint8_t * color()
const;
268 uint8_t color(
unsigned int index)
const;
269 void set_color(
unsigned int index,
const uint8_t new_color);
270 void set_color(
const uint8_t * new_color);
271 size_t maxlenof_color()
const;
272 virtual Message * clone()
const;
279 typedef struct __attribute__((packed)) {
280 int64_t timestamp_sec;
281 int64_t timestamp_usec;
284 } DeleteObjectMessage_data_t;
286 DeleteObjectMessage_data_t *data;
297 uint32_t object_id()
const;
298 void set_object_id(
const uint32_t new_object_id);
299 size_t maxlenof_object_id()
const;
300 virtual Message * clone()
const;
307 typedef struct __attribute__((packed)) {
308 int64_t timestamp_sec;
309 int64_t timestamp_usec;
310 } DeleteAllMessage_data_t;
312 DeleteAllMessage_data_t *data;
322 virtual Message * clone()
const;
338 virtual const char *
enum_tostring(
const char *enumtype,
int val)
const;
AddCartRectMessage Fawkes BlackBoard Interface Message.
LineStyle
Enumeration defining the possible line styles.
size_t maxlenof_counter() const
Get maximum length of counter value.
Base class for all messages passed through interfaces in Fawkes BlackBoard.
virtual const char * enum_tostring(const char *enumtype, int val) const
Convert arbitrary enum value to string.
Fawkes library namespace.
const char * tostring_Anchor(Anchor value) const
Convert Anchor constant to string.
AddCartCircleMessage Fawkes BlackBoard Interface Message.
Anchor
Enumeration defining the possible anchor points.
Base class for all Fawkes BlackBoard interfaces.
AddCartTextMessage Fawkes BlackBoard Interface Message.
uint32_t counter() const
Get counter value.
DeleteObjectMessage Fawkes BlackBoard Interface Message.
const char * type() const
Get type of interface.
AddCartLineMessage Fawkes BlackBoard Interface Message.
virtual void copy_values(const Interface *other)
Copy values from other interface.
virtual bool message_valid(const Message *message) const
Check if message is valid and can be enqueued.
Vertically and horitontally centered.
const char * tostring_LineStyle(LineStyle value) const
Convert LineStyle constant to string.
virtual Message * create_message(const char *type) const
Create message based on type name.
DeleteAllMessage Fawkes BlackBoard Interface Message.
VisualDisplay2DInterface Fawkes BlackBoard Interface.
std::map< int, std::string > interface_enum_map_t
Map of enum integer to string values.
void set_counter(const uint32_t new_counter)
Set counter value.