|
YARP
Yet Another Robot Platform
|
|
Go to the documentation of this file.
21 #ifndef YARP_ROSMSG_std_msgs_UInt32MultiArray_h
22 #define YARP_ROSMSG_std_msgs_UInt32MultiArray_h
39 std::vector<std::uint32_t>
data;
66 if (len > 0 && !connection.
expectBlock((
char*)&
data[0],
sizeof(std::uint32_t)*len)) {
92 for (
int i=0; i<len; i++) {
135 for (
size_t i=0; i<
data.size(); i++) {
156 static constexpr
const char*
typeName =
"std_msgs/UInt32MultiArray";
159 static constexpr
const char*
typeChecksum =
"4d6a180abc9be191b96a7eda6c8a233d";
163 # Please look at the MultiArrayLayout message definition for\n\
164 # documentation on all multiarrays.\n\
166 MultiArrayLayout layout # specification of data layout\n\
167 uint32[] data # array of data\n\
170 ================================================================================\n\
171 MSG: std_msgs/MultiArrayLayout\n\
172 # The multiarray declares a generic multi-dimensional array of a\n\
173 # particular data type. Dimensions are ordered from outer most\n\
176 MultiArrayDimension[] dim # Array of dimension properties\n\
177 uint32 data_offset # padding elements at front of data\n\
179 # Accessors should ALWAYS be written in terms of dimension stride\n\
180 # and specified outer-most dimension first.\n\
182 # multiarray(i,j,k) = data[data_offset + dim_stride[1]*i + dim_stride[2]*j + k]\n\
184 # A standard, 3-channel 640x480 image with interleaved color channels\n\
185 # would be specified as:\n\
187 # dim[0].label = \"height\"\n\
188 # dim[0].size = 480\n\
189 # dim[0].stride = 3*640*480 = 921600 (note dim[0] stride is just size of image)\n\
190 # dim[1].label = \"width\"\n\
191 # dim[1].size = 640\n\
192 # dim[1].stride = 3*640 = 1920\n\
193 # dim[2].label = \"channel\"\n\
195 # dim[2].stride = 3\n\
197 # multiarray(i,j,k) refers to the ith row, jth column, and kth channel.\n\
199 ================================================================================\n\
200 MSG: std_msgs/MultiArrayDimension\n\
201 string label # label of given dimension\n\
202 uint32 size # size of given dimension (in type units)\n\
203 uint32 stride # stride of given dimension\n\
219 #endif // YARP_ROSMSG_std_msgs_UInt32MultiArray_h
std::vector< std::uint32_t > data
bool read(yarp::os::ConnectionReader &connection) override
Read this object from a network connection.
virtual bool read(yarp::os::idl::WireReader &reader)
bool writeBare(yarp::os::ConnectionWriter &connection) const override
yarp::rosmsg::std_msgs::MultiArrayLayout layout
virtual bool isBareMode() const =0
Check if the connection is bare mode.
yarp::os::Type getType() const override
virtual bool isError() const =0
static Type byName(const char *name)
virtual std::int32_t expectInt32()=0
Read a 32-bit integer from the network connection.
static constexpr const char * typeName
Type & addProperty(const char *key, const Value &val)
An interface for writing to a network connection.
virtual bool isError() const =0
virtual bool convertTextMode()=0
Reads in a standard description in text mode, and converts it to a standard description in binary.
A "tamed" Portable, that promises to serialize itself in an IDL-friendly way.
virtual bool isBareMode() const =0
Check if the connection is bare mode.
virtual bool convertTextMode()=0
Converts a standard description in binary into a textual description, if the connection is in text-mo...
bool readBottle(yarp::os::ConnectionReader &connection) override
virtual void appendInt32(std::int32_t data)=0
Send a representation of a 32-bit integer to the network connection.
yarp::os::idl::BottleStyle< yarp::rosmsg::std_msgs::UInt32MultiArray > bottleStyle
IDL-friendly connection reader.
An interface for reading from a network connection.
yarp::os::idl::BareStyle< yarp::rosmsg::std_msgs::UInt32MultiArray > rosStyle
static constexpr const char * typeText
The main, catch-all namespace for YARP.
bool read(yarp::os::ConnectionReader &connection) override
Read this object from a network connection.
bool write(yarp::os::ConnectionWriter &connection) const override
Write this object to a network connection.
virtual void appendExternalBlock(const char *data, size_t len)=0
Send a block of data to the network connection, without making a copy.
static constexpr const char * typeChecksum
bool write(yarp::os::ConnectionWriter &connection) const override
Write this object to a network connection.
virtual bool expectBlock(char *data, size_t len)=0
Read a block of data from the network connection.
A single value (typically within a Bottle).
bool readBare(yarp::os::ConnectionReader &connection) override
bool writeBottle(yarp::os::ConnectionWriter &connection) const override
virtual bool write(const yarp::os::idl::WireWriter &writer) const