2009年12月1日火曜日

OpenLayers 35b TileCache について

serverResolutions について Class Documents を訳してみました。

serverResolutions {Array}
A list of all resolutions available on the server. Only set this property if the map resolutions differs from the server.

サーバー上で利用可能なすべての解像度のリストです。地図の解像度がサーバーと異なるとき、このプロパティを設定します。


また、Tolecache ホームページの

Using TileCache With OpenLayers
http://tilecache.org/docs/README#using-tilecache-with-openlayers

も訳してみました。

Using TileCache With OpenLayers

To run OpenLayers with TileCache the URL passed to the OpenLayers.Layer.WMS constructor must point to the TileCache script, i.e. tilecache.cgi or tilecache.py. As an example see the index.html file included in the TileCache distribution.

TileCacheを使ってOpenLayersを実行するために、OpenLayers.Layer.WMSのコンストラクタに渡したURLは、TileCacheスクリプト、すなわち、tilecache.cgiまたはtilecache.pyを指定しなければなりません。例として、TileCache ディストリビューションに含まれている index.html ファイル参照してください。


Note: index.html assumes TileCache is set up under CGI (see above). If you set up TileCache under mod_python you’d need to slighly modify index.html: the URL passed to the OpenLayers.Layer.WMS constructor must point to the mod_python script as opposed to the CGI script, so replace tilecache.cgi with tilecache.py. Similarly, you would need to edit this URL if you were to use TileCache with the standalone HTTP Server or FastCGI.

注:TileCache を mod_python に設定しているなら,少し index.htmlを変更する必要があります。:OpenLayers.Layer.WMS コンストラクタに渡た URL は、CGI スクリプトに対して mod_python スクリプトを指定しなければなりません。それで、tilecache.py とともに tilecache.cgi を置き換えます。同じように、TileCacheをスタンドアロンの HTTP Server または FastCGI とともに使用した場合には、この URL を編集する必要があります。


The most important thing to do is to ensure that the OpenLayers Layer has the same resolutions and bounding box as your TileCache layer. You can define the resolutions in OpenLayers via the ‘resolutions’ option or the ‘maxResolution’ option on the layer. The maxExtent should be defined to match the bbox parameter of the TileCache layer.

実行ための最も重要なことは、OpenLayers レイヤが TileCache と同じ解像度とバウンディングボックスだということを確認することです。あなたは、レイヤの'resolution'オプションまたは'maxResolution'オプションを介して、OpenLayersの解像度を定義することができます。 maxExtent は、TileCache レイヤの bbox パラメータと一致するように定義する必要があります。


If you are using TileCache for overlays, you should set the ‘reproject’ option on the layer to ‘false’.

オーバーレイとして TileCache を使用している場合は、レイヤー上の 'reproject' オプションを 'false' に設定する必要があります。

0 件のコメント: