[mapserver-users] Color the world, but not my country
Dear, I have a country shapefile and I would like to style everything, besides the one feature in the polygon. This is a shapefile layer, so I'm wondering on how I could possibly improve this: LAYER NAME "gadm" TYPE POLYGON TRANSPARENCY 70 DATA "gadm28.shp" STATUS default DEBUG 4 CLASS EXPRESSION ("[ISO]" != "NLD") style color "#00" end END END Basically, I would like to only use the data from the netherlands (NLD), because it's a lot less data, and color everything else, besides the one feature that it has. My above (working example) is taking the entire world and only filtering out what I want to see. The goal is to visually create a map of a single country and block out all the rest ;-). It's rendered as a tile layer. (gmaps) Thanks in advance for your feedback. Best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Color the world, but not my country
I came across this, but I'm not quite sure to what other layer it should relate? I would only have the 'Netherlands' description of the borders. I do not want to use the world dataset file, because it's too big. I cannot just add a 'complement' to the country layer or am I misinterpreting the mask function? It would be solved I believe if I could add a LAYER which did not require a datasource and renders everything black, but that is not possible I believe, because mapserver always requires a type and the annotation type is deprecated since 6.2 Thanks in advance. On 11 December 2015 at 20:57, Daniel Morissette <dmorisse...@mapgears.com> wrote: > I think the MASK layer should do what you want: > > http://mapserver.org/development/rfc/ms-rfc-79.html > > Daniel > > > On 2015-12-11 2:37 PM, Wim Vanbelle wrote: > >> Dear, >> >> I have a country shapefile and I would like to style everything, besides >> the one feature in the polygon. >> >> This is a shapefile layer, so I'm wondering on how I could possibly >> improve this: >> >> >> LAYER >> NAME "gadm" >> TYPE POLYGON >> TRANSPARENCY 70 >> DATA "gadm28.shp" >> STATUS default >> DEBUG 4 >> >> CLASS >> EXPRESSION ("[ISO]" != "NLD") >> >> style >> color "#00" >> end >> >> END >> END >> >> Basically, I would like to only use the data from the netherlands (NLD), >> because it's a lot less data, and color everything else, besides the one >> feature that it has. >> >> My above (working example) is taking the entire world and only filtering >> out what I want to see. >> >> The goal is to visually create a map of a single country and block out >> all the rest ;-). It's rendered as a tile layer. (gmaps) >> >> Thanks in advance for your feedback. >> >> Best regards, >> Wim >> >> >> ___ >> mapserver-users mailing list >> mapserver-users@lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > > -- > Daniel Morissette > http://www.mapgears.com/ > T: +1 418-696-5056 #201 > > http://evouala.com/ - Location Intelligence Made Easy > ___ > 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
Re: [mapserver-users] Mapserver fastcgi process errors / crash
Sorry, 6.4.1 Do you need the spawn-fastcgi script too? On 22 June 2015 at 17:51, Lime, Steve D (MNIT) steve.l...@state.mn.us wrote: What version? *From:* mapserver-users-boun...@lists.osgeo.org [mailto: mapserver-users-boun...@lists.osgeo.org] *On Behalf Of *Wim Vanbelle *Sent:* Monday, June 22, 2015 10:46 AM *To:* mapserver-users@lists.osgeo.org *Subject:* [mapserver-users] Mapserver fastcgi process errors / crash Hi all, Rather urgent production question. If we have some errors with our shapefiles, our fastcgi processes get killed very rapidly. (we believe this is some rapid error protection?) Is there a way to prevent this? We're running nginx + fastcgi mapserver over unix sockets. I'm aware that we need to look into our shapefiles/dbf's but that's not a simple thing because they need to be updated often. Migration to postgres is also not an option. Please let me know if we can tune this somehow. Anyone experience with this? Thanks in advance! best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Mapserver fastcgi process errors / crash
This is the full configuration: MapServer version 6.4.1 OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=FASTCGI INPUT=JPEG INPUT=POSTGIS INPUT=SHAPEFILE On 22 June 2015 at 17:55, Wim Vanbelle wimvanbe...@gmail.com wrote: Sorry, 6.4.1 Do you need the spawn-fastcgi script too? On 22 June 2015 at 17:51, Lime, Steve D (MNIT) steve.l...@state.mn.us wrote: What version? *From:* mapserver-users-boun...@lists.osgeo.org [mailto: mapserver-users-boun...@lists.osgeo.org] *On Behalf Of *Wim Vanbelle *Sent:* Monday, June 22, 2015 10:46 AM *To:* mapserver-users@lists.osgeo.org *Subject:* [mapserver-users] Mapserver fastcgi process errors / crash Hi all, Rather urgent production question. If we have some errors with our shapefiles, our fastcgi processes get killed very rapidly. (we believe this is some rapid error protection?) Is there a way to prevent this? We're running nginx + fastcgi mapserver over unix sockets. I'm aware that we need to look into our shapefiles/dbf's but that's not a simple thing because they need to be updated often. Migration to postgres is also not an option. Please let me know if we can tune this somehow. Anyone experience with this? Thanks in advance! best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Mapserver fastcgi process errors / crash
Hi all, Rather urgent production question. If we have some errors with our shapefiles, our fastcgi processes get killed very rapidly. (we believe this is some rapid error protection?) Is there a way to prevent this? We're running nginx + fastcgi mapserver over unix sockets. I'm aware that we need to look into our shapefiles/dbf's but that's not a simple thing because they need to be updated often. Migration to postgres is also not an option. Please let me know if we can tune this somehow. Anyone experience with this? Thanks in advance! best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Re: Clustering and tile clipping
Unfortunately it didn't solve the problem. I tried a lot of different values though. On top of that I'm also getting a lot of [Tue Jan 17 08:50:08 2012] [warn] [client] mod_fcgid: read data timeout in 40 seconds [Tue Jan 17 08:50:08 2012] [error] [client] Premature end of script headers: mapserv.fcgi In msCleanupOnSignal. [Tue Jan 17 08:50:48 2012] [warn] [client] mod_fcgid: read data timeout in 40 seconds [Tue Jan 17 08:50:48 2012] [error] [] Premature end of script headers: mapserv.fcgi In msCleanupOnSignal. Anyone have a clue how to increase the timeout? I'm clustering 44K points. And at lower zoomlevel (values) it is taking a long time. Wim On 16 January 2012 15:48, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, Thanks for your answer, i'll give that a try immediately :). I remember I played around with it in the beginning, but currently it is indeed set to 0. What is an acceptable value for this? Am I to set this to the same value as the maxdistance in the cluster? (Being 100 in my case) Or perhaps this should be set to the size of my image representing the cluster, being 10 pixels? Best regards, Wim On 16 January 2012 10:55, Tamas Szekeres szeker...@gmail.com wrote: Hi Wim, Did you try the BUFFER setting to increase the search area during the cluster creation? For more information see: http://mapserver.org/mapfile/cluster.html Best regards, Tamas 2012/1/16 Wim Vanbelle wimvanbe...@gmail.com Does anyone have any working examples of how they implemented clustering without the tile clipping? Thanks. On 11 January 2012 10:00, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, I'm very happy that mapserver is now capable of server side clustering. However I wonder if it's possible to completely get rid of the tile clipping. Currently I've clustered a point layer with 44k points: CLUSTER MAXDISTANCE 100 REGION ellipse END It is displayed with a simple image: STYLE SYMBOL small_shaded.png SIZE21 OUTLINECOLOR0 0 0 END However, when viewing this on google maps, the images are often clipped at the tile edges. I figured that I could solve this with mapcache: tileset name=ld sourceld/source cachedisk/cache gridg2/grid formatPNG/format metatile2 2/metatile metabuffer30/metabuffer expires3600/expires auto_expire2592000/auto_expire /tileset i've tried higher values for metatile and it helps a bit, but the problem simply shifts location. Also with higher values (eg 5 5 metatile) mapserver doesn't return the tiles on time for mapcache and I get gaps in my results. Would preseeding the data help with the timeouts? Any other solutions that I may try? The metadata parameter for tile_edge buffer only works with labels as far as i know. Thanks in advance, this issue has been troubling me for some time now :). Best regards, Wim ___ 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] Re: Clustering and tile clipping
Does anyone have any working examples of how they implemented clustering without the tile clipping? Thanks. On 11 January 2012 10:00, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, I'm very happy that mapserver is now capable of server side clustering. However I wonder if it's possible to completely get rid of the tile clipping. Currently I've clustered a point layer with 44k points: CLUSTER MAXDISTANCE 100 REGION ellipse END It is displayed with a simple image: STYLE SYMBOL small_shaded.png SIZE21 OUTLINECOLOR0 0 0 END However, when viewing this on google maps, the images are often clipped at the tile edges. I figured that I could solve this with mapcache: tileset name=ld sourceld/source cachedisk/cache gridg2/grid formatPNG/format metatile2 2/metatile metabuffer30/metabuffer expires3600/expires auto_expire2592000/auto_expire /tileset i've tried higher values for metatile and it helps a bit, but the problem simply shifts location. Also with higher values (eg 5 5 metatile) mapserver doesn't return the tiles on time for mapcache and I get gaps in my results. Would preseeding the data help with the timeouts? Any other solutions that I may try? The metadata parameter for tile_edge buffer only works with labels as far as i know. Thanks in advance, this issue has been troubling me for some time now :). Best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Re: Clustering and tile clipping
Hi, Thanks for your answer, i'll give that a try immediately :). I remember I played around with it in the beginning, but currently it is indeed set to 0. What is an acceptable value for this? Am I to set this to the same value as the maxdistance in the cluster? (Being 100 in my case) Or perhaps this should be set to the size of my image representing the cluster, being 10 pixels? Best regards, Wim On 16 January 2012 10:55, Tamas Szekeres szeker...@gmail.com wrote: Hi Wim, Did you try the BUFFER setting to increase the search area during the cluster creation? For more information see: http://mapserver.org/mapfile/cluster.html Best regards, Tamas 2012/1/16 Wim Vanbelle wimvanbe...@gmail.com Does anyone have any working examples of how they implemented clustering without the tile clipping? Thanks. On 11 January 2012 10:00, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, I'm very happy that mapserver is now capable of server side clustering. However I wonder if it's possible to completely get rid of the tile clipping. Currently I've clustered a point layer with 44k points: CLUSTER MAXDISTANCE 100 REGION ellipse END It is displayed with a simple image: STYLE SYMBOL small_shaded.png SIZE21 OUTLINECOLOR0 0 0 END However, when viewing this on google maps, the images are often clipped at the tile edges. I figured that I could solve this with mapcache: tileset name=ld sourceld/source cachedisk/cache gridg2/grid formatPNG/format metatile2 2/metatile metabuffer30/metabuffer expires3600/expires auto_expire2592000/auto_expire /tileset i've tried higher values for metatile and it helps a bit, but the problem simply shifts location. Also with higher values (eg 5 5 metatile) mapserver doesn't return the tiles on time for mapcache and I get gaps in my results. Would preseeding the data help with the timeouts? Any other solutions that I may try? The metadata parameter for tile_edge buffer only works with labels as far as i know. Thanks in advance, this issue has been troubling me for some time now :). Best regards, Wim ___ 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] Clustering and tile clipping
Hi, I'm very happy that mapserver is now capable of server side clustering. However I wonder if it's possible to completely get rid of the tile clipping. Currently I've clustered a point layer with 44k points: CLUSTER MAXDISTANCE 100 REGION ellipse END It is displayed with a simple image: STYLE SYMBOL small_shaded.png SIZE21 OUTLINECOLOR0 0 0 END However, when viewing this on google maps, the images are often clipped at the tile edges. I figured that I could solve this with mapcache: tileset name=ld sourceld/source cachedisk/cache gridg2/grid formatPNG/format metatile2 2/metatile metabuffer30/metabuffer expires3600/expires auto_expire2592000/auto_expire /tileset i've tried higher values for metatile and it helps a bit, but the problem simply shifts location. Also with higher values (eg 5 5 metatile) mapserver doesn't return the tiles on time for mapcache and I get gaps in my results. Would preseeding the data help with the timeouts? Any other solutions that I may try? The metadata parameter for tile_edge buffer only works with labels as far as i know. Thanks in advance, this issue has been troubling me for some time now :). Best regards, Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Dynamic map data input for mapserver
Hi, When using routeplanners, you often get very detailed results of routes, especially long ones, that need to be drawn by the client. We are considering the option of using mapserver to render these results as tiles. What would be the best way to implement a thing like this? I was thinking of generating some kind of WFS output that is used as input for mapserver, but i'm not sure if it will be dynamic enough. Or, can I for instance make a WMS request that actually specifies the whole Linestring/polyline that needs to be drawn by mapserver? Thanks for your insight. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Vectorizing/digitizing points that have been rendered as raster
Hi, Currently we have a lot of big datasets with points (think 50k points for instance) that we can now cluster service side with mapserver (cool). That works like a charm, but now we would like to fetch information if you click on them. (be it a clustered icon, or a non clustered). The client we are using is google maps with custom javascript code. As far as I'm aware, I need to perform a WFS request for this. I haven't got any problems setting that up, but what should be passed as a filter? Can we just pass a point as a filter in the request, or are we forced to supply a bounding box. I'm wondering if there are common solutions to tackle a similar problem. Thanks in advance. Best regards. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] free multilayer GIS data
I'd start here: http://downloads.cloudmade.com/ http://downloads.cloudmade.com/And then look for additional data in the OpenStreetMap project. On top of those, googling around for 'open data' also comes up with a lot of info :). On 17 August 2011 12:55, Esmin Gracić esmin.gra...@gmail.com wrote: Hi all, I need to make a presentation on free gis stack (apache phpmapscript pg pgrouting) to some interested party. My question is do you know where I could get some nice free GIS data with multiple layers like roads (to build pgrouting stuff on), houses, objects, gasline, powerline, optical cables, water etc... This is for demo only, so area does not have to more than 1km2. Pointing in right direction, would be helpful, too. Thanks, Esmin. ___ 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
Re: [mapserver-users] mapserver defunct
The problem definately seems related to concurrency. Load benching using 1 concurrent requests: 0 fails. Load benching using 2 concurrent requests: +- 30% fails more concurrent = more fails. The failed seem to return with HTTP 500. Running a shp2img during this time, still returns a good image. I'll post more info about this topic and a resolution, if i find one :). Do note that we're dealing with shapefiles with 3 000 000 linestrings. While they consist only of 2 coordinates (begin end obviously), it's still a big thing to load. On 12 January 2011 06:18, Stephen Woodbridge wood...@swoodbridge.comwrote: Wim, I'm not sure I have any magic bullet for this problem, because I'm not sure what is causing it. If this was my project, I would tackle it like this: 1. alert people we have a problem that might impact the release date if you have not already done that 2. divide the problem to try and localize what is causing it a. do the tiles that fail, always fail? this points at a potential mapserver related issue as opposed to a load issue a.1 have you turned on mapfile DEBUG output? can you identify the layer a.2 you can get some maybe useful output from: strace /path/to/mapserv QUERY_STRING='url arguments' gdb /path/to/mapserv run QUERY_STRING='url arguments' where quit valgrind /path/to/mapserv QUERY_STRING='url arguments' a.3 you can run it with shp2img ... b. is it fastcgi, do you see the same problem if you build it as cgi c. is it lighttpd, do you see the same problem if you run it with apache fastcgi? what about apache cgi? Intermittent problems are the hardest to diagnose because they often are not reproducable in a debuging environment. We might be able to help you with more information. I have done a lot of load testing on various versions of mapserver and tiled all of US and Canada about 4-5 different times using mapserver. I have not used FastCGI/Lighty and lighttpd, so I'm not sure about what influence that might have on the problem. Hope this gives you some ideas. Best regards, -Steve W http://imaptools.com/ On 1/11/2011 3:15 PM, Wim Vanbelle wrote: Well, the problem is that the requests are not always served. During load testing, say about 10 concurrent requests I also load the map. But there are randomly tiles that are never loaded. I thought this would be related to the defunct processes, but that is not a certainty. My setup is lighttpd + fastcgi. To be honest I'm in a pretty bad situation now, considering we go live with this in 9 days. Not sure what else I can do honestly. On 11 January 2011 19:05, Stephen Woodbridge wood...@swoodbridge.com mailto:wood...@swoodbridge.com wrote: Here is an explanation of defunct processes: http://www.webmasterworld.com/forum40/1032.htm I'm sure there are others. So since you are running fastcgi, it is the responsibility of the fastcgi parent process to clean up dead child processes. It is likely that it is busy because you are doing load testing or there is some subtle issue that is occurring. If you are getting good responses from mapserver, you probably do not need to worry about it unless you are getting tons of them. If you are using apache, I believe there is a parameter that you can set for fastcgi processes which will let them die after N requests. This should clean those up and apache will spawn a new process if needed to replace the that died. -Steve W On 1/11/2011 10:04 AM, Wim Vanbelle wrote: Hi all, I'm getting a lot of 27098 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct 27104 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct while load testing mapserver. Is there any way I can go about checking out why this is happening? Especially when doing concurrency tests it seems to go sideways. Currently i'm using : MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE using FastCGI/Lighty. Do note that the mapfile itself seems to be fine, since it does render content when i'm the single user using it. Thanks for your expert insight :D. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org mailto:mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver defunct
Thanks for your comments. I'll try switching to CGI. My current config is setup like this: MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE tmpfs is used over ramfs, because the latter cannot be exported using nfs. Initially we started using postgres, but switched to shapefiles because that would scale better with higher load. (no need to setup more databases) We have a lot of ram available, so any tips on using that better are appreciated. using iostat/vmstat i can see that disk was no issue though. On 12 January 2011 16:52, Stephen Woodbridge wood...@swoodbridge.comwrote: Have you built mapserver with threads? If so disable this and see if the problem goes away. HTTP 500 probably means that your process is getting a SIGV. Also unless you are using a database connection, using fastcgi is not going to give you a huge benefit because of the way mapserver works. And threads will probably not help either. OK, I admit I am somewhat biased against threads :) Tuning for performance in my experience is: 1. start by keep it simple 2. measure where your bottlenecks are 3. fix these bottlenecks 4. repeat Don't throw everything at it because you think think it will help. It just makes a complicated mess and you have no way to know if any given pieces is helping or hurting. Using a tmpfs is good if you manage it, I prefer a ramfs, the difference being the a ramfs is fixed size and you have to explicitly load it, but you have more control over size and behavior for a little more planning and it does not have down side of being able to eat all your memory or forcing linux to do more swapping which can slow down things. Also if you need to squeeze an additional 1-1.5% performance and can live without swap, disable your swap partition. Linux is a swappy OS and swaps to disk before it needs to in anticipation, this is costly if you have a lot of memory and do not NEED to swap. -Steve W On 1/12/2011 7:23 AM, Wim Vanbelle wrote: The problem definately seems related to concurrency. Load benching using 1 concurrent requests: 0 fails. Load benching using 2 concurrent requests: +- 30% fails more concurrent = more fails. The failed seem to return with HTTP 500. Running a shp2img during this time, still returns a good image. I'll post more info about this topic and a resolution, if i find one :). Do note that we're dealing with shapefiles with 3 000 000 linestrings. While they consist only of 2 coordinates (begin end obviously), it's still a big thing to load. On 12 January 2011 06:18, Stephen Woodbridge wood...@swoodbridge.com mailto:wood...@swoodbridge.com wrote: Wim, I'm not sure I have any magic bullet for this problem, because I'm not sure what is causing it. If this was my project, I would tackle it like this: 1. alert people we have a problem that might impact the release date if you have not already done that 2. divide the problem to try and localize what is causing it a. do the tiles that fail, always fail? this points at a potential mapserver related issue as opposed to a load issue a.1 have you turned on mapfile DEBUG output? can you identify the layer a.2 you can get some maybe useful output from: strace /path/to/mapserv QUERY_STRING='url arguments' gdb /path/to/mapserv run QUERY_STRING='url arguments' where quit valgrind /path/to/mapserv QUERY_STRING='url arguments' a.3 you can run it with shp2img ... b. is it fastcgi, do you see the same problem if you build it as cgi c. is it lighttpd, do you see the same problem if you run it with apache fastcgi? what about apache cgi? Intermittent problems are the hardest to diagnose because they often are not reproducable in a debuging environment. We might be able to help you with more information. I have done a lot of load testing on various versions of mapserver and tiled all of US and Canada about 4-5 different times using mapserver. I have not used FastCGI/Lighty and lighttpd, so I'm not sure about what influence that might have on the problem. Hope this gives you some ideas. Best regards, -Steve W http://imaptools.com/ On 1/11/2011 3:15 PM, Wim Vanbelle wrote: Well, the problem is that the requests are not always served. During load testing, say about 10 concurrent requests I also load the map. But there are randomly tiles that are never loaded. I thought this would be related to the defunct processes, but that is not a certainty. My setup
Re: [mapserver-users] Labels are cut at the borders of the tiles
Thanks for clearing that out Thomas. We were having similar issues here. Is there a similar setting for linestring drawing? Eg when using pixel offset the lines get cut off at the end of the tiles. This is resolved using the gutter parameter in openlayers as you have mentioned, but is still a problem for google and bing maps. thanks. On 10 January 2011 16:46, thomas bonfort thomas.bonf...@gmail.com wrote: it does not seem to be documented. when set to ON, what happens is that labels are fixed to a geographical location on the feature, instead of being adjusted to fit in the pixel range of the created map. this is essentially used for tiling, as in that case each feature will be labeled exactly once, instead of once per tile. -- thomas On Mon, Jan 10, 2011 at 16:34, Niccolo Rigacci nicc...@rigacci.org wrote: On Mon, Jan 10, 2011 at 10:43:22AM -0400, Jeff McKenna wrote: PROCESSING LABEL_NO_CLIP=1 Please, do you know if that directive is documented somewhere? I searched www.mapserver.org (with the Quick search box and with Google), but nothing is found. -- Niccolo Rigacci Firenze - Italy ___ 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
[mapserver-users] mapserver defunct
Hi all, I'm getting a lot of 27098 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct 27104 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct while load testing mapserver. Is there any way I can go about checking out why this is happening? Especially when doing concurrency tests it seems to go sideways. Currently i'm using : MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE using FastCGI/Lighty. Do note that the mapfile itself seems to be fine, since it does render content when i'm the single user using it. Thanks for your expert insight :D. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver defunct
Well, the problem is that the requests are not always served. During load testing, say about 10 concurrent requests I also load the map. But there are randomly tiles that are never loaded. I thought this would be related to the defunct processes, but that is not a certainty. My setup is lighttpd + fastcgi. To be honest I'm in a pretty bad situation now, considering we go live with this in 9 days. Not sure what else I can do honestly. On 11 January 2011 19:05, Stephen Woodbridge wood...@swoodbridge.comwrote: Here is an explanation of defunct processes: http://www.webmasterworld.com/forum40/1032.htm I'm sure there are others. So since you are running fastcgi, it is the responsibility of the fastcgi parent process to clean up dead child processes. It is likely that it is busy because you are doing load testing or there is some subtle issue that is occurring. If you are getting good responses from mapserver, you probably do not need to worry about it unless you are getting tons of them. If you are using apache, I believe there is a parameter that you can set for fastcgi processes which will let them die after N requests. This should clean those up and apache will spawn a new process if needed to replace the that died. -Steve W On 1/11/2011 10:04 AM, Wim Vanbelle wrote: Hi all, I'm getting a lot of 27098 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct 27104 x 20 0 000 Z1 0.0 0:00.03 mapserv defunct while load testing mapserver. Is there any way I can go about checking out why this is happening? Especially when doing concurrency tests it seems to go sideways. Currently i'm using : MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE using FastCGI/Lighty. Do note that the mapfile itself seems to be fine, since it does render content when i'm the single user using it. Thanks for your expert insight :D. ___ 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
Re: [mapserver-users] ‘mode=map’ with WMC of dyn amic Layer failing with getString() error
I haven't done something similar to what you are trying to do, but at first glance i see a space standing between vector’ and END. Did you try replacing the space with %20? Just a thought :). On 11 December 2010 14:49, Jeff McKenna jmcke...@gatewaygeomatics.comwrote: On 10-12-10 5:57 PM, myOpenLayersUName wrote: And, maybe I have, but now I’m completely stuck. At this point, I have the following URL: http://localhost/cgi-bin/mapserv.exe?map=/ms4w/apps/testing/dynamic.mapmap.layer[line]=DATA ‘id3/vector’ ENDlayers=linemode=map And it is giving me this error: getString(): Symbol definition error. Parsing error near (‘):(line 1) Quick note: That error usually occurs when there is a problem with the syntax of your CGI query string. There are notes on that at: http://www.mapserver.org/cgi/controls.html#changing-map-file-parameters-via-a-form-or-a-url My experience is that that error doesn't refer to a problem in your mapfile, but refers to a problem with the way you are calling mapserv.exe Others can hopefully assist you more thoroughly :) -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ ___ 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
Re: [mapserver-users] map file paths
I'm pretty sure you can use the rewrite module in IIS to achieve what you need. I use it myself for a couple of REST webservices. Do note that I am using IIS 7. Take a look here : http://learn.iis.net/page.aspx/460/using-the-url-rewrite-module/ On 4 November 2010 07:53, Waberzeck, Thomas thomas.waberz...@liag-hannover.de wrote: Jukka Rahkonen wrote: P Kishor wrote: So you have 15 copies of the binary floating around on your computer. What a nightmare. If you upgrade, you have to make 15 copies of the new version and replace the old version. What would happen when you publish the 150th geologic map? Use a single binary, and use a wrapper (or the env variable) to get the right query. I do not believe there are handy wrappers for Windows and the only way I have been able to get SetEnvIf to work is to make copies of mapserv.exe with different names. I maintain a batch file about our services with lines like COPY mapserv.exe WMS_service1 etc. and then I only need to run the batch after update and publishing the 150th service does not change anything. If you have php it's quite easy to write a small wrapper for it. See http://www.mapserver.org/ogc/mapscript.html#php-example so the only thing to do is to write the wrappers once and you have a single setup of Mapserver. Thomas BTW: The Example should be updated - I think php_mapscript_4.10.0.dll is out of date. The name of the .dll is just php_mapscript.dll. ___ 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
Re: [mapserver-users] conf of MapServ+Apache.Lighttpd for better usability
This would be a good thing. That way, if you would zoom in to a location very quickly, you would also not have to wait for mapserver to render the outer zooms first (where you clicked through quite fast), but you would get your data first and the data you don't need anymore later. But i suppose this is not easy to realize. On 2 November 2010 18:40, Sebastian E. Ovide sebastian.ov...@gmail.comwrote: Hi Guys, I am using MapServer as a FastCgi (with lighttpd and Apache) connected to Oracle, PG, ESRI shapes, ESRI binary grids and MapInfo TAB files. There is a situation that makes the use of MapServer not very user friendly: An user A opens a map, activates a slow layer and drags the map around. This would add a lot of calls to the webserver that would launch many MapServer processes reaching the maximum number of processes. At the same time, there is another user B displaying another layer... this time a fast layer As the maximum number of processes has been reached, the webserver cannot create new processes until those alive finish their work, it cannot serve the other user... that is very annoying as The other user would have to wait a long time until the queue is processed and his map is displayed. Another similar situation is when the user A get annoyed as the map is not displaying and therefore decides to turn off the layer and turn on a different layer... say a fast layer... he still need to wait that all the MapServer processes finish the processing... That annoys the users that doesn't understand what is going on... and thinks that the server has crashed... Is there anyway to configure Apache/Lighttpd to give higher priority to the new calls ? (that means to conver the queue from FIFO to LIFO) I have configured Apache FastCgi to kill the old processes once a minute... but the process wont die... actually they would not die with a simple kill... they would die with only kill -9 !!! Any other solutions ? Thanks -- Sebastian E. Ovide ___ 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
Re: [mapserver-users] Polygon hatch mismatch at tile borders.
I mailed this list for an issue regarding lines that have a certain thickness, that get cut off at the tile. Is this related to the same known issue above? So far I've been unable to resolve it using other suggestions. While using openlayers I can effectively use gutter, but that is a client side solution. I'd prefer something at the mapserver level as the client solution wouldn't work on google or bing maps. Steve Lime: this was the problem I reported to you a while ago. Maybe there's an update on the case since then? The original mail can be found at : http://osgeo-org.1803224.n2.nabble.com/Mapserver-tile-generation-google-maps-td5444090.html#a5455480 Using tilecache is not an option, I'm dealing with realtime information. Thanks. On 28 October 2010 17:00, thomas bonfort thomas.bonf...@gmail.com wrote: Yes, the problem is known and hasn't been addressed yet. This one would be a candidate for 6.2. cheers, thomas On Thu, Oct 28, 2010 at 15:19, Stephen Woodbridge wood...@swoodbridge.com wrote: On 10/28/2010 9:00 AM, Ausderau Larissa LT wrote: Thanks Alex, The gutter solution gives something better and the singleTile solve the problem. Unfortunately I can't use them, because we are pre-generating tiles in order to have good performances, which means that I need a solution at the level MapServer (Mapfile and / or symbol file). I've found that in The MapServer RFC Documentation http://mapserver.org/development/rfc/ms-rfc-45.html: - Polygon fill symbols Give hatches and vector fills a stable geographical coordinate origin (0,0) to better support tiling and continuous rendering of neighboring polygons - Does it mean that the problem is known and have been fixed? Larissa, Have you check to see it there is an open bug for this? The RFC would seem to indicate that the problem is known. And that it was considered in RFC45, but it is not clear from the RFC that it was actually solved as there is no bug number at the bottom that specifically tracks that particular change. This RFC was targeted for Mapserver 5.4. If you are on 5.4 or later then you might want to get a ticket opened asap, and maybe a fix can get put in 6.0 to resolve this. Steve L, Thomas B, - Do you guys know if this was tackled or not? -Steve W Best regards! Larissa -Message d'origine- De : Strunck, Alexander [mailto:stru...@bicc.de] Envoyé : jeudi, 28. octobre 2010 12:21 À : Ausderau Larissa LT; 'mapserver-users@lists.osgeo.org' Objet : AW: Polygon hatch mismatch at tile borders. Hello you can use the parameter gutter. Here an example http://trac.osgeo.org/openlayers/browser/trunk/openlayers/examples/gutter.html Or you can use the parameter onetile. Here another example http://dev.openlayers.org/releases/OpenLayers-2.9/examples/notile.html alex Von: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-boun...@lists.osgeo.org] Im Auftrag von Ausderau Larissa LT Gesendet: Donnerstag, 28. Oktober 2010 12:01 An: 'mapserver-users@lists.osgeo.org' Betreff: [mapserver-users] Polygon hatch mismatch at tile borders. Hi, I'm using MapServer 5.4.2 and when I'm working with tiles the hatches of hatch filled polygons are not matching at tile borders. See example hatch_mismatch.jpg How can I solve that? Thanks Larissa ___ 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 ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] How split single polygon into multiple polygons
I think the main question here, is what you are trying to achieve? Do you just want to split them randomly? Evenly into pieces of certain sizes? Based on other geometries that may or may not overlap? Best regards, Wim On 7 October 2010 14:51, venkat ven.tammin...@gmail.com wrote: Dear All, I need to split single polygon into multiple polygons using C#.Any one can guide me.I am waiting for your great response. Thanks and Regards, Ven ___ 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
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ 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
Re: [mapserver-users] Split Polygon using Clint or server side code not with PostGIS
Hmm. No guarantees, but perhaps the geoapi.net or nettopolgysuite have this functionality. Alternatively, what you could do, although it still involves a spatial database, is use the C# Sql Spatial libraries. You could install a microsoft sql server 2008 (spatial) database, reference the spatial libraries and perform the split of the polygon with those spatial functions, using C#. But as you stated, this is probably not the solution you are looking for. Maybe someone else is aware of another third party library that does this :). On 7 September 2010 08:59, venkat ven.tammin...@gmail.com wrote: Dear Wim, Thanks for your great response...I am not looking for triangulation(tin).I am looking for Split operation based on line...I did it using PostGIS (st_split) function.I want to work it by coding (that can be client or server side code.)..Please let me know is it possible.if it is possible, please let me know.. Thanks and Regards, Ven On Tue, Sep 7, 2010 at 12:25 PM, Wim Vanbelle wimvanbe...@gmail.comwrote: Hi, Are you trying to split a polygon using another geo object like a line? Or do you just want to divide the polygon in smaller pieces? You may want to look at triangulation for that. Take a look here: http://en.wikipedia.org/wiki/Polygon_triangulation Best regards, Wim On 7 September 2010 07:46, venkat ven.tammin...@gmail.com wrote: Dear All, How i can split polygon by client(JavaScript code) or Server side(C#).I have done splitting polygon using Postgis..I am not able to understand how to split polygon by code(client or server side code.Please let me know .Its very urgent. I am waiting for your great response. Thanks and Regards, Ven ___ 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
Re: [mapserver-users] MapServer and MapScript in separate hosts
Hi, If you compile mapserver from source, you can use ./configure --prefix=/path/to/executable to install it in the folder you want. You do need to make sure that LD can find the shared libraries. This should then be set in apache config so that the right environment paths are loaded. As for the external URL thing. Just configure a CGI script at a given URL (as configured in your webserver) and then point to the location of your mapserv executable. Perhaps this is what you are looking for: http://mapserver.org/cgi/wrapper.html 2010/9/7 Román González rgonza...@normagricola.com Hello: Maybe it’s a silly question but I’d like to know if I can use MapScript in a web server with PHP being MapServer installed in a different host. All the examples I’ve seen seem to run in the same server and I can’t find a way to set up an URL for the MapServer location. Thank you. ___ 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
Re: [mapserver-users] RGBA transparent images?
Hi Steve, I have this in my file: OUTPUTFORMAT NAME AGGPNG DRIVER AGG/PNG EXTENSION png MIMETYPE image/png;mode=24bit; IMAGEMODE RGBA FORMATOPTION INTERLACE=true FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=ON FORMATOPTION QUANTIZE_COLORS=256 END And in my layer, if you want opacity: OPACITY 60 That should render nice lines :). On 24 August 2010 21:16, Stephen Woodbridge wood...@swoodbridge.com wrote: If I want to generate RGBA transparent images using AGG, what should my OUTPUTFORMAT block look like? I was using this one for 8-bit images, but the anti aliasing was creating blackish artifacts along the rendered lines. Is there a way to avoid them? OUTPUTFORMAT NAME agg_qn DRIVER AGG/PNG EXTENSION png MIMETYPE image/png IMAGEMODE RGBA TRANSPARENT ON FORMATOPTION INTERLACE=false FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=OFF FORMATOPTION QUANTIZE_COLORS=37 FORMATOPTION TRANSPARENT=ON END Trying 32bit RGBA: IMAGECOLOR 0 0 0 OUTPUTFORMAT NAME agg_qn DRIVER AGG/PNG EXTENSION png MIMETYPE image/png IMAGEMODE RGBA TRANSPARENT ON FORMATOPTION TRANSPARENT=ON END Generated black backgrounds and not transparent. Is it as simple as removing the IMAGECOLOR? I didn't try that. -Steve W ___ 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
Re: [mapserver-users] RGBA transparent images?
Erm, pick interlace=false instead. That was just a test and I forgot to put that back On 25 August 2010 13:22, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi Steve, I have this in my file: OUTPUTFORMAT NAME AGGPNG DRIVER AGG/PNG EXTENSION png MIMETYPE image/png;mode=24bit; IMAGEMODE RGBA FORMATOPTION INTERLACE=true FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=ON FORMATOPTION QUANTIZE_COLORS=256 END And in my layer, if you want opacity: OPACITY 60 That should render nice lines :). On 24 August 2010 21:16, Stephen Woodbridge wood...@swoodbridge.comwrote: If I want to generate RGBA transparent images using AGG, what should my OUTPUTFORMAT block look like? I was using this one for 8-bit images, but the anti aliasing was creating blackish artifacts along the rendered lines. Is there a way to avoid them? OUTPUTFORMAT NAME agg_qn DRIVER AGG/PNG EXTENSION png MIMETYPE image/png IMAGEMODE RGBA TRANSPARENT ON FORMATOPTION INTERLACE=false FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=OFF FORMATOPTION QUANTIZE_COLORS=37 FORMATOPTION TRANSPARENT=ON END Trying 32bit RGBA: IMAGECOLOR 0 0 0 OUTPUTFORMAT NAME agg_qn DRIVER AGG/PNG EXTENSION png MIMETYPE image/png IMAGEMODE RGBA TRANSPARENT ON FORMATOPTION TRANSPARENT=ON END Generated black backgrounds and not transparent. Is it as simple as removing the IMAGECOLOR? I didn't try that. -Steve W ___ 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
Re: [mapserver-users] Tile mode multiple layers
Hi Clément, Your request is wrong ;). Try using a space instead. Take a look here : http://mapserver.org/output/tile_mode.html Good luck. On 25 August 2010 13:47, Clément MONIER clement.mon...@v-trafic.com wrote: Hi, I’m facing a (probable widely encountered) problem using MapServer with tile-mode option. It seems like multiple layers aren’t allowed ?? http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1= ok http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer2= ok http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1,layer2= ko ! Why ? Thanks Regards *Clément * ___ 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
Re: [mapserver-users] Tile mode multiple layers
Hi Clément, Under your MAP you can specify an OUTPUTFORMAT tag. See http://mapserver.org/mapfile/outputformat.html for details. There's also some additional information about the format options at the bottom. Use AGG for best quality results. On 25 August 2010 14:37, Clément MONIER clement.mon...@v-trafic.com wrote: Thanks a lot ! I have another bothering issue : PNG outputs of my MS CGI requests now don’t look nicely rendered any more (i.e no smoothly antialiased AGG display) http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1 layer2http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1%20layer2 as it was with similar WMS requests targeting the same mapfile though Where should I specify the desired output format ? Thank you for your help *De :* mapserver-users-boun...@lists.osgeo.org [mailto: mapserver-users-boun...@lists.osgeo.org] *De la part de* Wim Vanbelle *Envoyé :* mercredi 25 août 2010 13:50 *À :* mapserver-users@lists.osgeo.org *Objet :* Re: [mapserver-users] Tile mode multiple layers Hi Clément, Your request is wrong ;). Try using a space instead. Take a look here : http://mapserver.org/output/tile_mode.html Good luck. On 25 August 2010 13:47, Clément MONIER clement.mon...@v-trafic.com wrote: Hi, I’m facing a (probable widely encountered) problem using MapServer with tile-mode option. It seems like multiple layers aren’t allowed ?? http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1= ok http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer2= ok http://localhost/cgi-bin/mapserv.exe?mode=tiletilemode=gmaptile=X+Y+Smap=mymapfile.mapLAYERS=layer1,layer2= ko ! Why ? Thanks Regards *Clément * ___ 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
Re: [mapserver-users] Mapserver tile generation - google maps
For reference sake: The issue is also present when using Bing maps as overlay. I also recompiled mapserver against agg 2.5 and gd-2.0.36RC1, but no change unfortunately. As stated in my previous mail, I may have to look for alternatives as the tilecache will probably not be an option for us. Would it be possible to circumvent this problem by using WMS? On 24 August 2010 07:25, Wim Vanbelle wimvanbe...@gmail.com wrote: Hi, Thank you for your time both. Wouldn't using tilecache imply that I can no longer use dynamic data? My tiles have to update every minute. Perhaps this is possible with tilecache? Basically it's only the color value that changes for each object. An example request that is sent to mapserver: http:// ...maps?map=/.../white.maplayers=%20mode=tiletilemode=gmaptile=264+172+9 MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE My mapfile is configured like this: OUTPUTFORMAT NAME AGGPNG DRIVER AGG/PNG EXTENSION png MIMETYPE image/png;mode=24bit; IMAGEMODE RGBA FORMATOPTION INTERLACE=false FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=ON FORMATOPTION QUANTIZE_COLORS=256 END Although I've used GD as well. Not sure how I can check the GD AGG versions. I was in the process of making a new build for mapserver with the lastest versions of everything though. I'll let you know if that would somehow fix the problem. On 24 August 2010 06:45, Stephen Woodbridge wood...@swoodbridge.comwrote: If you are using mode=tile, then this is a known limitation on the mapserver side. There is a plan for 6.0 to add tilecache support to mapserver that would allow you to generate meta tiles and chop the tiles into a tilecache which is the way to resolve the artifacts you are seeing. http://trac.osgeo.org/mapserver/ticket/3513 You can add yourself the CC on this bug if you want to follow it. There is also an RFC for the mode=tile which I don't have handy that should give you more information on the limitations and feature of that. Hope this helps, -Steve W On 8/24/2010 12:34 AM, Lime, Steve D (DNR) wrote: What mapserver version, what graphics driver? Is this using mode=tile? Steve From: mapserver-users-boun...@lists.osgeo.org [mapserver-users-boun...@lists.osgeo.org] On Behalf Of Wim Vanbelle [wimvanbe...@gmail.com] Sent: Friday, August 20, 2010 6:26 AM To: mapserver-users@lists.osgeo.org Subject: [mapserver-users] Mapserver tile generation - google maps Hi all, I noticed a similar post regarding symbol issues, but there was no solution. My Google maps tiles are currently clipped at the tile itself. This results in rather unwanted behaviour: http://fileshare.myroute.be/exchange/Capture.PNG I'm not 100% sure that this is mapservers' 'issue' , or google maps issue. If anyone would have further tips to spice up the graphics even more, I'd be more than glad to hear them :). Thanks. Wim ___ 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
Re: [mapserver-users] Mapserver tile generation - google maps
Hi, At first I did try with single full page requests to mapserver. However we do intend to have a fullscreen map available for our customers. Which means it will at least render 1024*768 png's. That would indicate that panning/scrolling behaviour will not be fluent, as you have indicated. We're quite pleased with the current tiling output and performance. Perhaps I will need to write a proxy that translates tiles to actual boundary requests and then add some buffer space there. Or take a look at Paul's reply :). I'll try some things tomorrow if I have the time. On 24 August 2010 15:59, Rahkonen Jukka jukka.rahko...@mmmtike.fi wrote: Hi Wim, If your data is that dynamic then there is not much advantage in using tilecache. Perhaps there is not much advantage in making tiled requests either. Applications asking for 256x256 pixel sized tiles from on-demand bases are generating rather a lot of load for Mapserver. There is an advantage on the user side because tiles are cached on the client side and panning is fluent. However, the feeling is not necessarily bad even if the client is making single tile WMS requests. With OpenLayers single tile requests used together with transition effect resize is not bad at all. Perhaps Google maps and Bing have some similar modes. Rendering and labeling problems should go away by using single tiles. -Jukka Rahkonen- -Alkuperäinen viesti- Lähettäjä: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta Stephen Woodbridge Lähetetty: 24. elokuuta 2010 16:43 Vastaanottaja: mapserver-users@lists.osgeo.org Aihe: Re: [mapserver-users] Mapserver tile generation - google maps Tilecache probably is not what you want if you have very dynamic tiles. Or at least a tile cache that is persistent. Your problem is with tile edge artifacts. It might be possible to draw on a slightly larger image than the tile, then cut the tile out of it to avoid some of those, but there are some tile artifacts that you can not get away from when you draw single tiles, like label positioning and label thinning over multiple tiles. For an alternative, you might look to mapscript where you could have more programmatic control over the rendering and do things like render a larger image than needed and cut out the tile like I mentioned. You might also write a bug against mode=tile and see what the developer response to that might be. -Steve W On 8/24/2010 8:04 AM, Wim Vanbelle wrote: For reference sake: The issue is also present when using Bing maps as overlay. I also recompiled mapserver against agg 2.5 and gd-2.0.36RC1, but no change unfortunately. As stated in my previous mail, I may have to look for alternatives as the tilecache will probably not be an option for us. Would it be possible to circumvent this problem by using WMS? On 24 August 2010 07:25, Wim Vanbelle wimvanbe...@gmail.com mailto:wimvanbe...@gmail.com wrote: Hi, Thank you for your time both. Wouldn't using tilecache imply that I can no longer use dynamic data? My tiles have to update every minute. Perhaps this is possible with tilecache? Basically it's only the color value that changes for each object. An example request that is sent to mapserver: http://...maps?map=/.../white.maplayers=%20mode=tiletilemod e=gmaptile=264+172+9 MapServer version 5.6.5 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE My mapfile is configured like this: OUTPUTFORMAT NAME AGGPNG DRIVER AGG/PNG EXTENSION png MIMETYPE image/png;mode=24bit; IMAGEMODE RGBA FORMATOPTION INTERLACE=false FORMATOPTION QUANTIZE_NEW=ON FORMATOPTION QUANTIZE_FORCE=ON FORMATOPTION QUANTIZE_DITHER=ON FORMATOPTION QUANTIZE_COLORS=256 END Although I've used GD as well. Not sure how I can check the GD AGG versions. I was in the process of making a new build for mapserver with the lastest versions of everything though. I'll let you know if that would somehow fix the problem. On 24 August 2010 06:45, Stephen Woodbridge wood...@swoodbridge.com mailto:wood...@swoodbridge.com wrote
[mapserver-users] Mapserver tile generation - google maps
Hi all, I noticed a similar post regarding symbol issues, but there was no solution. My Google maps tiles are currently clipped at the tile itself. This results in rather unwanted behaviour: http://fileshare.myroute.be/exchange/Capture.PNG I'm not 100% sure that this is mapservers' 'issue' , or google maps issue. If anyone would have further tips to spice up the graphics even more, I'd be more than glad to hear them :). Thanks. Wim ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Mapserver tile generation - google maps
I'll try updating GD. Thanks. TileCache is probably not an option, as the color of the data changes every minute. That would mean that tilecache has to reset its data every minute. Not sure if that is possible, or rather, wanted behaviour. OpenLayers would have been a good option, but for some odd reason the client wants the 'real google maps' interface :). In any case, thanks for your help. On 20 August 2010 13:48, christopher.schm...@nokia.com wrote: On Aug 20, 2010, at 7:26 AM, ext Wim Vanbelle wrote: Hi all, I noticed a similar post regarding symbol issues, but there was no solution. My Google maps tiles are currently clipped at the tile itself. This results in rather unwanted behaviour: http://fileshare.myroute.be/exchange/Capture.PNG I think the answer to this is Use a more recent GD. If that's not an option, then you'll need to expand the frame of the selected image to be slightly larger than the actual image itself; this is possible with TileCache (metaBuffer), OpenLayers (gutter), etc. -- Chris I'm not 100% sure that this is mapservers' 'issue' , or google maps issue. If anyone would have further tips to spice up the graphics even more, I'd be more than glad to hear them :). Thanks. Wim ATT1..txt ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Mapserver tile generation - google maps
I was using AGG for the rendering. I suppose I need to look for updates for that? ;). On 20 August 2010 14:08, Wim Vanbelle wimvanbe...@gmail.com wrote: I'll try updating GD. Thanks. TileCache is probably not an option, as the color of the data changes every minute. That would mean that tilecache has to reset its data every minute. Not sure if that is possible, or rather, wanted behaviour. OpenLayers would have been a good option, but for some odd reason the client wants the 'real google maps' interface :). In any case, thanks for your help. On 20 August 2010 13:48, christopher.schm...@nokia.com wrote: On Aug 20, 2010, at 7:26 AM, ext Wim Vanbelle wrote: Hi all, I noticed a similar post regarding symbol issues, but there was no solution. My Google maps tiles are currently clipped at the tile itself. This results in rather unwanted behaviour: http://fileshare.myroute.be/exchange/Capture.PNG I think the answer to this is Use a more recent GD. If that's not an option, then you'll need to expand the frame of the selected image to be slightly larger than the actual image itself; this is possible with TileCache (metaBuffer), OpenLayers (gutter), etc. -- Chris I'm not 100% sure that this is mapservers' 'issue' , or google maps issue. If anyone would have further tips to spice up the graphics even more, I'd be more than glad to hear them :). Thanks. Wim ATT1..txt ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Re: Where to download symbolset file
I don't believe there's another. I actually thought that one contained quite a lot of symbols. Maybe ask here what it is exactly that you are trying to accomplish. On 17 August 2010 12:33, kboqvist krister.boqv...@smhi.se wrote: Thanks for the quick answer. I've already found that. But it doesn't contains so many symbols. Do you know any other ? /Krister - -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Where-to-download-symbolset-file-tp5431255p5431455.html Sent from the Mapserver - User mailing list archive at Nabble.com. ___ 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
Re: [mapserver-users] Load web error in Map server.
Do you want the map to be displayed in a html page, or do you just need the pic? In the latter case, you could try to just query the following link: http://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w2/apps/tutorial/htdocs/basic.maplayer=statesmode=maphttp://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w2/apps/tutorial/htdocs/basic.maplayer=stateszoom=0mode=browseroot=/tutorialprogram=/cgi-bin/mapserv.exemap_web=template+basic.html I also suggest you use the typical hello world to test and try your mapserver (and get a feel for it). Depending on what your ultimate goal is, you may or may not need the web templates at all. This would be a simple sample of a hello world map: MAP NAME Hello_World SIZE 400 300 IMAGECOLOR 249 245 186 IMAGETYPE png EXTENT -1.00 -1.00 1.00 1.00 LAYER STATUS default TYPE point FEATURE POINTS 0.0 0.0 END TEXT Hello World END # end feature CLASS STYLE COLOR 255 0 0 END LABEL TYPE bitmap END END END END Considering its named hello.map, you'd get an image by browsing to http://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w2/apps/helloworld/hello.mapmode=maphttp://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w2/apps/tutorial/htdocs/basic.maplayer=stateszoom=0mode=browseroot=/tutorialprogram=/cgi-bin/mapserv.exemap_web=template+basic.html (Don't forget to add the helloworld map in the apps directory) On 16 August 2010 08:27, Gupta gupta...@gmail.com wrote: Hi all, I am new to MAp server . i understood mapserver functionalities using the tutorial.now i want to create a map using image and shape file.when tried to use it.i am getting following error. loadWeb(): General error message. URL-based TEMPLATE configuration failed pattern validation. msEvalRegex(): Regular expression error. String (basic.html) failed expression test. my local URL is: http://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w2/apps/tutorial/htdocs/basic.maplayer=stateszoom=0mode=browseroot=/tutorialprogram=/cgi-bin/mapserv.exemap_web=template+basic.html actually i changed example2.2 file to basic.and in mapfile i placed my image. please let me know what i need to change to get output. Thanks and Regards, Kishor Gupta. Project Engineer, CDAC,Bangalore, INDIA. Ph.no:09538722172 If a drop of water falls on lake, it loses its identity. If it falls on a rose, it shines. If it falls on a shell, it becomes a pearl. The drop is the same but the company matters ___ 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
Re: [mapserver-users] Offset values from database
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 same side. This is why i would need the offset value to be configurable in the database. I could select a different pixel offset for each line and they 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
Re: [mapserver-users] need suggestions to implement simple dynamic zoom, pan select capabilities?!!
Usually, when displaying mapserver data on basemap layers such as openlayers, or directly on google / bing maps, you would use their tiling system. There's examples here of how you would do this in openlayers : http://docs.openlayers.org/library/spherical_mercator.html On 13 August 2010 07:16, mani2604 mani2...@gmail.com wrote: hi there... I've been using phpmapscript for on-the fly query displaying the resultant images... Now that I've got this problem that I tried using both mscross openlayers to display the image but somehow I cud not work it out.. I mean in both the above frameworks we need to specify the output image in the sort of URL tag-line style(wms) as below... eg:- http://localhost/index.php?mode=mapmap=/ms4w/apache/htdocs/india_roads1.mapmapext=60+7+102+38.5mapsize=640+480layers=SARDINIA%20india_ds%20IND_water_areas_dcw%20undefined Or may be I am wrong..Can we just specify the location of the resultant image and add all those dynamic zoom,pan functionality in 'Open Layers' i am sory If I am not clear enough but i need some suggestions for some simple script like mscross or soo where I need to add all those dynamic functions to my output image... that's it Thanks...!!@ -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/need-suggestions-to-implement-simple-dynamic-zoom-pan-select-capabilities-tp5418885p5418885.html Sent from the Mapserver - User mailing list archive at Nabble.com. ___ 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] 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: DATAgeom_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
Re: [mapserver-users] Offset values from database
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.uswrote: 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: DATAgeom_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
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 same side. This is why i would need the offset value to be configurable in the database. I could select a different pixel offset for each line and they 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: DATAgeom_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
Re: [mapserver-users] Offset values from database
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.uswrote: 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 same side. This is why i would need the offset value to be configurable in the database. I could select a different pixel offset for each line and they 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