Skip to content

Conversation

@ChristofDubs
Copy link
Contributor

Related to Issue #251 / the commit addressing it, the row_step field (Length of a row in bytes) is currently still set as if the point cloud was unorganized (point_step * width * height instead of point_step * width), which led to a deserialization error in my subscriber.

Since the PointCloud2Modifier::setPointCloud2Fields() function sets the row_step field correctly if height and width are set correctly, and also calls cloud_msg_.data.resize(cloud_msg_.height * cloud_msg_.row_step); in the end, the additional PointCloud2Modifier::resize() call is not required.

Tested this on my end and it worked.

syncing master of original repo
set height and width before setPointCloud2Fields() call such that this function call sets row_step correctly
@adujardin adujardin requested a review from Myzhar August 22, 2018 07:48
Copy link
Member

@Myzhar Myzhar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good fix 👍

@adujardin adujardin merged commit 43fb5f7 into stereolabs:master Aug 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants