question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

'sizes' in TileGrid is ignored

See original GitHub issue

Hello,

and thanks for your time and effort to understand my problem description. 😃

Greetings.

Describe the bug Maybe i’m too dumb to understand it, but when i set the ‘sizes’ property of the TileGrid, the Tile Image Source is still making requests to tiles outside of min/max x/y.

This is my grid as TileDebug shows it. I restrict it with an extent, for sure, but also with “sizes” as you can see below the image:

ol

The TileGrid is successfully creating the “fullTileRanges_

fullTileRanges_: Array(4)
0: t {minX: 0, maxX: 0, minY: 0, maxY: 1}
1: t {minX: 0, maxX: 1, minY: 0, maxY: 3}
2: t {minX: 0, maxX: 1, minY: 0, maxY: 3}
3: t {minX: 0, maxX: 10, minY: 0, maxY: 15}

1: t {minX: 0, maxX: 1, minY: 0, maxY: 3}

Until this point everything seems fine, but “fullTileRanges_” is ignored by the Layer/Source and creates requests for the following coords (z, x, y):

OutOfRange [1, 2, 0]
OutOfRange [1, 2, 1]
OutOfRange [1, 2, 2]
OutOfRange [1, 2, 3]

(I catch those requests in my “tileLoadFunction” (and tileloadstart event))

Hm … maybe its a hint that its only exceeding the X bounds … ?

To Reproduce Define your own TileGrid (restricted by “sizes” property) for your TileImage for your layer.Tile …

Expected behavior TileImage should not query tiles which are outside of the bounds of sizes/fullTileRanges_.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:10 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
ahocevarcommented, Sep 9, 2020

#11532 now fixes this issue - not by changing the documentation, but by implementing what the documentation says.

0reactions
ahocevarcommented, Nov 15, 2020

Fixed with #11532

Read more comments on GitHub >

github_iconTop Results From Across the Web

Openlayers3: incorrect image tile size - GIS Stack Exchange
I've just tried that and Sardina was the right size but in the wrong place. ... XYZ({ projection: 'EPSG:3003', tileGrid: new ol.tilegrid.
Read more >
Tile Size remains the same as default which is [256,256] in ...
I am not able to change the tile Size to any value. After numerous attempts I added tileGrid and it gives me Assertion...
Read more >
Size of images in a tilemap - Unity Forum
So, I'm having trouble getting my tilemap to work correctly. I can paint tiles into my project but can't change the size of...
Read more >
OpenLayers v7.1.0 API - Module: ol/source/DataTile
Name Type Default loader Loader attributions AttributionLike attributionsCollapsible boolean true
Read more >
terminalio – Displays text in a TileGrid - CircuitPython
The terminalio module contains classes to display a character stream on a display. The built in font is available as terminalio.FONT . Note....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found