commandline _Remove SF, not enough SF

If you are allergic to bug trackers, you can post here any remarks, issues and potential bugs you encounter
Post Reply
PablerasBCN
Posts: 296
Joined: Sat Jan 20, 2018 1:57 pm

commandline _Remove SF, not enough SF

Post by PablerasBCN »

Hi,

I think I found a silly bug.

In a file fin 10 SF, if I attemp to remove 6 or more, commandline will complaint.

command:

for %%f in (E:\LIDAR_JAPAN\MMS8\MMS\_00_ORIGINAL_PCV\08OE2713.las) DO "C:\Program Files\CloudCompare\cloudcompare.exe" -SILENT -O -GLOBAL_SHIFT AUTO %%f -AUTO_SAVE OFF -C_EXPORT_FMT LAS -REMOVE_SF 1 -REMOVE_SF 2 -REMOVE_SF 3 -REMOVE_SF 4 -REMOVE_SF 5 -REMOVE_SF 6 -SAVE_CLOUDS

I think that what happens is that it check the remaining SF's count which after each command seems to go lower, so when trying to delete 6th, having removed 5 out of 10 it complaints, yet, until 5th it removes properly the SF pointed ( I tried several times in a row _SF1 and does not work) so somehow the data seems stored in an array fed openning yet the count variable seems to update on each removal. May be it would need to check against the data holding array's count. Or resize array on each iteration. I'm speaking without knowing the code, but I think makes sense. :D

Image

Image
daniel
Site Admin
Posts: 7710
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: commandline _Remove SF, not enough SF

Post by daniel »

With the -REMOVE_SF command, you provide the SF index (starting from 0).

After having removed 5 scalar fields, only 5 scalar fields remain. So from index 0 to 4. Hence it's not possible to remove index '6'.

What you try to do is probably '-REMOVE_SF 0 -REMOVE_SF 0 -REMOVE_SF 0 -REMOVE_SF 0 -REMOVE_SF 0 -REMOVE_SF 0' (a 'pop front' operation, 6 times).
Daniel, CloudCompare admin
PablerasBCN
Posts: 296
Joined: Sat Jan 20, 2018 1:57 pm

Re: commandline _Remove SF, not enough SF

Post by PablerasBCN »

thank you, I would say I had already tried several with same number and only one was deleted, may be I opened the wrong file.

Anyways after clarifying by you that due to format specifics, eliminating SF does not impact size in many cases, removing SF has lost atractive, yet it could be interesting to keep things more tidy in the dropdown.
Post Reply