[Mapserver-users] Draw line in a map file

Eric Bridger eric at gomoos.org
Wed Sep 10 10:19:07 EDT 2003


O.K. I ran a quick test.  You also need a CLASS in your layer in order
to set the features color:
So try:
LAYER 
   NAME "pin"
...
   CLASS
     COLOR 255 0 0
   END
   FEATURE
   .....
   END
END

You might also try TRANSFORM FALSE since 
POINTS 1 1 50 50 50 1 1 1 END 
looks like pixel values to me.

Eric


On Wed, 2003-09-10 at 17:31, rajsalem at optonline.net wrote:
> Hi Eric,
> 
>      Thanks for your reply. i tried the feature object in the map file, but i am not getting the line drawn. here is the map file i am using.
> 
> MAP
>   NAME "test"
>   EXTENT 100 100 500 500 
>   SIZE 400 500 
>   IMAGECOLOR 102 102 255
>   TRANSPARENT OFF
>   UNITS METERS
>   IMAGETYPE GIF
>   LAYER
>     NAME "pin"
>     STATUS DEFAULT
>     TYPE LINE
>     TRANSFORM TRUE
>     FEATURE
>       TEXT "ptdrw"
>       POINTS
>         1 1 50 50 1 50 1 1
>       END
>     END
>   END
> # LAYER
> END
> 
> any changes needs to be done.
> 
> Raj
> 
> ----- Original Message -----
> From: Eric Bridger <eric at gomoos.org>
> Date: Wednesday, September 10, 2003 8:44 am
> Subject: Re: [Mapserver-users] Draw line in a map file
> 
> > You need a FEATURE object in your map file.  See this:
> > http://mapserver.gis.umn.edu/doc36/mapfile-reference.html#feature
> > 
> > Sorry I can't recall exactly how it is used.  I believe the 
> > FEATURE must
> > be part of a LAYER. Your POINTS can be either pixels or lat/lon by
> > setting TRANSFORM FALSE (pixels) or TRUE (lat/lon)
> > 
> > Eric
> > 
> > 
> > On Wed, 2003-09-10 at 15:06, rajsalem at optonline.net wrote:
> > > hello mapserver-users,
> > > 
> > >    How do i draw a line from a map file without having any 
> > shapefiles defined in the layer. Can i  draw a lines or points in 
> > a map file and just call the map from mapserver.
> > > 
> > > Thanks,
> > > Raj.
> > > 
> > > 
> > > _______________________________________________
> > > Mapserver-users mailing list
> > > Mapserver-users at lists.gis.umn.edu
> > > http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> > > 
> > 
> > 
> > 
> 
> 





More information about the mapserver-users mailing list