Getting elevated point details (x and y) in a given area.
mg.srikanth
Global Mapper User
Hi,
How do I get the most elevated point (x and y)/(lat-lon) in a given area (circle or polygon) or in a given line?
I could draw view shed analysis on the map with the help of TestViewShedCalculation function provided in the sample app. I require to draw the visible area and invisible area of view shed analysis in two different colors (eg. RED for visible and Green for invisible i.e. drawing entire circle), how do i do this?
How do i draw the LOS profile? How do i draw it on map with RED/GREEN colors indicating visible and invisible portion on the map?
Plz help.
Srikanth.
How do I get the most elevated point (x and y)/(lat-lon) in a given area (circle or polygon) or in a given line?
I could draw view shed analysis on the map with the help of TestViewShedCalculation function provided in the sample app. I require to draw the visible area and invisible area of view shed analysis in two different colors (eg. RED for visible and Green for invisible i.e. drawing entire circle), how do i do this?
How do i draw the LOS profile? How do i draw it on map with RED/GREEN colors indicating visible and invisible portion on the map?
Plz help.
Srikanth.
Comments
-
You could use GM_CalcAreaElevStats to get the stats for elevations in an area feature. That doesn't currently store the location of the highest elevation, but I could easily add that. For a line you would use the GM_GetPathProfileLOS function.
To get the view shed in 2 different colors you would basically have to run it twice, one with mShowHiddenPoints in the GM_ViewShedParams_t set to TRUE and again with it set to FALSE and with different mColor values each time.
For the LOS profile there isn't really an easy way to draw the line on the map with the blocked part colored differently. If the LOS is clear then the points can be seen from each other, if it is not clear then they can't be seen. The view shed would be more appropriate to see exactly what is visible from a point rather than just checking visibility between 2 points. You could simulate a line I guess by doing a very small width view shed beam in the direction between two points, then again in the reverse direction, but that is kind of clunky.
Thanks,
Mike
Global Mapper Guru
gmsupport@bluemarblegeo.com
http://www.globalmapper.com -
Thank you Mike,
For a view shed analysis my application is taking half a minute with default values, if i run the view shed again to draw a full circle with another color then it will take another half minute, total of 1 minute will be consumed. Is there any technique to minimize the time?
Srikanth. -
What you could do after running it once is run build your own in-memory raster that you build by scanning through all of the samples in the view shed layer using GM_GetPixelColor. If that returns an error then the pixel is not covered and you can fill it with green, otherwise fill it with the front color. You would also need to check to make sure the pixel is in the radius. Once you have your in-memory raster layer then use GM_CreateCustomRasterLayer to create a new image layer from the in-memory color array.
Thanks,
Mike
Global Mapper Guru
gmsupport@bluemarblegeo.com
http://www.globalmapper.com
Categories
- 12.7K All Categories
- 5.6K Features Discussion
- 342 Downloading Imagery
- 1.3K Elevation Data
- 380 Georeferencing Imagery Discussion
- 628 GM Script Language
- 53 User Scripts
- 113 GPS Features
- 414 Projection Questions
- 819 Raster Data
- 1.3K Vector Data
- 6.6K Support
- 177 Announcement and News
- 908 Bug Report
- 558 SDK
- 1.2K Suggestion Box
- 3.7K Technical Support
- 562 Other Discussion
- 129 GIS Data Sources
- 27 Global Mapper Showcase
- 233 How I use Global Mapper
- 107 Global Mapper Forum Website