# Curious Symbol Structure

6 messages
Open this post in threaded view
|

## Curious Symbol Structure

 I'm trying to learn the MapServer lore and now I'm focusing on symbols. Can anyone tell me what the logic is where one is defining a _line_ style by using a TYPE of ELLIPSE (instead of LINE) and POINTS definition of one (x y) as in the symbol definition below? (This is from http://mapserver.gis.umn.edu/docs/reference/symbology/examples). SYMBOL   NAME 'dashed1'   TYPE ELLIPSE   POINTS 1 1 END   FILLED true   STYLE 10 5 5 10 END END I'm just curious. This seems like some historical artifact from the days when learning MapServer was hard. ;-) The TYPE ELLIPSE seems especially weird to me. Why not TYPE LINE? - Bill Thoen
Open this post in threaded view
|

## Re: Curious Symbol Structure

 > Can anyone tell me what the logic is where one is defining a > _line_ style by using a TYPE of ELLIPSE (instead of LINE) The line will effectively be drawn as a thicker line, which looks nicer. Still kinda sketchy on my projects; I wish antialiasing did some good...
Open this post in threaded view
|

## Re: Curious Symbol Structure

 In reply to this post by bthoen@gisnet.com Hi, I am interested in an answer on this question from an expert, too. What I hope I understood from many little parts of information is: Specially for drawing thick line (line width > 1) you need a "pen". And think of the tip of the pen as being a circle or en ellipse. So your thick line is drawn by putting many ellipses one after another. A long time ago I read in a documentation for the "old" GKS about an optimization algorithm. Because you don't need to calculate the whole ellipse for each step. I hope, this explanation has some truth in it! Greetings Manfred Bill Thoen schrieb: > I'm trying to learn the MapServer lore and now I'm focusing on symbols. Can > anyone tell me what the logic is where one is defining a _line_ style by > using a TYPE of ELLIPSE (instead of LINE) and POINTS definition of one (x > y) as in the symbol definition below? (This is from > http://mapserver.gis.umn.edu/docs/reference/symbology/examples). > > SYMBOL >   NAME 'dashed1' >   TYPE ELLIPSE >   POINTS 1 1 END >   FILLED true >   STYLE 10 5 5 10 END > END > > I'm just curious. This seems like some historical artifact from the days > when learning MapServer was hard. ;-) > > The TYPE ELLIPSE seems especially weird to me. Why not TYPE LINE? > > - Bill Thoen >
Open this post in threaded view
|

## Re: Curious Symbol Structure

 In reply to this post by bthoen@gisnet.com The type refers to the base type of the brush or marker you are creating not to the type of feature it is useful for. It's true in this case that with the addition of the style that this symbol is only really useful for lines, but you could draw markers with it or fill polygons in which case the dashing would be ignored. I think ideally we should pull the style, better called a pattern, out into the class style. That would eliminate this type of confusion... Steve >>> Bill Thoen <[hidden email]> 12/26/2006 7:42:59 PM >>> I'm trying to learn the MapServer lore and now I'm focusing on symbols. Can anyone tell me what the logic is where one is defining a _line_ style by using a TYPE of ELLIPSE (instead of LINE) and POINTS definition of one (x y) as in the symbol definition below? (This is from http://mapserver.gis.umn.edu/docs/reference/symbology/examples). SYMBOL   NAME 'dashed1'   TYPE ELLIPSE   POINTS 1 1 END   FILLED true   STYLE 10 5 5 10 END END I'm just curious. This seems like some historical artifact from the days when learning MapServer was hard. ;-) The TYPE ELLIPSE seems especially weird to me. Why not TYPE LINE? - Bill Thoen