[Mapserver-users] Displaying Lat-Long grids in the map image?

Administrator jnovak at novacell.com
Thu Mar 20 09:28:25 PST 2003


This is a multi-part message in MIME format.

------_=_NextPart_001_01C2EF06.1D34104E
Content-Type: text/plain;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Francisco,
=20
A GRID keyword has been added to LAYER in Mapserver 3.7 that provides
the functionality you're looking for.  Here's an example:
=20
LAYER
  NAME "GRID"
  PROJECTION=20
   "proj=3Dlatlong"
   "ellps=3DWGS84"
   "datum=3DWGS84"
  END
  TYPE LINE
  STATUS DEFAULT
  CLASS
 COLOR 0 255 128
   LABEL
  TYPE BITMAP
  SIZE MEDIUM
  COLOR 255 128 89
   END
  END
  GRID
 MININTERVAL 0.10
 MAXINTERVAL 0.10
# INTERVALCOUNT 10
# MINARCS   16
# MAXARCS     16
  LABELFORMAT "DDMMSS"=20
  END
END
=20
This will render a grid in Lat-Long with one tenth degree spacing and
degree minute second labels.  For variable spacing, remove the min, max
interval tags.
=20
To allow Mapserver to pick defaults for the grid, simply specify
=20
GRID
END
=20
in your layer.
=20
Regards,
=20
John Novak
Novacell Technologies
www.novacell.com

-----Original Message-----
From: Francisco Delgado [mailto:fdelgado at snet.gob.sv]=20
Sent: Thursday, March 20, 2003 7:20 AM
To: mapserver-users at lists.gis.umn.edu
Subject: [Mapserver-users] Displaying Lat-Long grids in the map image?


Hello everybody.
=20
I want to set up my maps to show the Lat-Long (UTM or whatever) grids. I
got the idea that there is no way to add them as a property of the map
file, am I right? In that case, does someone has a clever idea to do
this? I made a shapefile with the gridlines cathegorized to show
different densities of gridlines at different scale levels, but I guess
that there must be much more elegant alternatives.
=20
Thank you all.
=20
---------------------------------
Francisco Delgado
Informatica - SNET
http://www.snet.gob.sv


------_=_NextPart_001_01C2EF06.1D34104E
Content-Type: text/html;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Dus-ascii">
<TITLE>Message</TITLE>

<META content=3D"MSHTML 5.50.4522.1800" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>Francisco,</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2>A GRID=20
keyword has been added to LAYER in Mapserver 3.7 that provides the =
functionality=20
you're looking for.  Here's an example:</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>LAYER<BR>  NAME "GRID"<BR>  =
PROJECTION <BR>  =20
"proj=3Dlatlong"<BR>   "ellps=3DWGS84"<BR>  =20
"datum=3DWGS84"<BR>  END<BR>  TYPE LINE<BR>  STATUS=20
DEFAULT<BR>  CLASS<BR> COLOR 0 255 128<BR>  =20
LABEL<BR>  TYPE BITMAP<BR>  SIZE =
MEDIUM<BR>  COLOR=20
255 128 89<BR>   END<BR>  END<BR>  =
GRID<BR> MININTERVAL=20
0.10<BR> MAXINTERVAL 0.10<BR># INTERVALCOUNT=20
10<BR># MINARCS   =
16<BR># MAXARCS    =20
16<BR>  LABELFORMAT "DDMMSS" <BR>  =
END<BR>END</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2>This=20
will render a grid in Lat-Long with one tenth degree spacing and degree =
minute=20
second labels.  For variable spacing, remove the min, max interval=20
tags.</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2>To=20
allow Mapserver to pick defaults for the grid, simply=20
specify</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>GRID</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>END</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2>in=20
your layer.</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>Regards,</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2>John=20
Novak</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =

size=3D2>Novacell Technologies</FONT></SPAN></DIV>
<DIV><SPAN class=3D782271717-20032003><FONT face=3DArial color=3D#0000ff =
size=3D2><A=20
href=3D"http://www.novacell.com">www.novacell.com</A></FONT></SPAN></DIV>=

<BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
  <DIV></DIV>
  <DIV class=3DOutlookMessageHeader lang=3Den-us dir=3Dltr =
align=3Dleft><FONT=20
  face=3DTahoma size=3D2>-----Original Message-----<BR><B>From:</B> =
Francisco=20
  Delgado [mailto:fdelgado at snet.gob.sv] <BR><B>Sent:</B> Thursday, March =
20,=20
  2003 7:20 AM<BR><B>To:</B>=20
  mapserver-users at lists.gis.umn.edu<BR><B>Subject:</B> [Mapserver-users] =

  Displaying Lat-Long grids in the map image?<BR><BR></FONT></DIV>
  <DIV><FONT face=3DArial size=3D2>Hello everybody.</FONT></DIV>
  <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
  <DIV><FONT face=3DArial size=3D2>I want to set up my maps to show the =
Lat-Long=20
  (UTM or whatever) grids. I got the idea that there is no way to add =
them as a=20
  property of the map file, am I right? In that case, does someone has a =
clever=20
  idea to do this? I made a shapefile with the gridlines cathegorized to =
show=20
  different densities of gridlines at different scale levels, but I =
guess that=20
  there must be much more elegant alternatives.</FONT></DIV>
  <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
  <DIV><FONT face=3DArial size=3D2>Thank you all.</FONT></DIV>
  <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
  <DIV><FONT face=3DArial =
size=3D2>---------------------------------<BR>Francisco=20
  Delgado<BR>Informatica - SNET<BR><A=20
  =
href=3D"http://www.snet.gob.sv">http://www.snet.gob.sv</A></FONT></DIV></=
BLOCKQUOTE></BODY></HTML>

------_=_NextPart_001_01C2EF06.1D34104E--



More information about the MapServer-users mailing list