ThinkGeo.com    |     Documentation    |     Premium Support

Editing Polylines that Follow Great Circle

Hi,


I have a shapefile that contains polylines that follow GreatCircle.  One of my requirements is to be able to edit these lines and have them continue to follow the GreatCircle.  Is this possible with Map Suite Desktop 3.0?


Thanks!



Clint



Have you taken a look at the Great Circle sample app in MapSuite DesktopEdition 2.0?

The sample uses the MultiLine geometry to create the shape for a line shape. Here's a snippet:



LineMapShape lineShape = new LineMapShape();

// Get shortest path converted to multiline. 

lineShape.Shape = (MultiLine)mPointShape2.GetShortestLineTo(map1.MapUnit, mPointShape1); ;


Taking a look at the Mapsuite DesktopEdition 3.0, I can see similar classes (although no Great Circle sample application yet). Take a look at the MultilineShape class. It also has the "GetShortestLineTo" method.


I'm not sure what format your lines take in the shape file (I haven't done any Great Circle coding myself yet), but if you can get them to MultilineShapes, you might be on the right track for editing.


Hope this helps


 


 



Clint, 



We have the API to get the great circle between 2 points. Here is the code showing how to do it. 



PointShape a = new PointShape(-90.34, 40.45); 

PointShape b = new PointShape(-130.57, 43.73); 

MultilineShape greatCircle = a.GreatCircle(b); 



As we don’t support editing for now, you cannot do it visually with Desktop Edition this version. But you can still see how to make it: every time the point is modified, get the great circle with the above method, and draw it on the map. Editing will be added in the coming releases and that will make it easier. 



Ben. 

 



ok, didn’t see the GreatCircle method:P Good to know it’s there.

Brendan, 
  
 Seems you are a Map Suite 2.0 expert and now becoming a Map Suite 3.0 expert. :)  Thanks for your reply anyway. 
  
 Ben