[OpenLayers-Users] tiling features to speed detecting features on the client

Eric Lemoine eric.c2c at gmail.com
Thu Apr 17 02:25:06 EDT 2008


On Wed, Apr 16, 2008 at 12:38 PM, Graham Carlyle
<graham.carlyle at maplecroft.com> wrote:
> In a previous post I said that I wanted to detect which feature a mouse
>  had clicked on at the client side in order to be more responsive. The
>  suggested solution worked well, that of downloading a geojson
>  representation of the features up front and using the 2.6 OL feature of
>  detecting whether the feature's geometry intersected with the mouse
>  point.

FWIW: what we do in MapFish is send the x,y position on each click to
the server, have the server do the intersection work and send a
GeoJSON representation of the matching features. Yes, this is one Ajax
request per click, but performance is good enough in general.

--
Eric



More information about the Users mailing list