TheSwamp

Code Red => .NET => Topic started by: nobody on July 22, 2018, 12:15:14 AM

Title: Angle @ Location
Post by: nobody on July 22, 2018, 12:15:14 AM
is there something that will return the angle of a line at a point location?  I thought about drawing a line from the point to, say 0.0001 distance from it and getting the angle of that line, but if there was change at all (as minute as possible as it is) in the bearing of the line it would be wrong.
Title: Re: Angle @ Location
Post by: Atook on July 23, 2018, 01:53:01 AM
A line should have the same angle no matter where the point falls on it?

For polylines, I use the .GetFirstDerivative(point) property.

Lately I cast it to a Curve, and take the derivative of that.
Title: Re: Angle @ Location
Post by: nobody on July 26, 2018, 01:34:46 AM
Thanks atook! that's what I was looking for. Appreciate the help.