Letractively / morisoliver

Automatically exported from code.google.com/p/morisoliver
0 stars 0 forks source link

Edit select too sensitive #59

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It grabs too much - it needs to use Intersects instead of BBOX (Identify uses 
Intersects) 

http://maps.massgis.state.ma.us/map_ol_mop/911.php?lyrs=Massachusetts%20Towns~ma
ssgis:GISDATA.TOWNS_POLY|911%20Streets%20to%20Edit~massgis:SETB.STREETS_911_TO_E
DIT&bbox=-71.06077460231536,42.43995845918227,-71.05574822375108,42.441270921421
435&coordUnit=m&measureUnit=m&base=custom&center=236343.68073728,910104.19038606
&zoom=11.954003328805788 

If I use the Identify tool to draw a box in the hollow of a line in "911 
Streets to Edit":

(see attachment)

It gets 0 features which is correct.
This is the request and response:

<wfs:GetFeature resultType="hits" xmlns:wfs="http://www.opengis.net/wfs" 
service="WFS" version="1.1.0" xsi:schemaLocation="http://www.opengis.net/wfs 
http://schemas.opengis.net/wfs/1.1.0/wfs.xsd" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<wfs:Query typeName="massgis:SETB.STREETS_911_TO_EDIT" srsName="EPSG:26986" 
xmlns:massgis="http://massgis.state.ma.us/featuretype">
<ogc:Filter xmlns:ogc="http://www.opengis.net/ogc">
<ogc:Intersects>
<ogc:PropertyName>SHAPE</ogc:PropertyName>
<gml:Envelope xmlns:gml="http://www.opengis.net/gml" srsName="EPSG:26986">
<gml:lowerCorner>236398.2527442 910129.75104504</gml:lowerCorner>
<gml:upperCorner>236428.92553498 910154.54488425</gml:upperCorner>
</gml:Envelope>
</ogc:Intersects>
</ogc:Filter>
</wfs:Query>
</wfs:GetFeature>

If I do the same with the Edit tool I get the feature.

This is the request:

<wfs:GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS" 
version="1.0.0" xsi:schemaLocation="http://www.opengis.net/wfs 
http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<wfs:Query typeName="massgis:SETB.STREETS_911_TO_EDIT" 
xmlns:massgis="http://massgis.state.ma.us/featuretype">
<ogc:Filter xmlns:ogc="http://www.opengis.net/ogc">
<ogc:BBOX>
<ogc:PropertyName>SHAPE</ogc:PropertyName>
<gml:Box xmlns:gml="http://www.opengis.net/gml" srsName="EPSG:26986">
<gml:coordinates decimal="." cs="," ts=" ">236396.71910466,910130.51786481 
236430.9703877,910149.68835904</gml:coordinates>
</gml:Box>
</ogc:BBOX>
</ogc:Filter>
</wfs:Query>
</wfs:GetFeature>

As you can see, Intersects is more accurate than BBOX.  It may be slower, but I 
think we need accuracy for editing. Note that the syntax of providing the 
coordinates is a little different.
This should be pretty simple to fix.  We made Charlton switch over, he was also 
using BBOX initially. 

Original issue reported on code.google.com by Aleda.Fr...@state.ma.us on 14 Sep 2011 at 8:07

Attachments:

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
This is resolved in r171.  Fix was to change the spatial filter type to 
"intersects" rather than BBOX

Original comment by its.s...@gmail.com on 13 Oct 2011 at 9:54

GoogleCodeExporter commented 9 years ago
Seems to work much better now.

Original comment by Aleda.Fr...@state.ma.us on 19 Oct 2011 at 8:27