Tell me more ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I would like to insert the BLOB data of a tile to a sqlite database (WebSQL) in order to create an MBtiles compatible database; Is there a class/method that will allow this? I have looked at canvasContext and OpenLayers.Tile.Image without success. The methods that would seem to work only give me back objects instead of the raw PNG/JPEG blob data.

canvasContext.canvas.toDataUrl() will not work for me because it is a string, not binary data.

EDIT: After a bit more creative googling, I found that it was easier to take the dataURL and construct a Blob from that.

http://stackoverflow.com/questions/6850276/how-to-convert-dataurl-to-file-object-in-javascript

share|improve this question

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.