Mapbox GL v1.6.0 Release Notes

Release Date: 2020-04-30 // about 4 years ago
  • ๐Ÿฑ โœจ New features

    ๐Ÿ‘ [core] Add support for Polygon, MultiPolygon geometry types in distance expression. (#16446)

    โšก๏ธ [core] Introduce Source::setMinimumTileUpdateInterval API (#16416)

    โšก๏ธ The Source::setMinimumTileUpdateInterval(Duration) method sets the minimum tile update interval, which is used to throttle the tile update network requests.

    โšก๏ธ The corresponding Source::getMinimumTileUpdateInterval() getter is added too.

    โšก๏ธ Default minimum tile update interval value is Duration::zero().

    [core] Indroduce distance expression. (#16397)

    โœ… The distance expression returns the shortest distance between two geometries. The returned value can be consumed as an input into another expression for changing a paint or layout property or filtering features by distance.

    ๐Ÿ‘ Currently, the distance expression supports Point, MultiPoint, LineString, MultiLineString geometry types.

    ๐Ÿ’… [core] Introduce style::Source::setVolatile()/isVolatile() API (#16422)

    The Source::setVolatile(bool) method sets a flag defining whether or not the fetched tiles for the given source should be stored in the local cache.

    The corresponding Source::isVolatile() getter is added too.

    0๏ธโƒฃ By default, the source is not volatile.

    ๐ŸŽ [ios, macos] Allow specifying multiple fonts or font families for local font rendering (#16253)

    0๏ธโƒฃ By default, CJK characters are now set in the font specified by the text-font layout property. If the named font is not installed on the device or bundled with the application, the characters are set in one of the fallback fonts passed into the localFontFamily parameter of mbgl::Renderer::Renderer() and mbgl::MapSnapshotter::MapSnapshotter(). This parameter can now contain a list of font family names, font display names, and font PostScript names, each name separated by a newline.

    ๐Ÿšš [core] Move logging off the main thread (#16325)

    โž• Add source property to limit parent's tile overscale factor (#16347)

    The new property sets a limit for how much parent tile can be overscaled.

    [core][tile mode] Introduce API to collect placed symbols data (#16339)

    The following methods are added to the Renderer class in implemented in the Tile map mode:

    collectPlacedSymbolData()
    enables or disables collecting of the placed symbols data

    getPlacedSymbolsData()
    if collecting of the placed symbols data is enabled, returns the reference to the PlacedSymbolData vector holding the collected data.

    [core] Enable circle-sort-key property (#15875)

    โž• Adds support for circle-sort-key property, consistent with symbol-sort-key.

    Sorts drawing order by sort key both within-tile and cross-tile.

    [core] Add LocationIndicator layer (#16340)

    โž• Adds a new layer type, location-indicator, that can be used to add a source-less indicator to the map, comprising raster images and a precision radius in meters.

    โž• Add generic setter for Layer's 'source' property (#16406)

    ๐Ÿฑ ๐Ÿž Bug fixes

    ๐Ÿ›  [core][tile mode] Labels priority fixes (#16432)

    This change does the following:

    • strictly arranges all the intersecting labels accordingly to the style-defined priorities
    • fixes placement order of the variable labels.
      ๐Ÿ’… Before this change, all variable labels that could potentially intersect tile borders were placed first, breaking the style label placement priority order. Now, all the variable labels, which do not actually intersect the tile borders, are placed accordingly to the style-defined priorities

    ๐ŸŽ [ios, macos] Fixed error receiving local file URL response (#16428)

    ๐ŸŽ [ios, macos] Corrected metrics of locally rendered fonts (#16253)

    ๐Ÿ›  CJK characters are now laid out according to the font, so fonts with nonsquare glyphs have the correct kerning. This also fixes an issue where the baseline for CJK characters was too low compared to non-CJK characters.

    [core][tile mode] Reduce cut-off labels (part 2) (#16369)

    Now, the intersecting symbols are placed across all layers symbol by symbol according to the following rules:

    1. First we look, which of the tile border(s) the symbol intersects and prioritize the the symbol placement accordingly (high priority -> low priority): vertical & horizontal -> vertical -> horizontal
    2. For the symbols that intersect the same tile border(s), assuming the tile border split symbol into several sections, we look at the minimal section length. The symbol with a larger minimal section length is placed first.
    3. For the symbols that intersect the same tile border(s), and have equal minimal section length, we look at the anchor coordinates.

    4. Finally, if all the previous criteria are the same, we look at the symbol key hashes.

    [core][tile mode] Fix variable placement for labels with the icon-text-fit property set (#16382)

    ๐Ÿ‘• The symbolIntersectsTileEdges() util in mbgl::TilePlacement now considers icon shift for the variable symbols with enabled icon-text-fit setting, thus providing more accurate results.

    ๐Ÿšš [core] Correctly log a warning instead of crashing when a non-existent image is attempted to be removed. (#16391)

    [core] Fix segfault resulting from an invalid geometry (#16409)

    ๐ŸŽ [macos] Restored support for macOS 10.11โ€“10.14 (#16412)