Dynamic position plots.

SinbadSinbad Global Mapper UserPosts: 7
edited July 2011 in GPS Features
Hi,

Is it or would it in the future be possible to overlay position information, regularly updated (say every 30-60 seconds) from a URL.

Users could generate the position data in a fixed format (i.e. lat,lon,speed,heading,name etc) via PHP in either XML, JSON, KML , or even as an NMEA ($prave ?) file.

It would be great if GM could visit a URL at set interval to download and display this data. A bit like a web map or moving map.

Example here of XML from Marine Traffic.

marinetraffic.com/ais/getxml.aspx?id=0.7771&sw_x=-6.0&sw_y=50.0&ne_x=-0&ne_y=55.0&zoom=10&fleet=

Is this possible already perhaps ?

Thanks

Comments

  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited June 2011
    With a little bit of programming you could do this yourself using the External Control API in Global Mapper (see http://globalmapper.com/developer/developer.htm#external_ctrl). That would allow you to write a simple application that polls whatever source that you need to at whatever interval you need, then send the updated location to a running instance of Global Mapper for display with a desired symbol.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • SinbadSinbad Global Mapper User Posts: 7
    edited June 2011
    Hi Mike,

    I appreciate the reply, thanks. I'm afraid that that is way beyond my abilities. I may as well be looking into a field as c++ ! I get the theory and could prepare the data server side, but the plugin is tricky. Perhaps somebody else reading this may have done something similar and would be willing to share ?

    Perhaps its time to start learning c++....

    Thanks again.
  • SinbadSinbad Global Mapper User Posts: 7
    edited July 2011
    Hi,

    I successfully managed to hack together some c++ and it's working great. I'm adding point features from dynamic XML. Is there a way to remove points ? I have tried (without success), passing NULL to the function with the same positions.

    GM_Ctrl_SendAddPointMessage(theGMWndHandle,lon,lat,NULL,NULL,NULL,NULL,0,0);

    Or better again is there a way to delete the whole layer ?



    Thanks again.
  • SinbadSinbad Global Mapper User Posts: 7
    edited July 2011
    Hi again,

    Just worked out to use GM_Ctrl_SendDrawSymbolMessage instead of GM_Ctrl_SendAddPointMessage works great. Fantastic !
Sign In or Register to comment.