8

Using the filter Sampling->Hausdorff Distance in MeshLab I computed the distance between a mesh and a target mesh.

How can I save the point to point distance and render it on a heat map or a plot it on a Histogram?

Rockcat
  • 3,002
  • 2
  • 14
  • 28
Fakher Mokadem
  • 1,059
  • 1
  • 8
  • 22

1 Answers1

10

You can do it easy if you use the filter "Distance from reference mesh" instead of "Hausdorff Distance". That filter will leave the distance as a quality on each vertex of the Measured mesh.

After that, you can colorize the mesh using the filter "Colorize by vertex Quality" or save the mesh to plot the distances outside of meshlab. The recommended file format is Stanford Polygon File Format .ply, and ensure "Quality" checkbox is checked and "Binary encoding" is not checked. The output file has a 11 lines header and then a list with 4 numbers, XYZ and quality (which is the distance you are looking for your plot)

0 -2 0 1.902114 
0 2 0 1.902113 
1 -2 0 1.701302 
0.9848077 -2 0.1736482 1.714225 
0.9396926 -2 0.3420202 1.722303 
Rockcat
  • 3,002
  • 2
  • 14
  • 28
  • I am very new to Meshlab. I was able to follow your steps up until "Colorize by vertex quality" but I when I tried exporting the mesh, I did not see any checkboxes related to "Quality" nor "Binary encoding". What did I miss? – useryk Feb 17 '21 at 15:05
  • Probably, you are exporting your mesh to a file format different of the recommended "Stanford Polygon File Format .ply". For example, if you save as .obj file format you can't include the quality values in the file. – Rockcat Feb 17 '21 at 17:35