Page 1 of 1

Command line command for creating mesh from point cloud

Posted: Thu Jan 21, 2016 4:39 pm
by ivan-zd
Hello,
I am trying to use CloudCompare command line mode to create mesh from the point cloud file (.ply).
It looks like command line mode of CloudCompare still doesn't support something like Poisson Surface Reconstruction but i see there is this -DELAUNAY option which uses 2.5D Delaunay triangulation. So the command that i run on my Ubuntu (where I've previously compiled latest verision of cloud compare) looks like this:

Code: Select all

/usr/local/CloudCompare/CloudCompare -compute_normals -o data/my_point_cloud.ply -DELAUNAY
When i execute this command i get success message and i see that new .bin file is created in my data folder. However, when I open that file in cloud compare on Linux machine i can't see my triangles. I tried to execute same command on Windows machine and there I can see triangles when i import created .bin file but the mesh is not listed in layer tree and i can't export it to any other format.

Does anybody else have similair experiences here?

Thank you in advance
Ivan

Re: Command line command for creating mesh from point cloud

Posted: Thu Jan 21, 2016 6:16 pm
by daniel
It's been a long time since I tested this option. I'll check it asp!

Meanwhile, can you change the output format to something like PLY, OBJ or STL? (use M_EXPORT_FMT)

Re: Command line command for creating mesh from point cloud

Posted: Mon Jan 25, 2016 8:13 am
by ivan-zd
Hi, I tried with different output formats but it's still always saved as .bin and I am not sure why? This is how my command looks like (in case i want to export it as obj)

Code: Select all

/usr/local/CloudCompare/CloudCompare -compute_normals -o data/my_point_cloud.ply -DELAUNAY -M_EXPORT_FMT OBJ
Did you maybe find time to test it on your side?

Thank you very much
Ivan

Re: Command line command for creating mesh from point cloud

Posted: Mon Jan 25, 2016 8:50 am
by daniel
You have to define '-M_EXPORT_FMT OBJ' before the DELAUNAY command (as commands are executed in the order they appear).

Re: Command line command for creating mesh from point cloud

Posted: Mon Jan 25, 2016 9:36 am
by ivan-zd
Yes, I tried also like that but then it was always complaining about 'incompatible entity/file types' .. I tried both with .las and .ply as source file and i set export format to .obj but it didn't work either way. The only thing that passed is when input and output were defined in same type (.ply) but then the output file didn't have mesh inside, it was again only the point cloud even though i applied delaunay triangulation in command.

Re: Command line command for creating mesh from point cloud

Posted: Mon Jan 25, 2016 9:46 pm
by daniel
Okay, I found the bug. You can now specify an output format other than BIN (and before using the DELAUNAY option).

You can download the latest beta version online (2.6.3).

By the way, the 'compute_normals' option is only used when reading gridded point clouds (PTX, FARO, DP, etc.). Therefore you can drop it.

Re: Command line command for creating mesh from point cloud

Posted: Fri Jan 29, 2016 8:10 pm
by daniel
Oups I just realized the update of the online version was not completed! Now it's ok ;)