<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Is it possible to only use a subset of an image that is referenced in a mapfile?  In the mapfile below there are two FAA sectional charts.  There are borders on the charts that I don’t want on the final composite image.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>If the “EXTENT” actually clipped the image before rendering, I could get what I’m looking for, but it only seems to be used to determine overlap with the bounds of the output image (and not always then).<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I’m sure I could use something like gdal_translate to preprocess all of the charts, but that a really tedious sort of task and results in extra images lying around.  Would prefer to use source images and have the mapfile pull the correct bits out of them.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The charts are available at: <a href="http://aeronav.faa.gov/index.asp?xml=aeronav/applications/VFR/chartlist_sect">http://aeronav.faa.gov/index.asp?xml=aeronav/applications/VFR/chartlist_sect</a><o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Xander<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>#<o:p></o:p></p><p class=MsoNormal># MapServer map file for FAA Sectional Raster charts (test case w/ only two charts)<o:p></o:p></p><p class=MsoNormal>#<o:p></o:p></p><p class=MsoNormal>MAP<o:p></o:p></p><p class=MsoNormal>  NAME "FAA Sectional Raster"<o:p></o:p></p><p class=MsoNormal>  IMAGETYPE PNG<o:p></o:p></p><p class=MsoNormal>  SIZE 256 256<o:p></o:p></p><p class=MsoNormal>  DEBUG OFF<o:p></o:p></p><p class=MsoNormal>  UNITS DD<o:p></o:p></p><p class=MsoNormal>  SHAPEPATH "/MapData/FAA/SectionalRaster"<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>  PROJECTION "init=epsg:4269" END<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>  WEB<o:p></o:p></p><p class=MsoNormal>    METADATA<o:p></o:p></p><p class=MsoNormal>      "wms_srs" "EPSG:900913 EPSG:4326"<o:p></o:p></p><p class=MsoNormal>      "ows_enable_request" "*"<o:p></o:p></p><p class=MsoNormal>    END<o:p></o:p></p><p class=MsoNormal>  END<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>  LAYER<o:p></o:p></p><p class=MsoNormal>    NAME "LA North" DATA "Los Angeles 89 North.tif"<o:p></o:p></p><p class=MsoNormal>    STATUS ON TYPE RASTER DUMP TRUE PROJECTION "auto" END<o:p></o:p></p><p class=MsoNormal>  END<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>  LAYER<o:p></o:p></p><p class=MsoNormal>    NAME "LA South" DATA "Los Angeles 89 South.tif"<o:p></o:p></p><p class=MsoNormal>    STATUS ON TYPE RASTER DUMP TRUE<o:p></o:p></p><p class=MsoNormal>    PROJECTION "+proj=lcc +lat_1=38.66667 +lat_2=33.33333 +lat_0=34.16667 +lon_0=-118.5" END<o:p></o:p></p><p class=MsoNormal>    EXTENT -122 32 -119 34 END<o:p></o:p></p><p class=MsoNormal>  END<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>END<o:p></o:p></p></div></body></html>