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
How to get stable depth image with align and post-processing? #2157
Comments
Are you filtering the depth image or the aligned depth image? |
If I do alignment before, I filter the aligned depth image. I'll try to post the code soon. |
`
` |
BTW, my working distance is about 500mm |
[Realsense Customer Engineering Team Comment] The align instance keep re-instantiating inside the loop cause the application slow down and you will see the flicker effect in the colorized depth map, you can just simply move instantiation outside the loop, then you should see consistent colorized depth map. I also suggest you to move filters into thread or processing block. For thread way you can refer to rs-post-processing.cpp, I post the processing block way code below for your reference.
|
As suggested, I moved the align object outside of the loop, but I could not notice any improvement. I can post videos of the depth image if needed. |
[Realsense Customer Engineering Team Comment] |
Yes, I ran your code and the results are about the same. Still shaky, not stable. |
@RealSense-Customer-Engineering |
[Realsense Customer Engineering Team Comment] |
Our computers run the Realsense viewer with no problem. When we set the depth units to 0.0001 we get a nice, stable depth image that's a huge improvement over before. The problem is in our custom code when we add alignment, the old shakiness reoccurs. If you run the code you wrote above with alignment and preprocessing and depth units to 0.0001, you should see it. There is no option in Realsense viewer to add alignment, correct? I have run it on 2 computers with the same result. A Dell laptop with an Intel i7-7700HQ CPU @ 2.80 GHz 4 physical cores and 8 logical cores. Our program runs with alignment and preprocessing it only uses 20% of the CPU according to task manager. Realsense viewer only uses 11% CPU. The other is a Gigabyte PC with an Intel i7-4790 @ 3.6 Ghz. The output from your bag file is very similar to our output from our Realsense viewer. It's just in custom code when adding alignment and preprocessing, that the shakiness returns. |
[Realsense Customer Engineering Team Comment] |
We have a similar problem. Any updates? |
[Realsense Customer Engineering Team Comment] |
The CUDA code in the latest drivers produce a slightly better depth image. The best way is to redesign your code to use the unaligned color and depth images and then align as necessary later. |
I get a nice stable depth image in Realsense viewer with depth units 0.0001 and post-processing enabled. I can do the same in my code, but when I add alignment either before or after post-processing, the depth image becomes much more shaky, almost like the post-processing is not applied. Is there anyway to add alignment and post-processing and still get a nice stable depth image?
The text was updated successfully, but these errors were encountered: