projection problem
Frank Warmerdam
warmerdam at POBOX.COM
Thu Dec 15 18:31:16 PST 2005
On 12/15/05, Serkan Girgin <girgink at gmail.com> wrote:
> Hi!
>
> I have a problem with on-the-fly projection and I would be grateful if you
> can help me. In my mapfile there is a raster Landsat image in UTM projection
> (zone 37N) and a shapefile containing a polygon with the same extent of the
> raster, again in UTM projection. When I set the overall projection of the
> mapfile to UTM these two layers coincide perfectly as expected (see
> landsat_utm.jpg). But when I change mapfile projection to a different
> projection, e.g. geographic or Lambert Conformal Conic, a shift occurs
> between the layers and they do not coincide (see landsat_lcc.jpg). Do you
> have any idea why this happens? You can find mapfiles that I used below.
Serkan,
I'm not sure from this information, but I would guess that
you get different results because the polygon is only
reprojected at the vertices and then the new polygon is
drawn "straight" between these transformed points. While
the raster is reprojected for each pixel. If the polygon is
big enough, this could account for the displacement.
But if this is the case, you should see the polygon match
up closely with the raster as you near one of the vertices of
the polygon.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the MapServer-users
mailing list