Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL

Overview

Mapbox GL Native

Circle CI build status Coverage Status

A C++ library that powers customizable vector maps in native applications on multiple platforms by taking stylesheets that conform to the Mapbox Style Specification, applying them to vector tiles that conform to the Mapbox Vector Tile Specification, and rendering them using OpenGL or Metal.

To embed interactive maps into a native application using a platform-specific language, install the Mapbox Maps SDK:

Mapbox GL JS is the WebGL-based counterpart to Mapbox GL Native that is designed for use on the Web.

Developing

We use CMake to build Mapbox GL Native for various platforms, including Linux, Android, iOS, macOS and Windows. The following command, executed from the root of this repository tree, will build Mapbox GL Native targeting your host architecture given that you have all the dependencies installed and run the example app.

$ git submodule update --init --recursive
$ cmake . -B build
$ cmake --build build
$ MAPBOX_ACCESS_TOKEN=my_access_token_here ./build/platform/glfw/mbgl-glfw

License

Mapbox GL Native is licensed under the 2-Clause BSD license. The licenses of its dependencies are tracked via FOSSA:

FOSSA Status

Comments
  • Offline maps

    Offline maps

    It is a personal goal to have the ability to view maps without needing an Internet connection.

    Very useful for activities such as bushwalking our mountain biking.

    Plus we know there are others interested in this feature too.

    feature offline 
    opened by ljbade 94
  • Implement Responsive User Location Tracking Mode

    Implement Responsive User Location Tracking Mode

    The User Location tracking mode (None, Follow, Bearing) was disabled in #1856 as the User Location dot was being updated on the main UI thread. The core logic is there, but it needs to be implemented in a more efficient way so that the UI remains responsive.

    /cc @erf

    Android 
    opened by bleege 80
  • Expose a generic Android View Marker API

    Expose a generic Android View Marker API

    Current Marker API on android is fairly limited because Markers are Gl-drawn components. I'm hearing about requests for animating markers or having the ability to do more typical Android SDK visual things with it (animations, selectors etc.).

    Concurrent InfoWindows from #3127 and UserLocationView showcased that we are able to sync Android Views with the underlying MapView. The logic is their but we do not expose a generic system.

    API proposal:

    For native annotations views in the Android Mapbox SDK. I don't see any reason to stray far from the adapter concept what an Android developer uses on daily basis. Combining this with the existing Mapbox API for adding annotations will look like:

     // combined API
     addMarker();
     addMarkers();
     removeMarker();
     removeMarkers();
     selectMarker();
    
     // new API
     setMarkerViewAdapter();
     setOnMarkerViewClickListener();
     setMarkerViewItemAnimation();
    

    Example API

    Integration of the API will follow the same path as the current Marker API.

      // Add country markers
      List<BaseMarkerOptions> countries = new ArrayList<>();
      countries.add(new CountryMarkerOptions().title("China").abbrevName("ch").flagRes(R.drawable.ic_china).position(new LatLng(31.230416, 121.473701)));
      countries.add(new CountryMarkerOptions().title("United States").abbrevName("us").flagRes(R.drawable.ic_us).position(new LatLng(38.907192, -77.036871)));
      countries.add(new CountryMarkerOptions().title("Brazil").abbrevName("br").flagRes(R.drawable.ic_brazil).position(new LatLng(-15.798200, -47.922363)));
      countries.add(new CountryMarkerOptions().title("Germany").abbrevName("de").flagRes(R.drawable.ic_germany).position(new LatLng(52.520007, 13.404954)));
      mapboxMap.addMarkers(countries);
    

    On top of that it will expose some new APIs to make ViewMarkers possible:

      // Add view marker adapter
      mapboxMap.setMarkerViewAdapter(new CountryAdapter(this));
    
      // Add a view marker click listener
      mapboxMap.setOnMarkerViewClickListener(new MapboxMap.OnMarkerViewClickListener() {
                @Override
                public void onMarkerClick(@NonNull Marker marker, @NonNull View view) {
                    Log.d(MapboxConstants.TAG, "Country clicked " + ((CountryMarker) marker).getAbbrevName());
                }
            });
    

    An example of the MarkerViewAdapter shown above:

        private static class CountryAdapter implements MapboxMap.MarkerViewAdapter<CountryMarker> {
    
            private LayoutInflater inflater;
    
            public CountryAdapter(@NonNull Context context) {
                this.inflater = LayoutInflater.from(context);
            }
    
            @Nullable
            @Override
            public View getView(@NonNull CountryMarker marker, @Nullable View convertView, @NonNull ViewGroup parent) {
                ViewHolder viewHolder;
                if (convertView == null) {
                    viewHolder = new ViewHolder();
                    convertView = inflater.inflate(R.layout.view_custom_marker, parent, false);
                    viewHolder.flag = (ImageView) convertView.findViewById(R.id.imageView);
                    viewHolder.abbrev = (TextView) convertView.findViewById(R.id.textView);
                    convertView.setTag(viewHolder);
                } else {
                    viewHolder = (ViewHolder) convertView.getTag();
                }
                viewHolder.flag.setImageResource(marker.getFlagRes());
                viewHolder.abbrev.setText(marker.getAbbrevName());
                return convertView;
            }
    
            private static class ViewHolder {
                ImageView flag;
                TextView abbrev;
            }
        }
    

    Next steps:

    • [x] Basic tracking view on Mapview - @tobrun
    • [x] Research limitations + perf. impacts - @tobrun
    • [x] Test out Android SDK animations - @tobrun
    • [x] Look into different approaches to publicly expose the API - @tobrun
    • [x] Introduce basic View Adapter approach - @tobrun
    • [x] Use a View reuse pattern in adapter (SimplePool) - @tobrun
    • [x] Integrate with selectMarker(Marker m) API - @tobrun
    • [x] Integrate with removeMarker(Marker m) API - @tobrun
    • [x] Hide old GL marker - @tobrun
    • [x] Trigger invalidate on View markers when Map is fully loaded - @tobrun
    • [x] Validate is exposed Android View Marker API matches iOS View Annotation API - @tobrun
    • [x] Profile execution - @tobrun
    • [x] Animation system - @tobrun
    • [x] Select animation API - @tobrun
    • [x] allow adding multiple adapters - @tobrun
    • [x] Flat configurable
    • [x] Offset configurable
    • [x] Double check changes made to basic Marker API - @tobrun
    • [ ] API documentation - @tobrun

    @incanus @bleege @zugaldia @cammace @danswick

    feature Android 
    opened by tobrun 70
  • merge GeoJSON vector tiles work

    merge GeoJSON vector tiles work

    Picking up from https://github.com/mapbox/mapbox-gl-native/issues/507#issuecomment-69076871, we'll need to merge the geojsonvt branch, which will require it interfacing better with the library.

    • [x] match vector tile object structure with main library
    • [x] allow for live reindexing when features are added/removed
    • [x] handle non-GeoJSON (in-memory features)
    • [x] nailing some hopefully-basic performance kinks
    • [ ] MultiGeometry support
    • [x] other API merging (e.g. LatLng struct)
    • [x] figuring out how independent of or reliant on GL we want the library to be

    /cc @mourner @1ec5

    feature 
    opened by incanus 59
  • Add arm64 As Supported ABI

    Add arm64 As Supported ABI

    Nexus 9 devices are arm64 based so Android GL needs to provide a arm64 based libmapboxgl.so binding. Update build process to support this ABI.

    https://developer.android.com/ndk/guides/abis.html

    /cc @incanus @ljbade

    build Android 
    opened by bleege 56
  • Freezes when going back and forth between activites

    Freezes when going back and forth between activites

    If you add a button to the main view in the test app, and open an arbitrary activity on a click event and then closes it, moves the map and click the button again, the app freezes on my nexus 7 (2012). I made a simple test case here: https://github.com/erf/mapbox-gl-native/tree/freezes

    bug Android 
    opened by erf 55
  • Android crashes on startup

    Android crashes on startup

    Hey guys,

    Looks like mapbox crashes for some devices on start.

    14620-14620/am.ggtaxi.main.ggdriver E/libEGL: validate_display:254 error 3008 (EGL_BAD_DISPLAY)
    14620-14620/am.ggtaxi.main.ggdriver E/mbgl: {Main}[OpenGL]: eglCreateWindowSurface() returned error 12296
    14620-14620/am.ggtaxi.main.ggdriver A/libc: Fatal signal 6 (SIGABRT) at 0x0000391c (code=-6), thread 14620 (i.main.ggdriver)
    

    Device: Samsung Galaxy Tab Pro 8.4 3G/LTE Android Version: 4.2.2

    Android crash 
    opened by iCyberon 54
  • Get Core GL C++ Into Android Project

    Get Core GL C++ Into Android Project

    In order to support C++ / NDK debugging in Android Studio and streamline CI builds and artifact publication we need to refactor the current make android process to integrate the Core GL C++ project files into the Gradle managed Android project. The current process compiles the Core GL into .so files based on ABI and places them into jniLibs for the Gradle build process to then use as a separate step, while the new process will copy the uncompiled C++ files into jni and make (the Gradle driven) Android NDK responsible for compiling them and linking them via JNI to the Android code along with building the SDK as whole in one step. This process will essentially mirror what is done for iOS and Xcode with make iproj where Xcode is responsible for all the compilation and linking.

    Unknowns

    • Will custom Android.mk files be needed or will the built in NDK controls in Gradle be enough.
    • Will current GL Makefile process work or will refactoring to use something like Bazel be needed?

    Resources

    @mapbox/mobile @mapbox/gl

    refactor Android 
    opened by bleege 52
  • Performance regression between iOS 0.5.2 and 0.5.3

    Performance regression between iOS 0.5.2 and 0.5.3

    I've noticed a performance regression between iOS 0.5.2 and 0.5.3. I have a UI element which acts as a scrubber along a polyline (video here). I use a custom animation, driven by a CADisplayLink, to set the zoom and centre coordinate of the map every frame using a 3D spring behaviour.

    In 0.5.2, the labels don't redraw until the animation stops, and during the animation the movement is smooth.

    In 0.5.3, if the animation changes the zoom to the extent that the labels are due for refresh, it becomes jerky. If you pause the movement long enough for the labels to redraw, it becomes smooth again.

    Let me know if you need any more information.

    iOS performance 
    opened by tomtaylor 51
  • Map tiles do not load on Android

    Map tiles do not load on Android

    After the app loads the map only renders the styles background fill colour and no tiles load.

    20150508-app-launch-screenshot

    @kkaefer I think you encountered this too a while back?

    bug Android 
    opened by ljbade 51
  • improve synced view tracking

    improve synced view tracking

    General ticket for improvement of "sticking" native, Cocoa-side views to the panning, zooming GL render view.

    This relates to the user dot now, later to callouts and annotation views. Let's keep a ticket around until we are 100% satisfied with the behavior here, but we can move it along milestones as we make staged improvements.

    bug iOS performance 
    opened by incanus 51
  • App crashes when trying to draw polyline by adding coordinates using onLocationChanged but works using hardcoded coordinates

    App crashes when trying to draw polyline by adding coordinates using onLocationChanged but works using hardcoded coordinates

    Platform: Android Studio

    Mapbox SDK version: 10.7.0

    Steps to trigger behavior

    1. Search for current location
    2. App crashes when trying to load the map

    Expected behavior

    Current location should be displayed and a polyline output on the user's location changing

    Actual behavior

    The app crashes when trying to load the map but if I remove the current location code and hardcode the coordinates it works and draws a line

    ` public class MapActivity extends LocationComponentActivity implements PermissionsListener, LocationListener {

    private MapView mapView;
    private List<Point> routeCoordinates;
    
    private PermissionsManager permissionsManager;
    
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        Mapbox.getInstance(this, "pk.eyJ1IjoiYWFyb25jb252ZXJ5IiwiYSI6ImNsN2l6ZHptMTB0YnYzcHBid2hrY2Q5cXUifQ.vMh6oO3R5sWWPPxklfrHRA");
        setContentView(R.layout.map_layout);
        mapView = findViewById(R.id.mapView);
        mapView.onCreate(savedInstanceState);
        mapView.getMapAsync(new OnMapReadyCallback() {
            @Override
            public void onMapReady(@NonNull final MapboxMap mapboxMap) {
    
                mapboxMap.setStyle(Style.OUTDOORS, new Style.OnStyleLoaded() {
                    @Override
                    public void onStyleLoaded(@NonNull Style style) {
                        enableLocationComponent(style);
                        // Create the LineString from the list of coordinates and then make a GeoJSON
                        // FeatureCollection so we can add the line to our map as a layer.
                        style.addSource(new GeoJsonSource("line-source",
                                FeatureCollection.fromFeatures(new Feature[] {Feature.fromGeometry(
                                        LineString.fromLngLats(routeCoordinates)
                                )})));
    
                        // The layer properties for our line. This is where we make the line dotted, set the
                        // color, etc.
                        style.addLayer(new LineLayer("linelayer", "line-source").withProperties(
                                PropertyFactory.lineDasharray(new Float[] {0.01f, 2f}),
                                PropertyFactory.lineCap(Property.LINE_CAP_ROUND),
                                PropertyFactory.lineJoin(Property.LINE_JOIN_ROUND),
                                PropertyFactory.lineWidth(5f),
                                PropertyFactory.lineColor(Color.parseColor("#e55e5e"))
                        ));
                    }
                });
            }
        });
    }
    
    @SuppressWarnings({"MissingPermission"})
    public void enableLocationComponent(@NonNull Style loadedMapStyle) {
        // Check if permissions are enabled and if not request
        if (PermissionsManager.areLocationPermissionsGranted(this)) {
            // Get an instance of the LocationComponent.
            LocationComponent locationComponent = mapboxMap.getLocationComponent();
    
            // Activate the LocationComponent
            locationComponent.activateLocationComponent(
                    LocationComponentActivationOptions.builder(this, loadedMapStyle).build());
    
            // Enable the LocationComponent so that it's actually visible on the map
            locationComponent.setLocationComponentEnabled(true);
    
            // Set the LocationComponent's camera mode
            locationComponent.setCameraMode(CameraMode.TRACKING);
    
            // Set the LocationComponent's render mode
            locationComponent.setRenderMode(RenderMode.NORMAL);
    
            //Set the zoom level
            locationComponent.zoomWhileTracking(17);
    
            locationComponent.getLastKnownLocation();
    
            LocationComponentActivationOptions
                    .builder(this, loadedMapStyle)
                    .useDefaultLocationEngine(true)
                    .locationEngineRequest(new LocationEngineRequest.Builder(750)
                            .setFastestInterval(750)
                            .setPriority(LocationEngineRequest.PRIORITY_HIGH_ACCURACY)
                            .build())
                    .build();
    
        } else {
            permissionsManager = new PermissionsManager(this);
            permissionsManager.requestLocationPermissions(this);
        }
    }
    
    @Override
    public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
        super.onRequestPermissionsResult(requestCode, permissions, grantResults);
        permissionsManager.onRequestPermissionsResult(requestCode, permissions, grantResults);
    }
    
    @Override
    public void onExplanationNeeded(List<String> permissionsToExplain) {
        Toast.makeText(this, R.string.user_location_permission_explanation, Toast.LENGTH_LONG).show();
    }
    
    @Override
    public void onPermissionResult(boolean granted) {
        if (granted) {
            mapboxMap.getStyle(new Style.OnStyleLoaded() {
                @Override
                public void onStyleLoaded(@NonNull Style style) {
                    enableLocationComponent(style);
    
                }
            });
        } else {
            Toast.makeText(this, R.string.user_location_permission_not_granted, Toast.LENGTH_LONG).show();
            finish();
        }
    }
    
    public void onLocationChanged(@NonNull Location location) {
    
        routeCoordinates = new ArrayList<>();
        routeCoordinates.add(Point.fromLngLat(location.getLongitude(), location.getLatitude()));
    
    }
    

    }

    `

    opened by xAaron1 0
  • attach MouseArea to MapParameter

    attach MouseArea to MapParameter

    i want to display geojson file on maps and make these shapes clickable to show more details about a building for example. what i get is just a coordinate ... i need to get geojson object of building clicked

    Map {
            id: map
            anchors.fill: parent
            plugin: Plugin {
                name: "mapboxgl"
                PluginParameter {
                    name: "mapboxgl.access_token"
                    value:"sk.eyJ1IjoiYWxub29yLXNjaG9vbCIsImEiOiJjbGF1cmd0YTEwOWNoM3ByNjdxaW0yZXZiIn0.-RGpdTPTSBqrUGc65oLPNQ"
                }
     MouseArea {
                acceptedButtons: Qt.LeftButton | Qt.RightButton
                anchors.fill: parent
     onClicked: {
                    mouse.accepted=true
                    if (mouse.button == Qt.LeftButton) {
                        var coord = map.toCoordinate(Qt.point(mouse.x,mouse.y));
                        console.log(coord.latitude, coord.longitude)
                        console.log(JSON.stringify(mouse) )
                }
            }
    
      DynamicParameter  {
                type: "source"
                property var name: "buildingSource"
                property var sourceType: "geojson"
                property var data: ":building.json"
            }
            DynamicParameter  {
                type: "layer"
                property var name: "buildingLayer"
                property var layerType: "fill"
                property var source: "buildingSource"
            }
            DynamicParameter  {
                type: "paint"
                property var layer: "buildingLayer"
                property var fillColor: "#bbb"
            }
    

    Clipboarder 2022 11 26-003

    QT_5.14 windows platform QML

    opened by dekemega 0
  • Using GPU server to speed up the rendering of mapbox-gl-native on the server side

    Using GPU server to speed up the rendering of mapbox-gl-native on the server side

    Platform: Mapbox SDK version:

    Steps to trigger behavior

    1.How using GPU server to speed up the rendering of mapbox-gl-native on the server side 2. 3.

    Expected behavior

    Actual behavior

    opened by liuziqian1 0
  • Map tiles not downloading to device

    Map tiles not downloading to device

    Currently using Mapbox Android com.mapbox.navigation:android:2.6.0 GA release since published. Map tiles were downloaded successfully until around 20jul22 when I noticed the Navigation screen was not working. Investigation led to realizing the map tiles and their containing directory did not exist on the device.

    I have made no local app code changes related to this issue. Currently it happens after requesting a route with 25 waypoints. I also checked my mapbox account and there is no indication of termination or locked account present. I also regenerated both public and secret keys but got the same issue of no map tile download.

    opened by tkvalentine56 5
  • Unclear error in android

    Unclear error in android

    Hello Android, Mapbox SDK 10.6.

    Using custom style and everything looks OK in the web (GL JS).

    But in android, unable to see road labels with the following error appearing: E/Mapbox: [maps-core]: {MapboxRenderThr}[Style]: Failed to load tile 14/9785/6610=>14 for source custom_bg: feature referenced out of range key

    The map shows , but the road labels are not visible and the above message pops up several times. the style is vector tiles, based with zoom levels 8 to 14, while the road labels is in zoom level 14. again, the same works great at the web, same style, same tiles.

    what is the meaning of the message ? how to debug further ?

    Yoni

    opened by yonibs 0
  • Sporadic crash in MGLRenderFrontend.render()

    Sporadic crash in MGLRenderFrontend.render()

    Im using Flutter MapBox GL (https://github.com/flutter-mapbox-gl/maps), which is a wrapper on this library/repo. Im not 100% sure if the crash occurs in this lib or the wrapper lib.

    Below is a screenshot of the crash in Xcode. It occurs too often to be neglected.

    Screenshot 2022-07-10 at 17 54 45

    Steps to reproduce

    I cannot say exactly how to trigger the crash but it seems to be just after the style has been loaded.

    This is how I configure MapboxMap (note that the style URL is public so you can test this use case).

          MapboxMap(
            styleString: "mapbox://styles/charmington/cl5e7uml0001p14r79ybci4eq",
            accessToken: MyApp.ACCESS_TOKEN,
            tiltGesturesEnabled: false,
            myLocationEnabled: true,
            myLocationTrackingMode: MyLocationTrackingMode.Tracking,
            myLocationRenderMode: MyLocationRenderMode.COMPASS,
            compassViewPosition: CompassViewPosition.TopLeft,
            initialCameraPosition: CameraPosition(
              zoom: 1.0,
              target: LatLng(60.15860080718994, 24.922044798731804),
            )
          );
    

    Expected behavior

    App not crashing

    Actual behavior

    App crashing

    Configuration

    Mapbox SDK versions: Mapbox-gl 0.16.0 Mapbox-gl-dart 0.2.1 Flutter 3.0.4 Dart 2.17.5 DevTools 2.12.2

    iOS/macOS versions: macOS Monterey 12.4

    Device/simulator models: iOS simulator - iPhone 11 Pro - iOS 15.5

    Xcode version: 13.4.1

    opened by BinaryDennis 1
Releases(maps-v1.6.0)
  • maps-v1.6.0(Apr 30, 2020)

    ✨ 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.

      By default, the source is not volatile.

    • [ios, macos] Allow specifying multiple fonts or font families for local font rendering (#16253)

      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)

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.5.2(Apr 27, 2020)

  • maps-v1.6.0-rc.2(Apr 25, 2020)

    ✨ New features

    • [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] Introduce 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.

      By default, the source is not volatile.

    • [ios, macos] Allow specifying multiple fonts or font families for local font rendering (#16253)

      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.

    🐞 Bug fixes

    • [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.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.6.0-rc.1(Apr 20, 2020)

    ✨ New features

    • [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] 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)

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.5.1(Apr 3, 2020)

    maps-v1.5.1

    🐞 Bug fixes

    • [core] Fix assert in gfx resources cleanup (#16349)

      Fix a resource leak assertion in gl::Context::~Context() that is evaluating false in scenarios where graphics context has been marked as lost.

    • Hillshade bucket fix for mapbox-gl-native-ios #240 (#16362)

      When dem tiles are loaded, border in neighboring tiles is updated, too leading to bucket re-upload. if std::move moved indices / vertices previously, they are empty and we get crash. Re-upload requires that only DEM texture is re-uploaded, not the quad vertices and indices.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.5.0(Mar 26, 2020)

    maps-v1.5.0

    ✨ New features

    • [core] Add Renderer::clearData() (#16323)

      The newly added Renderer::clearData() method allows to clear render data and thus save memory and make sure outdated tiles are not shown. It clears data more agressively than Renderer::reduceMemoryUse() does, as it clears not only the cache but all orchestration data, including the data used by the currently rendered frame.

    • [android] Add jni binding for styleable snapshotter (#16286)

    • [core] Ability to set generic layer properties using setProperty method (#16324) This change enables the following new keys for the mbgl::Layer::setProperty() API:

      • "filter" invokes setFilter()
      • "minzoom" invokes setMinZoom()
      • "maxzoom" invokes setMaxZoom()
      • "source-layer" invokes setSourceLayer()

      The newly-added API is used in the style-conversion code, which made this code much simpler.

    • [android] Expose getLayer, getSource and Observer interface for snapshotter (#16338)

    🐞 Bug fixes

    • [core] Use TileCoordinates instead of LngLat for within expression calculation (#16319)

      Fix the issue that within expression evaluates point features inconsistently across zoom levels if the point lies near the boundary of a GeoJSON object (#16301)

    • [core][tile mode] Reduce cut-off labels (#16336)

      Place tile intersecting labels first, across all the layers. Thus we reduce the amount of label cut-offs in Tile mode.

      Before, labels were arranged within one symbol layer (one bucket),which was not enough for several symbol layers being placed at the same time.

    • [core] Fix issue that within expression returns incorrect results for geometries crossing the anti-meridian (#16330)

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.4.1(Mar 16, 2020)

    maps-v1.4.1

    🐞 Bug fixes

    • [android] Fix wrong method call in map_snapshotter (#16308)

      In map_snapshotter, a wrong method call will cause Sanpshotter not works with a style url in Android. This change makes it call the right method to let Snapshotter works.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.4.0(Mar 13, 2020)

    maps-v1.4.0

    ✨ New features

    • [android] Add jni binding for line-sort-key and fill-sort-key (#16256)

      With this change, android sdk will be able to get sort key for LineLayer and FillLayer.

    • Styleable MapSnapshotter (#16268)

      New feature provides means of modifying style of a MapSnapshotter. The new API enables several use-cases, such as: adding route overlays, removing extra information (layers) from a base style, adding custom images that are missing from a style.

    • [core] Improve stability of symbol placement when the map is tilted (#16287)

      These changes improve performance and bring more stability to the symbol placement for the tilted view, which is mainly used for navigation scenarios.

    🐞 Bug fixes

    • [core] Fix iterators in addRegularDash() (#16249)

      Fixes possible crashes when using styles with line patterns.

    • [default] Fix possible crash at RunLoop::wake() (#16255)

    • [android] Update toGeoJSON in android_conversion.hpp (#16243)

      Before this chage, toGeoJSON method in android_conversion.hpp could not convert an Object (Map in android) to GeoJSON object.

      But within expression needs to accept an Object and then convert it to the GeoJSON object, now toGeoJSON method can convert both string and Object to GeoJSON.

    • [core] Fix within expression algorithm so that false value will be returned when point is on the boundary. Allow using different GeoJSON formats as arguments of within expression.(#16232)

      A valid GeoJSON argument should contain one of the following types: "Feature", "FeatureCollection","Polygon" or "MultiPolygon".

    • [core] [tile mode] placement algorithm must consider icons bounding boxes (#16277)

      Tile mode placement algorithm now checks if bounding boxes for both label text and icon are intersecting the edges of the tiles.

      Before, it checked only text bounding boxes and thus label icons might have got cut off.

    • [core] Calculate size of an ambient cache without offline region's resources (#15622)

      Resources that belong to an offline region, should not contribute to the amount of space available in the ambient cache.

    • [core][tile mode] Fix assertion at line-center placement handling (#16293)

      The Symbol Intersects Tile Edges placement algorithm should not be applied to the symbols with line-center placement.

    • Fixed using of the in expression as a layer filter (#16272)

      The bug was caused by mbgl::style::conversion::isExpression() always returning false for the in expression.

    🧩 Architectural changes

    • Changes to MapSnapshotter threading model (#16268)

      Snapshotter's threading model has been changed. Previously, Map and HeadlessFrontend that is responsible for rendering snapshot, were running on a dedicated thread. After #16268, Map object lives on client thread, so that the client can access Style object, while HeadlessFrontend lives on a dedicated Snapshotter thread.

    ⚠️ Breaking changes
    • Signature of a MapSnapshotter's constructor has been changed
    • Signature for a MapSnapshotter::snapshot method has been changed
    • Size of an offline regions do not affect ambient cache size (#15622)
    📌 Known issues
    • When feature is exactly on the geometry boundary, within expression returns inconsistent values for different zoom levels (#16301)
    Source code(tar.gz)
    Source code(zip)
  • maps-v1.3.1+ios(Mar 10, 2020)

  • maps-v1.3.1(Mar 2, 2020)

    maps-v1.3.1 (2020.02-release-vanillashake)

    🐞 Bug fixes

    • [core] Fix iterators in addRegularDash() (#16249)

      Fixes possible crashes when using styles with line patterns.

    • [default] Fix possible crash at RunLoop::wake() (#16255)

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.2.2(Mar 2, 2020)

    maps-v1.2.2 (2020.02-release-vanillashake)

    🐞 Bug fixes

    • [core] Fix iterators in addRegularDash() (#16249)

      Fixes possible crashes when using styles with line patterns.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.3.0(Feb 28, 2020)

    maps-v1.3.0 (2020.02-release-vanillashake)

    🐞 Bug fixes

    • [core] Fix offline region download freezing (#16230)

      Downloaded resources are put in the buffer and inserted in the database in batches.

      Before this change, the buffer was flushed only at the network response callback and thus it never got flushed if the last required resources were present locally and did not initiate network requests - it caused freezing.

      Now the buffer is flushed every time the remaining resources container gets empty.

    ✨ New features

    • [core] Add Layer::serialize() method (#16231)

      New method allows serialization of a layer into a Value type, including all modifications done via runtime style API. New method is also an enabler for Style object serialization (sources, layers, etc).

    • [android] Add jni binding for min and max pitch (#16236)

    • [offline] Offline tool does not hang on 404 error (#16240)

      The missing resource gets skipped and teh offline region download continues.

    ⚠️ Breaking changes
    • Changes to mbgl::FileSourceManager::getFileSource() (#16238)

      It returns now mbgl::PassRefPtr<FileSource> (previously was std::shared_ptr<FileSource>) in order to enforce keeping the strong reference to the returned object.

      Breaking code example: auto fs = FileSourceManager::getFileSource(); fs->..

      Posible fix: std::shared_ptr<FileSource> fs =;

    • The mbgl::OnlineFileSource class cannot be used directly (#16238)

      Clients must use the parent mbgl::FileSource interface instead.

      Breaking code example: std::shared_ptr<OnlineFileSource> onlineSource = std::static_pointer_cast<OnlineFileSource>(FileSourceManager::get()->getFileSource(..));

      Possible fix: std::shared_ptr<FileSource> onlineSource = FileSourceManager::get()->getFileSource(..);

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.2.1(Feb 28, 2020)

  • maps-v1.2.0(Feb 17, 2020)

    maps-v1.2.0 (2020.02-release-vanillashake)

    ✨ New features

    • [core] Global settings API (#16174)

      Global settings API provides means of managing non-persistent in-process settings. Initial implementation contains support for experimental option for setting thread priorities.

    • Expose READ_ONLY_MODE_KEY property for DatabaseFileSource (#16183)

      The READ_ONLY_MODE_KEY property is exposed for DatabaseFileSource.

      This property allows to re-open the offline database in read-only mode and thus improves the performance for the set-ups that do not require the offline database modifications.

    • [core] Add runtime API for setting tile prefetch delta for a Source (#16179)

      The new Source::setPrefetchZoomDelta(optional<uint8_t>) method allows overriding default tile prefetch setting that is defined by the Map instance.

    • [core] Add support for within expression. Implement the use of within expression with paint propery and filter expression. (#16157)

      The within expression enables checking whether a feature is inside a pre-defined geometry set/boundary or not. This within expression returns a boolean value, true indicates that the feature being evaluated is inside the geometry set. The returned value can be then consumed as input by another expression or used directly by a paint/layer property.

      Support for using within expression with layout property will be implemented separately.

    • [core] Add support for using within expression with layout property. (#16194)

    • [core] Add support for in expression. (#16162)

      The in expression enables checking whether a Number/String/Boolean type item is in a String/Array and returns a boolean value.

    🐞 Bug fixes

    • [core] Don't provide multiple responses with the same data for 304 replies (#16200)

      In cases when cached resource is useable, yet don't have an expiration timestamp, we provided data to the requester from the cache and the same data was returned once 304 response was received from the network.

    • [core] Fix potential visual artifact for line-dasharray (#16202)

    • Store gfx::DrawScope objects with associated render objects. (#15395)

      We used some shared SegmentVectors, e.g. for drawing raster or background tiles. In longer running maps, this lead to resource accumulation. By storing the SegmentVectors and the contained gfx::DrawScope objects, we ensure that resources get released when the associated render objects vanish.

    • [core] Fix sprite sheet merging in Style::Impl::onSpriteLoaded (#16211)

      If we get a new sprite sheet from the server, we need to merge current sprite sheet with a new one, while overwriting duplicates and keeping old unique images in a style.

    🏁 Performance improvements

    • [core] Loading images to style optimization (#16187)

      This change enables attaching images to the style with batches and avoids massive re-allocations. Thus, it improves UI performance especially at start-up time.

    🧩 Architectural changes

    ⚠️ Breaking changes
    • [core] Loading images to style optimization (#16187)

      The style::Style::getImage() semantics changed - it now returns optional<style::Image>.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.0.1(Feb 3, 2020)

    maps-v1.0.1 (2020.01-release-unicorn)

    🐞 Bug fixes

    • [core] Use std::list instead of std::map for factory instance (#16161)

      Factory 'get' method can be invoked recursively and stable iterators are required to guarantee safety.

    • [tile mode] Improvements in symbol placement on tile borders (#16159)

      In tile mode, the placement order of two symbols crossing a tile border is defined by their anchor Y values.

      Symbols crossing the borders between two neighboring tiles are placed with priority.

      It improves symbol placement stability in the tile map mode.

    Source code(tar.gz)
    Source code(zip)
  • maps-v1.0.0(Jan 27, 2020)

    maps-v1.0.0 (2020.01-release-unicorn)

    ✨ New features

    • [core] Implement stretchable icons (#16030)

      Stretchable icons allow defining certain areas of an icon that may be stretched, leaving the remaining areas of an icon at a fixed size.

    • [core] Port line-sort-key and fill-sort-key (#15839)

      The new feature allows to sort line and fill layer features. Similar to symbol-sort-key.

    • [core] Add image sections to format expression (#15937)

      The new feature allows to embed images into labels.

    • [core] Introduce OfflineDatabase::runPackDatabaseAutomatically() API (#15967)

      The new API allows to enable / disable automatic packing of a database.

    • [core] Decouple offline storage vacuum and the deleteRegion API (#15899)

      • introduce OfflineDatabase::pack() standing for incremental vacuum
      • make packing optional at offline region deletion
    • [core] Implement image expression (#15877)

      The image expression allows determining an image's availability.

    • [core] Add batch conversion of latLngs to/from screenCoords (#15891)

      This patch introduces batch conversion between LatLng and ScreenCoordinate in Gl-Native core, so for multiple conversions with single point/latLng previously now it can be done with invoking one function call by passing vector of points/latLngs.

    🐞 Bug fixes

    • [tile mode] Fix variable symbols placement (#16141

      This change allows the variable symbols to cross the tile border only if their anchor is the first anchor from the text-variable-anchor list.

    • [core] Use weak scheduler inside mailbox (#16136)

      If there are pending requests that are completed after main scheduler is destructed, worker threads may try to push messages to destructed scheduler's queue.

    • [core] Fix a crash in GeoJSON source parsing, caused by GeoJSONVTData ownership error (#16106)

    • [core] Stable position of labels at tile borders in tile mode (#16040)

      These changes allow to avoid cutting-off labels on tile borders if the variable text placement is enabled.

    • [core] Fix really overscaled lines (#16045)

      We resample lines after sharp corners in some situations. When tiles were really overscaled, sometimes we didn't have enough precision to represent the resampled vertex because it was too close. Disabling this after a certain point prevents this (#16018).

    • [core] Don't use signed int type for anchor segment (#16008)

      Erroneous signed to unsigned implicit conversion was used when PlacedSymbol(s) were created in SymbolLayout and signed values were used as indexes in a few other places.

    • [core] Increase padding in CollisionIndex for MapMode::Tile (#15880)

      This increases the padding to 1024 for MapMode::Tile which should be enough to completely include all the data two zoom levels past the data source's max zoom level. Beyond that, 1024 should be enough of a padding to make clipped labels unlikely.

    • [core] Blacklist VAO extension for Adreno (TM) 4xx GPUs (#15978)

      Blacklist in order to avoid crashes in a driver (Android 5.1.1)

    • [core] Retain thread pool in GeoJSONSource (#15992)

      Otherwise, the construction of the Immutable<Source::Impl> in background thread might never yeld.

    • [core] Fix supercluster lambdas capturing (#15989)

      Fix wrapping of the parameters in supercluster map/reduce lambdas (Previously, local variables were wrapped by reference).

    • [core] fix rendering of dashed lines with round caps (#15947)

      In #15862, we introduced individual textures for line dash patterns to eliminate atlas overflows. Unfortunately, this broke dashed lines that had round caps (dashed lines with straight caps still rendered correctly). Line pattern textures for round caps were now using 256×15 pixel textures.

    • [core] Fix incorrect resizing of TileCache (#15943)

    • [core] Avoid GeoJSON source flickering on style transitions (#15907)

      Before this change, all GeoJSON source cleared tile pyramid at the style transition and it caused flickering.

    • [core] Use individual textures for line dash patterns (#15862)

      This moves the LineAtlas from a shared texture that contained SDF dash patterns to use individual textures.

    • [core] Fix collisions with icon-text-fit and variable placement (#15828)

      When deciding the placement position it was only checking whether there were text collisions. Now, if icon-text-fit is used it now checks whether the icon fits before accepting a placement position.

    • [core] Fix icon-text-fit (#15634)

      This fixes rendering by account for the 1px texture padding around icons that were stretched with icon-text-fit.

    🏁 Performance improvements

    • [core] Cross tile index performance (#16127)

      For overscaled tiles, index only the symbols inside the viewport.

      Find matches only among the buckets that have the same leader Id.

    • [core] Calculate GeoJSON tile geometries in a background thread (#15953)

      Call mapbox::geojsonvt::GeoJSONVT::getTile() in a background thread, so that the rendering thread is not blocked.

    • [core] Make requests for expired resources lower priority than requests for new resources (#15950)

    • [core] Add Scheduler::scheduleAndReplyValue() API (#15885)

      This change converts GeoJSON features to tiles for the loaded source description in a background thread and thus unblock the UI thread.

    • [core] Enable incremental vacuum for Offline DB (#15837)

      Thus we avoid re-creating the whole database and keeping the backup file as it happens on calling VACUUM.

    • [core] Fix image requests for already obtained images (#15825)

      Before this fix, repeated request for an already obtained image was erroneously treated as pending, and it prevented from the tiles load completion.

    🧩 Architectural changes

    • [core] Merge style::Layer::set{Layout,Paint}Property (#15997)

    • [core] Use expected.hpp from mapbox-base (#15898)

    ⚠️ Breaking changes
    • [core] Cross tile index performance (#16127)

      Introduces public mblg::Renderer::render API break.

    • [core] Refactor DefaultFileSource codebase (#15768)

      • Adds FileSourceManager interface that provides access to FileSource instances and means of registering / unregistering FileSource factories
      • Splits DefaultFileSource into smaller parts
      • Adds DatabaseFileSource interface and it's default implementation
      • Removes inter-dependencies between concrete FileSource classes
      • All sources operate on dedicated thread, except MainResourceLoader that acts as a dispatcher and works on thread that requested it.
      • Removes ResourceOptions::withCacheOnlyRequestsSupport method
    • [core] Remove Map::cycleDebugOptions (#16005)

      This function was mostly used by the Android API, which is no longer necessary.

    Source code(tar.gz)
    Source code(zip)
  • android-v8.5.0-alpha.2(Oct 10, 2019)

  • ios-v5.5.0-alpha.2(Oct 9, 2019)

    Changes since Mapbox Maps SDK for iOS v5.5.0-alpha.1:

    Performance improvements

    • Improved rendering performance for the styles with multiple sources (#15756)

    Other changes

    • Added -[MGLMapSnapshotOverlay coordinateForPoint:] and -[MGLMapSnapshotOverlay pointForCoordinate:] to convert between context and map coordinates, mirroring those of MGLMapSnapshot. (#15746)
    • Fixed an issue that cause the ornaments to ignore MGLMapView.contentInset property. (#15584)
    • Fixed an issue that cause -[MGLMapView setCamera:withDuration:animationTimingFunction:edgePadding:completionHandler:] persist the value of edgePadding. (#15584)
    • Added MGLMapView.automaticallyAdjustsContentInset property that indicates if wether the map view should automatically adjust its content insets. (#15584)
    • Fixed an issue that caused MGLScaleBar to have an incorrect size when resizing or rotating. (#15703)

    To install this pre-release via a dependency manager, see our CocoaPods or Carthage instructions.

    Documentation is available online or as part of the download.

    Source code(tar.gz)
    Source code(zip)
    mapbox-ios-sdk-5.5.0-alpha.2-dynamic.zip(133.91 MB)
    mapbox-ios-sdk-5.5.0-alpha.2-stripped-dynamic.zip(48.87 MB)
  • android-v8.5.0-alpha.1(Oct 3, 2019)

    8.5.0-alpha.1 - October 3, 2019

    Changes since Mapbox Maps SDK for Android v8.4.0:

    Bug fixes

    • Suppress network requests for expired tiles update, if these tiles are invisible. #15741
    • Fixed opacity interpolation for composition expressions #15738
    • Fixed an issue where Projection#getMetersPerPixelAtLatitude returned a value incorrectly divided by the pixel ratio. This also fixes an issue where LocationComponent accuracy circle's radius was artificially increased. #15742
    Source code(tar.gz)
    Source code(zip)
  • ios-v5.5.0-alpha.1(Oct 2, 2019)

  • ios-v5.4.0(Sep 25, 2019)

    Please reach out to Mapbox Support if you have any questions regarding the new iOS 13 location dialog that appears when NSLocationAlwaysAndWhenInUseUsageDescription is set.

    Changes since Mapbox Maps SDK for iOS v5.3.2:

    Styles and rendering

    • Added an -[MGLMapSnapshotter startWithOverlayHandler:completionHandler:] method to provide the snapshot's current CGContext in order to perform custom drawing on MGLMapSnapshot objects. (#15530)
    • Fixed an issue that caused MGLTileSourceOptionMaximumZoomLevel to be ignored when setting MGLTileSource.configurationURL. (#15581)
    • Fixed an assertion caused by adding a layer to an incompatible source. (#15644)
    • Fixed crashes triggered when MGLSource and MGLStyleLayer objects are accessed after having been invalidated after a style change. (#15539)
    • Fixed an issue where the collision boxes for symbols would not be updated when MGLSymbolStyleLayer.textTranslation or MGLSymbolStyleLayer.iconTranslation were used. (#15467)
    • Enabled use of MGLSymbolStyleLayer.textOffset option together with MGLSymbolStyleLayer.textVariableAnchor (if MGLSymbolStyleLayer.textRadialOffset option is not provided). (#15542)
    • Fixed an issue that caused constant repainting for sources with invisible layers. (#15600)

    User interaction

    • Fixed an issue that caused the tilt gesture to trigger too easily and conflict with pinch or pan gestures. (#15349)
    • Fixed an issue that caused the map to rotate too easily during a pinch gesture. (#15562)

    Performance improvements

    • Improved offline region download performance by batching certain database activities. (#15521)
    • Newly loaded labels appear faster on the screen. (#15308)

    Other changes

    • Fixed a bug where the completion block passed to -[MGLMapView flyToCamera:completionHandler:] (and related methods) wouldn't be called. (#15473)
    • Fixed a crash when offline pack invalidation happened on different threads. (#15582)
    • Fixed a potential integer overflow at high zoom levels. (#15560)
    • Fixed a bug with annotation view positions after camera transitions. (#15122)

    Known issues

    • Edge padding is persisted when set through [MGLMapView setCamera:withDuration:animationTimingFunction:edgePadding:completionHandler:]. (#15233) Workaround: Manually set the contentInset property in the completion handler.
    • Ornaments layout does not respect the contentInset property. (#15584)

    Documentation is available online or as part of the download.

    Source code(tar.gz)
    Source code(zip)
    mapbox-ios-sdk-5.4.0-dynamic.zip(129.56 MB)
    mapbox-ios-sdk-5.4.0-stripped-dynamic.zip(47.67 MB)
  • android-v8.4.0(Sep 25, 2019)

  • ios-v5.3.2(Sep 19, 2019)

  • android-v8.4.0-beta.1(Sep 19, 2019)

    Changes since Mapbox Maps SDK for Android v8.4.0-alpha.2:

    Bug fixes

    • Fixed an issue that maxzoom in style Sources option was ignored when URL resource is provided. It may cause problems such as extra tiles downloading at higher zoom level than maxzoom, or problems that wrong setting of overscaledZ in OverscaledTileID that will be passed to SymbolLayout, leading wrong rendering appearance. #15581
    • Fixed constant repainting for the sources with invisible layers, caused by RenderSource::hasFadingTiles() returning true all the time. #15600
    • Fixed an issue that caused the state of CompassView not up to date when UiSettings.setCompassEnabled() is set to true. #15606
    • Ignore location tracking mode based animations when the camera is transitioning. #15641
    • Fixed MapSnapshotter so that MapSnapshotter.withApiBaseUri works again. #15642
    • Fixed an assertion hit caused by possibility of adding a layer to an incompatible source. #15644
    Source code(tar.gz)
    Source code(zip)
  • android-v8.3.3(Sep 20, 2019)

  • android-v8.3.2(Sep 20, 2019)

  • android-v8.3.1(Sep 19, 2019)

  • ios-v5.4.0-beta.1(Sep 20, 2019)

    Changes since Mapbox Maps SDK for iOS v5.4.0-alpha.2:

    Styles and rendering

    • Added an -[MGLMapSnapshotter startWithOverlayHandler:completionHandler:] method to provide the snapshot's current CGContext in order to perform custom drawing on MGLMapSnapShot objects. (#15530)
    • Fixed an issue that caused MGLTileSourceOptionMaximumZoomLevel to be ignored when setting MGLTileSource.configurationURL. (#15581)
    • Fixed an assertion hit caused by possibility of adding a layer to an incompatible source. (#15644)
    • Fixed a rendering issue of collisionBox when MGLSymbolStyleLayer.textTranslate or MGLSymbolStyleLayer.iconTranslate is enabled. (#15467)
    • Fixed a crash when -[MGLOfflinePack invalidate] is called on different threads. (#15582)

    Performance improvements

    • Newly loaded labels appear faster on the screen. (#15308)

    Other changes

    • Fixed constant repainting for the sources with invisible layers, caused by RenderSource::hasFadingTiles() returning true all the time. (#15600)

    To install this pre-release via a dependency manager, see our CocoaPods or Carthage instructions.

    Documentation is available online or as part of the download.

    Source code(tar.gz)
    Source code(zip)
    mapbox-ios-sdk-5.4.0-beta.1-dynamic.zip(129.58 MB)
    mapbox-ios-sdk-5.4.0-beta.1-stripped-dynamic.zip(47.64 MB)
  • ios-v5.3.1(Sep 19, 2019)

    Changes since Mapbox Maps SDK for iOS v5.3.0:

    Styles and rendering

    • Fixed an issue where connecting coincident holes in a polygon could lead to a race condition. (#15660)

    Other changes

    • Fixed an issue where the scale bar text would become illegible if iOS 13 dark mode was enabled. (#15524)
    • Fixed an issue with the appearance of the compass text in iOS 13. (#15547)

    Documentation is available online or as part of the download.

    Source code(tar.gz)
    Source code(zip)
    mapbox-ios-sdk-5.3.1-dynamic.zip(128.22 MB)
    mapbox-ios-sdk-5.3.1-stripped-dynamic.zip(47.24 MB)
  • ios-v5.4.0-alpha.2(Sep 11, 2019)

    Changes since Mapbox Maps SDK for iOS v5.4.0-alpha.1:

    Styles and rendering

    • Fixed crashes triggered when MGLSource and MGLStyleLayer objects are accessed after having been invalidated after a style change. (#15539)
    • Fixed a bug where the completion block passed to -[MGLMapView flyToCamera:completionHandler: (and related methods) wouldn't be called. (#15473)

    Other changes

    • Fixed a potential integer overflow at high zoom levels. (#15560)

    To install this pre-release via a dependency manager, see our CocoaPods or Carthage instructions.

    Documentation is available online or as part of the download.

    Source code(tar.gz)
    Source code(zip)
    mapbox-ios-sdk-5.4.0-alpha.2-dynamic.zip(128.27 MB)
    mapbox-ios-sdk-5.4.0-alpha.2-stripped-dynamic.zip(47.30 MB)
Owner
Mapbox
Mapbox is the location data platform for mobile and web applications. We're changing the way people move around cities and explore our world.
Mapbox
Allows you to use custom maps in iphone applications and attempts to mimics some of the behaviour of the MapKit framework

NAMapKit Lets you drop pins or custom annotations onto a standard UIImage or a tiled NATiledImageView. Includes callouts, multi-colored pins, animatio

Neil Ang 263 Jun 29, 2022
A spatial analysis library written in Swift for native iOS, macOS, tvOS, watchOS, and Linux applications, ported from Turf.js.

Turf for Swift ?? ?? ?? ?? ⌚️ A spatial analysis library written in Swift for native iOS, macOS, tvOS, watchOS, and Linux applications, ported from Tu

Mapbox 187 Dec 19, 2022
Use Swift in the macOS command line to build maps.

Use Swift in the macOS command line to build maps. imagefrom A Swift command line utility that gets an image from a URL. Saves the web image as JPEG o

Rob Labs 0 Dec 30, 2021
An iOS map clustering framework targeting MapKit, Google Maps and Mapbox.

ClusterKit is an elegant and efficiant clustering controller for maps. Its flexible architecture make it very customizable, you can use your own algor

null 502 Dec 25, 2022
M. Bertan Tarakçıoğlu 16 Dec 29, 2022
JDSwiftMap is an IOS Native MapKit Library. You can easily make a highly customized HeatMap.

JDSwiftMap is an IOS Native MapKit Library. You can easily make a highly customized HeatMap. Installation Cocoapods pod 'JDSWiftHeatMap' Usage JDSwi

郭介騵 135 Dec 26, 2022
Location, motion, and activity recording framework for iOS

LocoKit A Machine Learning based location recording and activity detection framework for iOS. Location and Motion Recording Combined, simplified Core

Matt Greenfield 1.5k Jan 2, 2023
Google Directions API helper for iOS, written in Swift

PXGoogleDirections Google Directions API SDK for iOS, entirely written in Swift. ?? Features Supports all features from the Google Directions API as o

Romain L 268 Aug 18, 2022
A Swift wrapper for forward and reverse geocoding of OpenStreetMap data

Nominatim NominatimKit is a Swift wrapper for forward and reverse geocoding of OpenStreetMap data. Why? Geocoding location data on iOS requires the us

Josef Moser 53 Feb 5, 2022
MSFlightMapView allows you to easily add and animate geodesic flights to Google map

MSFlightMapView Demo Requirements iOS 10.0+ Xcode 9.0+ Installation Just add the MSFlightMapView folder to your project. or use CocoaPods: pod 'MSFlig

Muhammad Abdul Subhan 48 Aug 13, 2022
Demo in SwiftUI of Apple Map, Google Map, and Mapbox map

SNMapServices SNMapServices is a serices for iOS written in SwiftUI. It provides Map capability by subclassing Mapbox, Google map and Apple map. This

Softnoesis 3 Dec 16, 2022
3D Shoot'em Up written with OpenGL ES 1.1/2.0 running on iOS, Android, Windows and MacOS X.

SHMUP This is the source code of "SHMUP" a 3D Shoot 'em up that I wrote in 2009. It is very inspired of Treasure Ikaruga, the engine runs on iOS, Andr

Fabien 242 Dec 16, 2022
🗺️ MAPS.ME — Offline OpenStreetMap maps for iOS and Android

MAPS.ME MAPS.ME is an open source cross-platform offline maps application, built on top of crowd-sourced OpenStreetMap data. It was publicly released

MAPS.ME 4.5k Dec 23, 2022
React Native utility library around image and video files for getting metadata like MIME type, timestamp, duration, and dimensions. Works on iOS and Android using Java and Obj-C, instead of Node 🚀.

Qeepsake React Native File Utils Extracts information from image and video files including MIME type, duration (video), dimensions, and timestamp. The

Qeepsake 12 Oct 19, 2022
Android/iOS Apps created to practice with different iOS/Android Tech. These apps were built to have similar feature sets using native Android/iOS.

AgilityFitTodayApp Android/iOS Apps created to practice with different iOS/Android Tech. These apps were built to have similar feature sets using nati

Lauren Yew 1 Feb 25, 2022
Tutorial GraphQL + Node Express + MySQL, and sample for Android / iOS client

GraphQL-tutorial Tutorial for GraphQL + Node Express + MySQL, and sample for Android / iOS client Blog NeoRoman's GraphQL-tutorial (Korean) Materials

Henry Kim 4 Oct 20, 2022
Automate box any value! Print log without any format control symbol! Change debug habit thoroughly!

LxDBAnything Automate box any value! Print log without any format control symbol! Change debug habit thoroughly! Installation You only need drag LxD

DeveloperLx 433 Sep 7, 2022
MKOverlayRenderer.setNeedsDisplay Causes MKTileOverlayRenderer To Re-Render Tiles

MKOverlayRenderer.setNeedsDisplay Causes MKTileOverlayRenderer To Re-Render Tiles Bug Report ID FB9957545 Note: this is still broken as of iOS 15 (Xco

Brian Coyner 1 Mar 16, 2022
Card-based view controller for apps that display content cards with accompanying maps, similar to Apple Maps.

TripGo Card View Controller This is a repo for providing the card-based design for TripGo as well as the TripKitUI SDK by SkedGo. Specs 1. Basic funct

SkedGo 6 Oct 15, 2022
Profiling / Debugging assist tools for iOS. (Memory Leak, OOM, ANR, Hard Stalling, Network, OpenGL, Time Profile ...)

MTHawkeye Readme 中文版本 MTHawkeye is profiling, debugging tools for iOS used in Meitu. It's designed to help iOS developers improve development producti

meitu 1.4k Dec 29, 2022