milgraphics icon indicating copy to clipboard operation
milgraphics copied to clipboard

Add input format SLF

Open spatialillusions opened this issue 7 years ago • 3 comments

Because it was an easy way to get access to some sample data I made a parser for SitaWare SLF files. Can't read all location types yet, but working on it and it works for all points, lines, and polygons. (And some mulitpoint symbols.)

spatialillusions avatar Mar 09 '17 19:03 spatialillusions

can you add example of SitaWare SLF file to you sourse code?

yevhenii-username avatar Mar 15 '17 13:03 yevhenii-username

I will see if there is any sample data I can include. The main input format for the library is however plain GeoJSON, and hopefully I will be able to create a draft of the format specification within a week or so. What the SLF parser does is to parse a SLF file from XML to GeoJSON and then input it into the library.

If you have a GeoJSON file that has points with an attribute called SIDC you can simply provide that directly into ms.GraphicsLayer(GeoJSON).

It is also possible to use ms.format.GeoJSON(geojson, mapping) to remap attributes to new attribute names.

spatialillusions avatar Mar 15 '17 17:03 spatialillusions

great work, thanks a lot!

yevhenii-username avatar Mar 16 '17 07:03 yevhenii-username