[josm-dev] Landsat tiled WMS support for wmsplugin implemented
Bodo Meissner
bodo at bodo-m.de
Tue Jul 8 23:08:19 BST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hello,
I tried to send this message with the big patch included but it did not appear on the list.
That's why I send it again but include only download links to the files.
The patch is available at
http://bodo-m.de/josm/wmsplugin.patch.txt
(For some files the patch wants to replace the whole file and does not show the individual changes, probably because of different UNIX/DOS line endings.)
A modified version of the .jar file created from my sandbox is available at.
http://bodo-m.de/josm/wmsplugin.jar
Bodo (bomm)
Bodo Meissner schrieb:
> Hello,
>
> I have implemented an extension for wmsplugin to support the tiled WMS operation mode of the Landsat WMS server as specified on
> http://onearth.jpl.nasa.gov/tiled.html
>
> Before committing this to SVN I would like to get some feedback.
>
> Implementation overview:
>
> WMSGrabber now requests GetCapabilities and partially parses the response into a WMSCapabilities object.
> If the server supports the GetTileService request it will perform this request and parse the response into a tree of objects from wmsplugin.tiledwms.
> The root of the tree is a TiledPatterns object that contains TiledGroup objects. A TiledGroup can contain other TiledGroup objects or TilePattern objects. TiledPatterns, TileGroup and TilePattern correspond to XML tags in the GetTileService response. A TilePattern tag contains one or more WMS request strings that will be parsed into WMSRequest objects.
>
> If the WMS server supports tiled WMS, the images will be grabbed with WMSGrabber.grabTiled() instead of WMSGrabber.grab().
> grabTiled() looks for the best matching WMS access pattern from the TiledPatterns structure. To find the best match, I first select all compatible patterns, i.e. patterns that have the same parameter values except coordinates (bbox) and image size (width, height). From the compatible patterns I select the pattern with the image resolution nearest to the requested resolution. If available I use the smallest resolution greater than or equal to the requested resolution, otherwise I use the highest available resolution.
> From the best pattern, a set of requests is generated to get one or more tiles of fixed size that fully cover the requested area and an area of images is returned.
>
> If the WMS server does not support tiled WMS or this mode is disabled or if no matching pattern is found, grabTiled() falls back to a normal WMS request using grab().
>
> Additionally to the tiled WMS operation, I added a flag to the preferences to enable/disable tiled WMS mode and a "Clone" button to create a new entry from an existing one. With this it is easy to create tiled/normal variants of the same WMS server.
>
>
>
> Currently the Landsat WMS server seems to work for non-tiled requests.
> When I download the same area using both tiled and normal WMS, there are some small differences between the images in these two layers.
> I don't know yet the reason for this. It might be JOSM stretching individual tiles instead of stretching a larger image or a different interpretation of coordinates and image size between JOSM and the WMS server. (When I specify the coordinates bounding box of the image, is this the center of the corner pixels or the outer corner of these pixels?)
>
>
> If you want to test the tiled WMS access I suggest to clone the Landsat entry and enable "use tiled".
> If everything is OK, I will change the default to "use tiled" in the final version, so it will use tiled WMS whenever possible.
>
>
> Bodo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFIc+VRnMz9fgzDSqcRAvVfAJ4srJyu8is+TsQPLiKyioLswRo/9gCeKEZf
TD/8xI6Hbo8j/i0HkYqT0sk=
=b4RU
-----END PGP SIGNATURE-----
More information about the josm-dev
mailing list