I would like to shade the inside of a polygon along it's border. Using the polygon border as the edge. Making wider lines means offsetting the poygon internally or putting up with the edge not being specifically accurate.
bobb >>> Wim Vanbelle <wimvanbe...@gmail.com> wrote: Would it not be possible to draw the polygon as 2 different polygons (the inner polygon & the outer using the postgis functions)? You could specify a fixed offset for one or the other. On the other hand, if you just have 1 polygon (with a single line, so no inner polygons) and you're trying to accomplish a visual effect that the inside of the polygon lies further away, i would accomplish this by drawing a thicker border. Or you could possibly use the asymmetric line drawing functions that are available. Maybe give a more concrete example of what exactly you are trying to do. On 12 August 2010 22:46, Bob Basques <bob.basq...@ci.stpaul.mn.us> wrote: All, Wondering, would this work for INSIDE/OUTSIDE situations with regard to polygon drawing? Or is the left/right sides of the line strictly relying on the from/to aspects of how the polygon was drawn (clockwise/counterclockwise) This would be handy for off-setting to (ONLY) the inside of a polygon for example. Thanks bobb >>> Wim Vanbelle <wimvanbe...@gmail.com> wrote: Thank you very much everyone. And especially Thomas. That was indeed what I was looking for. You saved me a lot of work! Much appreciated. On 12 August 2010 17:50, Fawcett, David (MPCA) <david.fawc...@state.mn.us> wrote: Thanks Thomas That looks nice in my test example. David. -----Original Message----- From: thomas bonfort [mailto:thomas.bonf...@gmail.com] Sent: Thursday, August 12, 2010 10:45 AM To: Fawcett, David (MPCA) Cc: Wim Vanbelle; mapserver-users@lists.osgeo.org Subject: Re: [mapserver-users] Offset values from database the -99 is a special offset value that shifts the line as you are looking for. style color 255 0 0 offset -2 -99 width 2 end style color 0 255 0 offset 2 -99 width 2 end not perfect as there are artifacts on sharp angles, but worth a try. regards, thomas On Thu, Aug 12, 2010 at 16:56, Fawcett, David (MPCA) <david.fawc...@state.mn.us> wrote: > Wim, > > > > You can do these offsets in pixel values at a class level, just not a > feature level. This pretty much does what you are describing, although it > gets a little funky when the lines are diagonal and not straight. > > > > CLASS > > STYLE > > COLOR 0 0 0 > > WIDTH 2 > > END > > STYLE > > COLOR 255 0 0 > > WIDTH 2 > > OFFSET 10 10 > > END > > STYLE > > COLOR 0 255 0 > > WIDTH 2 > > OFFSET -10 -10 > > END > > > > END > > > > David. > > > > From: mapserver-users-boun...@lists.osgeo.org > [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Wim Vanbelle > Sent: Thursday, August 12, 2010 9:32 AM > To: mapserver-users@lists.osgeo.org > Subject: Re: [mapserver-users] Offset values from database > > > > Maybe this pic helps elaborate on what i'm trying to accomplish: > http://fileshare.myroute.be/exchange/asymmetriclinedrawing.png > It should be noted that the distance between the 2 (new) lines, should be a > fixed value over the zoomlevels. It must not be the case that at the > furthest zoomlevel the lines are further apart. > > I've looked all over for this, but never really found a proper solution. I > tried cartographic symbol drawing, but it only draws on the same side every > time. Maybe I'm just doing it wrong :). > > On 12 August 2010 16:28, Wim Vanbelle <wimvanbe...@gmail.com> wrote: > > Hello, > > thanks for your feedback. > > The issue with this, is that the underlying linestrings (the 2 that would > lie on top of eachother), have different colors :(. > > So they have to be moved apart from one another. I have not found a way to > do this with asymmetric line drawing either, as it will always offset to the > would always appear next to eachtoher (no matter what zoomlevel). > > I can elaborate on the problem more if I am a little too confusing ! > > On 12 August 2010 16:20, Cristiano Sumariva <sumar...@gmail.com> wrote: > > If it is a display problem why not try create some special symbology to > overlap one line with another using different symbol strokes. So the user > will se that are 2 lines overlayed. > > 2010/8/12 Wim Vanbelle <wimvanbe...@gmail.com> > > Hi David, > > I read that documentation before though. I was hoping it just hadn't been > updated... Is this possibly a feature for 6.0 ? > > Are there any other ways how one could offset a feature in pixels, rather > than in lat/long coords? > > Maybe I should elaborate on the original problem a little. Consider 2 line > segments that lie above one another. The general idea is to 'offset' them a > given x , y value, so they will both display next to one another, rather > than on top of eachother. > > If you would however perform this code simply on lat/long values, it would > imply, that when scaling your map at the most detailed zoom level, the lines > would lie very far apart, and when zoomed out, they would appear to lie on > top of eachother. > > I find it hard to believe that I would need to pre calculate all the data in > order to obtain geometry objects for each zoom level. > > Maybe some veterans have some good insight in this :). > > > > On 12 August 2010 15:26, Fawcett, David (MPCA) <david.fawc...@state.mn.us> > wrote: > > Wim, > > > > If you don’t want me to tell you, you will likely want to look at the > mapfile documentation at: http://mapserver.org/mapfile/style.html > > > > [Spoiler Alert] > > You can’t use values from an attribute table to set the value of this > property > > [/Spoiler Alert] > > > > David. > > From: mapserver-users-boun...@lists.osgeo.org > [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Wim Vanbelle > Sent: Thursday, August 12, 2010 5:48 AM > > To: mapserver-users@lists.osgeo.org > > Subject: [mapserver-users] Offset values from database > > > > Hi, > > I'm trying to load offset X, Y data from the postgis database. > > Each feature has an offset value defined there. > > My mapfile (relevant part) looks like this: > > In the layer: > DATA "geom_mercator from map_links using > unique Id using SRID=900913" > > STYLE > WIDTH 6 > COLOR 0 255 0 > ANTIALIAS TRUE > ANGLE AUTO > OFFSET [offsetX] [offsetY] > END > > Please don't tell me the offsetX, Y values cannot be read from the database. > That would be a huge issue for me. > > Thank you for your time. > > Best regards > > > > > > _______________________________________________ > mapserver-users mailing list > > mapserver-users@lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users@lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > >
_______________________________________________ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users