marian42 / mesh_to_sdf

Calculate signed distance fields for arbitrary meshes
https://pypi.org/project/mesh-to-sdf/
MIT License
991 stars 107 forks source link

will the sample_sdf_near_surface normalize the mesh to a unit sephere? #33

Closed xinwei-zhuang closed 2 years ago

xinwei-zhuang commented 2 years ago

I read in the code that the sample_sdf will use the points that are sampled from sample_uniform_points_in_unit_sphere, however, I would like to keep the original mesh's vollumetric data (such as height, width..) and the mesh size is various a lot. Do you think I can use a fixed sphere to sample all points? Many thanks!

xinwei-zhuang commented 2 years ago

sorry after a second reading, I have two options, one is to set bounding_radius for all obj files, the other is to set a point array and calculate SDF directly from that point array.