Convert 3-D point cloud into organized point cloud
Convert HDL-64E Unorganized Point Cloud into Organized Point Cloud
Load point cloud data into the workspace.
fileName = fullfile(toolboxdir("lidar"),"lidardata","lcc","HDL64", ... "pointCloud","0001.pcd"); ptCloudUnorg = pcread(fileName);
Specify the horizontal resolution of the lidar sensor.
horizontalResolution = 1024;
lidarParameters object that represents an
HDL64E sensor with the specified
params = lidarParameters('HDL64E',horizontalResolution);
Convert the unorganized point cloud into an organized point cloud.
ptCloudOrg = pcorganize(ptCloudUnorg,params);
Display the dimensions of the input point cloud.
ans = 1×2 37879 3
Display the size of the converted point cloud.
pointCloud objects store organized point clouds as M-by-N-by-3 arrays, whereas they store unorganized point clouds as M-by-3 matrices
ans = 1×3 64 1024 3
ptCloudIn — Input point cloud data
Input point cloud data, specified as a