Code Monkey home page Code Monkey logo

Comments (11)

ns-1m avatar ns-1m commented on July 25, 2024

Is MbTiles supported in Openlayers? It seems that there is configuration to get tiles.

Please check this example,

http://trac.geoext.org/browser/sandbox/gxm/geoext/gxm/external/OpenLayers.r11966/examples/tms.html?rev=2677

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

The second argument to the constructor should be the base path, not a path of a tile:

new OpenLayers.Layer.TMS("MapBox Tile Natural Earth 2", "http://localhost:8888/", {
    layername: 'natural-earth-2',
    type: 'png',
    transitionEffect: 'resize'
}),

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

Also, OpenLayers does not access MBTiles directly - a component is needed to serve tiles from localhost or any other server. Unless http://localhost:8888/1.0.0/natural-earth-2/0.0.0.png resolves in your iPad app, this won't work.

from mbtiles-spec.

ns-1m avatar ns-1m commented on July 25, 2024

I realise it now that TMS or Openlayers Base Maps (e.g. WMS, TMS, etc.) are design to work on server side.

Since natural-earth-2.mbtiles is sqlite3 base format can I assign it into a sqlite3 database and query it using SQL select statement to get the tiles? If I can do a SELECT query, what is the SQL query and how would it be pass to Openlayers.Layer.TMS?

is "http://localhost:8888/1.0.0/natural-earth-2/0.0.0.png" string that can be equated in text.value? I am not sure where this question is leading to? But fishing for ideas how to pass the data from WebView to the mbtile and vice versa.

Any ideas how to get a local support for MbTiles in mobile gadget without the server?

One possible way is to have a server in the ipad. Possible in Jailbreak ipad and use Tileserver with Node.js.

Still waiting for ipad 2 jailbreak.

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

You've seen the MapBox iPad App right? This is exactly what it sets out to do.

from mbtiles-spec.

ns-1m avatar ns-1m commented on July 25, 2024

new OpenLayers.Layer.TMS("MapBox Tile Natural Earth 2", "http://localhost:8888/", {
layername: 'natural-earth-2',
type: 'png',
transitionEffect: 'resize'
}),

Can I map this "http://localhost:8888/" into the mbtiles in Objective-C

var sampleDatabase = new DataAccessObject("natural-earth2.mbtiles")

Now in WebView javascript side

http://localhost:8888/ = sampleDatabase

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

Er, yes, kind of. See the route-me project that has a connector for mbtiles, and the mbtiles ios example. If you aren't going the MapBox for iPad app route or an online server, this is probably a several-week task to do this with OpenLayers, which, unless you really need its other capabilities, isn't a necessary tool for this.

from mbtiles-spec.

ns-1m avatar ns-1m commented on July 25, 2024

I want Spatialite visualation in Openlayers thru JSTS. I can query my spatialite to render polygons, route, KML just PostGIS terminal is doing. However, I like to do with Javascript Topology Suite (JSTS), PostGIS terminal is using AsWKT function.

I can visualite crime statistic, umemployment figures, property values on Spatialite terminal and get the map in Openlayer canvas.

from mbtiles-spec.

ns-1m avatar ns-1m commented on July 25, 2024

I am not a programmer / developer, I am struggling with Objective-C
and route-me people are not so helpful at. Does not reply to questions
Hence, I just try to do it javascript / jquery.

On 6/2/11, tmcw
[email protected]
wrote:

Er, yes, kind of. See the route-me
project
that has a connector for
mbtiles, and the mbtiles ios
example
. If you aren't going
the MapBox for iPad app route or an online server, this is probably a
several-week task to do this with OpenLayers, which, unless you really need
its other capabilities, isn't a necessary tool for this.

Reply to this email directly or view it on GitHub:
#14 (comment)

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

OpenLayers unfortunately isn't going to make your job any easier on the iPad. You might want to try out the mbtiles ios example and see if you can modify it to your needs, or see if you can pre-render visualizations and use them in the MapBox iPad app.

from mbtiles-spec.

tmcw avatar tmcw commented on July 25, 2024

Closing; this is outside the scope of this respository.

from mbtiles-spec.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.