Page 1 of 1
Can't flip normals in C2M-Distance
Posted: Sun Dec 20, 2020 9:58 am
by michaeladamsen
I am having some problems with flipping the normals in the C2M-distance menu. It is not possible to check the checkbox saying "flip normals". Do any of you have an idea why this happens? I am calculating distances between a point cloud and a fitted plane.
Re: Can't flip normals in C2M-Distance
Posted: Mon Dec 21, 2020 11:24 am
by michaeladamsen
Here is some additional info: I tried to use the tool next to C2M, called "Calculate Distance to primitive". I thougt it was appropriate since I was dealing with a fitted plane between 4 points. In this menu it was possible to check the "Flip normals" option, and afterwards I compared the results with the C2M-results.
If i did not check the "Treat planes as bound" option I found a difference of 7 mm between the mean values in Stat Param. The standard deviation however, was not affected.
If i did check the "Treat planes as bound" option, I got the same result as the C2M-distance tool, which is great, because that was what I was looking for.
However, I am still curios what the difference is between the C2M-distance tool and the "Calculate Distance to Primitive"-tool, and I havent been able to find information on this topic on the wiki. Do they use the same method to calculate the distance to the pointcloud? And what does the "treat planes as bound"-option actually do? In which situation would you prefer not to check that option?
Re: Can't flip normals in C2M-Distance
Posted: Mon Dec 21, 2020 12:25 pm
by daniel
So for the C2M dialog, it was a bug (the code to activate the 'flip normals' checkobx disappeared apparently?!)
Normally, the 'Compute distance to primitive' tool uses the underlying primitive equation to compute the distance, and not the mesh (triangles) that are used to represent the primitive. This will give you a slightly more accurate result, especially for curved primitives (sphere, cylinder, etc.). Without requiring you to increase the number of triangles (= primitive resolution).
Re: Can't flip normals in C2M-Distance
Posted: Mon Dec 21, 2020 12:26 pm
by daniel
I updated the 2.12.alpha version online to fix the 'flip normals' bug.
Re: Can't flip normals in C2M-Distance
Posted: Tue Dec 22, 2020 8:26 pm
by WargodHernandez
just for your awareness the "Treat planes as bound" checkbox will make the calculations to the plane primitive either work based on the visible bound plane (bound by the width and height specified on the plane) or it will treat the plane as an infinite plane
Here is the same cloud and plane measured both ways, the plane was created by fitting a plane and then reducing the width and height to be smaller than the overall cloud. in the unbound version you will get the same result as the original plane before its size was reduced.
in other words when bounded the distance is to the rectangle defined by the plane and the width/height, where the unbounded it directly calculates directly against the plane equation
Code: Select all
plane equation: [a,b,c,d] as 'ax+by+cz=d' with norm(a,bc)==1