Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
BoundingBox.h
00001 #ifndef _ROS_jsk_recognition_msgs_BoundingBox_h 00002 #define _ROS_jsk_recognition_msgs_BoundingBox_h 00003 00004 #include <stdint.h> 00005 #include <string.h> 00006 #include <stdlib.h> 00007 #include "ros/msg.h" 00008 #include "std_msgs/Header.h" 00009 #include "geometry_msgs/Pose.h" 00010 #include "geometry_msgs/Vector3.h" 00011 00012 namespace jsk_recognition_msgs 00013 { 00014 00015 class BoundingBox : public ros::Msg 00016 { 00017 public: 00018 typedef std_msgs::Header _header_type; 00019 _header_type header; 00020 typedef geometry_msgs::Pose _pose_type; 00021 _pose_type pose; 00022 typedef geometry_msgs::Vector3 _dimensions_type; 00023 _dimensions_type dimensions; 00024 typedef float _value_type; 00025 _value_type value; 00026 typedef uint32_t _label_type; 00027 _label_type label; 00028 00029 BoundingBox(): 00030 header(), 00031 pose(), 00032 dimensions(), 00033 value(0), 00034 label(0) 00035 { 00036 } 00037 00038 virtual int serialize(unsigned char *outbuffer) const 00039 { 00040 int offset = 0; 00041 offset += this->header.serialize(outbuffer + offset); 00042 offset += this->pose.serialize(outbuffer + offset); 00043 offset += this->dimensions.serialize(outbuffer + offset); 00044 union { 00045 float real; 00046 uint32_t base; 00047 } u_value; 00048 u_value.real = this->value; 00049 *(outbuffer + offset + 0) = (u_value.base >> (8 * 0)) & 0xFF; 00050 *(outbuffer + offset + 1) = (u_value.base >> (8 * 1)) & 0xFF; 00051 *(outbuffer + offset + 2) = (u_value.base >> (8 * 2)) & 0xFF; 00052 *(outbuffer + offset + 3) = (u_value.base >> (8 * 3)) & 0xFF; 00053 offset += sizeof(this->value); 00054 *(outbuffer + offset + 0) = (this->label >> (8 * 0)) & 0xFF; 00055 *(outbuffer + offset + 1) = (this->label >> (8 * 1)) & 0xFF; 00056 *(outbuffer + offset + 2) = (this->label >> (8 * 2)) & 0xFF; 00057 *(outbuffer + offset + 3) = (this->label >> (8 * 3)) & 0xFF; 00058 offset += sizeof(this->label); 00059 return offset; 00060 } 00061 00062 virtual int deserialize(unsigned char *inbuffer) 00063 { 00064 int offset = 0; 00065 offset += this->header.deserialize(inbuffer + offset); 00066 offset += this->pose.deserialize(inbuffer + offset); 00067 offset += this->dimensions.deserialize(inbuffer + offset); 00068 union { 00069 float real; 00070 uint32_t base; 00071 } u_value; 00072 u_value.base = 0; 00073 u_value.base |= ((uint32_t) (*(inbuffer + offset + 0))) << (8 * 0); 00074 u_value.base |= ((uint32_t) (*(inbuffer + offset + 1))) << (8 * 1); 00075 u_value.base |= ((uint32_t) (*(inbuffer + offset + 2))) << (8 * 2); 00076 u_value.base |= ((uint32_t) (*(inbuffer + offset + 3))) << (8 * 3); 00077 this->value = u_value.real; 00078 offset += sizeof(this->value); 00079 this->label = ((uint32_t) (*(inbuffer + offset))); 00080 this->label |= ((uint32_t) (*(inbuffer + offset + 1))) << (8 * 1); 00081 this->label |= ((uint32_t) (*(inbuffer + offset + 2))) << (8 * 2); 00082 this->label |= ((uint32_t) (*(inbuffer + offset + 3))) << (8 * 3); 00083 offset += sizeof(this->label); 00084 return offset; 00085 } 00086 00087 virtual const char * getType(){ return "jsk_recognition_msgs/BoundingBox"; }; 00088 virtual const char * getMD5(){ return "f4b35de043f6031fe29bcfe43eeb9dca"; }; 00089 00090 }; 00091 00092 } 00093 #endif
Generated on Mon Sep 26 2022 13:47:00 by
