Releases: mapbox/mapbox-maps-android
Releases · mapbox/mapbox-maps-android
v11.6.0
11.6.0 August 16, 2024
Breaking changes ⚠️
- [compose] Remove
StyleImage
constructor withBitmapImage
, userememberStyleImage
composable function to build it instead. - [compose] Move layer properties within
*Layer
composable functions to*LayerState
classes, use the convenient method*Layer(sourceState, layerId, init)
with trailing lambda for easier migration. - [compose] Move
onClick
listener from last parameter to the second last parameter ofAnnotation
andAnnotationGroup
composable functions. - [compose] Move properties within
*Annotation
and*AnnotationGroup
composable functions to the new*AnnotationState
and*AnnotationGroupState
classes, use the convenient method*Annotation(point, onClick, init)
and*AnnotationGroup(annotations, annotationConfig, onClick, init)
with trailing lambda for easier migration. - [compose] Replace color int and color string property types in
*Annotation
with composeColor
type. - [compose] Replace
PointAnnotation.iconImageBitmap
andPointAnnotation.iconImage
withPointAnnotationState.iconImage
withIconImage
type,IconImage
can be constructed with either a image idString
or aBitmap
, and introducedrememberIconImage
to build and remember a bitmap fromPainter
or from a drawable resource id. - [compose] Introduce
StandardStyleConfigurationState
class to hold the configurations ofMapboxStandardStyle
, and movelightPreset
config fromMapboxStandardStyle
toStandardStyleConfigurationState
; consider using overload methodMapboxStandardStyle
with trailing init lambda for easier migration. - Experimental
CustomRasterSourceOptions.Builder
now acceptsCustomRasterSourceClient
containingCustomRasterSourceTileStatusChangedCallback
instead ofCustomRasterSourceTileStatusChangedCallback
interface directly.
Features ✨ and improvements 🏁
- [compose] Promote Compose Extension to stable.
- [compose] Mark
MapState
,MapViewportState
,TerrainState
, light states and source states asStable
as they are internally backed byMutableState
. - [compose] Add more config options including
showPlaceLabels
,showRoadLabels
,showPointOfInterestLabels
,showTransitLabels
andfont
toStandardStyleConfigurationState
. - [compose] Introduce
StyleImage
constructor withImage
type, and addrememberStyleImage
composable functions to create and rememberStyleImage
. - [compose] Add extension function to
*AnnotationOptions
to handle composeColor
, use it in*AnnotationGroup
composable functions for convenience. - [compose] Add style transition parameter in
GenericStyle
,MapStyle
andMapboxStandardStyle
. - [compose] Extend
StandardStyleConfigurationState
withtheme: ThemeValue
andshow3dObjects: BooleanValue
properties. - [compose] Introduce composable function
MapboxStandardSatelliteStyle
with dedicatedStandardSatelliteStyleConfigurationState
. - Add new
Style.STANDARD_SATELLITE
style that combines updated satellite imagery and vector layers. - Introduce new import configuration properties for
Style.STANDARD
:theme
,show3dObjects
which could be set withStyle.setStyleImportConfigProperty
. - Modify
awaitCameraForCoordinates
extension function to useMapCameraManagerDelegate
as receiver type. - Modify
queryRenderedFeatures
andquerySourceFeatures
extension functions to useMapFeatureQueryDelegate
as receiver type. - Introduce asynchronous overloaded method
ViewAnnotationManager.cameraForAnnotations
better covering some corner cases. - Make use of asynchronous
MapboxMap.cameraForCoordinates
in Mapbox overlay plugin better covering some corner cases. - Mark synchronous methods
MapboxMap.cameraForCoordinates
andViewAnnotationManager.cameraForAnnotations
with@MapboxDelicateApi
. Consider using asynchronous overloaded methods instead. - Deprecate
MapboxMap.getDebug()
/MapboxMap.setDebug()
in favour ofMapView.debugOptions
taking new enhanced enumMapViewDebugOptions
as an argument. - Introduce
MapViewDebugOptions.CAMERA
andMapViewDebugOptions.PADDING
debug options to track current camera state and visualize camera paddings. - Expose experimental
ClipLayer
to remove 3D data (fill extrusions, landmarks, instanced trees) and symbols. - Enable r8 optimisations for all the Mapbox extensions and plugins in consumer proguard file, the optimisation will apply when minify is enabled in app's build settings.
- Enable direct rendering into
CustomRasterSource
tiles. - Introduce a new
allowZElevate
option inViewAnnotationOptions
. When set to true, the annotation will be positioned on the rooftops of buildings, including both fill extrusions and models. - Support negative values for
CircleLayer.circleBlur
to render inner glow effect. - Support for model-uris as properties in geojson model layers.
- Allow usage of the tile leveling schemes with maximum zoom exceeding 16.
Bug fixes 🐞
- [compose] Fix minZoom/maxZoom not working for layers.
- [compose] Fix
java.lang.UnsupportedOperationException
when settingtextWritingMode
andtextVariableAnchor
. - Fix compass view ignoring
enabled
option when it is set inupdateSettings()
. - Fix background locations not received when unregistering other providers.
- Improve
linePattern
precision. - Fix local glyph rasterization to ensure the correct Typeface is used.
- Fix
CustomRasterSource
rendering when camera shows antimeridian or multiple world copies. - Fix elevated line occlusion issue in 2D mode.
- Fix blinking of layer as you are panning across the antimeridian.
- Fix
modelFrontCutoff
property for meshopt models. - Align location provider default displacement for Android and Google providers.
Dependencies
- Update gl-native to v11.6.0 and common to v24.6.0.
v11.6.0-rc.1
11.6.0-rc.1 August 02, 2024
Features ✨ and improvements 🏁
- Support negative values for
CircleLayer.circleBlur
to render inner glow effect. - Add new
Style.STANDARD_SATELLITE
style that combines updated satellite imagery and vector layers. More information could be found here. - Introduce new import configuration properties for
Style.STANDARD
:theme
,show3dObjects
which could be set withStyle.setStyleImportConfigProperty
. More information could be found here. - [compose] Extend
StandardStyleConfigurationState
withtheme: ThemeValue
andshow3dObjects: BooleanValue
properties. - [compose] Introduce composable function
MapboxStandardSatelliteStyle
with dedicatedStandardSatelliteStyleConfigurationState
.
Bug fixes 🐞
- Fix elevated line occlusion issue in 2D mode.
Dependencies
- Update gl-native to v11.6.0-rc.1 and common to v24.6.0-rc.1.
Known issues
- Experimental
ClipLayer
's propertyclipLayerTypes
is not updated in runtime. The fix is expected to land in stable 11.6.0.
v11.5.1
11.5.1 July 25, 2024
Bug fixes 🐞
- Fix local glyph rasterization to ensure the correct Typeface is used.
- Fix map freezing and huge memory consumption issue when using 3D models.
- Fix
CustomRasterSource
rendering when camera shows antimeridian or multiple world copies. - Fix shadow rendering issues with
FillExtrusionLayer.fillExtrusionCutoffFadeRange
.
Dependencies
- Update gl-native to v11.5.2.
v10.18.3
10.18.3 July 22, 2024
Bug fixes 🐞
- Fix multiple annotation clusters not supported issue.
v11.6.0-beta.1
11.6.0-beta.1 July 19, 2024
Breaking changes ⚠️
- [compose] Remove
StyleImage
constructor withBitmapImage
, userememberStyleImage
composable function to build it instead. - [compose] Move layer properties within
*Layer
composable functions to*LayerState
classes, use the convenient method*Layer(sourceState, layerId, init)
with trailing lambda for easier migration (see migration example). - [compose] Move
onClick
listener from last parameter to the second last parameter ofAnnotation
andAnnotationGroup
composable functions. - [compose] Move properties within
*Annotation
and*AnnotationGroup
composable functions to the new*AnnotationState
and*AnnotationGroupState
classes, use the convenient method*Annotation(point, onClick, init)
and*AnnotationGroup(annotations, annotationConfig, onClick, init)
with trailing lambda for easier migration (see migration example). - [compose] Replace color int and color string property types in
*Annotation
with composeColor
type. - [compose] Replace
PointAnnotation.iconImageBitmap
andPointAnnotation.iconImage
withPointAnnotationState.iconImage
withIconImage
type,IconImage
can be constructed with either a image idString
or aBitmap
, and introducedrememberIconImage
to build and remember a bitmap fromPainter
or from a drawable resource id. - [compose] Introduce
StandardStyleConfigurationState
class to hold the configurations ofMapboxStandardStyle
, and movelightPreset
config fromMapboxStandardStyle
toStandardStyleConfigurationState
; consider using overload methodMapboxStandardStyle
with trailing init lambda for easier migration. - Experimental
CustomRasterSourceOptions.Builder
now acceptsCustomRasterSourceClient
containingCustomRasterSourceTileStatusChangedCallback
instead ofCustomRasterSourceTileStatusChangedCallback
interface directly.
Features ✨ and improvements 🏁
- [compose] Promote Compose Extension to stable.
- [compose] Mark
MapState
,MapViewportState
,TerrainState
, light states and source states asStable
as they are internally backed byMutableState
. - [compose] Add more config options including
showPlaceLabels
,showRoadLabels
,showPointOfInterestLabels
,showTransitLabels
andfont
toStandardStyleConfigurationState
. - [compose] Introduce
StyleImage
constructor withImage
type, and addrememberStyleImage
composable functions to create and rememberStyleImage
. - [compose] Add extension function to
*AnnotationOptions
to handle composeColor
, use it in*AnnotationGroup
composable functions for convenience. - [compose] Add style transition parameter in
GenericStyle
,MapStyle
andMapboxStandardStyle
. - Modify
awaitCameraForCoordinates
extension function to useMapCameraManagerDelegate
as receiver type. - Modify
queryRenderedFeatures
andquerySourceFeatures
extension functions to useMapFeatureQueryDelegate
as receiver type. - Introduce asynchronous overloaded method
ViewAnnotationManager.cameraForAnnotations
better covering some corner cases. - Make use of asynchronous
MapboxMap.cameraForCoordinates
in Mapbox overlay plugin better covering some corner cases. - Mark synchronous methods
MapboxMap.cameraForCoordinates
andViewAnnotationManager.cameraForAnnotations
with@MapboxDelicateApi
. Consider using asynchronous overloaded methods instead. - Deprecate
MapboxMap.getDebug()
/MapboxMap.setDebug()
in favour ofMapView.debugOptions
taking new enhanced enumMapViewDebugOptions
as an argument. - Introduce
MapViewDebugOptions.CAMERA
andMapViewDebugOptions.PADDING
debug options to track current camera state and visualize camera paddings. - Expose experimental
ClipLayer
to remove 3D data (fill extrusions, landmarks, instanced trees) and symbols. - Enable r8 optimisations for all the Mapbox extensions and plugins in consumer proguard file, the optimisation will apply when minify is enabled in app's build settings.
- Align default displacement for Android and Google location providers.
- Enable direct rendering into
CustomRasterSource
tiles. - Introduce a new
allowZElevate
option inViewAnnotationOptions
. When set to true, the annotation will be positioned on the rooftops of buildings, including both fill extrusions and models.
Bug fixes 🐞
- [compose] Fix minZoom/maxZoom not working for layers.
- [compose] Fix
java.lang.UnsupportedOperationException
when settingtextWritingMode
andtextVariableAnchor
. - Fix compass view ignoring
enabled
option when it is set inupdateSettings()
. - Fix background locations not received when unregistering other providers.
- Improve
linePattern
precision. - Fix local glyph rasterization to ensure the correct Typeface is used.
- Fix
CustomRasterSource
rendering when camera shows antimeridian or multiple world copies.
Known issues
ClipLayer.clipLayerTypes
could not be updated with a layer setter. Layer has to be re-added to update it. This is expected to be fixed in v11.6.0-rc.1.
Dependencies
- Update gl-native to v11.6.0-beta.1 and common to v24.6.0-beta.1.
v11.4.2
11.4.2 July 17, 2024
Bug fixes 🐞
- Fix local glyph rasterization to ensure the correct Typeface is used.
Dependencies
- Update gl-native to v11.4.1.
v11.5.0
11.5.0 July 05, 2024
Breaking changes ⚠️
- [compose] Make
MapboxMap.onMapClickListener
andMapboxMap.onMapLongClickListener
nullable and default tonull
. - [compose] Rename
ImportConfig
toImportConfigs
. - [compose] Move
MapboxMap.mapEvents
to events flows inMapState
. - [compose] Move
MapboxMap.gesturesSettings
toMapState
. - [compose] Move
Projection
togenerated
package and renamedefault
values toDEFAULT
. - [compose] Rename
LightPreset
toLightPresetValue
. - [compose] Rename
TerrainState.disabled
toTerrainState.DISABLED
. - [compose] Replace terrain property
Exaggeration
withDoubleValue
. - [compose] Replace concrete
AtmosphereState
properties (e.g.HighColor
,HorizonBlend
,SpaceColor
, etc) with generic ones:ColorValue
,DoubleValue
,DoubleRangeValue
. - [compose] Replace concrete Layer properties(e.g.
CircleColor
,CircleOpacity
,IconImage
etc) with generic ones:ColorValue
,DoubleValue
,ImageValue
etc. - [compose] Replace concrete
GeoJsonSourceState
,ImageSourceState
,RasterArraySourceState
,RasterDemSourceState
,RasterSourceState
,SourceProperties
,VectorSourceState
properties with generic ones (e.g.BooleanValue
,StringValue
,LongValue
...). - [compose] Move
GeoJSONData
outside ofgenerated
package. - Remove experimental
CustomRasterSource.invalidateRegion
andCustomRasterSource.invalidateTile
methods and change signature ofCustomRasterSource.setTileData
. - Remove experimental
CustomRasterSource.tileCacheBudget
getter and setter. If needed, caching should be implemented on user's side. - Remove experimental
MapboxMap
andStyle
methods:invalidateStyleCustomRasterSourceTile
,invalidateStyleCustomRasterSourceRegion
; change signature ofsetStyleCustomRasterSourceTileData
method inMapboxMap
andStyle
.
Features ✨ and improvements 🏁
- [compose] Enable r8 optimisations of compose extension in consumer proguard file, the optimisation will apply when minify is enabled in app's build settings.
- [compose] Introduce
StyleImport
composable API to be used in theGenericStyle
,MapStyle
andMapboxStandardStyle
. - [compose] Introduce
MapState
that can be hoisted to interact with map states, such as query rendered features, subscribe to map events and configure gestures settings. - [compose] Expose
TerrainState
andAtmosphereState
properties asMutableState
. - [compose] Introduce
AmbientLightState
,DirectionalLightState
,FlatLightState
as separate states;LightsState
can be constructed by combination ofDirectionalLightState
andAmbientLightState
or withFlatLightState
to be set to the style. - [compose] Avoid recreation of objects during recomposition of
GenericStyle
. - Expose
LineJoin.NONE
which in conjunction with e.g.linePattern
image allows to display repeated series of images along a line (e.g. dotted route line). - Expose new function
DefaultLocationProvider.locationAnimatorOptions
to allow changing the value animator properties for puck position animation. - Deprecate
MapboxMap.cameraForCoordinates
suspending extension function in favour of suspendMapboxMap.awaitCameraForCoordinates
. - Add min/max/default values to the docs for the generated properties.
- Add asynchronous
TileStore.create().clearAmbientCache()
API that can be used for clearing all ambient cache data. - Expose experimental
lineZOffset
andlineOcclusionOpacity
forLineLayer
. - Expose experimental
modelFrontCutoff
forModelLayer
. - Expose experimental
iconOcclusionOpacity
andtextOcclusionOpacity
forSymbolLayer
andPointAnnotationManager
. - Expose experimental
lineOcclusionOpacity
forPolylineAnnotationManager
. - Expose experimental
lineZOffset
forPolylineAnnotation
andPolylineAnnotationOptions
. - Expose
clusterMinPoints
property forGeoJSONSource
and for annotation'sClusterOptions
. - Remove explicit main thread locking when using
CircleAnnotationManager
,PointAnnotationManager
,PolygonAnnotationManager
,PolylineAnnotationManager
and dragging the map that could lead to an ANR. - Use dedicated thread for the tile store to increase performance.
- [compose] Expose
TerrainState
andAtmosphereState
properties asMutableState
.
Bug fixes 🐞
- [compose] Fix the layer and annotation ordering by moving the annotations/layers according to the relative position in the node tree.
- [compose] Fix
No enum constant com.mapbox.maps.GeoJSONSourceData
crash when restoring app from background. - Fix transitioning to
OverviewViewportState
in corner cases when the map is not yet ready for rendering(e.g. immediately afterMapView
is created). - Set default minimum displacement between location updates to 0.1 meters in
DefaultLocationProvider
. Now this value is the same regardless of application using Google Play Services location library or not. - Fix
PointAnnotationManager
andCircleAnnotationManager
cluster layer id collision issue, so that multiple clusters can work at the same time. - Fix
RasterParticleLayer.rasterParticleCount
andRasterParticleLayer.defaultRasterParticleCount
returningnull
. - Fix an issue allowing view annotation to be added even if its associated layer does not exist. Now, view annotation will function correctly once the layer is added.
- Fix feature queries for symbols above the horizon.
- Fix the rotated icon position during the globe transition.
- Fix Dynamic View Annotation (DVA) placement to place DVA in the center of the line geometry point, and try to avoid placing DVA near the lines' intersection point.
- Reduce the max raster-particle animation speed. It prevents particles from moving too fast, causing a visible clipping artifact at tile boundaries.
Snapshotter
methods throwSnapshotterDestroyedException
ifdestroy
was already called.- Fix precision issues in
ColorUtils
methods. - Fix NPE when parsing
rgb(...)
strings withColorUtils
methods. - Fix
ScaleBar.useContinuousRendering
not being in sync withScaleBar.settings.useContinuousRendering
. - Fix accuracy ring related location settings updates not being rendered immediately.
- Fix a crash for Draco compressed 3D models whose geometry share indices.
- Fix tile rendering errors when the composited source tile components are overscaled.
- Fix transparent areas in overlapped polygons of MultiPolygon feature.
- Fix crash on multiple style pack loading operations.
Dependencies
- Update gl-native to v11.5.1 and common to v24.5.0.
v10.18.2
10.18.2 June 24, 2024
Features ✨ and improvements 🏁
- Remove explicit main thread locking when using
CircleAnnotationManager
,PointAnnotationManager
,PolygonAnnotationManager
,PolylineAnnotationManager
and dragging the map that could lead to an ANR.
v11.5.0-rc.1
11.5.0-rc.1 June 20, 2024
Breaking changes ⚠️
- [compose] Make
MapboxMap.onMapClickListener
andMapboxMap.onMapLongClickListener
nullable and default tonull
. - [compose] Rename
ImportConfig
toImportConfigs
. - [compose] Move
MapboxMap.mapEvents
to events flows inMapState
. - [compose] Move
MapboxMap.gesturesSettings
toMapState
. - Remove experimental
CustomRasterSource.invalidateRegion
andCustomRasterSource.invalidateTile
methods and change signature ofCustomRasterSource.setTileData
. - Remove experimental
CustomRasterSource.tileCacheBudget
getter and setter. If needed, caching should be implemented on user's side. - Remove experimental
MapboxMap
andStyle
methods:invalidateStyleCustomRasterSourceTile
,invalidateStyleCustomRasterSourceRegion
; change signature ofsetStyleCustomRasterSourceTileData
method inMapboxMap
andStyle
.
Features ✨ and improvements 🏁
- [compose] Introduce
StyleImport
composable API to be used in theGenericStyle
,MapStyle
andMapboxStandardStyle
. - [compose] Introduce
MapState
that can be hoisted to interact with map states, such as query rendered features, subscribe to map events and configure gestures settings. - Deprecate
MapboxMap.cameraForCoordinates
suspending extension function in favour of suspendMapboxMap.awaitCameraForCoordinates
. - Add min/max/default values to the docs for the generated properties.
- Add asynchronous
TileStore.create().clearAmbientCache()
API that can be used for clearing all ambient cache data. - Expose experimental
lineZOffset
andlineOcclusionOpacity
forLineLayer
. - Expose experimental
modelFrontCutoff
forModelLayer
. - Expose experimental
iconOcclusionOpacity
andtextOcclusionOpacity
forSymbolLayer
andPointAnnotationManager
. - Expose experimental
lineOcclusionOpacity
forPolylineAnnotationManager
. - Expose experimental
lineZOffset
forPolylineAnnotation
andPolylineAnnotationOptions
.
Bug fixes 🐞
- Fix
RasterParticleLayer.rasterParticleCount
andRasterParticleLayer.defaultRasterParticleCount
returningnull
. - Fix the rotated icon position during the globe transition.
- Fix Dynamic View Annotation (DVA) placement to place DVA in the center of the line geometry point, and try to avoid placing DVA near the lines' intersection point.
- Reduce the max raster-particle animation speed. It prevents particles from moving too fast, causing a visible clipping artifact at tile boundaries.
Dependencies
- Update gl-native to v11.5.0-rc.1 and common to v24.5.0-rc.1.
v11.5.0-beta.1
11.5.0-beta.1 June 11, 2024
Breaking changes ⚠️
- [compose] Move
Projection
togenerated
package and renamedefault
values toDEFAULT
. - [compose] Rename
LightPreset
toLightPresetValue
. - [compose] Rename
TerrainState.disabled
toTerrainState.DISABLED
. - [compose] Replace terrain property
Exaggeration
withDoubleValue
. - [compose] Replace concrete
AtmosphereState
properties (e.g.HighColor
,HorizonBlend
,SpaceColor
, etc) with generic ones:ColorValue
,DoubleValue
,DoubleRangeValue
. - [compose] Replace concrete Layer properties(e.g.
CircleColor
,CircleOpacity
,IconImage
etc) with generic ones:ColorValue
,DoubleValue
,ImageValue
etc. - [compose] Replace concrete
GeoJsonSourceState
,ImageSourceState
,RasterArraySourceState
,RasterDemSourceState
,RasterSourceState
,SourceProperties
,VectorSourceState
properties with generic ones (e.g.BooleanValue
,StringValue
,LongValue
...). - [compose] Move
GeoJSONData
outside ofgenerated
package.
Features ✨ and improvements 🏁
- Expose
clusterMinPoints
property forGeoJSONSource
and for annotation'sClusterOptions
. - Remove explicit main thread locking when using
CircleAnnotationManager
,PointAnnotationManager
,PolygonAnnotationManager
,PolylineAnnotationManager
and dragging the map that could lead to an ANR. - Use dedicated thread for the tile store to increase performance.
- [compose] Expose
TerrainState
andAtmosphereState
properties asMutableState
. - [compose] Introduce
AmbientLightState
,DirectionalLightState
,FlatLightState
as separate states;LightsState
can be constructed by combination ofDirectionalLightState
andAmbientLightState
or withFlatLightState
to be set to the style. - [compose] Avoid recreation of objects during recomposition of
GenericStyle
.
Bug fixes 🐞
- [compose] Fix
No enum constant com.mapbox.maps.GeoJSONSourceData
crash when restoring app from background. Snapshotter
methods throwSnapshotterDestroyedException
ifdestroy
was already called.- Fix precision issues in
ColorUtils
methods. - Fix NPE when parsing
rgb(...)
strings withColorUtils
methods. - Fix
ScaleBar.useContinuousRendering
not being in sync withScaleBar.settings.useContinuousRendering
. - Fix accuracy ring related location settings updates not being rendered immediately.
- Fix a crash for Draco compressed 3D models whose geometry share indices.
- Fix tile rendering errors when the composited source tile components are overscaled.
- Fix transparent areas in overlapped polygons of MultiPolygon feature.
- Fix crash on multiple style pack loading operations.
Dependencies
- Update gl-native to v11.5.0-beta.1 and common to v24.5.0-beta.4.