<div dir="ltr">By default, OpenLayers applies up- and downscaling to the tiles. To avoid upscaling, configure the source with<div><br></div><div>    zDirection: -1</div><div><br></div><div>Andreas.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, May 4, 2020 at 8:47 PM Toni Hernandez Valles <<a href="mailto:toni.hernandez@udg.edu">toni.hernandez@udg.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">Helo everyone,<br>
<br>
I am using a vector tile from mapbox and I am getting bluring tiles<br>
with no apparent reason. Not for me, at least<br>
<br>
I have checked tiles directly to mapbox and the quality is perfect,<br>
but, when using tiles with OpenLayers the map quality gets lower.<br>
<br>
In this link (<a href="https://mapscloud.udg.edu/blurry_tiles.png" rel="noreferrer" target="_blank">https://mapscloud.udg.edu/blurry_tiles.png</a>) you can see<br>
the quality of the map image (on the left) and the quality of a single<br>
tile. Check the costline and the name "Roses" to see the difference.<br>
<br>
<br>
I have tried both tile sizes (256 and 512) with the same result.<br>
<br>
This is the code for the layer for size 256.<br>
<br>
var mapbox =  new TileLayer({<br>
    source: new SourceXYZ({<br>
      url: '<br>
<a href="https://api.mapbox.com/styles/v1/mapesbasesigte/ck9olcn8017xc1it6mhv6myje/tiles/256/%7Bz%7D/%7Bx%7D/%7By%7D?access_token=mytoken" rel="noreferrer" target="_blank">https://api.mapbox.com/styles/v1/mapesbasesigte/ck9olcn8017xc1it6mhv6myje/tiles/256/{z}/{x}/{y}?access_token=mytoken</a>'<br>
,<br>
    })<br>
  })<br>
<br>
And the code for the map.<br>
<br>
map = new Map({<br>
  layers: [ mapbox ],<br>
  target: 'map',<br>
  view: new View({<br>
    center: [0, 0],<br>
    zoom: 2,<br>
    projection: 'EPSG:3857',<br>
  }),<br>
  controls: defaultControls({attribution:<br>
false}).extend([attribution]),<br>
});<br>
<br>
Am I doing something wrong?<br>
<br>
Thanks you!!!<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.osgeo.org" target="_blank">Users@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/openlayers-users" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/openlayers-users</a></blockquote></div>