[Tilecache] Problem with resolution

Eric Lemoine Eric.Lemoine at camptocamp.com
Wed Feb 28 05:25:13 EST 2007


On 2/28/07, Yves Jacolin <yjacolin at free.fr> wrote:
> Le Mercredi 28 Février 2007 11:05, Eric Lemoine a écrit:
> > On 2/28/07, Yves Jacolin <yjacolin at free.fr> wrote:
> > > Hi Eric,
> > >
> > > Thanks very much for this tips. I get this resolutions:
> > > 4938.886622189033,2469.443110945165,1411.110349115227,705.5551745557
> > > 614,...
> > >
> > > This seems incorrect, isn'it ?
> >
> > Are your scales and unit correct?
> Well, here my values:
>      var myScales =[14000000,7000000,4000000,2000000,901000,451000,225000];
>      var options = {scales:myScales,units: 'm'};
>
> The scales has been set up using the map.addControl(new
> OpenLayers.Control.Scale()) control box.
>
> My EPSG code is 4326.

First, do not use OpenLayers.Control.Scale() to set up your scales.
Use something like this instead:

var myScales = [ 3750, 7500, 15000, 30000, 60000, 120000 ];
var options = { scales: myScales, ... };
map = new OpenLayers.Map($('map'), options);

-- 
Eric


More information about the Tilecache mailing list