[mapserver-users] Shape file conversion question
Stephen Woodbridge
woodbri at swoodbridge.com
Mon Feb 11 12:41:08 PST 2002
Steve,
MapServer can already handle this situation without the need to convert
your files if you have PROJ4 built into your mapserver which would be a
good thing. In the mapfile there is a PROJECTION ... END section that
can be added before the LAYER definition in which case it is interperted
as the output project to use when you display your map. This is NOT the
section you need for your problem.
When you define a LAYER if you include a PROJECTION ... END section
which defines the current projection of the data defined in the data
files for this specific layer. So you would have to know (in any case)
what the projection parameters are for the data in your shape file, then
define layers like:
LAYER
NAME streets
...
PROJECTION
"proj=latlong"
# you might optionally need to define the ellps and other params
"ellps=grs80"
END
...
END
LAYER
NAME parcel
...
PROJECTION
"proj=utm"
...
END
...
END
I hope this helps,
-Steve W.
> klehr1 at tampabay.rr.com wrote:
>
> GIS 101 Question:
>
> I have a street layer shape file in decimal degrees and would like to
> overlay that on the parcel shapefile which is in feet.
>
> Parcel Layer:
> [steve at Miracle mapserv]$ ./showextent.pl /usr/maps/jbs.shp
> 2102351.89913092 394981.042580036 2250421.58049244 608454.114243081
> 2094948.41506284 384307.388996884 2257825.06456052
> 619127.767826233
>
> Street Layer
> [steve at Miracle mapserv]$ ./showextent.pl /usr/maps/str12065.shp
> -84.076234 30.118074 -83.604398 30.671142
> -84.0998258 30.0904206 -83.5808062 30.6987954
>
> Question:
>
> What are options in making these two files work together in the same
> view? (i.e. convert the shape file, or add a world file, projection
> file?)
>
> If you could elaborate a little on the solutions that would be great
> (i.e. conversion suggestion, or world file conversion example).
>
> Thank you very much.
> Steve Lehr
>
>
More information about the MapServer-users
mailing list