Releases: Outdooractive/gis-tools
v1.11.0
v1.10.0
-
Added a shortcut to
Coordinate3D
:func mapTile(atZoom zoom: Int) -> MapTile
-
Added methods to
GeometryCollection
,MultiLineString
,MultiPoint
andMultiPolygon
for adding/removing objects (like they already existed inFeatureCollection
) -
Improved bounding box handling
This version now not only updates bounding boxes for the outermost container object, but also updates the bounding boxes for all contained objects.
So, when you did this before:
let multiPolygon = MultiPolygon([...many polygons...])
let featureCollection = FeatureCollection([multiPolygon])
featureCollection.updateBoundingBox()
... only the bounding box of the featureCollection
was updated which was a problem if you had e.g. a country MultiPolygon with many non-overlapping polygons and did many featureCollection.contains(coordinate)
checks.
So if the coordinate was inside the FeatureCollection, all the polygons where still checked separately.
Now, updateBoundingBox()
will also update the bounding boxes for contained objects in GeometryCollection
, FeatureCollection
, MultiLineString
, MultiPoint
and MultiPolygon
which will speed up certain checks considerably.
v1.8.5
v1.8.3
v1.8.2
v1.8.1
v1.8.0
v1.7.1
v1.7.0
Always include the m value of Coordinate3D in JSON
The m
value of Coordinate3D
will now always be includeded in the JSON dump of a coordinate. This means that a null
value will be added for the altitude
if the coordinate's altitude
is nil
.
let coordinateM = Coordinate3D(latitude: 15.0, longitude: 10.0, altitude: nil, m: 1234)
let coordinateDataM = try JSONEncoder().encode(coordinateM)
print(String(data: coordinateDataM, encoding: .utf8)) // [10,15,null,1234]