24 #include <interfaces/TransformInterface.h> 26 #include <core/exceptions/software.h> 51 TransformInterface::TransformInterface() : Interface()
53 data_size =
sizeof(TransformInterface_data_t);
55 data = (TransformInterface_data_t *)
data_ptr;
62 unsigned char tmp_hash[] = {0x97, 0xc8, 0x15, 0xe9, 0xcb, 0xd2, 0x33, 0x33, 0xf3, 0xfe, 0x49, 0x72, 0x92, 0x99, 0xd9, 0xeb};
67 TransformInterface::~TransformInterface()
105 strncpy(data->frame, new_frame,
sizeof(data->frame));
119 return data->child_frame;
142 strncpy(data->child_frame, new_child_frame,
sizeof(data->child_frame));
157 return data->translation;
174 throw Exception(
"Index value %u out of bounds (0..3)", index);
176 return data->translation[index];
200 memcpy(data->translation, new_translation,
sizeof(
double) * 3);
217 throw Exception(
"Index value %u out of bounds (0..3)", index);
219 data->translation[index] = new_translation;
234 return data->rotation;
252 throw Exception(
"Index value %u out of bounds (0..4)", index);
254 return data->rotation[index];
279 memcpy(data->rotation, new_rotation,
sizeof(
double) * 4);
297 throw Exception(
"Index value %u out of bounds (0..4)", index);
299 data->rotation[index] = new_rotation;
307 "message type for this interface type.", type);
322 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.
const char * type() const
Get message type.
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.
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)
Add an entry to the info list.
const char * type() const
Get type of interface.