Ideas for Transparent MultiScaleImage Sources
Daniel,
I know you're hard at work on new rendering techniques, so hopefully I'm not overlapping anything. I wondered, with regard to the issue I have of semi-opaque layers appearing to stack, where in the SDK would I look if I wanted to possibly set the opacity on a layer on its way "out of view", that is, a layer that is being written over with the next zoom level? What I'm hoping to experiment with is setting the opacity on the older layer to 0 as the newer layer is imported, then switch it back to the current opacity as its brought back into view. That way, stacking still occurs, but not visually. I'd presume there is a better way to handle that, but it may be at least down the right path. Thoughts?
Grant
I know you're hard at work on new rendering techniques, so hopefully I'm not overlapping anything. I wondered, with regard to the issue I have of semi-opaque layers appearing to stack, where in the SDK would I look if I wanted to possibly set the opacity on a layer on its way "out of view", that is, a layer that is being written over with the next zoom level? What I'm hoping to experiment with is setting the opacity on the older layer to 0 as the newer layer is imported, then switch it back to the current opacity as its brought back into view. That way, stacking still occurs, but not visually. I'd presume there is a better way to handle that, but it may be at least down the right path. Thoughts?
Grant
1
person likes this idea
I like this idea!
Tell me when this idea gets some attention.
The more people who like this idea, the more it gets noticed.
The more people who like this idea, the more it gets noticed.
The company implemented this idea.
The best point from the company
-
Grant,
It's great to see you hang in there, trying to solve the problem but I also kind of feel bad because I don't think there's a sane solution to this problem under the current rendering architecture. Looking back, I never really took special care for supporting transparent layers. :/
I am experimenting with a more low-level approach for rendering the image pyramid that will basically flatten the whole scenario (using texture mapping) making stacking a thing of the past.
If you'd like to follow that work, just check out the NeoRenderer branch in the OpenZoom SDK:
http://code.google.com/p/open-zoom/so...
–Daniel
The company thinks
this is one of the best points
-
Inappropriate?Grant,
The issue is that you'd have to write a whole lot of logic (I believe) to determine whether a certain level fully covers the layer beneath. Otherwise you'll have blanks when turning the alpha value of lower levels to zero.
Nevertheless, if you feel like playing around with this, have a look at the org.openzoom.flash.renderers.MultiScaleImageRenderer class.
Good luck!
–Daniel
-
Inappropriate?Daniel,
How about a less ambitious version of the logic you are describing? Would it be possible to tell when a layer has completely rendered at the current zoom level? I read another post that suggested that this may be possible with a bit of work. If I could just determine when the current level's tiles have loaded, I could just THEN make the level above it invisible right? This would not be perfect visually, but I think it would get me much closer no?
Also, just finished writing a function into my current working copy that converts the mouse location to lat and lng. I'm going to be working with markers as soon as I think I can get the tile opacity issue worked out to some extent.
Grant
-
Inappropriate?Daniel,
After a little looking, here's what I see, let me know if I'm on the right track.
I see the function UpdateDisplayList, in which the function loadTiles is called. If I were to fire an event after the For loop in the Smooth Rendering section, and after the loadtiles call in the other modes, would that effectively let me know when the tiles had been rendered?
If that's the case, the next step would be to then make all layers above and below invisible or 0 opacity, right? Any pointers there?
Grant
-
Inappropriate?Daniel,
I think I figured out why the FAST rendering mode doesnt help. The problem is not that they are being explicitly stacked, like with the SMOOTH mode, but rather, that they aren't explicitly being disposed of/hidden in any mode. The lack of opacity causes implicit visible stacking simply because you can see through the layers. I'm also thinking my suggestion above won't help much because you use event listeners to actually send for the tiles, so I'd hit the completion event before they had loaded likely.
Given that, I'm guessing I'll need to keep track of whether there are any pending network requests, and when that number hits zero, programmatically check for the visibility/opacity of the other layers. I think I can handle the network queue stuff unless you know of any shortcuts, but how would I go about hiding the levels of a layer that were not active, and then naturally, explicitly ensuring that the currently active layer IS visible?
I wonder if a new RenderMode is in order for this?
Grant -
Inappropriate?Grant,
It's great to see you hang in there, trying to solve the problem but I also kind of feel bad because I don't think there's a sane solution to this problem under the current rendering architecture. Looking back, I never really took special care for supporting transparent layers. :/
I am experimenting with a more low-level approach for rendering the image pyramid that will basically flatten the whole scenario (using texture mapping) making stacking a thing of the past.
If you'd like to follow that work, just check out the NeoRenderer branch in the OpenZoom SDK:
http://code.google.com/p/open-zoom/so...
–Daniel
The company thinks
this is one of the best points
-
Inappropriate?Daniel,
No worries, I'd be a bit weary of anyone who thought theyd figure out every angle of a project this big on the first try :)
I would love to follow that work! This thing is really starting to come along! Once stacking isnt an issue, then all that'll be needed is perhaps a slightly cleaner way to add and remove layers. At present, it's a little clunky(I don't mean to slam your work, it's been phenomenal!). Just an example: z-index is basically backwards. The top layer must be added first, which would make dynamically adding and removing layers tricky after the initial load without reinitializing all layers. A more declarative way of adding them would definitely be cool.
Grant
-
Inappropriate?Hey Daniel,
I've checked out the NeoRenderer and that's awesome! You got it to load tiles while still moving the map! There seems to be other side effects of doing this. Is this simply because you aren't done with it yet, or is this anticipated?(I was looking at the VirtualEarth.as example, and the rendering seems to skip to the next zoomlevel instead of progressing to it.)
Awesome work! This is exciting to watch it progress!
Grant
-
Inappropriate?Hey Daniel,
Been out of town the last week or so, but I see you've done a bit more work on the NeoRenderer? How is it coming?
Regards,
Grant
-
Inappropriate?Grant,
Sorry for not answering earlier. I am quite busy studying for an exam at the end of the week but I was able to make quite some progress last week on the new rendering architecture. I finally integrated a caching system that will make things hopefully both more network and memory efficient compared to before. Support for transparent renderers as well as rendering of collections is still under development.
Therefore, I wanted to ask you whether you could point me to a publicly accessible source of transparent layers, ideally with different content on different levels, in order to test this new functionality during development.
Sneak Peek
http://openzoom.org/go/neo/
–Daniel
-
Inappropriate?Daniel,
Oh no worries, you're kind enough to answer them at all :) Good luck on that exam! That's great to hear(and see) about the new rendering architecture. As for where to look: I don't know of a publicaly available system right off the top of my head, however, I can point you to a tile server that I wrote for my company. I'd prefer you not release any of it's information publicly, but it'll give you something to test with immediately while I look around for an overlay that's public. The one I'm going to send you has US States, then as you dive deeper it changes to counties, and if you go further still, it turns into ZIP code boundaries. It should be a good one to test with. It's what I used in my testing. I'll see if I can PM the details to you now.
Regards,
Grant
-
Inappropriate?Daniel,
I'm not sure I can PM information through GetSatisfaction. If you have an email address I can send the info to, mind posting it for me? Or, you can just e-mail me directly if you prefer, its granthamm@awhere.com
Regards,
Grant
Loading Profile...




EMPLOYEE