[mapguide-users] Re: How to realize the dynamic segment function in MGOS?

Jackie Ng jumpinjackie at gmail.com
Tue Jun 14 03:06:57 EDT 2011


A high-level process flow would be something like this off the top of my
head:

Create a MgCoordinateSystem object from the SRS of your MgMap

With the MgGeometry instance in question (representing the highway), start
from the first coordinate and use the measuring functionality of your
MgCoordinateSystem to measure the distance between each coordinate, tallying
up the running total distance. Once this running total distance passes
22.3km, measure the distance between the current coordinate and the
previously sampled one to determine which coordinate is closest to the
22.3km mark. The coordinate closest to this mark would be the coordinate you
are after.

- Jackie

--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/How-to-realize-the-dynamic-segment-function-in-MGOS-tp6472870p6472985.html
Sent from the MapGuide Users mailing list archive at Nabble.com.


More information about the mapguide-users mailing list