Update
I haven’t got any time to put down on the actual project, but I did some on the side. A lot of mappers actually have this feature already, and as I’ve added so you can output region/chunks, I thought that I would add such a feature as well. So I did.
It really is just trying to load all images within the window area, and then you can scroll through them and it loads more images as you scroll. However, there was several issues with the first prototype: First off, it could not zoom. Well, it could, but it only did it on page load, and if you did it afterwards, it would bug out a lot. I noticed that there really is no good zooming mechanism in css, only the one that browsers implement, which we should not use anyway.
Secondly, I do not clean up the previously loaded images. Well, I could easily add a timer that removed these after a while if they are not inside the window, but I’m currently unsure what is the best choice. If I keep all images all the time, the browser will silently invalidate them until they get into the window view again. Also, it will make the drawing a lot slower, and zooming will be lagging a lot.
Finally, I have no idea how I will be able to notify the script that a new image have been rendered, not even mention how I will be able to render only updated chunks/regions. Most probably I will just read timestamps from the region file and the generated images. Most definitely. But for the notification, I currently just load the images if they haven’t been loaded, and then ignores any subsequently loads. Works, but not the best way.
Anyway, there is always solutions for this kind of issues, an I think I know how to solve them, but I am just prototyping right now to see what fits best with what I want to do. It looks quite alright, but I need to either limit zooming greatly, or render several zooming levels, something that is not hard, but bothersome. Btw, I’m running out of characters for this update, so I’ll stop right there…