24 #include <interfaces/TransformInterface.h> 26 #include <core/exceptions/software.h> 53 TransformInterface::TransformInterface() : Interface()
55 data_size =
sizeof(TransformInterface_data_t);
57 data = (TransformInterface_data_t *)
data_ptr;
65 unsigned char tmp_hash[] = {0xb6, 0xb0, 0xd3, 0x96, 0xda, 0x61, 0xdd, 0xd3, 0x6, 0x9e, 0x66, 0x4d, 0x14, 0x54, 0x5e, 0xfb};
70 TransformInterface::~TransformInterface()
108 strncpy(data->frame, new_frame,
sizeof(data->frame));
122 return data->child_frame;
145 strncpy(data->child_frame, new_child_frame,
sizeof(data->child_frame));
159 return data->static_transform;
182 data->static_transform = new_static_transform;
197 return data->translation;
214 throw Exception(
"Index value %u out of bounds (0..3)", index);
216 return data->translation[index];
240 memcpy(data->translation, new_translation,
sizeof(
double) * 3);
257 throw Exception(
"Index value %u out of bounds (0..3)", index);
259 data->translation[index] = new_translation;
274 return data->rotation;
292 throw Exception(
"Index value %u out of bounds (0..4)", index);
294 return data->rotation[index];
319 memcpy(data->rotation, new_rotation,
sizeof(
double) * 4);
337 throw Exception(
"Index value %u out of bounds (0..4)", index);
339 data->rotation[index] = new_rotation;
347 "message type for this interface type.", type);
362 memcpy(data, oi->data,
sizeof(TransformInterface_data_t));
void * data_ptr
Pointer to memory that contains local data.
Base class for all messages passed through interfaces in Fawkes BlackBoard.
void set_hash(unsigned char *ihash)
Set hash.
Fawkes library namespace.
Base class for all Fawkes BlackBoard interfaces.
message_data_ts_t * data_ts
data timestamp aliasing pointer
unsigned int data_size
Size of memory needed to hold all data.
bool data_changed
Indicator if data has changed.
const char * type() const
Get type of interface.
Base class for exceptions in Fawkes.
void add_fieldinfo(interface_fieldtype_t type, const char *name, size_t length, void *value, const char *enumtype=0, const interface_enum_map_t *enum_map=0)
Add an entry to the info list.
const char * type() const
Get message type.