Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/3rdParty/_PCL/services/ICP_Simple.jl
Original file line number Diff line number Diff line change
Expand Up @@ -249,11 +249,11 @@ function alignICP_Simple(
#
size(X_fix)[2] == 3 || error(""""X_fix" must have 3 columns""")
size(X_mov)[2] == 3 || error(""""X_mov" must have 3 columns""")
correspondences >= 10 || error(""""correspondences" must be >= 10""")
min_planarity >= 0 && min_planarity < 1 || error(""""min_planarity" must be >= 0 and < 1""")
neighbors >= 2 || error(""""neighbors" must be >= 2""")
min_change > 0 || error(""""min_change" must be > 0""")
max_iterations > 0 || error(""""max_iterations" must be > 0""")
10 <= correspondences || error(""""correspondences" must be >= 10""")
0 <= min_planarity < 1 || error(""""min_planarity" must be >= 0 and < 1""")
2 <= neighbors || error(""""neighbors" must be >= 2""")
0 < min_change || error(""""min_change" must be > 0""")
0 < max_iterations || error(""""max_iterations" must be > 0""")

dt = @elapsed begin
verbose && @info "Create point cloud objects ..."
Expand Down
11 changes: 11 additions & 0 deletions src/3rdParty/_PCL/services/PointCloud.jl
Original file line number Diff line number Diff line change
Expand Up @@ -359,6 +359,17 @@ function PCLPointCloud2(cloud::PointCloud{T,P,R}; datatype = _PCL_FLOAT32) where
)
end

## =========================================================================================================
## Useful utils
## =========================================================================================================


function _filterMinRange(pts, minrange, maxrange)
# filter pointcloud section of interest
msk = findall(x-> minrange < norm(x) < maxrange, pts)
pts[msk]
end


## =========================================================================================================
## Custom printing
Expand Down