Comments (6)
I have verified this happens only with databases generated using TileMill. When I try it with the ones provided by the sample it works perfectly.
from deprecated-mapbox-ios-sdk.
Hmm, this is odd. Can you maybe provide a sample MBTiles for me to try?
from deprecated-mapbox-ios-sdk.
I have done some additional testing and found something very odd.
I did all the testing using the Sample App to take code errors out of the equation.
So, using the provided mbtiles (control room) everything works as expected.
When using a mbtiles database generated using TilleMill not even the sample app works.
Here is an example mbtiles where this happens: https://www.dropbox.com/s/3h0vqcr1b8enrxc/metro%5B1.0%5D.mbtiles
When analyzing the structure of both databases you can clearly see they are completely different:
So I went and manually changed the structure of the databse to match the Control Room database and it is all working now.
So I am absolutely sure the problem is that the databases being exported from TilleMill dont have the same format as the ones used on the example app.
Please tell me if I can do anything else to help, I could also send you the python script I used to fix the database structure.
from deprecated-mapbox-ios-sdk.
I'll check out this file you've linked, but the schema differences are ok. See the spec. The grid stuff is all optional and is related to interactivity. All you really need is metadata
and tiles
, which can be either a true table or a view as done in the left example following de-duplication optimizations.
from deprecated-mapbox-ios-sdk.
I was fighting with it in my head forever too, as it SHOULD work the same with tiles as a view instead of a table, but for some strange reason it doesn't load on my app and it doesn't load on the sample app either.
Hopefully you can figure out what is going on, what I did to make it work was create a new database with just two tables and copied the info from the tiles view on the original to an actual table on a new database.
from deprecated-mapbox-ios-sdk.
So I just grabbed your MBTiles and after renaming it to metro.mbtiles
(to avoid the square brackets) it works fine on both sim and device. I'm doing this:
mapView.zoom = 13;
CLLocationCoordinate2D centerCoordinate = {
.latitude = 19.4326,
.longitude = -99.1331
};
[mapView setCenterCoordinate:centerCoordinate animated:NO];
After instantiating the map view in OfflineLayerViewController
.
from deprecated-mapbox-ios-sdk.
Related Issues (20)
- Can't even add the map on device! HOT 1
- MapboxGL on XCode Version 7.0 beta (7A121l) HOT 2
- RMPointAnnotation need access token to place it on map
- MGLPolygon HOT 2
- RMShape layer size problem
- Buildings size HOT 1
- Not downloading all the needed tiles in beginBackgroundCacheForTileSource:southWest:northEast:minZoom:maxZoom: HOT 3
- Rotate map and 3d HOT 2
- Animate annotations HOT 1
- Setting RMMapView frame in an animation block doesn't animate centerCoordinate HOT 1
- RMGreatCircleAnnotation bug - and fix HOT 1
- deprecate repo in favor of GL HOT 2
- Converting a CGPoint to a CLLocation or CLLocationCoordinate2D (Question) HOT 2
- Cached Tiles not showing - Mapbox 1.6.1 (iOS 8) HOT 4
- Map Attribution not display AppName (Mapbox 1.6.1) HOT 1
- After iOS 9 huge CPU usage HOT 2
- MapBox SDK deprecated HOT 2
- iOS 8: center coordinate not in the middle HOT 1
- Method "selectAnnotation: animated:" doesn't work. HOT 1
- How to set my own annotation pin instead of default pin? HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from deprecated-mapbox-ios-sdk.