JME for Rendering World Maps

Hello Everyone.

It’s been AGES since I last was here :slight_smile: . Work has kept me very busy for a long time.

I am working on a library to render 3D real world maps using JME that anyone can use for their game or app. It will have the following features:

  • Raster tiles: This is essentially textures of maps such as in satellite or street maps.
  • Vector tiles: 3D data that will feed JME to render as a geometry.
  • Terrain heights: when there are mountains and valley data (where available) it should reflect on the map.
  • and more:

For more info about map Raster and Vector tiles you can get a quick idea Here.

I am implementing some tech features as I am working on this:

  • Local caching on data (Raster and Vector) from web providers using sqlite.
  • Being able to obtain map data from multiple providers (Mapbox, MapTiler, Bing, Google, etc).
  • Procedural generation of maps keeping the use of assets to a minimum.
  • Zoom in and out of the map to get different detail data.

There are other things I want to support but first I need to get the base rendering on the map going.
So far I have a small tile from San Francisco that I use as a test while comparing with other libraries used for other game engines.

It will become open source in the future (MIT license). So far the project is still in diapers

Here is a screenshot:

14 Likes

Sounds great! keep us updated :slight_smile:

Here are some updates:

  • Now with latitude, longitude and zoom level you can create an area map of anywhere in the world as long as it is available online.
  • You can define the size of the map in tiles, it will be a square map, so you can have from 2x2 to whatever you see fit. However I am planning to have an upper limit of 10x10 due to performance. Usually a 5x5 is a sweet spot.
  • Since we can have terrain, you can also set the detail, the more detail the better looking it may be but you will have higher poly meshes. The default value for the tile is 10x10 vertices.

Things I am working on:

  • Stitching: The terrain is formed but it creates gaps between adjacent tiles, so a stitching algorithm needs to be added to ensure the borders meet correctly and reduce the gaps.
  • Vector Tiles: This is a complex part which is creating the geometries of buildings based on map data. I have the reading of the data ready but it needs to be transformed into 3D geometries on the map.
  • Multithreading: For ease of development everything is running on the main thread which is easy but not optimal. Once I have the Vector tiles I will go to this step to increase speed in rendering the map area

While you can see the map area of San Francisco here. I will share one of Tokyo in this thread

1 Like

Just drop a skirt. If the tiles already align edge-to-edge and it’s just a matter of different resolutions then just drop a vertical skirt… where the lower edges have the exact same normal, texture coordinate, etc. as the top edge.

It will magically fill in the gaps.

1 Like

I will try that out, thanks :grinning:

Edit: got this now

5 Likes

I am back with more stuff.

I added support for vector tiles. The representation for buildings in the real world environment based on data provided by services like Mapbox.

This sample here is merging the building meshes before rendering. I am also putting some processes to be done on separate threads using the executor and callback listeners to reduce load on the running thread.

8 Likes

Very nice work! are you rendering a .mvt (MapBox vector tiles) format tiles or .PBF tiles? or is it any other tile format?

I am currently rendering .pbf vector tiles. However, I am planning to add support for .mvt and GeoJson in the future :slight_smile:

1 Like

Nice! I’m interested in tile rendering (I’m developing an Offroad navigation Android app - ADV Rally)
does you code open source?

2 Likes

It will be open source under MIT or BSD license.

This will also become a Gradle/Maven library.

4 Likes

Now you can move along a map… Well, more like the map moves and we can go anywhere. I am glad I can process a lot of the data to create nodes and meshes on threads and just use the main one to attach/detach nodes

7 Likes

Zooming on maps are now supported, we can navigate from one city to another.

Now I need to polish and refactor and fix some rare bugs that happen in some runs but never in others :slight_smile: and start documenting more. I may not be updating often since I am on job hunting and portfolio work.

9 Likes

Looks good. And good luck with the job hunt!

2 Likes

Fantastic Job! looks good

Nice job! Any update on this? I’d really like to use this for my own project.

1 Like

Hello @Sgambe33 and welcome To JME Community!

This project is temporarily on hold until I release the Dominoes game and then will continue working on this. :slight_smile:

3 Likes