Monthly Archives: November 2010

Whatevermap engine v iKatastru

iKatastr pro iPad/iPhone je poháněn Whatevermap enginem, ten toho dokaze vic, nez  se na prvni pohled zda. Jirka Kaminek predvedl ‘kouzlo’ s Mapy.cz  http://mapserver.mendelu.cz/wordpress/?p=204 bezici v aplikaci iKatastr !

 


iKatastr ranks

 

iKatastr HD is reaching 1 month of #1 in Navigation category in Czech Republic store : http://www.appannie.com/ikatastr-hd/ranking/history/#store_id=143489

iKatastr is following:

http://www.appannie.com/ikatastr/ranking/history/#store_id=143489

both have been featured in “What is Hot” in Czech Republic store.

Jiri Kaminek will reveal more statistics details of iKatastr application as part of his upcoming PhD thesis.


Android vs iPhone development

this is interesting comparison of OS versions runing on Android and iOS and ‘developer friendly environments’ from the SDK perspective:
“The number of devices per OS is a great marketing number for Google and Apple to fight over but as a developer—who wants to get the most out of the SDK—I care about the version of the OS on the devices. If I want to use the latest and greatest SDK’s I’ll take Apple’s 80% of 21% over Google’s 30% of 28%.”

http://jeffreysambells.com/posts/2010/05/20/android-vs-iphone-development-decisions

“The iPhone has another big advantage and it solves the problem of distribution as I alluded to earlier. iPhone users use iTunes to sync their devices and add content. The process of syncing the device also checks for updates and allows all iPhone OS devices (iPhones, iPod Touches, iPads) to download the latests version of the OS. As a result the March 2010 iPhone Platform Versions stats look very developer friendly”

“More than 50% of the Android install base is still using version 1.6 or less. As a developer what should I do? If I choose to take advantage of the latest and greatest SDK I get less than half of the devices! But still, the bigger problem is there is no clear and easy upgrade path for those bottom 50% to get the newer OS version”


SVG map sample and Canavas in OpenLayers

SVG map sample : http://cartagen.org/

Canvas map sample : http://trac.osgeo.org/openlayers/wiki/Future/OpenLayersAndHTML5

Thesis on Canvas and Open Layers (August 2010)  ”Evaluation of HTML5 for its Use in the Web Mapping Client OpenLayers” : http://erwin-sauerwein.de/tobias/Tobias%20Sauerwein%20-%20Evaluation%20of%20HTML5%20for%20its%20Use%20in%20the%20Web%20Mapping%20Client%20OpenLayers.pdf

OpenLayers with Canavas  (partialy deprecated) http://trac.osgeo.org/openlayers/wiki/Future/OpenLayersWithCanvas

SVG vs Canvas comparison by Jeffrey Warren from : http://unterbahn.com/2009/08/svg-vs/

“Well, SVG doesn’t scale well to large numbers of objects, but Canvas doesn’t
scale well to large screens”

“SVG performance degrades quickly (exponentially on Safari?) in the number of
objects, but Canvas performance remains at a near-constant low. This makes
sense, since Canvas is just a bitmap buffer, while SVG has to maintain
additional references to each object that it renders. Also, though not pictured,
note that performance in clearing an SVG element also decreases in the number of
drawn objects.”

[UPDATE] PDC2010 video by Patrick Dengler : http://videoaz.microsoftpdc.com/vod/downloads/vod/CD53_PatrickDengler/CD53_PatrickDengler_PDC_WMV_High_1280x720_2500k.wmv

 


WMS overlay on Bing Maps vs. DeepEarth on WP7

2 comparisions videos of runing Bing maps and DeepEarth with tiled WMS overlay.

BING MAPS:

DEEP EARTH:


OpenLayers or GoogleMap v3 for mobile web app ?

I have experimented with OpenLayers 2.9 using touch.js extension for capturing touch events from iPhone/iPad. Although stripped down version of OL is about 184KB, the performance is very bad. If you have iPhone/iPad check this experiment: http://www.sumbera.com/lab/iphone/katastr.htm (note it will not work from desktop browser)

 OL team is working on v3 of OL to be more lighter, faster even for mobile devices, see here: http://trac.osgeo.org/openlayers/wiki/three  or here : http://openlayers.org/blog/2010/06/30/openlayers-3-on-github/

 Meanwhile I have tested new GoogleMaps v3 how it works on iPhone/iPad. despite few problems (stability, problems with cached tiles or disconnected JavaScirpt  to load new tiles -iPad)  it works pretty well . Check yourself this page from your mobile touch device (iPhone.iPad,Android): http://www.ikatastr.cz/iKatastrM.htm

Conclusion : Google Maps v3 wins on mobile over the Openlayers 2.9

 

[2011 September] UPDATE : new Openlayers 2.11 works quite well on iPad/iPhone.


Tiled WMS overlay in Windows Phone 7

  This post [http://blog.sumbera.com/2010/02/25/overlay-wms-on- google-in-silverlight-bing/ ] talked about how to overlay over the Bing maps Silverlight control Google tiles  and tiled WMS. It was quite easy to port this web sample into the Windows Phone 7 emulator. I took a smaple code from Training kit called “Ex1-TheBingMapControl” and extend it with the 2 classes : GoogleTile and WmsTile, with slight changes to the namespace using Microsoft.Phone.Controls.Maps (original for Silverlight was  Microsoft.Maps.MapControl). Then extend MainPage.XAML with :

                    <my:MapTileLayer Opacity=”1″>
                        <my:MapTileLayer.TileSources>
                            <local:GoogleTile></local:GoogleTile>
                        </my:MapTileLayer.TileSources>
                    </my:MapTileLayer>
                    <my:MapTileLayer Opacity=”1″>
                        <my:MapTileLayer.TileSources>
                            <local:WMSTiledOverlay></local:WMSTiledOverlay>
                        </my:MapTileLayer.TileSources>
                    </my:MapTileLayer>
 
 

Extended sample code availabel for download here : http://www.sumbera.com/lab/wp7/TheBingMapControlWithWMSandGoogle.zip

 Update: I found the way calculating BoundingBox from the quadkey somehow limiting (the DeepEarth weay) since it worked only till the level 18. So here is updated class fro getting correct bounding box of the tiled WMS request in the Bing Silverlight control:

            public static double TileToWorldPosX(double tile_x, int zoom) {
                return  (float)((tile_x / Math.Pow(2.0, zoom) * 360.0) – 180.0);
            }
            public static double TileToWorldPosY( double tile_y, int zoom) {
                double n = Math.PI – ((2.0 * Math.PI * tile_y) / Math.Pow(2.0, zoom));
                return   (float)(180.0 / Math.PI * Math.Atan(Math.Sinh(n)));
            }
            public override Uri GetUri(int tilePositionX, int tilePositionY, int tileLevel) {
                int zoom = tileLevel; //SSU tileLevel would be same as zoom in Bing control
                double deltaX = 0;// 0.00135; //SSU deltaX for SLP WMS
                double deltaY = 0;// 0.00058; //SSU deltaY for SLP WMS
                double minXLon = TileToWorldPosX(tilePositionX, zoom) + deltaX;
                double minYLat = TileToWorldPosY(tilePositionY + 1, zoom) + deltaY;
                double maxXLon = TileToWorldPosX(tilePositionX + 1, zoom) + deltaX;
                double maxYLat = TileToWorldPosY(tilePositionY, zoom) + deltaY;
                string wmsUrl = string.Format(this.UriFormat, minXLon, minYLat, maxXLon, maxYLat, 256);
                return new Uri(wmsUrl);
            }
        
        }
   

 


Tiled WMS overlay on Google Map v3

this is the third sample of the tiled WMS overlay over the Spherical Mercator, this time over the new Google Map v3. Previsous post talked about overlyaing WMS in  Silverlight Bing maps (http://blog.sumbera.com/2010/02/25/overlay-wms-on-google-in-silverlight-bing/ ) and OpenLayers (http://blog.sumbera.com/2010/02/17/overlay-wms-on-google-in-openlayers/).

Sample application can be found here: http://www.sumbera.com/lab/GoogleV3/tiledWMSoverlayGoogleV3.htm You can try to run it on your mobile device as well – suprisingly it run very well on my iPhone (sometimes it just crash Safari :), however on the iPad there are some more serious issues that will be hopefuly resolved with new iOS update (JavaScript stops to run).

For the new Google Map v3 you have to do the following :

//Define custom WMS tiled layer
var SLPLayer =
 new google.maps.ImageMapType (
 {
  getTileUrl:
    function (coord, zoom) { 
      var proj = map.getProjection(); 
      var zfactor = Math.pow(2, zoom); 
       // get Long Lat coordinates
      var top = proj.fromPointToLatLng(
             new google.maps.Point(coord.x * 256 / zfactor, coord.y * 256 / zfactor) ); 
      var bot = proj.fromPointToLatLng(
            new google.maps.Point((coord.x + 1) * 256 / zfactor, (coord.y + 1) * 256 / zfactor)); 
      //corrections for the slight shift of the SLP (mapserver)
       var deltaX = 0.0013; 
       var deltaY = 0.00058; 
     
      //create the Bounding box string
       var bbox = (top.lng() + deltaX) + “,” +(bot.lat() + deltaY) +“,”
                           +(bot.lng() + deltaX) +“,” +(top.lat() + deltaY);
      
       //base WMS URL
        var url =
       “http://mapserver-slp.mendelu.cz/cgi-bin/mapserv?map=/var/local/slp/krtinyWMS.map&” ;
       url +=“&REQUEST=GetMap”; //WMS operation
       url +=“&SERVICE=WMS”; //WMS service
       url +=”&VERSION=1.1.1″; //WMS version 
       url +=“&LAYERS=” + “typologie,hm2003″; //WMS layers
       url +=“&FORMAT=image/png”; //WMS format
       url +=“&BGCOLOR=0xFFFFFF” ;
       url +=“&TRANSPARENT=TRUE” ;
       url +=“&SRS=EPSG:4326″; //set WGS84 
       url +=“&BBOX=”+ bbox; // set bounding box
       url +=“&WIDTH=256″; //tile size in google
       url +=“&HEIGHT=256″ ; 
       return url; // return URL for the tile    
     }, //getTileURL
 tileSize: new google.maps.Size(256, 256),
 isPng: true
 }); 
 //add WMS layer 
 map.overlayMapTypes.push(SLPLayer); 

 
 
 

Follow

Get every new post delivered to your Inbox.