These are chat archives for openseadragon/openseadragon

15th
Jul 2015
Antoine Vandecreme
@avandecreme
Jul 15 2015 14:17
@ConnerMan There is a typo in the changelog (see the PR). Good work though :+1:
Conner Wingard
@ConnerMan
Jul 15 2015 14:26
Thanks @avandecreme, fixed :)
Grant Echols
@gechols
Jul 15 2015 16:16
I'm working to optimize the loading process for our 1000s of tiled images and one thing I've noticed is that in what we are calling 'grid view' we have restricted the zoom (disabled it) in a hopes of getting it to load faster. What we are seeing though is that OSD still tries to load tiles from levels 2-6 or something like that. Unfortunately, each request is taking around 400-500ms to complete so its making for a painfully slow load process. Is there a way we can configure OSD to load only a single level for each image while we are in our 'grid view' mode?
I've tried the immediateRender=true but that didn't seem to have any effect on the problem
Ian Gilman
@iangilman
Jul 15 2015 16:21
@gechols Hmm...that's exactly what immediateRender is supposed to take care of. Perhaps it's broken somehow.
I've actually been thinking we should change the code to always grab the largest level contained in a single tile rather than going through all of the little levels.
See some discussion in #207
Ian Gilman
@iangilman
Jul 15 2015 16:27
I've filed #684
Grant Echols
@gechols
Jul 15 2015 16:44
Thanks - I may just dig into it and try to fix it. For now its nice to know its not something we are doing wrong.
Ian Gilman
@iangilman
Jul 15 2015 16:45
Cool
I think fixing that is the best path, but another options is to populate your grid view with LegacyTileSources that each have just a single tile associated with them, then swapping to full TileSources when you zoom in. Here is a demo of that: http://iangilman.com/osd/test/demo/tilesource-swap.html https://github.com/openseadragon/openseadragon/blob/master/test/demo/tilesource-swap.html
Ian Gilman
@iangilman
Jul 15 2015 16:52
@ConnerMan #673 has landed! I added a couple tweaks: openseadragon/openseadragon@1c17374
Grant Echols
@gechols
Jul 15 2015 17:33
@iangilman - in the duomoStandin object you specify both the width and height of the smaller image. For our case we can fix the width, but we don't know the size ahead of time. Can I just drop the height variable and let OSD figure it out?
Conner Wingard
@ConnerMan
Jul 15 2015 17:33
Cool, I saw that on github! :smile: I looked at your tweaks too. I debated where to put the deprecation notice for a good 5 minutes, chose the wrong place hah
Ian Gilman
@iangilman
Jul 15 2015 17:37
@gechols I don't think that works, but maybe. That might be tricky with LegacyTileSource, since it can contain a pyramid, and you want them all to match aspect ratio. Might be a good reason to make the SingleTileSource (openseadragon/openseadragon#467); you wouldn't need to pass a width and height at all, and it could just figure it out from the image once it's loaded.
@ConnerMan No worries :) but yeah, I think keeping the breakage and deprecations at the top of the list is a good idea
Conner Wingard
@ConnerMan
Jul 15 2015 17:39
yup, makes sense. Those are what I would want to know about first as a user
Ian Gilman
@iangilman
Jul 15 2015 17:39
Exactly
LarissaSmith
@LarissaSmith
Jul 15 2015 17:53
I'm having some difficulty getting the desired resize behavior for our implementation. We want the worldBounds to always fill the viewport width and for the height to be calculated from that. I got very close to the desired behavior by turning off autoResize and writing a custom handler, but it seems to leave something in the viewer in a weird state -- the next time I try to zoom, I get a scheduled update after the animation finishes that causes a glitch. This is my custom resize handler:
var containerSize = OpenSeadragon.getElementSize(openseadragon.container);
openseadragon.viewport.resize(containerSize, true);
openseadragon.prevContainerSize = containerSize;
openseadragon.forceRedraw = true;
Ian Gilman
@iangilman
Jul 15 2015 17:56
@LarissaSmith looks good so far. How are you enforcing the bounds filling the width of the viewport?
LarissaSmith
@LarissaSmith
Jul 15 2015 18:07
As far as I can tell, openseadragon.viewport.resize does the calculations I want for me if I pass in maintain=true. It looks like it calculates a ratio from the change in container size and uses that to calculate the new bounds width. (I fit the viewport width to the world bounds width during loading.)
Ian Gilman
@iangilman
Jul 15 2015 18:11
Interesting. Well, if it works, cool. Otherwise you can be more explicit about it. As for the glitch, I guess I'd have to see it in action. Do you have a link?
LarissaSmith
@LarissaSmith
Jul 15 2015 19:27
I think I fixed my problem by moving around some code in the app. I'll let you know if it shows up again. Thanks!