This routine performs a Voronoi decomposition of an input dataset and constrains the vertices to the input bounded rectangular cuboid domain.
I know that this kind of file already exists, but they had some issues and were not usable for me specific needs. This version works for any type of rectangular cuboid. There are no restrictions for the input seeds: they can be placed far or close from the cuboid domain, inside or outside. The only restriction is that the domain must form a rectangular cuboid.
The file can run as a stand-alone but it would be better to install geom3d toolbox and the function
"mergeCoplanarFaces" used to avoid unnecessary vertices.
Rémy Bretin (2021). 3D_voronoi_cuboid_bounded (https://www.mathworks.com/matlabcentral/fileexchange/74742-3d_voronoi_cuboid_bounded), MATLAB Central File Exchange. Retrieved .
Inspired by: geom3d
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!