SLD & Spatial filter
Kralidis,Tom [Burlington]
Tom.Kralidis at EC.GC.CA
Tue Jul 5 14:39:19 PDT 2005
The documentation for SLD says that it supports Filter as per the Filter howto. This suggests to me that the sld support in MapServer works off the filter support. So any supported filter, whether via a WFS GetFeature or a Filter in an SLD document, should work. Perhaps one of the developers can confirm?
The Filter howto documents the following support for spatial filters:
BBox
Intersects
DWithin
more below...
> -----Original Message-----
> From: UMN MapServer Users List
> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Bart van
> den Eijnden
> Sent: Tuesday, 05 July, 2005 14:51
> To: MAPSERVER-USERS at LISTS.UMN.EDU
> Subject: Re: [UMN_MAPSERVER-USERS] SLD & Spatial filter
>
>
> I know the BBOX spatial Filter works for SLD don't know about
> the other
> ones though, haven't tried.
>
> Do they work on your WFS server?
>
> Best regards,
> Bart
>
> On Tue, 05 Jul 2005 17:34:27 +0200, François Prunayre
> <fx.prunayre at OIEAU.FR> wrote:
>
> > Hi list, I'm looking for advice about SLD FILTER ... Comparison
> > Filters
> > and
> > Logical Filters works in SLD file like
> > "<PropertyIsEqualTo>
> > <PropertyName>ID</PropertyName>
> > <Literal>655</Literal>
> > </PropertyIsEqualTo>"
> >
> > But spatial filter doesn't seem to be applied to layers like
> > " <DWithin>
> > <PropertyName>Geometry</PropertyName>
> >
> >
> <gml:Point><gml:coordinates>0.37,48.68</gml:coordinates></gml:Points>
> > <Distance units='m'>10000<Distance>
> > </DWithin>" or
> >
> > " <Intersect>
> > <PropertyName>Geometry</PropertyName>
> >
> >
You have an opening gml:Point element with a closed gml:Points element. Should be:
<ogc:DWithin>
<ogc:PropertyName>Geometry</ogc:PropertyName>
<gml:Point>
<gml:coordinates>0.37,48.68</gml:coordinates>
</gml:Point>
<ogc:Distance units="m">10000<ogc:Distance>
</ogc:DWithin>
> <gml:Polygon><gml:outerBoundaryIs><gml:LinearRing><gml:coordinates>0,4
> > 8.27
> > 1.67,49.24 2.62,47.56
> >
> 0,48.27</gml:coordinates></gml:LinearRing></gml:outerBoundaryI
> s></gml:Polygo
> > n>
> > </Intersect> "
> >
It is interprested as Intersects, not Intersect. Should be:
<ogc:Intersects>
<ogc:PropertyName>Geometry</ogc:PropertyName>
<gml:Polygon>
<gml:outerBoundaryIs>
<gml:LinearRing>
<gml:coordinates>0,48.27 1.67,49.24 2.62,47.56 0,48.27</gml:coordinates>
</gml:LinearRing>
</gml:outerBoundaryIs>
</gml:Polygon>
</ogc:Intersects>
> > Does spatial filter work only with WFS layers and not with SLD ? Is
> > this
> > in
> > the OGC spec for SLD or is it not implemented in mapserver ?
> >
> > Thanks for your help.
> > Francois
> >
> >
More information about the MapServer-users
mailing list