[geotk] Next step for WMS

Sam B totalsam at hotmail.com
Thu Aug 27 07:55:11 EDT 2009


Dear Johann,

Thanks a lot for that answer. It helped so much that now I am able to get a picture from demis WorldMap server.

> > By the way, looking at puzzle gis, I noticed that the URL for the WMS server contains the "&STYLES=null" argument, which makes the server to send a blank image.
> > Is it a way to get rid of this ?

I made small investigations about this. I put here a few links so that you can see what happens. I mainly used Puzzle GIS as example. There, when you create your distance source, the default server is

   http://www2.demis.nl/WMS/wms.asp?wms=WorldMap

This is the approximate request that Puzzle-GIS cound have sent :

   http://www2.demis.nl/wms/wms.asp?Service=WMS&WMS=WorldMap&Version=1.1.1&Request=GetMap&BBox=-20,-40,60,40&SRS=EPSG:4326&Width=400&Height=400&Layers=Countries&Format=image/png&STYLES=null

You can see that everything is black, but you get an image. Without the "null" now :

   http://www2.demis.nl/wms/wms.asp?Service=WMS&WMS=WorldMap&Version=1.1.1&Request=GetMap&BBox=-20,-40,60,40&SRS=EPSG:4326&Width=400&Height=400&Layers=Countries&Format=image/png&STYLES=

And you will see (mainly green) colors.

Now if you do the same with the BlueMarble WMS :

   http://www2.demis.nl/wms/wms.ashx?Service=WMS&WMS=BlueMarble&Version=1.1.1&Request=GetMap&BBox=-20,-40,60,40&SRS=EPSG:4326&Width=400&Height=400&Layers=Earth%20Image&Format=image/png&STYLES=

works perfectly well, as 

  
http://www2.demis.nl/wms/wms.ashx?Service=WMS&WMS=BlueMarble&Version=1.1.1&Request=GetMap&BBox=-20,-40,60,40&SRS=EPSG:4326&Width=400&Height=400&Layers=Earth%20Image&Format=image/png&STYLES=null

produces no image.

This may come from line 225 in AbstractGetMap.java, in which toString(styles) probably returns null when no style has been specified.

A workaround could be to call WMSMapLayer.setStyles(new String("")), but as WMSMapLayer extends AbstractMapLayer, which doesn't implement setStyles(), I don't know if it is possible. Does someone knows this ??

I found something else that could maybe be a display bug. Yesterday night I played with Puzzle GIS and were able to get maps from demis, and they displayed correctly on the screen. Now, I am currently developping on another computer. I finally succeeded to get a picture from demis with my test software, but the display was horrible. So I ran PuzzleGIS on the computer I am developping on, and the same "display bug" appears.

Here is a screenshot from Puzzle GIS. Is it possible that this is a display bug depending on the computer ?

http://img353.imageshack.us/img353/1622/puzzlegisbug.jpg

See you,

Sam


_________________________________________________________________
La Suisse reçoit plus d'espace! Votre disque dur virtuel de 25 Go avec Windows Live SkyDrive.
http://skydrive.live.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/geotoolkit/attachments/20090827/61452b14/attachment.html


More information about the Geotoolkit mailing list