Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

depth_frame filtering (post-processing) #2399

Closed
ywjia opened this issue Sep 15, 2018 · 3 comments
Closed

depth_frame filtering (post-processing) #2399

ywjia opened this issue Sep 15, 2018 · 3 comments
Assignees

Comments

@ywjia
Copy link

ywjia commented Sep 15, 2018

  • Before opening a new issue, we wanted to provide you with some useful suggestions (Click "Preview" above for a better view):

  • All users are welcomed to report bugs, ask questions, suggest or request enhancements and generally feel free to open new issue, even if they haven't followed any of the suggestions above :)


Required Info
Camera Model D435
Firmware Version 5.10.3.0
Operating System & Version Ubuntu 16
Kernel Version (Linux Only) 4.15
Platform PC
SDK Version 2.16.0
Language C++
Segment VR

Issue Description

For filtering (i.e., post-processing) the depth_frame, why does the following code give random results?

rs2::spatial_filter spat_filter;
rs2::temporal_filter temp_filter;
rs2::disparity_transform depth_to_disparity(true);
rs2::disparity_transform disparity_to_depth(true);
depth_frame = depth_to_disparity.process(depth_frame);
depth_frame = spat_filter.process(depth_frame);
depth_frame = temp_filter.process(depth_frame);
depth_frame = disparity_to_depth.process(depth_frame);

"original depth_frame"
test_depth_t_0000

"filtered depth_frame"
test_depth_f_0000

Thanks.

@dorodnic
Copy link
Contributor

Hi @ywjia

rs2::disparity_transform depth_to_disparity(true);
rs2::disparity_transform disparity_to_depth(true);

One of these needs to be false.
Right now you are transforming to disparity twice.

@ywjia
Copy link
Author

ywjia commented Sep 17, 2018

Thanks, it works now.

@AIBluefisher
Copy link

Thanks, it works now.

Hi, @ywjia
Can you show me your code ? Thanks so much!

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

No branches or pull requests

4 participants