Closed ufrhaidar closed 4 months ago
Hi, this sounds like an interesting and useful addition to UniformSampling
. However, I have a few comments:
unsigned int
for count
in Leaf
output
has to be resized again based on how many points are actually added. Otherwise, output
may have some uninitialized points at the endmin_points_per_voxel_
because no centroid is computedThanks for the comments.
The output.width = output.size ();
i removed wasn't necessary as the output.resize() function was already doing that here
Description
This pull request modifies the
UniformSampling
filter to include amin_points_per_voxel_
filter. This allows users to specify a minimum number of points that a voxel must contain to be included in the output.These changes allow users to filter out voxels that contain too few points, which can be useful in situations where such voxels are likely to be noise.