Hi Julien,<br><br>That makes sense, but it doesn&#39;t work.&nbsp; I modified my mapfile so that I now generate a 20_deg x 20_deg tile that is 600_pixels x 600_pixels.&nbsp; If I georeference that image using the extents, I still get incorrect placement.&nbsp; Maybe if I choose an output projection which always has square pixels, like spherical mercator (?) this will work.&nbsp; I&#39;ll give it a shot.<br>
<br>Is there any way to give a WMS request via mapscript and NOT go through CGI?<br><br>Roger<br>--<br><br><br><br><div class="gmail_quote">On Mon, Dec 8, 2008 at 12:25 PM, Julien-Samuel Lacroix <span dir="ltr">&lt;<a href="mailto:jlacroix@mapgears.com">jlacroix@mapgears.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi,<br>
<br>
I guess would be that the WMS use non-square pixels. So if your BBOX x/y &nbsp;(rectangle in your case) doesn&#39;t match you WIDTH/HEIGHT ratio (square in your case) the map will appear stretched. MapServer will actually stretch the map to fit the extent in the WIDTH/HEIGHT.<br>

<br>
The mode=map don&#39;t do that. If your extent doesn&#39;t have the same ratio, it adds some degree in your extent to fit the size.<br>
<br>
Make sure your BBOX and EXTENT are a square in your requests and retry<br>
<br>
<br>
Julien<br>
<br>
Roger André wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div class="Wj3C7c">
Hi All,<br>
<br>
I think I&#39;m having an instance of cranial flatulation, but maybe not. &nbsp;Hopefully you can set me straight.<br>
<br>
I need to create an image with Mapserver using mapscript that I can then georeference manually and use in another application. &nbsp;It needs to look exactly the same as the image I can already generate via a WMS call that looks like this:<br>

<br>
<a href="http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.map" target="_blank">http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.map</a><br>
&amp;SERVICE=WMS<br>
&amp;version=%221.1.1%22<br>
&amp;REQUEST=GetMap<br>
&amp;LAYERS=imagery<br>
&amp;STYLES=&amp;BBOX=-125,39,-108,54<br>
&amp;WIDTH=600<br>
&amp;HEIGHT=600<br>
&amp;FORMAT=png<br>
&amp;SRS=epsg:4326<br>
<br>
I&#39;m testing my mapscript parameters using a simple &quot;mode=map&quot; call to Mapserver, and the results I&#39;m getting so far don&#39;t match the appearance of the WMS output at all. &nbsp;My mapfile has the following extent and projection info in it:<br>

<br>
 &nbsp;PROJECTION<br>
 &nbsp; &nbsp;&quot;init=epsg:4326&quot;<br>
 &nbsp;END<br>
<br>
 &nbsp;EXTENT -125.0 &nbsp;39.0 -108.0 &nbsp;54.0<br>
 &nbsp;SIZE 600 600<br>
<br>
In addition to the mapfile projection specification, I am also specifying the same projection info in each of my LAYERS as well.<br>
<br>
Is it possible to do what I&#39;m trying to accomplish here?<br>
<br>
Thanks,<br>
<br>
Roger<br>
--<br>
<br>
<br></div></div>
------------------------------------------------------------------------<br>
<br>
_______________________________________________<br>
mapserver-users mailing list<br>
<a href="mailto:mapserver-users@lists.osgeo.org" target="_blank">mapserver-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</blockquote>
<br>
-- <br>
Julien-Samuel Lacroix<br>
Mapgears<br>
<a href="http://www.mapgears.com/" target="_blank">http://www.mapgears.com/</a><br>
</blockquote></div><br>