[gdal-dev] GDAL can't open MBTiles sample from the MapBox site

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[gdal-dev] GDAL can't open MBTiles sample from the MapBox site

jratike80
Hi,
On page https://www.mapbox.com/help/define-mbtiles/ there is a link into
https://www.mapbox.com/help/data/trails.mbtiles

My GDAL 2.3.0dev does list MBTiles as a supported format but it can't still open this database

gdalinfo trails.mbtiles
ERROR 4: `trails.mbtiles' not recognized as a supported file format.
gdalinfo failed - unable to open 'trails.mbtiles'.

-Jukka Rahkonen-
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: GDAL can't open MBTiles sample from the MapBox site

Even Rouault-2
On mercredi 28 mars 2018 14:28:14 CEST Rahkonen Jukka (MML) wrote:

> Hi,
> On page https://www.mapbox.com/help/define-mbtiles/ there is a link into
> https://www.mapbox.com/help/data/trails.mbtiles
>
> My GDAL 2.3.0dev does list MBTiles as a supported format but it can't still
> open this database
>
> gdalinfo trails.mbtiles
> ERROR 4: `trails.mbtiles' not recognized as a supported file format.
> gdalinfo failed - unable to open 'trails.mbtiles'.

Jukka,

Yep, there's no raster in that file, but vector instead.
So:

$ ogrinfo trails.mbtiles -al -so
INFO: Open of `trails.mbtiles'
      using driver `MBTiles' successful.
Metadata:
  ZOOM_LEVEL=14
  center=-113.8348,48.6402,9
  format=pbf
  maxzoom=14
  minzoom=0

Layer name: multilinestring-glacier_trails
Geometry: Unknown (any)
Feature Count: 1409
Extent: (-12743581.355705, 6149206.051486) - (-12604160.216112,
6276397.266552)
Layer SRS WKT:
PROJCS["WGS 84 / Pseudo-Mercator",
    GEOGCS["WGS 84",
        DATUM["WGS_1984",
            SPHEROID["WGS 84",6378137,298.257223563,
                AUTHORITY["EPSG","7030"]],
            AUTHORITY["EPSG","6326"]],
        PRIMEM["Greenwich",0,
            AUTHORITY["EPSG","8901"]],
        UNIT["degree",0.0174532925199433,
            AUTHORITY["EPSG","9122"]],
        AUTHORITY["EPSG","4326"]],
    PROJECTION["Mercator_1SP"],
    PARAMETER["central_meridian",0],
    PARAMETER["scale_factor",1],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]],
    AXIS["X",EAST],
    AXIS["Y",NORTH],
    EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0
+x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"],
    AUTHORITY["EPSG","3857"]]
mvt_id: Integer64 (0.0)
Avg_Slope: Real (0.0)
CLASS: Real (0.0)
DESC_SEG: String (0.0)
LENGTH: Real (0.0)
MILES: Real (0.0)
NAME: String (0.0)
ROUTE_NO: Real (0.0)
SEG_NO: Real (0.0)
evaluating: String (0.0)

Even

--
Spatialys - Geospatial professional services
http://www.spatialys.com
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: GDAL can't open MBTiles sample from the MapBox site

jratike80
Hi Even,

Thanks, after updating my GDAL to a more recent 2.3.0dev version ogrinfo indeed shows that information.

-Jukka-
________________________________________
Lähettäjä: Even Rouault <[hidden email]>
Lähetetty: 28. maaliskuuta 2018 17:47
Vastaanottaja: [hidden email]
Kopio: Rahkonen Jukka (MML)
Aihe: Re: [gdal-dev] GDAL can't open MBTiles sample from the MapBox site

On mercredi 28 mars 2018 14:28:14 CEST Rahkonen Jukka (MML) wrote:

> Hi,
> On page https://www.mapbox.com/help/define-mbtiles/ there is a link into
> https://www.mapbox.com/help/data/trails.mbtiles
>
> My GDAL 2.3.0dev does list MBTiles as a supported format but it can't still
> open this database
>
> gdalinfo trails.mbtiles
> ERROR 4: `trails.mbtiles' not recognized as a supported file format.
> gdalinfo failed - unable to open 'trails.mbtiles'.

Jukka,

Yep, there's no raster in that file, but vector instead.
So:

$ ogrinfo trails.mbtiles -al -so
INFO: Open of `trails.mbtiles'
      using driver `MBTiles' successful.
Metadata:
  ZOOM_LEVEL=14
  center=-113.8348,48.6402,9
  format=pbf
  maxzoom=14
  minzoom=0

Layer name: multilinestring-glacier_trails
Geometry: Unknown (any)
Feature Count: 1409
Extent: (-12743581.355705, 6149206.051486) - (-12604160.216112,
6276397.266552)
Layer SRS WKT:
PROJCS["WGS 84 / Pseudo-Mercator",
    GEOGCS["WGS 84",
        DATUM["WGS_1984",
            SPHEROID["WGS 84",6378137,298.257223563,
                AUTHORITY["EPSG","7030"]],
            AUTHORITY["EPSG","6326"]],
        PRIMEM["Greenwich",0,
            AUTHORITY["EPSG","8901"]],
        UNIT["degree",0.0174532925199433,
            AUTHORITY["EPSG","9122"]],
        AUTHORITY["EPSG","4326"]],
    PROJECTION["Mercator_1SP"],
    PARAMETER["central_meridian",0],
    PARAMETER["scale_factor",1],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]],
    AXIS["X",EAST],
    AXIS["Y",NORTH],
    EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0
+x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"],
    AUTHORITY["EPSG","3857"]]
mvt_id: Integer64 (0.0)
Avg_Slope: Real (0.0)
CLASS: Real (0.0)
DESC_SEG: String (0.0)
LENGTH: Real (0.0)
MILES: Real (0.0)
NAME: String (0.0)
ROUTE_NO: Real (0.0)
SEG_NO: Real (0.0)
evaluating: String (0.0)

Even

--
Spatialys - Geospatial professional services
http://www.spatialys.com
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev