[mapserver-commits] r11367 - trunk/mapserver
svn at osgeo.org
svn at osgeo.org
Tue Mar 29 16:28:13 EDT 2011
Author: assefa
Date: 2011-03-29 13:28:13 -0700 (Tue, 29 Mar 2011)
New Revision: 11367
Modified:
trunk/mapserver/HISTORY.TXT
trunk/mapserver/mapogcfilter.c
Log:
add support for gml:Box for spatial filters (#3789)
Modified: trunk/mapserver/HISTORY.TXT
===================================================================
--- trunk/mapserver/HISTORY.TXT 2011-03-29 18:26:43 UTC (rev 11366)
+++ trunk/mapserver/HISTORY.TXT 2011-03-29 20:28:13 UTC (rev 11367)
@@ -14,6 +14,9 @@
Current Version (SVN trunk):
----------------------------
+
+- add support for gml:Box for spatail filters (#3789)
+
- fix query map generation error introduced in beta2 when output format
initialized was made as needed.
Modified: trunk/mapserver/mapogcfilter.c
===================================================================
--- trunk/mapserver/mapogcfilter.c 2011-03-29 18:26:43 UTC (rev 11366)
+++ trunk/mapserver/mapogcfilter.c 2011-03-29 20:28:13 UTC (rev 11367)
@@ -98,8 +98,16 @@
if (hGeometry)
{
- FLTogrConvertGeometry(hGeometry, psShape,
- OGR_G_GetGeometryType(hGeometry));
+ OGRwkbGeometryType nType;
+ nType = OGR_G_GetGeometryType(hGeometry);
+ if (nType == wkbPolygon25D || nType == wkbMultiPolygon25D)
+ nType = wkbPolygon;
+ else if (nType == wkbLineString25D || nType == wkbMultiLineString25D)
+ nType = wkbLineString;
+ else if (nType == wkbPoint25D || nType == wkbMultiPoint25D)
+ nType = wkbPoint;
+ FLTogrConvertGeometry(hGeometry, psShape, nType);
+
OGR_G_DestroyGeometry(hGeometry);
}
@@ -1053,7 +1061,9 @@
else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "MultiPolygon")))
bPolygon = 1;
else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "MultiSurface")))
- bPolygon = 1;
+ bPolygon = 1;
+ else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "Box")))
+ bPolygon = 1;
else
{
psGMLElement= CPLGetXMLNode(psXMLNode, "LineString");
@@ -1129,11 +1139,14 @@
bPolygon = 1;
else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "MultiSurface")))
bPolygon = 1;
+ else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "Box")))
+ bPolygon = 1;
else if ((psGMLElement= CPLGetXMLNode(psXMLNode, "LineString")))
{
if (psGMLElement)
bLine = 1;
}
+
else
{
psGMLElement = CPLGetXMLNode(psXMLNode, "Point");
More information about the mapserver-commits
mailing list