Open

Description
Change request
In the Image
, CompressedImage
, and PointCloud2
messages there are data
fields that have type uint8[]
. I suggest these are chaged to byte[]
.
Change description
According to the wiki, uint8
is interpreted as a python int
, whereas byte
is interpreted as a python byte
. For the messages where arrays of uint8
are used, it's normally because the data is some arbitrary binary format. Currently, it seems that rclpy
takes this binary data, copies it out into a list[int]
, which client code then normally converts back to some collection of byte
types for use. This is much more processing and copying than is necessary.
This should also somewhat mitigate this issue, as no range check will be necessary.
Implementation considerations
I can think of no cons of this change
connects to ros2/rosidl#190
Metadata
Metadata
Assignees
Labels
No labels