I need to get the height from a tin for a given point (or a sequence of points) using the ArcGis Pro SDK.
I successfully created a tin layer with the 3D Analyst Tool "Create Tin" and it looks very good in ArcGis Pro. But now I wonder how it's possible to actually get a height value from this layer? I'm aware of "Intersect3DLineWithSurface_3d" but that seems like overkill and I'd prefer to do it in plain code instead of calling a python function.
Also: Extracting the polygons from the tin via the "TIN Triangle" tool gave me the tin as polygons and I tried to intersect a polygon with a polyline representing a vertical ray.. but I had no success in obtaining the height.
Any help would be greatly appreciated. Thanks!
Solved! Go to Solution.
Sorry, there isn't a TIN specific API call in Pro to do this yet. Therefore, calling a GP tool is probably the way to go. Instead of Intersect3DLineWithSurface look at InterpolateShape, which will produce 3D points from your 2D query locations, or AddSurfacceInformation, which will add a height attribute to your 2D query point features.
We are evaluating TIN API requirements and are seeking input. Aside from spot height query, do you have other needs from a TIN API?
thank you as well for your suggestions. The InterpolateShape_3d tool did work as well but I prefer to do it via the GetZsFromSurfaceAsync-method. Maybe I need to get accustomed to using tools in my c# code first, it doesn't really feel natural to me so far.
Apart from querying the tin for heights at specific coordinates there's not really much I need in a tin API to be honest. Especially since there are already tools like "Decimate Nodes" when working with a tin