Global Mapper Pro Coming Soon

kml export precision == only ten decimal places?

J.M. SchomburgJ.M. Schomburg Global Mapper UserPosts: 3
edited March 2011 in Technical Support
Hello,

I'm presently putting together a project using the Google Maps API, and I have access to a highly precise data source (the topography of the City of Paris). A KML export goes well (all the polygons are rendered correctly), but I have one problem with the resulting precision: all decimal values are truncated to ten decimal places, which results in a sometimes sloppy rendering for objects needing extreme detail (like walls and stairs).

Is there any way to increase the precision of KML output, say, to fourteen or eighteen decimal places? This requirement is essential if I am going to use your application in a production environment.

Thanks very much in advance for any insight.

Comments

  • redbeardredbeard Global Mapper User Posts: 279Trusted User
    edited March 2011
    I think 8 decimal places is about millimeter precision. 1 degree at equator is 110574 meters...I may have made a mistake, but
    Degree - Meters - Precision
    0 - 110574 - 100 KM
    0.1 - 11057.4 - 10 KM
    0.12 - 1105.74 - Kilometer
    0.123 - 110.574 - 100 meter
    0.1234 - 11.0574 - Decameter
    0.12345 - 1.10574 - Meter
    0.123456 - 0.110574 - Decimeter
    0.1234567 - 0.0110574 - Centimeter
    0.12345678 - 0.00110574 - Millimeter
    0.123456789 - 0.000110574 - Tenth of a Millimeter
  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited March 2011
    I agree with redbeard's assessment, you should already be getting sub-millimeter precision from 10 decimal digits of precision in the KML export. I think that perhaps Google Earth is limiting precision, but you could tell by loading an exporting KML file back into Global Mapper and seeing if the full precision is preserved there.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • redbeardredbeard Global Mapper User Posts: 279Trusted User
    edited March 2011
    Not to mention, the positioning of the imagery on Google Earth is not that precise.
  • J.M. SchomburgJ.M. Schomburg Global Mapper User Posts: 3
    edited March 2011
    I can tell you that Global Mapper's mapping of coordinates to KML is better than Google's Fusion Tables' engine - the latter trunciates everything to six decimal places (or, according to the logic cited so kindly above, to the nearest decimetre). This is crucial for the mapping of walls and stairways that are sometimes even less than a decimetre in width.

    As for positioning, I get almost the exact same displacement factor when projecting onto Google maps and OpenStreetmap data - do both use Mercator projection now? But I digress.

    Thank you for your kind replies.
  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited March 2011
    The Google Maps and OpenStreetMap tiled sources are both based on the Web Mercator projection.

    If you load your KML file back into Global Mapper is the full resolution displayed there? If so that would confirm that indeed the resolution limit is indeed in Google Earth/Google Maps and not in Global Mapper. I wouldn't be surprised if the KML decimal degree coordinates are converted either to single-precision floating point values or to 32-bit scaled integers to reduce memory requirements, although this would limit your precision from the full double-precision coordinates that Global Mapper uses.

    Let me know if I can be of further assistance.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
  • J.M. SchomburgJ.M. Schomburg Global Mapper User Posts: 3
    edited March 2011
    I'll try to reload the kml into Global Mapper tomorrow - but as far as what I've seen (through a kml-parsing script I used to load coordinates into Google Fusion Tables in bypassing their default kml 'import' engine) the results seem to be satisfactory. I'll let you know as soon as I make it to the 'walls and fences' level - these are coordinates precise to the centimetre, and if these are a bit off the results will be visible right away.

    For a bit more clarity, the city of Paris has recently made public all the architectural data pertaining to the city (streets, buildings, addresses, even trees), but these files are extrememly precise (and heavy!); for the time being, I'm just seeing what tools there are to deal with that sort of data, and Global Mapper is the best I've found thus far. If you would like to see a version of my WIP, I can send you a pm with a link: what you'll see there is my work with Cartographica (as I'm on a Mac platform), but their polygon export method, through kml, leaves much to be desired - you will see that 'nested polygons' are exported in a way inexploitable by Google.

    Google Fusion tables, with which I am attempting to use to render map data, has yet many limitations - namely their coordinate 'simplification' and inability to map more than 100,000 objects at a time - so at present I am trying Global Mapper's Google tile export method. Although the execution is efficient, I find that the resulting .png images are rather jagged and blocky compared to Google's rendering, limited as it is.

    It would be a pleasure for me to work, through my 'high-level' experimentation, with your development team; your product is the best I've seen so far.

    Best, and thank you so much for your reply,

    Josef.
  • global_mapperglobal_mapper Administrator Posts: 17,238
    edited March 2011
    Josef,

    The Google Maps tile export resolution is going to be determined by what zoom level you export too, although the max Google Map pre-rendered tile resolution won't approach centimeter resolution. If you can however directly use a KML export from Global Mapper that should maintain the desired resolution.

    Thanks,

    Mike
    Global Mapper Support
    support@globalmapper.com
Sign In or Register to comment.