How to query DTED offline using ArcGIS .Net SDK?

1155
3
12-08-2016 03:08 PM
Highlighted
New Contributor

Our application needs to do some elevation calculations (and is not connected to the internet), as a result we need to determine the highest elevation for a given polygon. How can we query DTED offline using ArcGIS .Net SDK?

Option 1 - Use Esri.ArcGISRuntime.Controls.FileElevationSource

So in order to use FileElevationSource it turns out it must be associated with a SceneView. We were only using a MapView so I added in a SceneVeiw and associated the FileElevationSource

sceneView.Scene.Surface.Add(elevationSource);W

When I tired to access the elevation source I get an AccessViolation

elevationSource.GetElevationAsync(location as MapPoint).Result

Option 2 - Some how use LocalServer

The doco states that ArcGIS Runtime LocalServer support a number of Raster formats including DTED.

Local Server raster support—ArcGIS Runtime SDK for .NET | ArcGIS for Developers 

So I use ArcMap to create a map package file with the DTED files within but have no idea how to use Local Sever to query the package file 

Ultimately we want to:

1) Load a number of DTED files  

2) Query for a given lat/lon what the elevation is at that point

Any help would be greatly appreciated!

Note we are using .Net Runtime SDK v10.2.7

Reply
0 Kudos
3 Replies
Highlighted
New Contributor III

I have similar goals but we are using v100.0 (Quartz). Did you ever figure this one out?

Reply
0 Kudos
Highlighted
New Contributor

I have a similar if not the exact same error "AccessViolation" when using the GetElevationAsync funciton.  Has anyone had any luck resolving this Error?

Here are my current post on my error and the access violation i was having.  We only see this issue when we are using prism and the SceneView is in its own module.  With a stand alone wpf application the GetElevationAsync funtion call works fine.

access violation with GetElevationAsync(mapPoint) when using Prism 

c# - Prism and Esri GetElevationAsync(mapPoint) - Stack Overflow 

 

Reply
0 Kudos
Highlighted
New Contributor III

Here is a thread describing how to get Elevation from DTED. We got it working successfully using the info from the thread:

https://community.esri.com/message/674346-re-dted-as-a-local-elevation-source-net-wpf-v1000?commentI... 

Reply
0 Kudos