[mapserver-commits] r9839 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Sun Feb 21 10:25:38 EST 2010


Author: jimk
Date: 2010-02-21 10:25:38 -0500 (Sun, 21 Feb 2010)
New Revision: 9839

Modified:
   trunk/mapserver/mapwmslayer.c
Log:
Fix bug in WMS client layers where PROCESSING "RESAMPLE=..." is given.

The bug occurs when a PROCESSING "RESAMPLE=" directive is given and 
there is not a re-projection between the WMS server and the MapServer
output. The bug occurs because the resampling code expects a valid
world file, however MapServer only writes a world file if
re-projection is necessary. This change writes a world file if either
a re-projection is necessary or resampling is specified.


Modified: trunk/mapserver/mapwmslayer.c
===================================================================
--- trunk/mapserver/mapwmslayer.c	2010-02-21 15:07:49 UTC (rev 9838)
+++ trunk/mapserver/mapwmslayer.c	2010-02-21 15:25:38 UTC (rev 9839)
@@ -1349,7 +1349,9 @@
     if (lp->data) free(lp->data);
     lp->data =  strdup(pasReqInfo[iReq].pszOutputFile);
 
-    if (!msProjectionsDiffer(&(map->projection), &(lp->projection)))
+    /* #3138 If PROCESSING "RESAMPLE=..." is set we cannot use the simple case */
+    if (!msProjectionsDiffer(&(map->projection), &(lp->projection)) && 
+         (msLayerGetProcessingKey(lp, "RESAMPLE") == NULL) )
     {
         /* The simple case... no reprojection needed... render layer directly. */
         lp->transform = MS_FALSE;



More information about the mapserver-commits mailing list