「202-ol3ex.js」
var layers = [
new ol.layer.Tile({
/** ol.layer.Tile
* For layer sources that provide pre-rendered, tiled images
* in grids that are organized by zoom levels for specific
* resolutions.
* プリレンダリング(事前描画)を提供するレイヤソースのための、
* 特定の解像度でのズームレベルによって編成されているグリッドの
* タイルイメージ。(ol3 API)
*/
source: new ol.source.MapQuest({layer: 'sat'})
/** ol.source.MapQuest
* Layer source for the MapQuest tile server.
* MapQuest タイルサーバのレイヤソース。(ol3 API
* 2 - ol3ex 23b - MapQuest example 2 参照)
*/
}),
new ol.layer.Image({
/** ol.layer.Image
* Server-rendered images that are available for arbitrary
* extents and resolutions.
* 任意の範囲と解像度で利用可能な server-rendered イメージ。
* (ol3 API)
*/
// extent: [-13884991, 2870341, -7455066, 6338219],
// extent: [138.85, 35.4, 140, 35.975],
extent: [15456711, 4218373, 15584728, 4297181],
source: new ol.source.ImageWMS({
/** ol.source.ImageWMS
* Source for WMS servers providing single, untiled images.
* 単一、アンタイル(タイル状でない)イメージを提供する WMS
* のためのソース。(ol3 API)
*/
// url: 'http://demo.opengeo.org/geoserver/wms',
// params: {'LAYERS': 'topp:states'},
url: 'http://localhost:8080/geoserver/wms?',
params: {'LAYERS': 'npn:tokyo_kuiki'},
serverType: 'geoserver',
attributions: [new ol.Attribution({html: '国土数値情報'})]
/** ol.Attribution
* An attribution for a layer source.
* レイヤソースの属性(ol3 API)
*/
})
})
];
var map = new ol.Map({
layers: layers,
target: 'map',
view: new ol.View({
// center: [-10997148, 4569099],
center: [15520720, 4257706],
// zoom: 4
zoom: 10
})
});


0 件のコメント:
コメントを投稿