k***@gmail.com
2013-11-30 14:44:59 UTC
Hello,
I try to calculate the distance between a 3D cylinder to a 3D planar triangle. I found some implementations regarding line segment to triangle (http://www.geometrictools.com/LibMathematics/Distance/Distance.html) and distance between cylinder and point (http://liris.cnrs.fr/Documents/Liris-1297.pdf) - However, I have problems to find a good solution to calculate the distance between a cylinder and a triangle. My first idea was to calculate the distance segment to triangle and to substract the radius of the cylinder. But this would create spherical ends rather than discs on the cylinder. I found also algorithms to calculate the intersection of cylinder and triangle (http://www.geometrictools.com/LibMathematics/Intersection/Intersection.html). But to extend this to distance rather than intersection doesn't seem to be straight forward.
I wonder whether there is acutally a solution to my problem or if this problem cannot be solved without approximation.
I would be thankfull for any help,
Konrad
I try to calculate the distance between a 3D cylinder to a 3D planar triangle. I found some implementations regarding line segment to triangle (http://www.geometrictools.com/LibMathematics/Distance/Distance.html) and distance between cylinder and point (http://liris.cnrs.fr/Documents/Liris-1297.pdf) - However, I have problems to find a good solution to calculate the distance between a cylinder and a triangle. My first idea was to calculate the distance segment to triangle and to substract the radius of the cylinder. But this would create spherical ends rather than discs on the cylinder. I found also algorithms to calculate the intersection of cylinder and triangle (http://www.geometrictools.com/LibMathematics/Intersection/Intersection.html). But to extend this to distance rather than intersection doesn't seem to be straight forward.
I wonder whether there is acutally a solution to my problem or if this problem cannot be solved without approximation.
I would be thankfull for any help,
Konrad