Opened 7 years ago

Last modified 7 years ago

#3933 new defect

WMS layer produces incorrect worldfile cell size distorting cascaded layers

Reported by: warmerdam Owned by: mapserverbugs
Priority: normal Milestone:
Component: WMS Client Version: unspecified
Severity: normal Keywords:
Cc: rhow, pramsey, dmorissette, assefa


The following logic in mapwmslayer.c produces the wrong cell size:

            double dfCellSizeX = MS_CELLSIZE(pasReqInfo[iReq].bbox.minx,
            double dfCellSizeY = MS_CELLSIZE(pasReqInfo[iReq].bbox.maxy,

The problem is that MS_CELLSIZE() is designed for MapServer "center of pixel" extents but WMS bounding boxes are outer edge of pixels. The fix is to use width+1 and height+1.

I have a test case to demonstrate this but the data is potentially not redistributable. I can, if necessary, produce a redistributable demonstration.

Attachments (1)

wms.patch (892 bytes) - added by warmerdam 7 years ago.
Proposed Fix.

Download all attachments as: .zip

Change History (2)

Changed 7 years ago by warmerdam

Attachment: wms.patch added

Proposed Fix.

comment:1 Changed 7 years ago by warmerdam

Cc: pramsey dmorissette assefa added
Note: See TracTickets for help on using tickets.