Skip to content
This repository has been archived by the owner on Jan 7, 2023. It is now read-only.

Aligned depth image repeats itself #160

Open
ItsMeTheBee opened this issue Sep 19, 2020 · 0 comments
Open

Aligned depth image repeats itself #160

ItsMeTheBee opened this issue Sep 19, 2020 · 0 comments

Comments

@ItsMeTheBee
Copy link

System Info
Camera Model D435
Firmware Version 05.12.06.00
Operating System & Version Ubuntu 18.04 (host) & Docker Container ros:eloquent
Kernel Version (Linux Only) 5.4.0-47-generic
Platform Desktop x86_64
Language C++

Issue Description

I´m trying to segment objects by detecting them in the rgb image, cropping the depth image and then converting that image to a pcl.
Doing this I´m facing some issues and you might be able to help me with this one:

The depth image seems to repeat itself instead of actually being aligned to the color image:
color_depth_diff

This leads to issues when I try to crop and convert the depth image.
Where does this behavior come from? Is there anything I can do about it?

Code to convert the depth image msg to cv::Mat:
cv::Mat image(m_current_depth_msg.height, m_current_depth_msg.width, CV_8UC3, const_cast<unsigned char *>(m_current_depth_msg.data.data()), m_current_depth_msg.step);

Something I noticed is that I can´t visualize the topic "/d435/camera/aligned_depth_to_color/image_raw" in Rviz. The messages get dropped due to some unknown error. The topic "/d435/camera/depth/image_rect_raw" can be visualized just fine but here I´m facing the same issue (plus the image is obviously no aligned so I can´t really use it).

Any help would be appreciated!
Thanks in advance!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant