mapbox / mbtiles-spec

specification documents for the MBTiles tileset format
https://www.mapbox.com/help/an-open-platform/#mbtiles
Other
612 stars 99 forks source link

Mixed Image File Format #33

Closed cmorabito-woolpert closed 10 years ago

cmorabito-woolpert commented 11 years ago

Propose adding a "mixed" image file format, like the MapServer or ArcGIS Server "MIXED" cache modes. This would indicate that the database contains both JPEG and PNG images, supporting a scenario--useful in overlay layers--where PNGs are used only where transparency is needed and JPEGs are used elsewhere. This minimizes cache size while guaranteeing that the layer will cleanly overlay on a basemap layer.

incanus commented 11 years ago

Is specifying the format absolutely needed? The current spec doesn't say which format it would be and leaves this up to the client to decode. I think it's better kept that way, because you could technically also have GIF, TIFF, BMP...

kkaefer commented 11 years ago

Yup, we currently don't really respect this field and always automatically detect the correct image decoder. Almost all image formats use magic bytes at the beginning so this shouldn't be an issue.