MMA update

MMA update

Yesterday I looked into (ab)using google maps to use with the MMA.

Because I did not felt like implementing an entire tile engine myself I looked around on Google and found this actionscript project: Google Maps API opensource. However this looked kinda complex to me so I started to look for an alternative.

While chatting in #nuigroup, c.moore told me that he was trying to create something like that as well. He recommended too look into ModestMaps.

Unfortunately it was not just a matter of including a few class and adding it the to the stage. Besides adding google maps, controlling google maps would be a problem too. As you probably know it is possible to scale and rotate the desktop with 2 fingertips, but this is also true for the border of Google maps and it would also be true for the Google maps layer itself. This would mean 3 layers of scaling and rotating.

Instead of trying to implement a smooth browsing Google maps object, I created a new actionscript class called GoogleMapsSimple instead.
This class basically allows you to browse the tiles in the way as Google has cut them (at different zoom levels). There are not that many sites which explain how you can collect satellite or vector images from Google maps, however the few I could find were pretty useful ( sources: #1 / #2 / #3 )

When building an application based on the Google maps data you should consider building a caching service as well. While I was testing out my GoogleMapsSimple class I got banned from the server, because it looked like an automated system requesting the same tiles over and over again. To solve this problem I made a caching service in PHP. Instead of connecting my flash application to Google it would now request a tile from my own server. The caching service would then check if it has a local copy available, if it has one it sends the local copy, otherwise it would randomly select one of the four Google maps servers and request the tile.

Below you find two images of the GoogleMapsSimple objects. The interaction modes on these objects are pretty primitive. The corners allow you to zoom in according the way Google has cut the tiles. The center button allows you to zoom out and the other buttons allow you to move north, south, east and west.

Any release?
Uhm no, because the caching service sometimes fails in acquiring the tile (even after a few retries) I am not releasing the new MMA yet. But don’t worry it will be here soon enough 😉 …

MMA update
Older post

Multitouch Media Application v2 Release

Newer post

MMA Pro

MMA update

One response

  1. hi. Your work is a inspiration for me :) I am trying to do my own mti. Good luck.

    1coffeenosugar September 22nd, 2007