Friday, May 28, 2010


Finally i am able to integrate Smallworld Application with Bing web map Service + Google Static maps and yahoo maps.

I tried in 3 flavors of Binghoo…A java version, c# with managed code and with sw_dotnet_dll
I am not very successful with Java version as Bing map web services with java is not the best combination and it took lots of time with trouble shooting.
I tried to create the web services using managed C code from C#. This C code is available in …Smallworld\product\data\acp_source\ but performance is not very good.. Sometimes application is hanging (may be because of managed C code)
I could found sw_dotnet_acp_dll in magik components (Thanks to Author: Pedro Miranda for the example)

I just added methods PutObject and GetObject to this dll to make my life easier. (Image transfer from acp to maick makes application slow.. to overcome this problem, the images are cached with coordinate and zoom level. This added two advantages to application

1. No need to go to the server for every pan/zoom if the coordinate is already visited.

2. Headache of transferring image form acp to magik is removed making application faster)

I modified!do_render and added few lines in the method

1. Self.application.plugin(:maps).current_map_view…window.render_raster(i_path, 0, 0)

2. I_path << self.get_cached_image_path_for_current_location()
This renders image at 0, 0 of map window and 2nd line will fetch the cached image path if no path exists it will request an image.

The real challenge is, to synchronize smallworld with geo images form 3-4 different map providers.

For Bing maps I tried different mathematical equations to get perfect sync between Smallworld and Bing geo images but still there are not perfectly in sync (see for calculating zoom level for the coordinates)

Zoom level for Google is somewhat fine (see the image) .. The detail images from Yahoo are not of very good quality and at many places they are not in very details so zoom for yahoo maps are not affecting.

1 comment:

  1. hi, I want to learn magik that too in a timeline of 1 month. Can you please guide me how I can do that. If you can help with some documents it would be of great help. Since there is no help available I am contacting you.
    my mail is