Hi! I have to select in Unity 4 points of my point cloud. This selection must return a surface to me. How can I do this? Thanks for the help,Hi, I have to select in Unity 4 points of my point cloud. This selection must return a surface to me. How can I do this? Thanks for the help
this is a bit difficult to answer. In general 3 points define a plane or surface. Any other point then has to be checked if it is on that defined surface. Now the this in general is a complex calculation and we could need some more info on this.
Where is the pointcloud from? If you say that you want a “surface” of 4 points - is there any other constraint? Can you guarantee that this 4 point plane/surface exist? What amount of tolerance do you give here? Due to floating point imprecision it is probable that you will never find 4 points which are mathematically exactly on the same plane.
If you already want to do some reading and so on on your own i’d suggest you read into how you define a plane from 3 points in math and how you can calculate the distance of a point from that plane. Example for how-to-distance-calculation
then when you have implemented that it would only be necessary to iterate over all your points to check on all possible groups of points if they satisfy the constraint given in your distance calculation.
At the start I asked how many points you have. → the complexity of this problem scales exponentially → depending on how many points there are in your cloud this might take a really really long time to calculate.