Select Point Cloud from Depth Map

Function

This Procedure selects a 2D ROI on the original depth map, and then converts the depth map in the 2D ROI to the point cloud to facilitate further calculation.

Usage Scenario

This Procedure is usually used in the measurement scenario for large workpieces. Usually, the Capture Images from Camera Step is used before this Procedure to obtain the depth map, and the Extract Planar Point Clouds Procedure follows this Procedure to convert the point cloud to planar point cloud.

Input and Output

../../../../_images/select_point_cloud_from_depth_map.png

Parameter Description

Segment Depth Map

The following parameters are used to segment the depth map to obtain the desiried point cloud.

Max Height Diff between Neighbouring Pixels:
Parameter description: In the process of segmenting the depth map, this parameter specifies the maximum height difference between neighbouring pixels. If the height difference between two pixels is smaller than this value, the two pixels belong to the same area. The larger the value, the more the segmented area.
Default value: 0.5 mm
Tuning recommendation: If you want to segment a depth map of a flat surface, you can adjust the value to a larger value. However, an overly large value may lead to overly small segmented areas and no valid point cloud will be output. If you want to segment the depth map of a curved surface or threaded holes, you can adjust the value to a smaller value to avoid a loss of desired point clouds. If the point clouds are closely adjacent to each other, adjusting the value may not be able to remove the unwanted point cloud.
Min Segment Area:
Parameter description: This parameter specifies the minimum area of the segmented depth map. Segmented depth map with pixels less than this value will be removed. The smaller the value, the more the segmented area; the larger the value, the larger the removed area.
Default value: 1500 px
Depth ROI File Name:
Parameter description: This parameter is used to select an ROI on the depth map.
Tuning recommendation: Click Set 2D ROI to select an accurate 2D ROI.

Get Highest Layer Regions in Depth Map

Layer Height:
Parameter description: After the depth map is converted to the point cloud, this parameter specifies the distance (unit: m) between the camera and the planar point cloud along the Z-axis in the camera reference frame. The larger the value, the more point cloud will be kept.
Default value: 0.01 m
Tuning recommendation: When the point cloud of the object to be measured has multiple layers, you can adjust this value to obtain the desired point cloud.