[mapserver-commits] r13028 - branches/branch-6-0/mapserver
svn at osgeo.org
svn at osgeo.org
Thu Feb 2 09:01:02 EST 2012
Author: aboudreault
Date: 2012-02-02 06:01:01 -0800 (Thu, 02 Feb 2012)
New Revision: 13028
Modified:
branches/branch-6-0/mapserver/HISTORY.TXT
branches/branch-6-0/mapserver/mapdrawgdal.c
Log:
Backport 6.0: Raster layer fails to be drawn if the window is less than half a pixel (#4172)
Modified: branches/branch-6-0/mapserver/HISTORY.TXT
===================================================================
--- branches/branch-6-0/mapserver/HISTORY.TXT 2012-02-02 13:56:22 UTC (rev 13027)
+++ branches/branch-6-0/mapserver/HISTORY.TXT 2012-02-02 14:01:01 UTC (rev 13028)
@@ -15,6 +15,8 @@
Current Version (future 6.0.2, SVN branch-6-0):
---------------------------
+- Raster layer fails to be drawn if the window is less than half a pixel (#4172)
+
- Fixed SLD with FILTER doesn't apply properly to database layers (#4112)
- Fixed a problem with calls to labelInImage() (maplabel.c) when label gutter
Modified: branches/branch-6-0/mapserver/mapdrawgdal.c
===================================================================
--- branches/branch-6-0/mapserver/mapdrawgdal.c 2012-02-02 13:56:22 UTC (rev 13027)
+++ branches/branch-6-0/mapserver/mapdrawgdal.c 2012-02-02 14:01:01 UTC (rev 13028)
@@ -250,6 +250,12 @@
src_ysize = MIN(MAX(0,(int) (lly - ury + 0.5)),
GDALGetRasterYSize(hDS) - src_yoff);
+ /* We want very small windows to use at least one source pixel (#4172) */
+ if( src_xsize == 0 && (urx - llx) > 0.0 )
+ src_xsize = 1;
+ if( src_ysize == 0 && (lly - ury) > 0.0 )
+ src_ysize = 1;
+
if( src_xsize == 0 || src_ysize == 0 )
{
if( layer->debug )
More information about the mapserver-commits
mailing list