Page 1 of 1

Setting scalar field by many polyline segments

Posted: Wed Nov 13, 2024 7:36 pm
by RyeK
I am attempting to simplify the process of separating a cloud by many closed polyline areas.
I have a python script to iteratively segments a cloud using crop2D however this is extremely inefficient and not a feasible solution for the cloud size or number of polylines required.
The GUI segment function allows you to segment or set a SF class of the points within the selected polyline, however this only works on one individual polyline at a time. Is there a way to perform this, or a similar function, on many polyline areas at once. Open to any GUI/LCI/python solutions.
Having a result with a separate cloud of segmented areas or a scalar field to classify the areas are acceptable results, open to other suggestions that give a similar affect.

Re: Setting scalar field by many polyline segments

Posted: Thu Nov 14, 2024 5:02 pm
by daniel
Well, I guess the 'fastest' (keeping the CloudCompare's code involved) is to call the ccGraphicalSegmentationTool::segment method.

Not sure if that's possible with either of the Python wrappers (CloudCompy or the Python plugin).

And you could make it more efficient by hacking the C++ code (or developing your own small plugin ;).