Mobile GMaps Home Page
 FAQFAQ    SearchSearch    MemberlistMemberlist    UsergroupsUsergroups   RegisterRegister  
 ProfileProfile    Log in to check your private messagesLog in to check your private messages    Log inLog in 

MapCruncher maps in MGMaps
Goto page 1, 2, 3  Next
 
Post new topic   Reply to topic   printer-friendly view    MGMaps Forum Index -> Stored Maps
View previous topic :: View next topic  
Author Message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Tue Dec 11, 2007 11:13 am    Post subject: MapCruncher maps in MGMaps Reply with quote

Starting with version 1.39.02, Mobile GMaps supports stored maps created using Microsoft's Map Cruncher tool. Follow these steps to make your own map and store it on your phone:
  1. Download MapCruncher from http://research.microsoft.com/mapcruncher/ and install it.
  2. Use MapCruncher to split your map into tiles. A nice tutorial is available at http://www.metacafe.com/watch/496160/5_minute_msr_mapcruncher_tutorial/
  3. Open your output folder, then find the subfolder named Layer_NewLayer (or Layer_xxx where xxx is the name you gave the layer). You'll only be needing this subfolder, rename it as you wish (for example "MyMap").
  4. UPDATED: Download the zip file attached to this message, extract cache.conf and copy it into this subfolder. This is needed for MGMaps to recognize it as a stored map folder. NOTE: When you first use the map in mgmaps, it will start centered somewhere in a corner of your downloaded map — if you feel confortable with editing a plain text file, you can open cache.conf with notepad and change the "center" line to start centered on your actual map (this is not done automatically yet). The line includes 4 numbers meaning: latitude,longitude,zoom,maptype (you can leave maptype equal to MicrosoftMap or change it to some other map type which must be a preset map short-name or an already-added custom map).
  5. Copy the subfolder and all the included files to your phone. You can remove all the other files and folders created by mapcruncher in the output folder.
  6. On your phone, open MGMaps -> Settings -> Map Browsing and enable Stored Maps (and possibly Offline Mode too). Use the "Browse" option to browse to the folder with the new map. Save the settings and restart mgmaps to view your map.

Post any problems or questions below.

Cristian Streng



cacheconf.zip
 Description:
Zipped cache.conf file for MapCruncher maps.

Download
 Filename:  cacheconf.zip
 Filesize:  179 Bytes
 Downloaded:  4003 Time(s)



Last edited by Cristian Streng on Fri Dec 14, 2007 9:36 pm; edited 3 times in total
Back to top
View user's profile Send private message Visit poster's website
nanquim
MGMapper


Joined: 23 Nov 2007
Posts: 22
Location: Brazil
Phone Type: Nokia 6630, 6280 e N70 + HOLUX GPSlim240

PostPosted: Tue Dec 11, 2007 9:50 pm    Post subject: Reply with quote

I tried to download the tutorial but unable to ... Spent more than an hour to download the "Metacafe Pro" and many videos that for me has no interest and no where trying to tuturial received an error message without providing a reason for the error. I stop to trie ... I do not have time for that. There is no practical way to save the file on my pc? Hum... I think I will use camtasia to record video in avi ...
Back to top
View user's profile Send private message MSN Messenger
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Tue Dec 11, 2007 9:54 pm    Post subject: Reply with quote

nanquim wrote:
I tried to download the tutorial but unable to ... Spent more than an hour to download the "Metacafe Pro" and many videos that for me has no interest and no where trying to tuturial received an error message without providing a reason for the error. I stop to trie ... I do not have time for that. There is no practical way to save the file on my pc? Hum... I think I will use camtasia to record video in avi ...

You don't need to download the tutorial, just view it online like you view a movie from youtube (metacafe is just another video hosting website).

But if you want, you can download the movie in .flv format -- using VideoDownloader I got the URL http://akvideos.metacafe.com/ItemFiles/%5BFrom%20www.metacafe.com%5D%20496160.3394517.11.flv. You'll still need the players/codecs to view it, I'm using Media Player Classic that comes with K-Lite Codec Pack.
Back to top
View user's profile Send private message Visit poster's website
nanquim
MGMapper


Joined: 23 Nov 2007
Posts: 22
Location: Brazil
Phone Type: Nokia 6630, 6280 e N70 + HOLUX GPSlim240

PostPosted: Tue Dec 11, 2007 10:35 pm    Post subject: Reply with quote

Thanks! Perhaps for having lots of disk like to have in the same folder to install the programs, the tools that I use with it, and their manuals and instructions. I know that everything is on the net, but sometimes it is difficult to find again the same information that interests us ... And as I am a little impatient ... hehehe!
With the link and getwright was a flash!! Hehehehe!!
And I have a program "videoinspector" which analyzes the files, identifies the codecs and opens the download page ... EXCELLENT ...
Back to top
View user's profile Send private message MSN Messenger
Turbo3
MGMapper


Joined: 04 Dec 2007
Posts: 21

Phone Type: HTC Touch Pro US Version (CDMA)

PostPosted: Thu Dec 13, 2007 9:13 am    Post subject: Reply with quote

I have installed the maps and the new cache.conf but how do you enable the new maps for viewing. I was expecting to see a MapCruncher type in Map Types that I could enable and then use the 0 key to select.

What am I missing.

Jim
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Thu Dec 13, 2007 9:16 am    Post subject: Reply with quote

Turbo3 wrote:
I have installed the maps and the new cache.conf but how do you enable the new maps for viewing. I was expecting to see a MapCruncher type in Map Types that I could enable and then use the 0 key to select.

No, just enabled stored maps on your mapcruncher folder. The map will simply replace the other maps displayed. Future versions of MGMaps will automatically define a custom map type for your mapcruncher stored map.
Back to top
View user's profile Send private message Visit poster's website
Turbo3
MGMapper


Joined: 04 Dec 2007
Posts: 21

Phone Type: HTC Touch Pro US Version (CDMA)

PostPosted: Thu Dec 13, 2007 4:55 pm    Post subject: Reply with quote

I did all that. When I look at the log file I have a lot of error messages. "java.lang.NullPointerException, DESC:Invalid image data,MSG:null"

When I look at the folder data the files seem very large with most around 250KB and all in the single folder with no subfolders. All zoom levels are in the one folder with names like 1323031.png, 13230312.png.

The oringinal map was a 7MB jpg scanned at 300 dpi and the resulting MapCruncher folder is 168MB with 959 files.

Jim
Back to top
View user's profile Send private message
lofarkas
Power User


Joined: 02 Jun 2007
Posts: 92

Phone Type: HTC Desire

PostPosted: Thu Dec 13, 2007 9:36 pm    Post subject: Reply with quote

Wait, one can't easily switch betweem mapcruncher and other stored maps? It'll require going to settings and switching between the MGMapsCache and the Mapcruncher folders?

Anyway, thanks for this cool update and special kudos for implemeting it so that we mere mortals don't need to run some sort of a bulk rename/reformat/whatever application to convert the mapcruncher output. I've been waiting for this and for stored KML for a while now:)

I'll try it out over the weekend. And I'll throw some spare change your way, too (I hope your moneybookers account is alive and kicking).

LF
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Fri Dec 14, 2007 6:41 am    Post subject: Reply with quote

lofarkas wrote:
Wait, one can't easily switch betweem mapcruncher and other stored maps? It'll require going to settings and switching between the MGMapsCache and the Mapcruncher folders?

Yes, that's how it is for now.
Back to top
View user's profile Send private message Visit poster's website
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Fri Dec 14, 2007 7:36 am    Post subject: Reply with quote

Turbo3 wrote:
I did all that. When I look at the log file I have a lot of error messages. "java.lang.NullPointerException, DESC:Invalid image data,MSG:null"

When I look at the folder data the files seem very large with most around 250KB and all in the single folder with no subfolders. All zoom levels are in the one folder with names like 1323031.png, 13230312.png.

The oringinal map was a 7MB jpg scanned at 300 dpi and the resulting MapCruncher folder is 168MB with 959 files.

Jim

Umm... yes, I guess it's possible that the files are large... and this can cause various problems with the mgmaps cache. Try to just start the application and look at the end of the error log, see what file it is trying to load and make sure that file is present, etc. Also make sure cache.conf is present. You could try to increase the cache size to 1024 - 2048 kB (in settings/map browsing), although I don't know if the phone would be able to handle that much.
Back to top
View user's profile Send private message Visit poster's website
Turbo3
MGMapper


Joined: 04 Dec 2007
Posts: 21

Phone Type: HTC Touch Pro US Version (CDMA)

PostPosted: Fri Dec 14, 2007 8:59 am    Post subject: Reply with quote

The debug log reports that it has a total memory of 7168kB with 6333kB free. I had orginally set the cache to 10000kB but changed it to 5000kB.

Yes, I have the config file. I have opened it on the memory card and it looks ok.

I have sent you an error report from the phone. I don't see any file names in the logs. I just see a lot of invalid image data error messages.

The only stored maps I have ever gotten working had extensions of .mgm whereas the mapcruncher files have extension .png.

I am making up a test folder with only .png files less than 100kB and the config file to see if that works. I'll update this entry with the results.

Limiting the file size did not help. Same error messages about invalid image data. Is the format of the .mgm images the same as the .png images? They must be bit map to be so large.

My phone has a built-in File Manager and picture viewer and I can go to the .png files an view them on the phone. The viewer does not understand the .mgm and will not display them.

How many different tile (image) formats does mgmaps understand? Or are they just all bit maps (.bmp) but with different extension names?

Jim
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Fri Dec 14, 2007 9:38 am    Post subject: Reply with quote

Turbo3 wrote:
The debug log reports that it has a total memory of 7168kB with 6333kB free. I had orginally set the cache to 10000kB but changed it to 5000kB.

OK, that was too much Smile Even 5000 is too much, but the limit will only kick in after showing some maps...

Turbo3 wrote:
The only stored maps I have ever gotten working had extensions of .mgm whereas the mapcruncher files have extension .png.

Right, the extension was different to avoid showing them in nokia's gallery programs. But mapcruncher creates files with the .png extension.

Turbo3 wrote:
Limiting the file size did not help. Same error messages about invalid image data. Is the format of the .mgm images the same as the .png images? They must be bit map to be so large.

They are all bitmap (png), but some of them are compressed better and some are compressed worse.

Turbo3 wrote:
How many different tile (image) formats does mgmaps understand? Or are they just all bit maps (.bmp) but with different extension names?

This depends on the phone, but most support png and jpg. mgm files (when using 1 tile-per-file) are just renamed png or jpgs.

Bottom line, I don't know why this doesn't work, I'll need more people to test.
Back to top
View user's profile Send private message Visit poster's website
lofarkas
Power User


Joined: 02 Jun 2007
Posts: 92

Phone Type: HTC Desire

PostPosted: Fri Dec 14, 2007 5:41 pm    Post subject: Reply with quote

OK, I give up.

I'm having the same problem as Turbo3. Tried two different mapcruncher maps, no dice, same error messages. (Exact copy of last msg: 16:38:09.063: ERROR: EX: java.lang.NullPointerException, DESC: Invalid image data, MSG: null)
The phone didn't actually switch to mapcruncher mode (the maps listed under "go to" are the usual Yahoo, Google etc. stuff).
Browse doesn't work on my phone so I had to manually set the route but I put the folder in the root and gave it a simple name so I'm pretty sure I got it correctly. It does contain cache.conf.


Also, now mgmaps doesn't even display my good old cached maps. I think that's because of a map format change...
Mine look like: MGMapsCache/GoogleMap_14/[0]/7895_5461.mgm
Is that not supported anymore? If so, can I convert the map cache?
Back to top
View user's profile Send private message
lokura
MGMapper


Joined: 18 Aug 2007
Posts: 22

Phone Type: Unknown

PostPosted: Fri Dec 14, 2007 9:04 pm    Post subject: Reply with quote

nor working for me, same error:
"java.lang.NullPointerException, DESC:Invalid image data,MSG:null"
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Fri Dec 14, 2007 9:35 pm    Post subject: Reply with quote

Sorry about that... it seems cache.conf was incorrect. Try with this one attached (it switches to MS Live Maps).

Cristian



cacheconf.zip
 Description:

Download
 Filename:  cacheconf.zip
 Filesize:  179 Bytes
 Downloaded:  5425 Time(s)

Back to top
View user's profile Send private message Visit poster's website
lokura
MGMapper


Joined: 18 Aug 2007
Posts: 22

Phone Type: Unknown

PostPosted: Sat Dec 15, 2007 1:31 pm    Post subject: Reply with quote

still not working with the same debbug error, tested on n6234 and ipaq514 (j9) and with two differents maps
Back to top
View user's profile Send private message
lofarkas
Power User


Joined: 02 Jun 2007
Posts: 92

Phone Type: HTC Desire

PostPosted: Sun Dec 16, 2007 4:47 pm    Post subject: Reply with quote

Well, it does work for me with the new cache.conf but not quite as well as I'd like it to.

The map appears but I can only zoom in until the on-screen scale indicator shows 3km. That's a sort of city overview resolution and if I zoom in closer it only shows blank white space and my favourites marked on it. The map itself is much more detailed; there are 3 or 4 more zoom levels on my card, only mgmaps is not displaying them for some reason.
BTW, I had to leave out the 2 closest zoom levels in order to spare memory space... but I believe that shd cause no problems.

Edit: I just tested it again to see the debug message it produces and now it did better... showed 2 more zoom levels before it gave up the good fight. Loaded one screen partially, leaving the rest blank. Then I tried to zoom out and everything went blank, no more maps displayed until I restarted mgmaps. The log has a bunch of messages like: Enqueuing http://r0.ortho.tiles.virtualearth.net/tiles/r120231030.png?g=97 etc

What the hell is going on with virtualearth?

Anyway, I'm guessing that it's some sort of out of memory error or a problem w/ handling the largish files. Any suggestions?


On a related note, is there a way to compress the mapcruncher maps somehow? Mine are in png and take a huge amount of space (~200kB/tile). Can one get mapcruncher to spit out jpg-s instead? Or do a batch conversion with some other application?
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Sun Dec 16, 2007 8:32 pm    Post subject: Reply with quote

lofarkas wrote:
The map appears but I can only zoom in until the on-screen scale indicator shows 3km. That's a sort of city overview resolution and if I zoom in closer it only shows blank white space and my favourites marked on it.

That's probably because the PNG files generated are too big. What is your mgmaps cache size?

lofarkas wrote:
On a related note, is there a way to compress the mapcruncher maps somehow? Mine are in png and take a huge amount of space (~200kB/tile). Can one get mapcruncher to spit out jpg-s instead? Or do a batch conversion with some other application?

I think there's an option to generate jpg files, but they wouldn't be recognized by mgmaps unless you rename them manually back to png (it expects the file extension to be png).
Back to top
View user's profile Send private message Visit poster's website
lofarkas
Power User


Joined: 02 Jun 2007
Posts: 92

Phone Type: HTC Desire

PostPosted: Mon Dec 17, 2007 9:52 am    Post subject: Reply with quote

Cristian Streng wrote:
lofarkas wrote:
The map appears but I can only zoom in until the on-screen scale indicator shows 3km. That's a sort of city overview resolution and if I zoom in closer it only shows blank white space and my favourites marked on it.

That's probably because the PNG files generated are too big. What is your mgmaps cache size?

lofarkas wrote:
On a related note, is there a way to compress the mapcruncher maps somehow? Mine are in png and take a huge amount of space (~200kB/tile). Can one get mapcruncher to spit out jpg-s instead? Or do a batch conversion with some other application?

I think there's an option to generate jpg files, but they wouldn't be recognized by mgmaps unless you rename them manually back to png (it expects the file extension to be png).

Cache was 384k but I just increased it to 1000 and then to 2000 before I read you message. No improvement. I'll try and play around with it more.

Sucks about the png... can you remove that limitation from the next release? I guess there has to be a batch rename tool that can change the extension though.
Back to top
View user's profile Send private message
Cristian Streng
Founder


Joined: 28 Oct 2005
Posts: 4585

Phone Type: (many)

PostPosted: Mon Dec 17, 2007 10:02 am    Post subject: Reply with quote

lofarkas wrote:
Sucks about the png... can you remove that limitation from the next release?

Yeah, but then I'll need to add another configuration parameter to cache.conf...
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MGMaps Forum Index -> Stored Maps All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
MGMaps topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group