Get depth from dfs
-
Hi, I'm currently working on an application that requires depth information. After configuring voxl-dfs-server I'm able to obtain a good disparity. I compute the depth information as so: depth = focal length*baseline/disparity. The result that I obtain seems wrong by a scaling factor. Focal length and baseline are taken from the calibration file obtained from voxl-calibrate-camera stereo.
Can you share some information on how to perform this operation?
dfs config file:
"dfs_pair_1_input_pipe": "stereo_rear", "dfs_pair_1_skip_n_frames": 1, "dfs_pair_1_blur_size": 9, "dfs_pair_1_post_median_size": 15, "dfs_pair_1_intrinsics_file": "/data/modalai/opencv_stereo_rear_intrinsics.yml", "dfs_pair_1_extrinsics_file": "/data/modalai/opencv_stereo_rear_extrinsics.yml", "dfs_pair_1_en_cvp_rectification": 1, "dfs_pair_1_min_disparity": 4, "dfs_pair_1_max_disparity": 64, "dfs_pair_1_min_threshold": 10, "dfs_pair_1_cost_threshold": 80,
-
@planch98 Have you ever tried to calibrate the camera again to see if the parameters have changed? After calibrating the stereo camera several times, I found that the wrong parameters could be obtained due to inputting the wrong width of the chessboard. By the way, could you please give some suggestions on this issue link text?
-
@cch you can see the code where voxl-vision-hub takes the pointcloud topic from DFS and uses the information, this should be a good reference: https://gitlab.com/voxl-public/voxl-sdk/services/voxl-vision-hub/-/blob/master/src/voa_manager.c?ref_type=heads#L434