[OpenLayers-Dev] OpenLayers for Mobile devices

Beau Anderson elbeau at gmail.com
Mon Dec 27 10:26:50 EST 2010


No, the "resize" behavior is not the same as what I am describing.  Using
Google maps as an example, as you pinch to zoom in/out the raster image
tiles resize to sized in-between the zoom levels.  The "resize"
transitionEffect does do a raster resize, but only to an actual zoom level.
 In other words, there is no graceful zooming to fractional zoom levels.  In
order to get an effect similar to Google's, you need to not only make the
background tiles zoom to fractional zoom levels, but the actual foreground
tiles themselves need to do the same, because if you've pinched to zoom in
to a fractional zoom level, you need any newly loaded tiles to also be
resized appropriately.

To put it another way, if you're loading tiles whose actual dimensions are
256X256 pixels, it doesn't mean that you will actually be displaying the
image at 256X256.  The fractional zooming is second-nature for users on iOS
and the newer versions of Android mobile devices these days.  The other
benefit you get for desktop computer users is that once you have fractional
zooming, then even if the're doing a zoom to a new zoom level, it's not hard
to do an animated zoom-in/zoom-out (again, the same way Google does).  In
the end, OpenLayers is AWESOME in it's support for various formats, but
there are a couple UI paradigms that I really want to tweak before I turn it
loose on my user base.  The thing I HAVEN'T delved into yet is how easy/hard
this will be to implement on other types of layers so that the whole UI acts
appropriately :s

On Sun, Dec 26, 2010 at 6:13 AM, Tom Hughes <tom at compton.nu> wrote:

> On 23 December 2010 17:21, Beau Anderson <elbeau at gmail.com> wrote:
>
>
>> I've got an existing successful iPhone application that I'm porting to
>> other platforms.  There's a lot that I want to add to my app's mapping
>> functionality and OpenLayers looks like it would fit the bill great, but the
>> user experience is just not as smooth as Google and Bing provide.  The
>> headache that I've been working on is getting layers that extend from
>> OpenLayers.Grid to act more like Google where when you zoom in or out it
>> simply scales the tiles you already have loaded then loads new tiles on top
>> of them.  To accomplish this we need to rethink the way that Grid layers
>> layout their tiles so that there are multiple layers of tiles within one
>> Grid (not just foreground and background img's in Image.js).
>>
>
> Doesn't setting transitionEffect to "resize" on the layer already do that?
>
> Tom
>
> --
> Tom Hughes (tom at compton.nu)
> http://compton.nu/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-dev/attachments/20101227/c6f0b45a/attachment.html


More information about the Dev mailing list