Mapbox Navigation Blue Line Layer with KML data line in iOS - mapbox

My application loads different KML data lines on the map. Now, when the user draws the route on the map, a blue line hides the KML data lines. I want to make data lines visible on top of the navigation blue line.
Can anyone help me to resolve this?
I have already checked for the below link solution, but it didn't work for me.
https://github.com/mapbox/mapbox-navigation-ios/pull/3897
I am attaching screens of my application.
Mapbox map with KML data load
Mapbox with KML data and navigation blue line

Related

How to edit MapBox Style editor dynamic on app

I'm developing a map app using mapbox_gl package, and trying to edit style layer while app is running.
Generally, style layers are edited using the MapBox style editor. But I want to change the state of the layer depending on the conditions of the app user.
For example, in the MapBox style editor, set a layer to show a red line tracing the road as shown in the image below.
And I want to be able to change this to blue within the app.
But I don't know how to edit the state of the layer. Anyone know how to do this?

problem of displaying geojson file with leaflet

I want to display the attributes of a shapefile layer using leaflet, I found that should i to convert the layer from shp to GeoJson. I can display the popups of my layers but the large layers can not displayed and the computer is not responding.
what is the solution?

Mapbox gl repeat marker

I try to repeat a marker at the same coordinates when I am moving the map to infinity, in the same way that layers.
example : https://www.mapbox.com/mapbox-gl-js/example/geojson-polygon/
Has anyone found how to do that please?
If it's not possible, conversely is it possible to not repeat layers when you moving the map ?
Thank you
The Link example you provided is not using Markers to render the shaded area. It is using a feature, in this case a polygon, included in a layer (a layer can have many features).
In MapBox the rendered map is made up of any number of layers (including the tile data) which is rendered whenever you scroll or drag to a particular area of the map. For example as you keep dragging to the right in the map it will just keep rendering in the relevant layers and tiles.
The Marker functionality has a different purpose which is as a one off selected point which is useful for a user click or hover interaction.

Multicolor polylines for a route in mapbox

i record routes with my app, mostly for motorbikes, and want to color it depending on the speed at each point of the route.
basically i know how to do it in mapbox and that is the problem. since you can set a color for only one polyline, i have to split up the route in speed sections and print every route sections polyline with it's specific color, which works fine basically. problem is that i have up to 500-2000 polylines for a route. so the map crashes very easily.
i don't have that problem when i set like 5000 image annotations to the map, which i can color individually. this could be a solution but it can take up to 20 seconds to print all image annotations. any other options to make a colored route like the on in the image ?
This is not possible with out of the box mapbox polylines.
You will have to add a new layer, perform the translations and add the gradient lines yourself. This might get you started drawing the lines:
https://stackoverflow.com/a/25034854/4019540
Good luck

Is it possible to overlay an icon on top of a geometry object in Open Street Map?

I was wondering if it was possible to overlay an icon marker over a geometry object in Open Street Maps. I am using gwt-openlayers which is a java wrapped version of the open layers api with an Open Street Map tile server in Eclipse. If anyone has any knowledge about this I'd greatly appreciate it.
Thanks,
Matt
You can if these geometric objects are points by using the externalGraphic property which is a URL of the image.
If you need to overlay them on top of a polygon just create an ImageOverlay on top of the center of the polygon.
I have it figured out. I am just making two different layers, one for the markers and one for the geometry figures. I am overlaying the markers over the geometry figures by adding the markers to the top of the layer list.