Hello CloudCompare community,
I have a few hundreds of point clouds (ASCII ply) that I want to convert to .xyz files.
These clouds contain a lot of informations (points, colors, normals etc), and I want to keep only the points and normals while converting them.
A simple and nice way I found to do it, is, while loading the point cloud on CC, to keep only the points and normals, and then export it as an ASCII .xyz file. However, I'm not going to do that for hundreds of clouds.
So, as I know that CC is scriptable (http://www.cloudcompare.org/doc/wiki/in ... _line_mode), my question is:
How, in command line, can I choose to load only the points and normals, and not the whole cloud?
Thanks in advance!
Scripting CloudCompare - Choose which parts of the cloud to load
Re: Scripting CloudCompare - Choose which parts of the cloud to load
Hum, that's not possible directly via the command line. Maybe one trick would be to use the 'PN' format as intermediate format (as it only contains points + normals). Save your cloud to PN, reload it from PN, and save it to xyz? (use the -C_EXPORT_FMT option).
Daniel, CloudCompare admin
Re: Scripting CloudCompare - Choose which parts of the cloud to load
Thank you very much for the trick!
However, I have a problem while storing files via command line,
I want to specify the name of the stored file, but when I use the "FILE" option of the "SAVE_CLOUDS" command, I have the following error:
"Command expected (commands start with '-'). Found 'FILE'"
The command I used are:
CloudCompare -O myFile.ply
CloudCompare -C_EXPORT_FMT pn
CloudCompare -SAVE_CLOUDS FILE "/my/path/to/file.pn" <--- error is here
The command seemed ok from the documentation pov, but maybe I misunderstood something,
Do you have any idea why this occurs?
PS: I forgot to precise that I'm working with CC 2.9 beta
However, I have a problem while storing files via command line,
I want to specify the name of the stored file, but when I use the "FILE" option of the "SAVE_CLOUDS" command, I have the following error:
"Command expected (commands start with '-'). Found 'FILE'"
The command I used are:
CloudCompare -O myFile.ply
CloudCompare -C_EXPORT_FMT pn
CloudCompare -SAVE_CLOUDS FILE "/my/path/to/file.pn" <--- error is here
The command seemed ok from the documentation pov, but maybe I misunderstood something,
Do you have any idea why this occurs?
PS: I forgot to precise that I'm working with CC 2.9 beta
Re: Scripting CloudCompare - Choose which parts of the cloud to load
Oh, this version is too old indeed. Why not moving to 2.10 or even 2.11.alpha?
Daniel, CloudCompare admin
Re: Scripting CloudCompare - Choose which parts of the cloud to load
Thanks daniel, I upgraded to v2.11.alpha, but now I keep getting "[ERROR] Unhandled format specifier (PN)" errors,
Is it that pn is not supported anymore?
Is it that pn is not supported anymore?
Re: Scripting CloudCompare - Choose which parts of the cloud to load
Hum should be... Do you have the "Additional IO" plugin? (Help > About plugins)
Daniel, CloudCompare admin