Google Earth or Google Map Stitcher - A "Must Have" program.

Map Tiles or Tile Maps, the technology behind Google Maps and others, is quite fascinating. However, cartographic mapping may require a bit more than running a few smart http get requests.

So I may be missing the point here, but I understand the "Buddy" tool as a simple image stitcher, downloading and combining adjacent map tiles to a larger image, hereby loosing location and scale (i.e. all the georeferencing information).

Google Maps and others are in Mercator projection, which means a floating scale even within the same zoom level. Now, who is providing the conversion to the Cartesian coordinate system of Trainz? And who is providing the coordinates to mark the location?
 
Geophil is obviously too modest to say that those of us who have TransDEM are able to use Google Earth or Planning Portal to generate highly detailed UTM 'tiles' that are 1km by 1km and are placed in exactly the right position under the baseboard, properly aligned with georeferenced coordinates and the DEM terrain that the programme also creates.

It doesn't cost very much and I'd strongly recommend it. ;)

Paul
 
standard peramiters?

Hi John,
Is it possible to have a fixed rule of thumb, like a standard size zoom in Google map, and a standard set of programs to work with, e.g., good equipment, but stuff that won't brake the bank, Lets say something along the lines of one baseboard big. So that you can just follow the guide lines and finish up with a covered baseboard at a standard scale e.g., (real scale) as that is the default in trainz?
 
Google Maps, Microsoft Virtual Earth / Live / Bing Maps, Yahoo Maps, Yandex Maps or, last but not least, Open Street Map all use the same way of representing a map structure for the entire planet. It's called Map Tiles or Tile Maps. The basic idea behind it is to start off with an exact square of a flattened Earth, containing everything but the polar caps. In geographic coordinates this covers all longitudes (-180° to +180°) and most latitudes (-85.xxx° to +85.xxx°). To build such a square you need a mathematical map projection called Meractor, invented centuries ago. This projection maps the surface of the earth to a cylinder and unwraps the cylinder.

Now, to zoom in, you simply split the square into four smaller squares "tiles" and continue doing so until you reach the desired zoom level. This is called a quad tree. The big advantage: Due to the strict rules for the quad tree and the underlying Mercator projection, you can derive the exact geographic position from the position of a tile in the quad tree and vice versa.

The disadvantage: The Mercator projection is non-linear (as you can imagine if you try to form a flat square from an orange peel). Scale is floating, even at the same zoom level, and longitudinal distances are not constant. They depend on latitude, even on the same tile.

Trainz terrain, on the other hand, is based on a classic Cartesian coordinate system. 1000m in east/west direction equals 1000m in north/south direction, and equal 100 ground vertices on the 10 m grid or 200 ground vertices on the 5m grid, anywhere.

A "Basemap" is a Trainz scenery object with a size of 1000 x 1000m and it carries a texture which usually represents a large scale topographical map, a plan or an orthophoto. There other other objects with different names, following the same principle. Some are 720x720m (size of an internal Trainz baseboard). 1000 x 1000m is quite convenient as this matches the grid lines of many topographic maps. Topographic maps have their own map projections and most often, the projection coordinates are linear and in meters. Very helpful.

One of the most popular projections for large scale topographic maps is UTM. UTM stands for Universal Transverse Mercator. Hang on, this Mercator again? Mercator is non-linear, isn't it. Correct, just like all map projections. But if we rotate the principal axes by 90° (Transverse Mercator) and split the Earth into many zones, creating an individual coordinate system for each zone and sticking close to the origin of each zone longitude-wise (Universal Transverse Mercator) we can almost eliminate the non-linearities.

Now with UTM (or a similar Cartesian system) it is quite easy to determine the right 1000 x 1000 m square to fill our Basemap texture.

How do we get from the Google Map in (standard) Mercator to UTM? We re-project the map. That's a mathematical transformation, a bit complex. Our map or plan or aerial photo will be in a raster image format. The re-projection transformation has to be applied to each pixel of such a raster image. Something to be done by software. Several specialised software packages can do that.

This all sounds very complicated and it certainly doesn't comes close to a set of simple guidelines.

I still don't know how this Google Map "Buddy", featured in this thread, does fit in, but I'm sure it will have a role somewhere.

...a standard set of programs to work with, e.g., good equipment, but stuff that won't brake the bank
One such tool is "TransDEM", already mentioned by Paulsw2 before. It is payware and it is an "all-in-one" tool. TransDEM does exactly what I described above with much built-in automation: It acquires map or aerial photo clippings from a map tile server (which is one of several options for map sources), retaining geographic position and scale, re-projects to UTM, creates multiple instances of "Basemaps", called "UTM tiles" in TransDEM, paints them with matching textures from the topo map or aerial imagery, and inserts them into the Trainz route, at the proper position. With TransDEM, you will usually shape the terrain as well, using a DEM for this, and the UTM tiles will automatically match the location, thanks to the magic of coordinates.

You can read more about TransDEM here:
http://forums.auran.com/trainz/showthread.php?t=49378

TransDEM is not the only automatic option for "Basemap" style approaches and DEM integration. There is also "MapMaker" which is free. MapMaker, however, does not offer a front-end link to Google Maps or the like, and it does not do any re-projection for maps. It expects you to provide the map clippings in UTM coordinates.
 
Last edited:
Jonathan, I raised the subject of Google Map Buddy mainly because there had been a lot of past discussion on these forums regarding the difficulty of joining maps together. GMB does that, although realise it's far from perfect. I've only had a short time to play with it because I'm now expending most of my energy towards the Newsletter and what will be a new Community website where I'm hoping projects like this will develop into bigger and better things.

On the one hand you have a few ad-hoc programs that will do what you want with some effort, or TranzDEM which Geophil is supporting. I haven't used TranzDEM, but I've only read good reports about it. The Newsletter won't be promoting commercial software as such, but that doesn't mean we're giving it the thumbs down. Any information that may assist the modeller, such as Geophil's comments below are welcomed with open arms.

Although there will be distortion in any map, I guess it comes down to how accurate you want your virtual world to be. When using geodata with distorted maps, I can see problems arising because the geodata won't accurately line up with the map. Whether this will be a serious problem for the casual modeller is something I can't answer, but it's certainly something I'd like to play with when I get the time. Until then, I'm joining the rest of you and absorbing any information others are prepared to share.

Sooner or later, we'll have enough material to throw into some interesting tutorials.

Thanks guys.
 
Although there will be distortion in any map, I guess it comes down to how accurate you want your virtual world to be. When using geodata with distorted maps, I can see problems arising because the geodata won't accurately line up with the map. Whether this will be a serious problem for the casual modeller is something I can't answer

As long as you are the casual modeller and use only one data source, be it Google Earth/Maps, a scanned paper topo map or whatever, you will probably not be bothered that much. I have seen people using a DEM with a 3:2 distortion without noticing for months (3:2 is a typical distortion of many DEMs for Central Europe or parts of North America when delivered in lat/long coordinates. Australia would be more like 4:3).

However, as soon as you try to combine two different geo data sources you will face problems if not working accurately. This is where you end up with rivers floating uphill and worse. "Working accurately" most often means to delegate to some software for processing the "coordinates".

As it seems, route builders taking the "Basemap" approach generally do not employ DEMs, so they probably won't be affected.

I have seen one or two US route projects, presented in this forum or its predecessor some time ago, which combined the MicroDEM/HOG technique, i.e. DEM plus TIGER with Basemaps. The TIGER overlay on the Trainz terrain was taken to manually align the Basemaps. The advantage is that you avoid systematic error as you can adjust per Basemap instance.

Some people suggested to refer to Trainz internal geographic coordinates (lat/long) which are used internally for celestial calculations (sun and moon). The idea was to take these lat/long values to align the Basemaps. However, as we don't know how lat/longs are computed in Trainz, what type of projection is used (it's certainly not UTM), we quickly introduce another source of systematic error.
 
404 error

dear sir, i have tried to load the link to the trains community news letter
but i keep getting a 404 error page not found,am i doing something
wroung? i am trying to get the a-z base maps:o... you can eather pm me
or email thank you four help
 
I think John may be away from the Trainz community at the moment. You might want to ask for help in a new thread.

William
 
Download link John King's newsletter ( Buddy tool + Vulcan's Tutorial )

Hello everybody,

When John King's Trains resources directory Newsletters became available on the www - I downloaded the newsletters to my HD

For the Trainzers interested in the Buddy tool and
Vulcan's tutorial Producing topography Maps for Trainz using Google earth


a) Buddy tool on page 20 of the newsletter

Here is the link http://dl.dropbox.com/u/19070177/2010_02.zip ( John Kings Trains resources directory Newsletter ).

b) Vulcan's tutorial on page 26 of the newsletter

Here is the link http://dl.dropbox.com/u/19070177/2010_03.zip ( John Kings Trains resources directory Newsletter )


Ps To John King : I hope your recovery is going well.

Best regards

Kurt :wave:
 
Last edited:
hi everybody

very nice and useful help here

can someone please help me with the below problem
i had to re download my new route from google earth.
i done it twice and it always comes out like this
any ideas as to what i'm doing wrong?
thanks
ron

unnamed201201200002.jpg
 
There's been a lot of discussion on these forums in the past about stiching or joining Google Maps oe Google Earth images. Well some kind gentleman has just released a very small program that does all this automatically. The software doesn't need to be installed, in fact you can even run it from a memory stick. That in itself makes it worth a try.

Like any free software, it has its limitations, but it still works very well. I created a very large (48 inches square) photo of a railway yard in Australia and this allowed me to then pick any area and work from there. If you're playing around with Google Maps, or Google Earth, I strongly suggest you give this little program a try.

I've supplied a link to to the program and a three or four page tutorial which I wrote myself, in the Trainz Community Newsletter which has just been released. If you've already downloaded the Newsletter, then you already have the link and the tutorial. If you haven't, may I suggest you do so, because the program is a beauty and the Newsletter contains 24 pages of valuable Trainz information. The tutorial starts at around page 20.

The program only works with Google Maps, but the imagery is almost the same as Google Earth anyway.
Enjoy

Having trouble with your link, says not found on this server, Ithink I am on your list to recieve the newsletter.
 
John has not been active in Trainz for a long time due to very serious illness as already stated in this thread, alternative links have been given in the thread for the Newsletters.
 
Back
Top