[Tilecache] Current x value ...... is too far from tile corner .......

CaSC casc84ab at gmail.com
Mon Nov 10 03:34:04 EST 2008


Hi Alexandre, i have this configuration:

Tilecache.cfg:

[Ortofoto]
type=WMSLayer
url=http://localhost/cgi-bin/mapserv?map=/usr/local/webmapping/sigal/private/data/sigal.map
layers=Ortofoto
bbox=447771.640919811,4530747.8,448508.759080189,4531073.7
resolutions=2.879368,0.005446,0.005314,0.007498,0.007720,0.007556,0.003485,0.005543,0.005859,0.000977,0.001953,0.022173
srs=EPSG:23030
extent_type=loose
size=256,256

Openlayers (index.html):

(...)
var lon = -122.4625;
        var lat = 40.2532;
        var zoom = 2;
        var maxres = 5.6762 / 256;
        var map, layer;
	var options = { theme:null,
			projection:'EPSG:23030',
			maxExtend: new
OpenLayers.Bounds(447771.640919811,4530747.8,448508.759080189,4531073.7),
resolutions:[2.879368,0.005446,0.005314,0.007498,0.007720,0.007556,0.003485,0.005543,0.005859,0.000977,0.001953,0.022173],
			};

       function init(){
            map = new OpenLayers.Map( $('map'), {'maxResolution': maxres,
'numZoomLevels':10});

                    layer = new OpenLayers.Layer.WMS("Ortofoto",
"../tilecache/tilecache.cgi?",
                          {layers: 'Ortofoto', format: 'image/png' },
                          {'displayOutsideMaxExtent':false}
                    );
            map.addLayer(layer);

            map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
            map.addControl(new OpenLayers.Control.Permalink());
            map.addControl( new OpenLayers.Control.LayerSwitcher() );
        }

(...)


Alexandre Dube wrote:
> 
> Firts, I would suggest that you check the resolutions in your 
> tilecache.cfg and the ones at your baselayer in OpenLayers. Make sure 
> they're the same ( change in your .cfg if that's not the case )
> 
> Alexandre
> 

-- 
View this message in context: http://www.nabble.com/Current-x-value-......-is-too-far-from-tile-corner-.......-tp20339619p20416137.html
Sent from the TileCache mailing list archive at Nabble.com.




More information about the Tilecache mailing list