-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
space between tiles when using skip-sizes #248
Comments
This is a browser quirk with images and the I've created a Code Sandbox minimal example. There are 3 options:
Atlas currently relies on this third option to smooth out these rounding issues. However, this will not work when applying an opacity. We can only render ONE image and then set its opacity. The browser doesn't currently have a way to group together layers of things and then set a opacity on the group as a whole. This is where we can set different values. The currently supported values:
What we could do is add an extra config value to increase the size of images by 1px if there is only one layer being drawn. In this file, anywhere where there is a |
@stephenwf I just took a deeper look at this, and it looks like it's happening on the I added a little debug to the
The maths look right, but wondering if there's a similar issue with rounding when drawing on the canvas somewhere else? |
@stephenwf I did a bit more testing and put up a draft PR....
Links: |
Throwing this up as an idea for how we might turn this on more selectively -- atlas-viewer/atlas@eeff34b |
Thanks @abrin, looks like a deep dive. 1. I agree with Dan that this feels like a math issue somewhere (he suggested openseadragon/openseadragon#2198) It's possible that the math could be wrong - the main goal of Atlas is compatibility with 2.1 and 3.0 images with level0, since there is no room for error there. The rounding and calculations tries to align with level0, with the hope that any caching for level1 and level2 use similar calculations. (The V2 WIP code also has a tile grid implementation, suitable for maps and infinite spaces, with some tests. If the current implementation requires too much work, it might be better using this as a starting point. I hope thats not the case though). 4. But... this feels like something is getting dropped further up the line, but when I look at the tiles requested from the image service, the math looks right. Wondering if you have any ideas? 5. is there an easy way you'd recommend to loop this into a conditional flag that we could set in CanvasPanel? I think we could try just changing the default to |
@stephenwf I will take a closer look later today. I think from our end, we're feeling a bit of a time-crunch, go live is Monday for everything. Would it be possible to merge a version with the temporary fix of .5 (or for something that's a bit more configurable) and then to come back to this. I'm happy to dedicate a little time looking at the map option and tests in option #1 if you like, but, it would be nice to know we're clear to go with this issue resolved. thanks |
Yes no problem, I'll make/merge the 0.5 fix and test to make sure its working later today (~3 hours). I'll mention you in a PR to this repository with the fix. |
@abrin I've pushed a branch here: atlas-viewer/atlas#44 It's from Atlas v2.0.8 (so we can make a 2.0.9 as 2.1.0 is a more involved change in #237) I did some testing, and I found that FireFox produced gaps. However, the performance dropped a bit when adding the There is a hosted storybook example here: This is configured to only render one layer. Can you confirm if this fixes the issue on your end. |
@stephenwf I'm seeing lines in the example story -- adding some screenshots. also wondering if the addition was transposed? |
I think you're right, the missing |
I just tested the example story on Firefox/Chrome/Safari on both the retina screen and an LG set up similar to Adam's and I'm not seeing the issue in any instance. |
Excellent! Then the PR is ready, I can merge and make a new v62 of canvas panel web components 👍 |
Published in |
When the
skip-sizes
prop is settrue
we've been able to observe a small amount of empty space between image tiles. The severity of the issue seems to vary based on screen size with the issue being more prevalent on larger displays of higher resolution and less severe apparent on smaller windows. Noting also that as the zoom level increases the issue seems to be lessen to a point of being almost invisible to the eye, but is most apparent on initial load.In this example below to highlight the issue I've applied
style={{ '--atlas-background': 'red'}}
to the "Canvas with Skip Sizes" story:tagging @itspamlam as she was first to observe this in and may have other useful observations.
The text was updated successfully, but these errors were encountered: