Where can i see that??
Met vriendelijke groet, Lucas Heezen [Beschrijving: http://www.covadis.nl/emailkop/logo.gif] Covadis b.v. t: 026 3616600 Geograaf 12 f: 026 3612317 6921 EW Duiven e: [email protected]<mailto:[email protected]> Van: Tobias Reinicke [mailto:[email protected]] Verzonden: vrijdag 25 november 2011 15:59 Aan: Lucas Heezen - Covadis CC: [email protected] Onderwerp: Re: [OpenLayers-Users] Display WMTS as baselayer with different map size Hi, What size are the tiles you are bringing back via WMTS? If they are bigger than the map window (i.e. 512 x 512) that might be the prob. Toby On 25 November 2011 14:54, Lucas Heezen - Covadis <[email protected]<mailto:[email protected]>> wrote: Hello, I have downloaded the WMTS example from OpenLayers. I have modified it so it can be used as baseLayer. But when I change the map size (css) the WMTS doesn't show up. Here is my code: var map; function init() { // Alle map opties gaan meegeven aan de map, var mapOptions = { theme: null, numZoomLevels: 27, //controls: [ ], //maxExtent: bounds, maxExtent: new OpenLayers.Bounds(-20037508, -20037508,20037508, 20037508.34), maxResolution: "auto", units: "m", projection: new OpenLayers.Projection("EPSG:900913"), displayProjection: new OpenLayers.Projection("EPSG:28992") }; map = new OpenLayers.Map( "map", mapOptions ); var osm = new OpenLayers.Layer.OSM(); // If tile matrix identifiers differ from zoom levels (0, 1, 2, ...) // then they must be explicitly provided. var matrixIds = new Array(26); for (var i=0; i<26; ++i) { matrixIds[i] = "EPSG:900913:" + i; } var wmts = new OpenLayers.Layer.WMTS({ name: "Medford Buildings", url: "http://localhost/geoserver/gwc/service/wmts", layer: "topp:O10004_gemeenten_xml", matrixSet: "EPSG:900913", matrixIds: matrixIds, format: "image/png", style: "", isBaseLayer: true }); map.addLayers([wmts]); map.addControl(new OpenLayers.Control.LayerSwitcher()); var lon = 663907.86312027; var lat = 6999450.3161499; var zoom = 8; map.setCenter(new OpenLayers.LonLat(lon, lat), zoom); } And the css .smallmap { width: 512px; height: 256px; border: 1px solid #ccc; } Met vriendelijke groet, Lucas Heezen [Beschrijving: http://www.covadis.nl/emailkop/logo.gif] Covadis b.v. t: 026 3616600 Geograaf 12 f: 026 3612317 6921 EW Duiven e: [email protected]<mailto:[email protected]> _______________________________________________ Users mailing list [email protected]<mailto:[email protected]> http://lists.osgeo.org/mailman/listinfo/openlayers-users
<<inline: image001.gif>>
_______________________________________________ Users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/openlayers-users
