Page 1 of 1
MGM maps -> AQX conversion
Posted: Mon Sep 03, 2012 6:27 pm
by mfc
Is possible? I have two collections of maps; an extensive/expensive set in .qct format and another set in MGM Maps format (offline-stored by MyTrails). It would be really nice to have just one app for using both.
AlpineQuest seems to be the leader for .qct ... but is it possible to convert my 1.5 GB of Spanish MGM-format maps to AQX format?
Or, alternatively, is a custom map source for the cnig.es maps possible? I've read the online help, but it is not clear where to start on that.
Thanks --Mike
Re: MGM maps -> AQX conversion
Posted: Tue Sep 04, 2012 8:50 am
by Psyberia-Support
Hi,
Unfortunately you won't be able to convert MGM maps to AQM maps (the offline format for AlpineQuest).
If you created your MGM maps using MOBAC, it's possible that it still have the map data in cache, so you just have to export it again to the AQM format without any more downloads.
The cnig.es maps are not supported if AlpineQuest right now. You may ask to MOBAC users to get some help to add it as a custom source for MOBAC, and so be able to create offline maps for AlpineQuest (MOBAC supports the AQM format).
Meanwhile, I will have a look at the MGM format, and see if I can add read support for this format in AlpineQuest.
Best regards
Edit:
MOBAC seems to be able to support cnig maps (I haven't tested it):
http://www.foromtb.com/showthread.php/8 ... NOA/page11
Re: MGM maps -> AQX conversion
Posted: Tue Sep 04, 2012 1:12 pm
by mfc
OK, many thanks for the quick reply. I've been researching the MGM format this morning, and have discovered that all it is doing is packing a number of JPGs into a single file to reduce the number of files and overhead. So I should be able to unpack into individual .jpg files and then probably use MOBAC to load them all again and generate an .aqm [where is that format documented, by the way? .. perhaps I can do this as a script and avoid MOBAC entirely].
My collection of notes on what I found about MGM, and verified, is attached below in case that helps!
Thanks for the pointer to some more XMLs for the Spanish maps .. so far I have not had much luck with those, but new ones worth a try. But it would be nice to just use the same format to avoid having to re-specify areas and having two copies (but it does look as though MGM format is a dead end).
Mike
. . . . . .
Notes found on the web or by experiment for MGM format files.
-------------------------------------------------------------
cache.conf contains "version=3" and "tiles_per_file=<N>" (number of
tiles per file).
Compute Nx=Ny=sqrt(N) (if N is an even power of two) and
Nx=2*Ny=sqrt(2*N) (if N is an odd power of two). For example, for
N=32, Nx=8 and Ny=4.
The map tile given by (x,y,zoom,maptype) is cached in a folder named
(maptype) + "_" + (zoom), the file being named (x/Nx) + "_" + (y/Ny)
+ ".mgm".
Each .mgm file has the following structure: K=number of tiles
currently in the file (2 bytes), then K entries of 6 bytes each: dx
(1 byte), dy (1 byte), offset (4 bytes).
[MFC: the K entries are padded to allow N entries always. i.e.,
there ate N entries of 6 bytes, of which only the first K have data]
dx=x%Nx, dy=y%Ny, and the
offset gives the offset for the END of the tile, computed from the
beginning of the file. All numbers are stored as big-endian. For more
info, see the map tile cacher script or download some map tiles and
analyze the file format with a binary editor.
Re: MGM maps -> AQX conversion
Posted: Tue Sep 04, 2012 1:26 pm
by mfc
Tried the MOBAC xml suggestions -- many thanks for that. It does work, but unfortunately is just the 'street map' base. I'm looking for (and have in MGM format for the area I frequent) the multi-level TOPO maps, as seen here:
http://maps.peterrobins.co.uk/e.html
for example; these drill down to the 1:25,000.
Mike
Re: MGM maps -> AQX conversion
Posted: Thu Sep 06, 2012 3:42 pm
by Psyberia-Support
That's an interesting map. That's quite weird that all levels are not supported in MOBAC....
I'll try to add it as a community map in AlpineQuest.
Best regards