[Mapserver-users] Tolerance question ..
Norbert Thieme
norbert.thieme at ilmenau.baw.de
Mon Apr 19 00:19:37 PDT 2004
Murilo Lacerda Yoshida schrieb:
> Hi all,
>
> I have two questions now...
>
> First one is about the tolerance I set on the map file. This tolerance
> is like a radium around the user click? Like, if I set the tolerance to
> 5 pixels, it would be like if the user clicks on a point, I will query
> everything in a 5 pixel radium, to all directions?
>
> Second one is about the querybypoint method. My first attempt to use
> tolerance on my map was setting it on the querybypoint method, so I put
> a 5 on the last parameter. But this tolerance was looking like if it was
> like 5000000000 kilometers
. In every point of the map I clicked I would
> query something, even if it was very far from my click. Then I tried to
> put a -1 on the last parameter, and put tolerance 5 on my map file. It
> worked fine. But now Im curious why the 5 of the querybypoint is so
> different from the 5 of the map file
>
> Thanks,
>
> Murilo
>
Sorry I missed an important point:
The tolerance in the mapfile depends on the definition of the
toleranceunits. If toleranceunits is not set then it is in pixel.
If you use a tolerance in the querybypoint function <= 0 then mapscript
uses the value set in the mapfile.
In the other case (tolerance > 0) the tolerance in the querybypoint
function have to be in georeferenced map coordinates.
And yes, I think it is the definition of the radius for a buffer around
the pointObj where you make a click.
Regards,
Norbert
More information about the MapServer-users
mailing list