D455 - Strange deph measure when use depth to disparity
Hi,
for experimentations, I must use poor and extremely smooth depth data image.
For this, i've ajusted my JSON file, and some C++ parameters.
But when i use depth to disparity,
rs2::disparity_transform depth2disparity(true);
...
measure = frame.get_distance(x, y)
my measures is very big ! Why ? Can you explain me ?
I explain you my problem in 4 steps :
1 - My scene (Lyon 3th - FRANCE)
2 - Without depth to disparity (false)
Image + deph data measures are ok.. But it's not that i want

3 - With depth to disparity (true)
My colored frame it's that i want !! But measures on my depth frame is very strange. 7772050 meters.. measures is very buggy !

4 - Code
s2::decimation_filter dec_filter(4);
rs2::spatial_filter spat_filter(0.25f, 50, 5, 0);
rs2::temporal_filter temp_filter(0.3f, 20, 3);
// True : Bitmap OK. Depth measures BUGGY.
// False : Bitmap NON OK. Depth measures OK.
rs2::disparity_transform depth2disparity(true);
// Wait frames
rs2::frameset frames = instance_pipeline.wait_for_frames();
rs2::frame image_frame = frames.get_depth_frame()
.apply_filter(temp_filter)
.apply_filter(dec_filter)
.apply_filter(depth2disparity) // true
.apply_filter(spat_filter)
.apply_filter(aligner)
.apply_filter(couleur_depth);
rs2::depth_frame depth_frame = frames.get_depth_frame()
.apply_filter(temp_filter)
.apply_filter(dec_filter)
.apply_filter(depth2disparity) // true
.apply_filter(spat_filter);
Thank a lot!
-
The SDK's post-processing documentation recommends that depth2disparity is applied after the decimation filter and before the spatial filter. The link below provides the recommended order of applying each filter type.
I would also recommend removing the second round of filter application at the bottom of the script to see if your results improve.
Please sign in to leave a comment.
Comments
2 comments