From peter at peterse-uithuizen.com Wed Jul 1 00:31:48 2009 From: peter at peterse-uithuizen.com (Peter Peterse) Date: Wed, 01 Jul 2009 09:31:48 +0200 Subject: [mapserver-users] compiling mapserv 5.4.1 with PNG driver In-Reply-To: <2922382e0906302222t58fd18cbjc86dfee9a3e9b82c@mail.gmail.com> References: <2922382e0906302222t58fd18cbjc86dfee9a3e9b82c@mail.gmail.com> Message-ID: Thanks, but I'm not that far. I've just compiled mapserv After that I call the next command's: $ ./mapserv -v MapServer version 5.4.1 OUTPUT=GIF OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE $ ./shp2img -m ../mapserver-utils-read-only/osm.map -o osm.png loadOutputFormat(): General error message. OUTPUTFORMAT clause references driver AGG/PNG, but this driver isn't configured.
My configure command gave me the next result: ==================== MapServer is now configured for -------------- Compiler Info ------------- C compiler: gcc -g -O2 -fPIC -Wall C++ compiler: g++ -g -O2 -fPIC -Wall Debug: -g -DNEED_NONBLOCKING_STDERR Generic NINT: -------------- Renderer Settings --------- zlib support: -DUSE_ZLIB png support: palette rgba png support: jpeg support: iconv support: -DUSE_ICONV AGG support: -DUSE_AGG AGG Freetype support: agg_font_freetype.o Ming(flash) support: PDFLib support: -------------- Support Libraries --------- Proj.4 support: -DUSE_PROJ Libxml2 support: -DUSE_LIBXML2 FriBidi support: Curl support: -DUSE_CURL FastCGI support: Threading support: -DUSE_THREAD GEOS support: -DUSE_GEOS -------------- Data Format Drivers ------- native tiff support: -DUSE_TIFF PostGIS support: -DUSE_POSTGIS EPPL7 support: -DUSE_EPPL ArcSDE support: OGR support: -DUSE_OGR GDAL support: -DUSE_GDAL Oracle Spatial support: -------------- OGC Services -------------- WMS Server: -DUSE_WMS_SVR WMS Client: -DUSE_WMS_LYR WFS Server: -DUSE_WFS_SVR WFS Client: -DUSE_WMS_LYR WCS Server: -DUSE_WCS_SVR SOS Server: -DUSE_SOS_SVR -------------- MapScript ----------------- PHP MapScript: no ==================== I hope this give some more information. Peter. > you're apache configuration is probably not calling the mapserv binary > you just compiled, but another one on your system. > > regards, > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Tue, Jun 30, 2009 at 22:41, Peter Peterse > wrote: >> Hello, >> >> I'm trying to compile mapserv v5.4.1. I used the next configure command: >> ================ >> ./configure ?? ?? --with-ogr=/usr/local/bin/gdal-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-gdal=/usr/local/bin/gdal-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-httpd=/usr/sbin/httpd \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-wfsclient \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-wmsclient \ >> ?? ?? ?? ?? ?? ?? ?? ??--enable-debug \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-curl-config=/usr/local/bin/curl-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-proj=/usr/local \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-tiff \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-gd=/usr/local \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-jpeg=/usr/lib/ \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-png=/usr/local/bin/libpng12-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-freetype=/usr/ \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-threads \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-wcs \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-wfs \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-postgis=/usr/local/pgsql/bin/pg_config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-libiconv=/usr \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-geos=/usr/local/bin/geos-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-libiconv=/usr \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-xml2-config=/usr/bin/xml2-config \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-sos \ >> ?? ?? ?? ?? ?? ?? ?? ??--with-agg=/home/peter/src/agg-2.5 >> ================ >> >> after the make command there is a mapserv program. >> mapserv -v gives: >> ================ >> MapServer version 5.4.1 OUTPUT=GIF OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG >> SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV >> SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER >> SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER >> SUPPORTS=THREADS SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS >> INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE >> ================ >> >> In my map-file I have defined OUTPUTFORMAT: >> ========== >> OUTPUTFORMAT >> ?? ??NAME agg >> ?? ??DRIVER AGG/PNG >> ?? ??IMAGEMODE RGB >> ?? ??FORMATOPTION "INTERLACE=false" >> ?? ??MIMETYPE "image/png" >> END >> ========== >> this give the next error: >> OUTPUTFORMAT clause references driver AGG/PNG, but this driver isn't >> configured. >> >> Does anyone knows what I'm doing wrong? >> >> >> Thanks for your response. >> >> Peter. >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > From deomurari at gmail.com Wed Jul 1 01:03:53 2009 From: deomurari at gmail.com (Arpit Deomurari) Date: Wed, 1 Jul 2009 13:33:53 +0530 Subject: [mapserver-users] Help Needed - MS4W, Tikiwiki and Vista In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5056DA5F0@s-sp22.pca.state.mn.us> References: <6246727221874A4FB8D3F9BBC37D9BD5056DA5F0@s-sp22.pca.state.mn.us> Message-ID: <26af92cd0907010103g7bb59441rcd741dfb637338e4@mail.gmail.com> Thanks for the Help... Now I landed up in new problem.... My PAth problem is solved.... But now map is not displayed in tikiwiki....But when I click on the image it shows..... Regards On Tue, Jun 23, 2009 at 7:16 PM, Fawcett, David wrote: > You could also try writing it like: /xampp/htdocs/tw/map/images/ > > This should work fine on a Windows system if the path is correct. > > David. > > -----Original Message----- > From: mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Rahkonen > Jukka > Sent: Monday, June 22, 2009 10:24 AM > To: Arpit Deomurari; mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Help Needed - MS4W, Tikiwiki and Vista > > > Hi, > > Maybe IMAGEPATH should be like IMAGEPATH D:\xampp\htdocs\tw\map\images\ > Mapfile reference at http://www.mapserver.org/mapfile/web.html tells: > > "IMAGEPATH [path] > Path to the temporary directory fro writing temporary files and > images. Must be writable by the user the web server is running as. Must > end with a / or depending on your platform." > > There is really "Must end with a / or depending", I suppose it should be > "end with a / or \". > > -Jukka Rahkonen- > > > Arpit Deomurari wrote: > > Dear Friends... > I'm trying to use tikiwiki as a GeoCMS on MS4W on windows(Vista) > Platform... > > I have configured Mapserver 5.4.0 RC2 on XAMPP Platform and it's working > perfectly standalone... > > But when I use with tikiwiki map module I get this error.... Can Some > one help me in solving this error..... > > > *An error as occured with the mapfile: world.map > > [MapServer Error]: loadWeb(): Parsing error near (:):(line 33) > * > > * # > WEB > TEMPLATE D:\xampp\htdocs\tw\map\map.html > --> IMAGEPATH D:\xampp\htdocs\tw\map\images > IMAGEURL /map/images > METADATA > VIEW1 > "Australia,117.500594119,-34.8753753754,165.037355881,-3.2087087087" > VIEW2 > "Fiji,165.704315901,-24.5147748593,201.374684099,-0.76477485929"* > > > -- > Arpit Deomurari > > Naturalist And Birder...... > "AVANI" Anand Colony Road No-1 > Nr. "Gurukrupa", Opp. "Rushi" Apartment, > Vikasgruh Road, Jamnagar - 361008 > Gujarat(INDIA) > > E-Mail:- deomurari at gmail.com > arpit at waders.in > > Web site: > http://www.waders.in > http://indianaturewatch.net/view_cat.php?tag=Arpit%20Deomurari > http://www.flickr.com/photos/deomurari > > Mobile No.:- +91-9426442243 (Mobile) > > I Believe In God, Only spell It Nature > ******************************************* > One should not have a job, career or profession- only a hobby, passion > and a cause > > Please consider your environmental responsibility before printing this > e-mail - Save paper. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- Arpit Deomurari Naturalist And Birder...... "AVANI" Anand Colony Road No-1 Nr. "Gurukrupa", Opp. "Rushi" Apartment, Vikasgruh Road, Jamnagar - 361008 Gujarat(INDIA) E-Mail:- deomurari at gmail.com arpit at waders.in Web site: http://www.waders.in http://indianaturewatch.net/view_cat.php?tag=Arpit%20Deomurari http://www.flickr.com/photos/deomurari Mobile No.:- +91-9426442243 (Mobile) I Believe In God, Only spell It Nature ******************************************* One should not have a job, career or profession- only a hobby, passion and a cause Please consider your environmental responsibility before printing this e-mail - Save paper. -------------- next part -------------- An HTML attachment was scrubbed... URL: From hrodriguez at siscat.com.ar Wed Jul 1 05:29:17 2009 From: hrodriguez at siscat.com.ar (Rodriguez, Heraldo) Date: Wed, 1 Jul 2009 09:29:17 -0300 Subject: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver 5.4.1 In-Reply-To: <4A4A986D0200008F000258A9@co5.dnr.state.mn.us> Message-ID: <296E5F9B6BB1C445BDDC9C94FC83835E34B1C8@ZEUS-Exchg2k3.sc.com> Thank you very much. I am afraid I am not allowed to upload any data ( the map would be fine , but without the data I think it'll be useless). Anyway, I made the metatile larger (from 5x5 to 6x6) and now the map looks acceptable (some minimal duplication still persists, though.) Thanks a lot again. Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A -----Mensaje original----- De: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Enviado el: mi?rcoles, 01 de julio de 2009 0:58 Para: mapserver-users at lists.osgeo.org; Rodriguez, Heraldo Asunto: Re: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver 5.4.1 Hi Rodriguez: I did a couple of quick tests and it seems like the directive is working as intended, at least with some government unit boundary data. Any chance you could put together a small test case? Perhaps converting some data to shapefile and whipping up a simple mapfile that shows the problem. Are others experiencing the same issues? Steve >>> "Rodriguez, Heraldo" 06/30/09 10:33 AM >>> Hi everyone, We have just upgraded from mapserver 5.2.0 to 5.4.1 Our application use OpenLayers, Tilecache with metatiles on, and postgis. The label positioning in polygons has improved a lot but now we are experiencing label duplication on metatile boundaries. The layer with the issues is parcelas. We are using labelcache_map_edge_buffer and LABEL_NO_CLIP=ON . Has anyone an idea why this is happening? The labels length varies from 2 to 4 characters maximum . A fragment of our map is the following WEB # TEMPLATE "set in index.html" # MINscale 1000 MAXscaleDENOM 1550000 METADATA "wms_title" ... "wfs_title" ... "wms_onlineresource" ... "wfs_onlineresource" ... "WMS_FEATURE_INFO_MIME_TYPE" "text/html" "wms_srs" ... "wfs_srs" ... "wms_encoding" ... "labelcache_map_edge_buffer" "-10" END IMAGEPATH "/tmp/mapserver/" IMAGEURL "/mapserver/" END LAYER NAME parcelas METADATA "wms_title" "parcelas" "wms_include_items" "all" "wms_group_title" "Geograficos" "wfs_title" "parcelas" "gml_include_items" "all" "gml_featureid" "gid" END CONNECTION "user=xxxxx password=xxxxxx dbname=scgis host=localhost port=5432" CONNECTIONTYPE postgis PROCESSING "CLOSE_CONNECTION=DEFER" PROCESSING "LABEL_NO_CLIP=ON" DATA "the_geom FROM parcelas USING UNIQUE gid" STATUS DEFAULT TYPE POLYGON OPACITY 80 MAXscaledenom 15000 LABELITEM parcela LabelMaxscaledenom 1200 DUMP true CLASS NAME "parcelas" TEMPLATE './QueryTemplates/parcelas.html' STYLE COLOR 242 239 233 #g earth OUTLINECOLOR 210 210 210 END Label minsize 7 Size 7 maxsize 8 type truetype PARTIALS false POSITION AUTO MINDISTANCE 20 PRIORITY 5 font "vera" color 86 86 86 end END END Any help would be appreciated. Thanks in advance Regards, Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From darenas2001 at yahoo.es Wed Jul 1 05:44:30 2009 From: darenas2001 at yahoo.es (darenas) Date: Wed, 1 Jul 2009 05:44:30 -0700 (PDT) Subject: [mapserver-users] How to use msQueryByPoint with RASTER In-Reply-To: <4A4AB1990200008F000258AE@co5.dnr.state.mn.us> References: <1246349146381-3180021.post@n2.nabble.com> <4A4AB1990200008F000258AE@co5.dnr.state.mn.us> Message-ID: <1246452270391-3188765.post@n2.nabble.com> Hi Steve, I tested GetFeatureInfo directly with the folowing sentence: http://localhost/cgi-bin/prueba_grid?REQUEST=GetFeatureInfo&VERSION=1.1.0&SERVICE=WMS&QUERY_LAYERS=mapa_apicola&FEATURE_COUNT=1&X=521&Y=426&SRS=EPSG:25830&BBOX=462204.1344,4460380.45879,463515.19339,4461472.57092&WIDTH=1000&HEIGHT=833&LAYERS=mapa_apicola&STYLES=default&FORMAT=image/jpeg and the response is the same: GetFeatureInfo results: Search returned no results. TIFF file has an attribute table. I made a shot: http://n2.nabble.com/file/n3188765/tiff.jpg That?s the layer code; maybe could be useful to guess the problem: LAYER # Comienzo del objeto LAYER NAME "mapa_apicola" # Nombre corto para la capa TYPE RASTER # [point/line/polygon/circle/annotation/raster/query] especifica como los datos podr?n ser dibujados STATUS ON # [on/off/default] Establece el estado de la capa #PROCESSING "SCALE_1=1,255" #PROCESSING "SCALE_2=1,255" #PROCESSING "SCALE_3=1,255" #PROCESSING "SCALE=AUTO" # Pasa un directorio de proceso que se utilizar? con esta capa PROCESSING "DITHER=YES" # Pasa un directorio de proceso que se utilizar? con esta capa #OFFSITE 0 0 0 DEBUG OFF DUMP TRUE # [true/false] Permite que Mapserver genere la descarga en formato GML DATA "D:\TIFF\mapa_apicola.tif" TEMPLATE "D:\ms4w\maps\etc\template.html" METADATA "WMS_SRS" "EPSG:3034 EPSG:3035 EPSG:4230 EPSG:4258 EPSG:4267 EPSG:4269 EPSG:4324 EPSG:4326 EPSG:25828 EPSG:25829 EPSG:25830 EPSG:25831 EPSG:23028 EPSG:23029 EPSG:23030 EPSG:23031 EPSG:32628 EPSG:32629 EPSG:32630 EPSG:32631" "WMS_TITLE" "Mapa Ap?cola" "WMS_ABSTRACT" "Mapa Ap?cola" "WMS_FEATURE_INFO_MIME_TYPE" 'text/html' "wms_keywordlist" "WMS, servidor de mapas en red" "wms_extent" "60000 3980769 650000 4304000" #"wms_metadataurl_href" "http://idena.navarra.es/busquedas/xml/c_toponimia.xml" #URL donde se recogen m?s metadatos sobre la capa #"wms_metadataurl_type" "TC211" #Norma de Metadatos el valor: "TC211" equivale a ISO 19115 #"wms_metadataurl_format" "xml" # #"wms_dataurl_href" "...." # Direcci?n URL de los datos asociados #"wms_dataurl_format" "xml" # Formato de los datos "gml_featureid" "OID" "gml_include_items" "VALUE,COUNT" END #METADATA PROJECTION "init=epsg:23030" #Proyecci?n UTM European Datum 50 Huso 30 N #"init=epsg:25830" #Proyecci?n UTM ETRS89 Huso 30 N END CLASS NAME '1.- Zona restringida ' EXPRESSION ('[pixel]' = '0') STYLE COLOR 51 51 204 #OUTLINECOLOR 110 110 110 END #STYLE END #CLASS CLASS NAME '2.- Zona ?ptima ' EXPRESSION ('[pixel]' = '1') STYLE COLOR 61 108 60 #OUTLINECOLOR 110 110 110 END #STYLE END #CLASS CLASS NAME '3.- Zona marginal ' EXPRESSION ('[pixel]' = '2') STYLE COLOR 240 159 12 #OUTLINECOLOR 110 110 110 END #STYLE END #CLASS CLASS NAME '4.- Zona extramarginal ' EXPRESSION ('[pixel]' = '3') STYLE COLOR 218 193 44 #OUTLINECOLOR 110 110 110 END #STYLE END #CLASS END #Fin del objeto LAYER #================================# END Thanks a lot again Steve Lime wrote: > > Does the query work outside WMS, that is, with straight calls to the > MapServer CGI? One thing to check right away is that the layer > is queryable by making sure a value for the layer TEMPLATE is set, > anything (e.g. TEMPLATE 'dummy') will suffice. > > Steve > >>>> darenas 06/30/09 3:06 AM >>> > > Hi everyone! > > I?m creating a WMS service with a TIFF file. But I have problems in the > moment to do querybypoints action on the raster so the error is the > following: > > msQueryByPoint(): Search returned no results. No matching record(s) > found > > I?m using the folowing parameters in mapfile as always with its > attributes, > but doens?t work: > > "gml_featureid" "OID" > "gml_include_items" "VALUE,COUNT" > > any ideas? > > Thanks a million > > > > > > -- > View this message in context: > http://n2.nabble.com/How-to-use-msQueryByPoint-with-RASTER-tp3180021p3180021.html > Sent from the Mapserver - User mailing list archive at Nabble.com. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- View this message in context: http://n2.nabble.com/How-to-use-msQueryByPoint-with-RASTER-tp3180021p3188765.html Sent from the Mapserver - User mailing list archive at Nabble.com. From Dejan.Gambin at pula.hr Wed Jul 1 05:44:55 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Wed, 1 Jul 2009 14:44:55 +0200 Subject: [mapserver-users] GeoJSON output from MapServer Message-ID: Hi, Is it possible to use GeoJSON template for getting GeoJSON output from MapServer? I have tried using outputformat as described in: http://mapserver.org/development/rfc/ms-rfc-36.html and http://mapserver.org/development/rfc/ms-rfc-56.html Is it supported at all? I have a project where I need a GeoJSON output. This project originally uses GeoServer whcih has a plugin for this. Is this possible with MapServer? I am using MapServer 5.4.1 thanks very much regards, dejan -------------- next part -------------- An HTML attachment was scrubbed... URL: From sluhmer at uni-bonn.de Wed Jul 1 05:50:54 2009 From: sluhmer at uni-bonn.de (Sebastian Luhmer) Date: Wed, 01 Jul 2009 14:50:54 +0200 Subject: [mapserver-users] SLD-Integration with UMN Mapserver Message-ID: Hi everybody, does anybody know, how I can integrate SLD-Files with the UMN Mapserver? According to the Mapserver documentation, this can be done by adding wms_sld_url in the Metadta-Part within the Layer-Description in the Mapfile and pointing to a remote SLD File. I have done all this, but the layer ist stylied by the styling-information contained in the mapfile and not by the SLD-File (like it sholuld be. Can anybody give me a hint, how i can embedd SLD Files with Mapserver? Best regards, Sebastian! ------------------------------ Sebastian Luhmer Student assistant Center for Development Research Department of Ecology and Resource Management Walter-Flex-Strasse 3 53113 Bonn (Germany) Tel.: +49 (0) 228 - 73-1793 FAX: +49 (0) 228 - 73-1889 E-Mail: sluhmer at uni-bonn.de Web: http://www.coffee.uni-bonn.de http://www.zef.de From hrodriguez at siscat.com.ar Wed Jul 1 06:51:47 2009 From: hrodriguez at siscat.com.ar (Rodriguez, Heraldo) Date: Wed, 1 Jul 2009 10:51:47 -0300 Subject: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver 5.4.1 In-Reply-To: <4A4A986D0200008F000258A9@co5.dnr.state.mn.us> Message-ID: <296E5F9B6BB1C445BDDC9C94FC83835E34B1EA@ZEUS-Exchg2k3.sc.com> Hey Steve, I found what the problem was. It was a silly mistake I made. Some time ago the labels were separated from the polygon in another layer ( the labelling was no good so we provided the centroids to draw the labels) Since they were points ,in that case partials=False was fine. I changed partials to true and that solved my problem. I hope this comment can help someone if they face the same problem I do. To sum up I use "labelcache_map_edge_buffer" "-10" at map level PROCESSING "LABEL_NO_CLIP=ON" at layer level Partials=true with labels Thanks and regards. Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A -----Mensaje original----- De: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Enviado el: mi?rcoles, 01 de julio de 2009 0:58 Para: mapserver-users at lists.osgeo.org; Rodriguez, Heraldo Asunto: Re: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver 5.4.1 Hi Rodriguez: I did a couple of quick tests and it seems like the directive is working as intended, at least with some government unit boundary data. Any chance you could put together a small test case? Perhaps converting some data to shapefile and whipping up a simple mapfile that shows the problem. Are others experiencing the same issues? Steve >>> "Rodriguez, Heraldo" 06/30/09 10:33 AM >>> Hi everyone, We have just upgraded from mapserver 5.2.0 to 5.4.1 Our application use OpenLayers, Tilecache with metatiles on, and postgis. The label positioning in polygons has improved a lot but now we are experiencing label duplication on metatile boundaries. The layer with the issues is parcelas. We are using labelcache_map_edge_buffer and LABEL_NO_CLIP=ON . Has anyone an idea why this is happening? The labels length varies from 2 to 4 characters maximum . A fragment of our map is the following WEB # TEMPLATE "set in index.html" # MINscale 1000 MAXscaleDENOM 1550000 METADATA "wms_title" ... "wfs_title" ... "wms_onlineresource" ... "wfs_onlineresource" ... "WMS_FEATURE_INFO_MIME_TYPE" "text/html" "wms_srs" ... "wfs_srs" ... "wms_encoding" ... "labelcache_map_edge_buffer" "-10" END IMAGEPATH "/tmp/mapserver/" IMAGEURL "/mapserver/" END LAYER NAME parcelas METADATA "wms_title" "parcelas" "wms_include_items" "all" "wms_group_title" "Geograficos" "wfs_title" "parcelas" "gml_include_items" "all" "gml_featureid" "gid" END CONNECTION "user=xxxxx password=xxxxxx dbname=scgis host=localhost port=5432" CONNECTIONTYPE postgis PROCESSING "CLOSE_CONNECTION=DEFER" PROCESSING "LABEL_NO_CLIP=ON" DATA "the_geom FROM parcelas USING UNIQUE gid" STATUS DEFAULT TYPE POLYGON OPACITY 80 MAXscaledenom 15000 LABELITEM parcela LabelMaxscaledenom 1200 DUMP true CLASS NAME "parcelas" TEMPLATE './QueryTemplates/parcelas.html' STYLE COLOR 242 239 233 #g earth OUTLINECOLOR 210 210 210 END Label minsize 7 Size 7 maxsize 8 type truetype PARTIALS false POSITION AUTO MINDISTANCE 20 PRIORITY 5 font "vera" color 86 86 86 end END END Any help would be appreciated. Thanks in advance Regards, Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at dnr.state.mn.us Wed Jul 1 07:05:41 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 01 Jul 2009 09:05:41 -0500 Subject: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver 5.4.1 In-Reply-To: <296E5F9B6BB1C445BDDC9C94FC83835E34B1EA@ZEUS-Exchg2k3.sc.com> References: <4A4A986D0200008F000258A9@co5.dnr.state.mn.us> <296E5F9B6BB1C445BDDC9C94FC83835E34B1EA@ZEUS-Exchg2k3.sc.com> Message-ID: <4A4B26EA.5157.008F.0@dnr.state.mn.us> Thanks for the follow up, this is the type of resolution I like (not my fault)... ;-) Steve >>> On 7/1/2009 at 8:51 AM, in message <296E5F9B6BB1C445BDDC9C94FC83835E34B1EA at ZEUS-Exchg2k3.sc.com>, "Rodriguez, Heraldo" wrote: > Hey Steve, > I found what the problem was. It was a silly mistake I made. > Some time ago the labels were separated from the polygon in another > layer ( the labelling was no good so we provided the centroids to draw the > labels) Since they were points ,in that case partials=False was fine. > I changed partials to true and that solved my problem. I hope > this comment can help someone if they face the same problem I do. > To sum up > I use "labelcache_map_edge_buffer" "-10" at map level > PROCESSING "LABEL_NO_CLIP=ON" at layer level > Partials=true with labels > Thanks and regards. > > > > Lic. Heraldo G. Rodriguez > hrodriguez at siscat.com.ar > TEL: 54-11-4326-4002 int 255 > Dpto. Desarrollo > Sistemas Catastrales S.A > > > > -----Mensaje original----- > De: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] > Enviado el: mi?rcoles, 01 de julio de 2009 0:58 > Para: mapserver-users at lists.osgeo.org; Rodriguez, Heraldo > Asunto: Re: [mapserver-users] LABEL_NO_CLIP seems not working inmapserver > 5.4.1 > > Hi Rodriguez: I did a couple of quick tests and it seems like the directive > is > working as intended, at least with some government unit boundary data. Any > chance you could put together a small test case? Perhaps converting some > data to shapefile and whipping up a simple mapfile that shows the problem. > > Are others experiencing the same issues? > > Steve > >>>> "Rodriguez, Heraldo" 06/30/09 10:33 AM >>> > Hi everyone, > We have just upgraded from mapserver 5.2.0 to 5.4.1 > Our application use OpenLayers, Tilecache with metatiles on, and > postgis. > The label positioning in polygons has improved a lot but now we are > experiencing label duplication on metatile boundaries. > > The layer with the issues is parcelas. We are using > labelcache_map_edge_buffer and LABEL_NO_CLIP=ON . > > Has anyone an idea why this is happening? The labels length varies from > 2 to 4 characters maximum . > > > A fragment of our map is the following > > > WEB > # TEMPLATE "set in index.html" > # MINscale 1000 > MAXscaleDENOM 1550000 > METADATA > "wms_title" ... > "wfs_title" ... > "wms_onlineresource" ... > "wfs_onlineresource" ... > "WMS_FEATURE_INFO_MIME_TYPE" "text/html" > "wms_srs" ... > "wfs_srs" ... > "wms_encoding" ... > "labelcache_map_edge_buffer" "-10" > END > IMAGEPATH "/tmp/mapserver/" > IMAGEURL "/mapserver/" > > END > > LAYER > > NAME parcelas > METADATA > "wms_title" "parcelas" > "wms_include_items" "all" > "wms_group_title" "Geograficos" > "wfs_title" "parcelas" > "gml_include_items" "all" > "gml_featureid" "gid" > END > CONNECTION "user=xxxxx password=xxxxxx dbname=scgis > host=localhost port=5432" > CONNECTIONTYPE postgis > PROCESSING "CLOSE_CONNECTION=DEFER" > PROCESSING "LABEL_NO_CLIP=ON" > DATA "the_geom FROM parcelas USING UNIQUE > gid" > STATUS DEFAULT > TYPE POLYGON > OPACITY 80 > MAXscaledenom 15000 > LABELITEM parcela > LabelMaxscaledenom 1200 > DUMP true > CLASS > NAME "parcelas" > TEMPLATE './QueryTemplates/parcelas.html' > STYLE > COLOR 242 239 233 #g > earth > OUTLINECOLOR 210 210 210 > END > Label > minsize 7 > Size 7 > maxsize 8 > type truetype > PARTIALS false > POSITION AUTO > MINDISTANCE 20 > PRIORITY 5 > font "vera" > color 86 86 86 > end > > END > END > > > Any help would be appreciated. Thanks in advance > Regards, > > > Lic. Heraldo G. Rodriguez > hrodriguez at siscat.com.ar > TEL: 54-11-4326-4002 int 255 > Dpto. Desarrollo > Sistemas Catastrales S.A > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at dnr.state.mn.us Wed Jul 1 07:36:48 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 01 Jul 2009 09:36:48 -0500 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: References: Message-ID: <4A4B2E35.5157.008F.0@dnr.state.mn.us> Depends on how you need to access it. You certainly can create a template that will output GeoJSON. However, at the moment you can only access that output though calls to the CGI and (probably) MapScript. WMS and WFS do not recognize the template output format although there are plans to do so in the upcoming release. Let me know if I can help further... Steve >>> On 7/1/2009 at 7:44 AM, in message , wrote: > Hi, > > Is it possible to use GeoJSON template for getting GeoJSON output from > MapServer? I have tried using outputformat as described in: > > http://mapserver.org/development/rfc/ms-rfc-36.html and > http://mapserver.org/development/rfc/ms-rfc-56.html > > Is it supported at all? I have a project where I need a GeoJSON output. > This project originally uses GeoServer whcih has a plugin for this. Is > this possible with MapServer? I am using MapServer 5.4.1 > > thanks very much > > regards, dejan From randre at gmail.com Wed Jul 1 08:27:53 2009 From: randre at gmail.com (=?ISO-8859-1?Q?Roger_Andr=E9?=) Date: Wed, 1 Jul 2009 08:27:53 -0700 Subject: [mapserver-users] Documentation for serving large rasterimagesusing tile cache. In-Reply-To: <452F37AE49199D49B1702D7D45038C4D01254058@et.ad.sdsc.edu> References: <491852CB020000A80000EA4F@jeckle> <452F37AE49199D49B1702D7D45038C4D01254058@et.ad.sdsc.edu> Message-ID: <9c2015090907010827n23a836b8g959f1a6764a4b61c@mail.gmail.com> Hi Asif, I don't know of any specific applications or methods to stress test MapServer. However, I would think that you could use some web-based tools such as Selenium (possibly) to exercise a web-based setup, or write a test-script which does the same. Sean Gillies has an excellent set of unit tests written to exercise Python Mapscript. You can view them here - http://kentuckykarst.org/mapserver/mapscript/python/tests/cases/. It might be possible to adapt some of these to suit your needs, but I would think that a utility which exercises your installation in the same way a user does would be better. There is a good, generic description of how to approach load testing of web applications here - http://msdn.microsoft.com/en-us/library/bb924374.aspx. Best of luck, Roger -- On Tue, Jun 30, 2009 at 10:15 PM, Asif Memon wrote: > Hello, > > We have started using Map Server to serve large size images. Now we want to > do a performance/stress test on Map Server. Do you have any documentation > that explains the performance/stress test on a Map Server? If not, could you > please suggest what shall I do? > > Sincerely, > Asif Memon > > > -----Original Message----- > From: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] > Sent: Monday, November 10, 2008 1:27 PM > To: randre at gmail.com; Asif Memon > Cc: mapserver-users at lists.osgeo.org > Subject: RE: [mapserver-users] Documentation for serving large > rasterimagesusing tile cache. > > Asif, > > While it may be a bit of overhead to implement just for testing, the > GeoMoose client would definitely help with your performance testing. If > you combine it with FireBug/FireFox, you should be able to extract all > the performance information you need (from the client end). > > From the server side, you can run the MapServer requests on the > commandline. In my experience though, the web side of the equation is > usually the bottleneck for most performance issues. > > bobb > > > > >>> "Asif Memon" 11/10/08 3:21 PM >>> > Thanks Roger, > > > > I have tiled a large mosaic(2 GB) by using the GDAL utility(gdal_convert > "TILED=YES"). I want to test the performance for querying the mosaic > with the zoom functionality. Do I need to write a client or is there > anything readily available with which I can check the performance? > > > > Sincerely, > > Asif Memon > > > > > > From: Roger Andr? [mailto:randre at gmail.com] > Sent: Monday, November 10, 2008 9:35 AM > To: Asif Memon > Cc: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Documentation for serving large raster > images using tile cache. > > > > Hi Asif, > > My apologies. I saw your message Friday evening but forgot about it > over the weekend in the course of reinstalling my Linux OS. If time is > of the essence, posting your question to the entire list should ensure a > speedier response. > > Regarding your questions: > > 1) I am not aware of any applications that will act as viewers for > Mapserver operating in "map" mode. They may exist, but I'm not familiar > with them. I tend to use Mapserver in only one of two ways at the > moment; in "map" mode to generate static maps, in "wms" mode with a > connection to it via OpenLayers (or TileCache). > > 2) Regarding the path to your mapfile, I believe there are several > solutions that you can try if your goal is to shorten the URL string. > They are well-explained here - > > http://mapserver.gis.umn.edu/docs/howto/wms_server/#more-about-the-online-resource-url > . > As far as why the 1st URL doesn't actually work, it's because the path > should be relative to the mapserv.exe location in cgi-bin, not to > htdocs. So try this instead: > > - > > http://localhost:9090/cgi-bin/mapserv.exe?map=../htdocs/mapdemo/itasca_demo.map&mode=map > < > http://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.map&mode=map > > > > > Roger > -- > > On Mon, Nov 10, 2008 at 1:58 AM, Asif Memon wrote: > > Hi All, > > > > I have couple of question, could you please take a look at it : > > > > 1) Do you know any Map Server Client that allows viewing the image > service (created on the Minnesota Map Server) if I give the URL listed > below: > > http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.map&mode=map > " > > > > 2) I am using Windows XP on my PC. When I give the URL in this > format - > > http://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.map&mode=map > ", > it doesn't work. But if I give it in format - > http://localhost:9090/cgi-bin/mapserv.exe?map=C > :\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.map&mode=map > < > http://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.map&mode=map > > > , it works. The problem in giving the URL is this format is I have to > put the complete path starting with "C: drive" and if I have to run it > on the server, I cannot give it like that. > > > > Could you please help me with both the above issues? Thanks! > > > > Sincerely, > > Asif Memon > > > > > > From: Roger Andr? [mailto:randre at gmail.com] > Sent: Tuesday, October 28, 2008 8:11 PM > To: Asif Memon > Cc: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] RE: Documentation for serving large > raster images using tile cache. > > > > Hi Asif, > > I downloaded the demo.tif file that you sent earlier, and the > itasca_demo.map from you rprevious email. I changed the path in the > DATA portion of the LAYER section to point to my filesystem, > DATA "/var/www/mapfiles/itasca/demo.tif" > > and also changed the EXTThis matches the extent of the file when you run > gdalinfo against it > (min_x min_y max_x Max_y). > > With these changes, I'm able to view the file with the following URL: > > http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/itasca/itasca_demo.map&mode=map > > (Note, I'm running this in Linux, so paths and URLs are going to be > slightly different than yours) > > Try changing your EXTENT entry to match mine, that might do the trick. > -- > > On Tue, Oct 28, 2008 at 3:45 PM, Asif Memon wrote: > > Thanks Roger. > > > > I don't see any errors now, but no image appears in the browser(the > browser is blank). I made minor changes to the map file that you sent me > (about the paths, attached is the file). > > > > The URL that I am using in the browser is > http://localhost:9090/cgi-bin/mapserv.exe?map=C > :\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.map&mode=map > < > http://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.map&mode=map > > > > > > > Please correct me if anything is wrong in the URL or in the map file. > > > > Sincerely, > > Asif Memon > > > > > > From: Roger Andr? [mailto:randre at gmail.com] > Sent: Tuesday, October 28, 2008 3:17 PM > > > To: Asif Memon > Cc: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] RE: Documentation for serving large > raster images using tile cache. > > > > Hi Asif, > > Ok, here's a new mapfile that you can try. Change your request to point > to this one, and see if you get an image back in your browser. > > Roger > -- > > On Tue, Oct 28, 2008 at 2:06 PM, Asif Memon wrote: > > I believe one of the "END" was missing at the end of the file, I have > added that. This resolves the earlier error and generated a new one - > msDrawMap(): Image handling error. Unable to initialize image. > msPrepareImage(): General error message. Image dimensions not specified. > msCalculateScale(): General error message. Invalid image extent, > minx=-1.000000, miny=-1.000000, maxx=-1.000000, maxy=-1.000000. > mapserv(): Web application error. No way to generate map extent. > > > > Any help is much appreciated? > > > > Sincerely, > > Asif Memon > > > > From: Asif Memon > Sent: Tuesday, October 28, 2008 1:48 PM > To: 'Roger Andr?' > > > Cc: 'mapserver-users at lists.osgeo.org' > > Subject: RE: [mapserver-users] RE: Documentation for serving large > raster images using tile cache. > > > > No, TileCache didn't come with that. I am trying to view any image right > now to see an example of serving an image into Mapserver. > > > > I changed the path of the WMS > URL(http://localhost:9090/cgi-bin/mapserv.exe?map=C > :\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\demo.map&mode=map > < > http://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Cdemo.map&mode=map > > > ) and the error I am getting now is - msLoadMap(): Premature > End-of-File. > > > > I ran the GDAL tile cache command on a .tif image to create the shape > files using (gdaltindex doq_index.shp doq/*.tif). Also, I made some > changes in the map file. Attached is the most updated map file along > with the shape files. > > > > Could you please take a look at it. > > > > Sincerely, > > Asif Memon > > > > From: Roger Andr? [mailto:randre at gmail.com] > > Sent: Tuesday, October 28, 2008 1:22 PM > To: Asif Memon > > Subject: Re: [mapserver-users] RE: Documentation for serving large > raster images using tile cache. > > > > Sorry I assumed that the index.html file was the one that came with > TileCache. Is that not correct? > -- > > On Tue, Oct 28, 2008 at 1:02 PM, Asif Memon wrote: > > Thanks for your reply. > > > > Attached is the map file. I do not have the any tilecache.cfg file. From > the error(msLoadMap(): Unable to access file. (/path/to/demo.map)), it > appears the map file is not accessible. > > > > Sincerely, > > Asif Memon > > > > > > From: Roger Andr? [mailto:randre at gmail.com] > > Sent: Tuesday, October 28, 2008 12:53 PM > To: Asif Memon > > Cc: mapserver-users at lists.osgeo.org > > > Are you able to view a map when you go to > " > http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.map&mode=map > " > ? Also, can you send a copy of your mapfile, and of your tilecache.cfg > files? > > Roger > -- > > On Tue, Oct 28, 2008 at 11:15 AM, Asif Memon wrote: > > Hi Roger, > > > > I followed the instructions on the documentation and setup the map > server and demo, when I try to execute the index.html, I get this error > - msLoadMap(): Unable to access file. > (http://localhost:9090/mapdemo/itasca.map) > > > > Do you know what could be it? > > > > Sincerely, > > Asif Memon > > > > From: Roger Andr? [mailto:randre at gmail.com] > Sent: Monday, October 20, 2008 1:38 PM > To: Gregor Mosheh > Cc: Asif Memon; mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] RE: Documentation for serving large > raster images using tile cache. > > > > Hi Asif, > > Best thing to do is take a look at these 2 docs first: > - http://mapserver.gis.umn.edu/docs/howto/raster_data > - http://tilecache.org/readme.html > > Once you have the ability to see your raster in MapServer via a > "mode=map" request, then you will have to decide how you wish to view > your data afterwards. There are different things to do in TileCache > depending on whether you wish to view the data in OpenLayers, or over > Google Maps/MS VE. > -- > > On Mon, Oct 20, 2008 at 12:01 PM, Gregor Mosheh > wrote: > > Asif Memon wrote: > > Could someone please point me to the documentation for serving large > (2GB to 3GB) raster images using tile cache. I want to use Minnesota Map > Server and GDAL to achieve this. > > > > You'll want to ask the TileCache list about that, likely. Once you have > MapServer actually serving up the imagery, get your client using > MapServer or WMS (I like OpenLayers, myself). Then install TileCache and > change the OL app to use TC's URL instead of MapServer's. Easy. > > But you may want to install OpenLayers and get it working with MapServer > first, then hit up the OL and TC mailing lists. > > -- > Gregor Mosheh / Greg Allensworth BS, A+, Network+, Security+, Server+ > System Administrator, Lead Programmer > HostGIS development & hosting services, http://www.HostGIS.com/ > > "Remember that no one cares if you can back up, > only if you can restore." - AMANDA > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.deklerk at gmail.com Wed Jul 1 10:47:45 2009 From: andrew.deklerk at gmail.com (stretch) Date: Wed, 1 Jul 2009 10:47:45 -0700 (PDT) Subject: [mapserver-users] Dynamic LabelItem In-Reply-To: <1246379444083-3183671.post@n2.nabble.com> References: <1246285306236-3174574.post@n2.nabble.com> <1246298901193-3176090.post@n2.nabble.com> <4A48C6A0.5157.008F.0@dnr.state.mn.us> <1246302809284-3176452.post@n2.nabble.com> <4A49E8D3.5157.008F.0@dnr.state.mn.us> <1246379444083-3183671.post@n2.nabble.com> Message-ID: <1246470465541-3190607.post@n2.nabble.com> Upgraded to 5.4.1 with no problems and now performing dynamic labelling. Thanks for the help! -- View this message in context: http://n2.nabble.com/Dynamic-LabelItem-tp3174574p3190607.html Sent from the Mapserver - User mailing list archive at Nabble.com. From andy at squeakycode.net Wed Jul 1 10:50:03 2009 From: andy at squeakycode.net (andy) Date: Wed, 01 Jul 2009 12:50:03 -0500 Subject: [mapserver-users] mapscript perl fastcgi Message-ID: <4A4BA1CB.8080705@squeakycode.net> Hi All, I have linux/apache/mapscript/perl/cgi working ok, but wanted to try fastcgi to speed it up. This is a wms server, and under fastcgi it seems to work, but all the output is sent to stderr, not stdout. I dont need to do any buffering or anything after the request, so I am not using msIO_installStdoutToBuffer. OWSDispatch returns a zero (MS_SUCCESS), but there is no output. If I look in /var/log/httpd/error_log however, there is lots and lots of binary'ish crap. The script: #!/usr/bin/perl use strict; use mapscript; use FCGI; my $request = FCGI::Request(); my $map = new mapscript::mapObj( "/var/www/maps/hamilton.map" ) or die 'cant load hamilton.map'; while($request->Accept() >= 0) { my $req = new mapscript::OWSRequest(); my $x = $req->loadParams(); print STDERR "loadParams: $x\n"; $x = $map->OWSDispatch( $req ); print STDERR "OWSDispatch: $x\n"; my $errObj = new mapscript::errorObj(); while ($errObj) { print STDERR "ERROR: $errObj->{code}:$errObj->{message}:$errObj->{routine} \n"; $errObj = $errObj->next(); } } Any help would be appreciated. Thanks, -Andy From Steve.Lime at dnr.state.mn.us Wed Jul 1 11:41:44 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 01 Jul 2009 13:41:44 -0500 Subject: [mapserver-users] best practice: map data structure In-Reply-To: <200906290827.34395.liste@geo-dienstleistung.de> References: <200906261543.05642.liste@geo-dienstleistung.de> <757145.36637.qm@web51407.mail.re2.yahoo.com> <200906290827.34395.liste@geo-dienstleistung.de> Message-ID: <4A4B679D.5157.008F.0@dnr.state.mn.us> I believe the include closing problems have long since been resolve. I'm using 22 layer includes in one app with no worries via the CGI. You can always keep a master mapfile that uses includes and then write a simple script to open that mapfile and save a production version with all the includes expanded. Steve >>> On 6/29/2009 at 1:27 AM, in message <200906290827.34395.liste at geo-dienstleistung.de>, Frank Broniewski wrote: > Hi Dan, > > thanks for your response. Using includes for the layers is a nice idea, and > it > keeps the layer data and configuration together. And you'd get a good > overview > over all avail. layers on your server just by looking at the existing. > directories. Even postgis layers would have a directory since the layers > mapfile would be stored there. And you could have several "stylesheet" layer > > map files in the directory ... > And in an application directory you could include all the layers necessary > for > the application in a master mapfile. > > Do you have experience in using lots of includes within a mapfile? I > remember > using includes for about 30 layers in an php application (pmapper) once > (v4.10 > on ubuntu 7.10) and I run into problems. namely there where too many open > files opened by apache and the mapserver process. It seemed, that the > includes > weren't closed, and each time the map was redrawn, the includes where opened > > again and so the file system limit of max. open files was reached quite > soon. > > On Saturday 27 June 2009 17:08:35 Dan Little wrote: >> It is very dependent on your needs. For example, if you have departments >> responsible for various layers you may want to divide the structure by >> that, if there is only one administrator then that isn't necessary. >> >> Typically, if there is only one administrator I tend to do something like >> this... >> >> [root]/ -- make this whatever you want and that makes sense from a >> permissions and storage stand point for your new server. >> >> for a simple shapefile layer... >> [root]/layer_a/layer_a.map >> [root]/layer_a/layer_a.[shp|dbf|shx] >> >> for a tree'd shapfile >> [root]/layer_b/layer_b.map >> [root]/layer_b/layer_b.[shp|dbf|shx] >> [root]/layer_b/data/[... quad tree goes here ...] >> >> for a raster... >> [root]/layer_c/layer_c.map >> [root]/layer_c/raster/[... raster data ...] >> >> Then you can use mapserver includes to include the proper mapfile fragments >> into an applications various mapfiles. >> >> ----- Original Message ---- >> >> > From: Frank Broniewski >> > To: mapserver-users at lists.osgeo.org >> > Sent: Friday, June 26, 2009 8:43:05 AM >> > Subject: [mapserver-users] best practice: map data structure >> > >> > Hello List, >> > >> > I want to migrate our old server to a new one, and I want to replace the >> > somewhat grown map data folder and file mess into something more >> > structured. Therefore I am looking for some advice on how to organize the >> > Filesystem Hierarchy. Sure somehow its always a matter of taste and need, >> > but maybe you have some comments on my proposed structure. >> > >> > I browsed already the mailing list archives and the documentation on the >> > mapserver site but did not find any related infos, but I am willing to >> > summarize this thread into a howto document if something useful comes up. >> > >> > I will be using a linux server, so the structure will reflect the unix >> > filesystem hierarchy to a certain degree. >> > >> > A good starting point seems to be /usr/local/ to me. >> > >> > /usr/local/mapdata/ for storing raster and vector files >> > /usr/local/mapfiles/ for mapfiles and other config files >> > >> > You would have /usr/local/mapdata/CLIENTDIR/vector and >> > /usr/local/mapdata/CLIENTDIR/raster for client specific map data >> > similar to >> > /usr/local/mapdata/PROJECTDIR/... for project data >> > >> > and /usr/local/mapdata/share/vector & /usr/local/mapdata/share/raster for >> > shared map data (srtm topo maps e.g.) >> > >> > A good structure for mapfiles & co would be: >> > /mapfile.map >> > /fonts/ - font config and font files (ttf) >> > /icons/ - icon files (png, ...) >> > /symbols/ - symbol.map >> > /templates/ - template files >> > >> > This structure could be mapped to >> > /usr/local/mapfiles/share/... >> > or >> > /usr/local/mapfiles/CLIENTDIR/... >> > >> > I would really appreciate any comments and shared experience on this ... >> > >> > Listing: >> > >> > /usr/local/mapdata/ >> > /usr/local/mapdata/share/ >> > /usr/local/mapdata/share/raster/ >> > /usr/local/mapdata/share/raster/topo20/ >> > /usr/local/mapdata/share/raster/topo20/01.tif >> > /usr/local/mapdata/share/raster/topo20/... >> > /usr/local/mapdata/share/raster/topo20/99.tif >> > /usr/local/mapdata/share/raster/topo20/tileindex.shp >> > /usr/local/mapdata/share/vector/ >> > /usr/local/mapdata/share/vector/streetnetwork/ >> > /usr/local/mapdata/share/vector/streetnetwork/streets.shp >> > /usr/local/mapdata/CLIENT/raster/ >> > /usr/local/mapdata/CLIENT/raster/ortho/ >> > /usr/local/mapdata/CLIENT/raster/ortho/01.tif >> > /usr/local/mapdata/CLIENT/raster/ortho/... >> > /usr/local/mapdata/CLIENT/raster/ortho/99.tif >> > /usr/local/mapdata/CLIENT/raster/ortho/tileindex.shp >> > /usr/local/mapdata/CLIENT/vector/ >> > /usr/local/mapdata/CLIENT/vector/cad/contours.shp >> > /usr/local/mapdata/PROJECT/raster/ >> > /usr/local/mapdata/PROJECT/raster/climate/ >> > /usr/local/mapdata/PROJECT/raster/climate/precipitation.tif >> > /usr/local/mapdata/PROJECT/vector/ >> > /usr/local/mapdata/PROJECT/vector/archeology-sites.shp >> > >> > /usr/local/mapfiles/ >> > /usr/local/mapfiles/share/ >> > /usr/local/mapfiles/share/mapfile.map >> > /usr/local/mapfiles/share/fonts/ >> > /usr/local/mapfiles/share/icons/ >> > /usr/local/mapfiles/share/symbols/ >> > /usr/local/mapfiles/share/templates/ >> > /usr/local/mapfiles/CLIENT/ >> > /usr/local/mapfiles/CLIENT/mapfile.map >> > /usr/local/mapfiles/CLIENT/fonts/ >> > /usr/local/mapfiles/CLIENT/icons/ >> > /usr/local/mapfiles/CLIENT/symbols/ >> > /usr/local/mapfiles/CLIENT/templates/ >> > /usr/local/mapfiles/PROJECT/mapfile.map >> > /usr/local/mapfiles/PROJECT/fonts/ >> > /usr/local/mapfiles/PROJECT/icons/ >> > /usr/local/mapfiles/PROJECT/symbols/ >> > /usr/local/mapfiles/PROJECT/templates/ >> > _______________________________________________ >> > mapserver-users mailing list >> > mapserver-users at lists.osgeo.org >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From Dejan.Gambin at pula.hr Wed Jul 1 13:11:36 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Wed, 1 Jul 2009 22:11:36 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <4A4B2E35.5157.008F.0@dnr.state.mn.us> Message-ID: Steve, Here are more details, I am sure you'll have some further suggestions: There is a project called GeoReport, part of GeoBI suite, that integrates the data coming from Business Intelligence processes (Pentaho BI) with their cartographic representation. Since I am pretty much involved in both areas (WebGIS, BI), this seems very interesting to me, although I first saw it yesterday :-( Here are the main informations about GeoReport: http://www.geobi.org/2009/01/georeport-module.html As I can see, basically, there is a MapOL module that runs BI process in order to get resultset, join it with geometries coming from GeoServer (WFS) and returns GeoJSON data to WebGIS client (MapFish and OpenLayers + Geostat widgets) which displays it on the map. I have been in contact with Fabio (he is "responsible" for all this). Based on what he said, I understood (maybe wrongly) that WFS server needs to return GeoJSON, and GeoServer can do it. Now, as I write this to you, it seems like MapOL is responsible for creating GeoJSON data ?! Anyway, I am new to this almost as you and if you can take a look on above link, I would appreciate it very much. I "only" want to use MapServer instead of GeoServer. If I can't do it, then I'll rather do nothing as I have no intentions to use anything but MapServer :-) thanks very much regards, dejan "Steve Lime" wrote on 01.07.2009 16:36:48: > Depends on how you need to access it. You certainly can create a > template that will output GeoJSON. However, > at the moment you can only access that output though calls to the > CGI and (probably) MapScript. WMS and WFS > do not recognize the template output format although there are plans > to do so in the upcoming release. > > Let me know if I can help further... > > Steve > > >>> On 7/1/2009 at 7:44 AM, in message > , > wrote: > > Hi, > > > > Is it possible to use GeoJSON template for getting GeoJSON output from > > MapServer? I have tried using outputformat as described in: > > > > http://mapserver.org/development/rfc/ms-rfc-36.html and > > http://mapserver.org/development/rfc/ms-rfc-56.html > > > > Is it supported at all? I have a project where I need a GeoJSON output. > > This project originally uses GeoServer whcih has a plugin for this. Is > > this possible with MapServer? I am using MapServer 5.4.1 > > > > thanks very much > > > > regards, dejan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hrodriguez at siscat.com.ar Wed Jul 1 13:30:35 2009 From: hrodriguez at siscat.com.ar (Rodriguez, Heraldo) Date: Wed, 1 Jul 2009 17:30:35 -0300 Subject: [mapserver-users] LABEL_NO_CLIP seems not working in mapserver 5.4.1 In-Reply-To: <4A4AE562.3030206@datalinktech.com.au> Message-ID: <296E5F9B6BB1C445BDDC9C94FC83835E34B27E@ZEUS-Exchg2k3.sc.com> You are right David ,thanks, I realized the culprit was having set partials=false as I told Steve in a previous e-mail. And by the way (Steve and you) it?s Heraldo ( Rodriguez is my surname) ;-) Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A -----Mensaje original----- De: David Nugent [mailto:davidn at datalinktech.com.au] Enviado el: mi?rcoles, 01 de julio de 2009 1:26 Para: Rodriguez, Heraldo CC: mapserver-users at lists.osgeo.org Asunto: Re: [mapserver-users] LABEL_NO_CLIP seems not working in mapserver 5.4.1 On 1/7/09 1:02 AM, Rodriguez, Heraldo wrote: > Hi everyone, > We have just upgraded from mapserver 5.2.0 to 5.4.1 > Our application use OpenLayers, Tilecache with metatiles on, and > postgis. > The label positioning in polygons has improved a lot but now we are > experiencing label duplication on metatile boundaries. Rodriguez, I can report having a similar problem, but have noticed that seeems to be related to use of some of the other settings in the LABEL section. I don't recall the details exactly unfortunately, but if you are trying to reproduce a test case then try different values of MINDISTANCE and POSITION in particular (including AUTO and not present). I know something I did at some point was causing LABEL_NO_CLIP to not function, but I don't recall what. Regards, David From fabiodovidio at gmail.com Wed Jul 1 14:39:19 2009 From: fabiodovidio at gmail.com (Fabio D'Ovidio) Date: Wed, 1 Jul 2009 23:39:19 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: References: <4A4B2E35.5157.008F.0@dnr.state.mn.us> Message-ID: <9c74bb700907011439y219e99dcw7fe2987c49abb031@mail.gmail.com> Hello, sorry ...but i read also this mailing list :-) Well, our project wants to be indipendent from web application used to transfer GeoJson because GeoBI is compliant to the OGC standards such as WFS, WMS, SLD, etc... Now, about this first implementation of GeoReport we used GeoServer because it gives the possibilitiy to use in append to the WFS HTTP request "outputformat=geojson" instead of GML. Anyway MapOl makes a WFS request and reads the output by using mapfish-geojson-lib...so there are 3 ways to use MapServer to do the same: 1. use a GeoJSON template for WFS output 2. use a GeoJSON template for mapserver CGI output 3. GeoReport must do the conversion from WFS-GML to GeoJSON At the moment we have choosen GeoServer but this is not exclusive respect other WFS service implementations! Anyway I think you can use at the moment both MapServer and GeoServer: you must serve with GeoServer only the LAYER on which you want to do BI analysis (so...one, two layers...not all cartographic levels)...while you can display your layers by using MapFish Client and OpenLayers as WMS, WFS or MapServer Layers! PS: what kind of geometries you want to analyze (by using GeoJSON)? POINTS, POLYGONS....MULTIGEOMETRIES? Thank you very much! Fabio D'Ovidio 2009/7/1 > > Steve, > > Here are more details, I am sure you'll have some further suggestions: > > There is a project called GeoReport, part of GeoBI suite, that integrates > the data coming from Business Intelligence processes (Pentaho BI) with their > cartographic representation. Since I am pretty much involved in both areas > (WebGIS, BI), this seems very interesting to me, although I first saw it > yesterday :-( > > Here are the main informations about GeoReport: > http://www.geobi.org/2009/01/georeport-module.html > > As I can see, basically, there is a MapOL module that runs BI process in > order to get resultset, join it with geometries coming from GeoServer (WFS) > and returns GeoJSON data to WebGIS client (MapFish and OpenLayers + Geostat > widgets) which displays it on the map. > > I have been in contact with Fabio (he is "responsible" for all this). Based > on what he said, I understood (maybe wrongly) that WFS server needs to > return GeoJSON, and GeoServer can do it. Now, as I write this to you, it > seems like MapOL is responsible for creating GeoJSON data ?! > > Anyway, I am new to this almost as you and if you can take a look on above > link, I would appreciate it very much. I "only" want to use MapServer > instead of GeoServer. If I can't do it, then I'll rather do nothing as I > have no intentions to use anything but MapServer :-) > > thanks very much > > regards, dejan > > "Steve Lime" wrote on 01.07.2009 16:36:48: > > > Depends on how you need to access it. You certainly can create a > > template that will output GeoJSON. However, > > at the moment you can only access that output though calls to the > > CGI and (probably) MapScript. WMS and WFS > > do not recognize the template output format although there are plans > > to do so in the upcoming release. > > > > Let me know if I can help further... > > > > Steve > > > > >>> On 7/1/2009 at 7:44 AM, in message > > , > > wrote: > > > Hi, > > > > > > Is it possible to use GeoJSON template for getting GeoJSON output from > > > MapServer? I have tried using outputformat as described in: > > > > > > http://mapserver.org/development/rfc/ms-rfc-36.html and > > > http://mapserver.org/development/rfc/ms-rfc-56.html > > > > > > Is it supported at all? I have a project where I need a GeoJSON output. > > > > This project originally uses GeoServer whcih has a plugin for this. Is > > > this possible with MapServer? I am using MapServer 5.4.1 > > > > > > thanks very much > > > > > > regards, dejan > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Dejan.Gambin at pula.hr Wed Jul 1 15:31:57 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Thu, 2 Jul 2009 00:31:57 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <9c74bb700907011439y219e99dcw7fe2987c49abb031@mail.gmail.com> Message-ID: Fabio, Glad to here you are here too :-) I can certainly use both GeoServer and MapServer but this is not something I would like at the end. Since I am still investigating all this, I am not in such a hurry to get it working with my data ASAP. So, I would rather go with one of your Mapserver solutions. My first question, to be sure - so MapOl reads/gets the GeoJSON data from Geoserver WFS and outputs GeoJSON data to WebClient? If I understand Steve correctly, there is no way currently to get GeoJSON output from MapServer WFS, only with CGI? So we come to your solution 2. I have tried getting GeoJSON outuput from MapServer using CGI, but I didn't succeed. There is little written about this. I have tried setting something like: OUTPUTFORMAT NAME 'geojson' DRIVER 'TEMPLATE' MIMETYPE 'application/json; subtype=geojson' FORMATOPTION 'FILE=myTemplate.js' END but I got errors (using the newest MS4W beta with MapServer 5.4.1)? Regarding my geometries - I am planning to analyze some cadastral data (that's why I was so interested in your "italian" example). This will be points and polygons mostly. We have our cadastral data vectorized but still in dwg/multyline. We can identfy parcels as points with parcel IDs, but in near future we'll make polygons for all of them. regards, dejan mapserver-users-bounces at lists.osgeo.org wrote on 01.07.2009 23:39:19: > Hello, > sorry ...but i read also this mailing list :-) > > Well, our project wants to be indipendent from web application used > to transfer GeoJson because GeoBI is compliant to the OGC standards > such as WFS, WMS, SLD, etc... > > Now, about this first implementation of GeoReport we used GeoServer > because it gives the possibilitiy to use in append to the WFS HTTP > request "outputformat=geojson" instead of GML. > > Anyway MapOl makes a WFS request and reads the output by using > mapfish-geojson-lib...so there are 3 ways to use MapServer to do the same: > 1. use a GeoJSON template for WFS output > 2. use a GeoJSON template for mapserver CGI output > 3. GeoReport must do the conversion from WFS-GML to GeoJSON > At the moment we have choosen GeoServer but this is not exclusive > respect other WFS service implementations! > Anyway I think you can use at the moment both MapServer and > GeoServer: you must serve with GeoServer only the LAYER on which you > want to do BI analysis (so...one, two layers...not all cartographic > levels)...while you can display your layers by using MapFish Client > and OpenLayers as WMS, WFS or MapServer Layers! > > PS: what kind of geometries you want to analyze (by using GeoJSON)? > POINTS, POLYGONS....MULTIGEOMETRIES? > > Thank you very much! > > Fabio D'Ovidio > 2009/7/1 > > Steve, > > Here are more details, I am sure you'll have some further suggestions: > > There is a project called GeoReport, part of GeoBI suite, that > integrates the data coming from Business Intelligence processes > (Pentaho BI) with their cartographic representation. Since I am > pretty much involved in both areas (WebGIS, BI), this seems very > interesting to me, although I first saw it yesterday :-( > > Here are the main informations about GeoReport: http://www.geobi. > org/2009/01/georeport-module.html > > As I can see, basically, there is a MapOL module that runs BI > process in order to get resultset, join it with geometries coming > from GeoServer (WFS) and returns GeoJSON data to WebGIS client > (MapFish and OpenLayers + Geostat widgets) which displays it on the map. > > I have been in contact with Fabio (he is "responsible" for all > this). Based on what he said, I understood (maybe wrongly) that WFS > server needs to return GeoJSON, and GeoServer can do it. Now, as I > write this to you, it seems like MapOL is responsible for creating > GeoJSON data ?! > > Anyway, I am new to this almost as you and if you can take a look on > above link, I would appreciate it very much. I "only" want to use > MapServer instead of GeoServer. If I can't do it, then I'll rather > do nothing as I have no intentions to use anything but MapServer :-) > > thanks very much > > regards, dejan > "Steve Lime" wrote on 01.07.2009 16:36:48: > > > > Depends on how you need to access it. You certainly can create a > > template that will output GeoJSON. However, > > at the moment you can only access that output though calls to the > > CGI and (probably) MapScript. WMS and WFS > > do not recognize the template output format although there are plans > > to do so in the upcoming release. > > > > Let me know if I can help further... > > > > Steve > > > > >>> On 7/1/2009 at 7:44 AM, in message > > , > > wrote: > > > Hi, > > > > > > Is it possible to use GeoJSON template for getting GeoJSON output from > > > MapServer? I have tried using outputformat as described in: > > > > > > http://mapserver.org/development/rfc/ms-rfc-36.html and > > > http://mapserver.org/development/rfc/ms-rfc-56.html > > > > > > Is it supported at all? I have a project where I need a GeoJSON output. > > > This project originally uses GeoServer whcih has a plugin for this. Is > > > this possible with MapServer? I am using MapServer 5.4.1 > > > > > > thanks very much > > > > > > regards, dejan > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From erguen.ay at gmx.de Wed Jul 1 22:33:40 2009 From: erguen.ay at gmx.de (=?iso-8859-1?Q?Erg=FCn_Ayduran_=28GMX=29?=) Date: Thu, 2 Jul 2009 07:33:40 +0200 Subject: [mapserver-users] Problem with WFS Filter Message-ID: Hi, i want to filter set a filter in a wfs request: I want to get all polygons, where ("von_pegel" >= 70 or "bis_pegel" < 70) and datumzeit = 2009-07-09 12:00:00. I tried it with the request: http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00 and with this request (is the same request,without %20 in date) http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09 12:00:00 Both requests response me only all polygons. Example: (1) 0 - 50 (2) 50 - 100 (3) 100 - 150 (4) 150 - 200 Setting the filter should response only (2), (3) and (4) Plz, can anyone tell me, what is wrong in my filter. EA -------------- next part -------------- An HTML attachment was scrubbed... URL: From erguen.ay at gmx.de Wed Jul 1 22:40:56 2009 From: erguen.ay at gmx.de (=?iso-8859-1?Q?Erg=FCn_Ayduran_=28GMX=29?=) Date: Thu, 2 Jul 2009 07:40:56 +0200 Subject: [mapserver-users] Problem with WFS Filter References: Message-ID: Sry i forgot to write: All data have the same "datumzeit" = 2009-07-09 12:00:00 ----- Original Message ----- From: Erg?n Ayduran (GMX) To: mapserver-users at lists.osgeo.org Sent: Thursday, July 02, 2009 7:33 AM Subject: [mapserver-users] Problem with WFS Filter Hi, i want to filter set a filter in a wfs request: I want to get all polygons, where ("von_pegel" >= 70 or "bis_pegel" < 70) and datumzeit = 2009-07-09 12:00:00. I tried it with the request: http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00 and with this request (is the same request,without %20 in date) http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09 12:00:00 Both requests response me only all polygons. Example: (1) 0 - 50 (2) 50 - 100 (3) 100 - 150 (4) 150 - 200 Setting the filter should response only (2), (3) and (4) Plz, can anyone tell me, what is wrong in my filter. EA ------------------------------------------------------------------------------ _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From fabiodovidio at gmail.com Thu Jul 2 00:28:06 2009 From: fabiodovidio at gmail.com (Fabio D'Ovidio) Date: Thu, 02 Jul 2009 09:28:06 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: References: Message-ID: <4A4C6186.4000604@gmail.com> Hi, Dejan.Gambin at pula.hr ha scritto: > > Fabio, > > Glad to here you are here too :-) > > I can certainly use both GeoServer and MapServer but this is not > something I would like at the end. Since I am still investigating all > this, I am not in such a hurry to get it working with my data ASAP. > So, I would rather go with one of your Mapserver solutions. It is not so difficult...just 2, 3 minutes to load your layer in GeoServer ;-) > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > understand Steve correctly, there is no way currently to get GeoJSON > output from MapServer WFS, only with CGI? So we come to your solution 2. If you want to use the second solution you must create the HTTP string to get GeoJSON from CGI-MapServer and than you must change MapOl request to receive data and read them. If you want send me the URL and I'll send you the new MapOl as soon as possbile! -- Fabio D'Ovidio Geospatial solutions Inova S.r.l. Web : http://www.inovaos.it GeoBI Blog: www.geobi.org Tel.: 081 197 57 600 mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it skype: dovidio_fa From meenu.monu at gmail.com Thu Jul 2 00:43:10 2009 From: meenu.monu at gmail.com (meenu) Date: Thu, 2 Jul 2009 00:43:10 -0700 (PDT) Subject: [mapserver-users] select one column values from a table In-Reply-To: <1242819298398-2945586.post@n2.nabble.com> References: <1242634303620-2931342.post@n2.nabble.com> <1242721664439-2938255.post@n2.nabble.com> <1242724544315-2938452.post@n2.nabble.com> <1242729551230-2938771.post@n2.nabble.com> <1242732358124-2938939.post@n2.nabble.com> <1242740965463-2939629.post@n2.nabble.com> <1242819298398-2945586.post@n2.nabble.com> Message-ID: <1246520590108-3193894.post@n2.nabble.com> can anybody help me ??? meenu wrote: > > hi friend thanks....i tried mentioned code ...but am getting error like > "msLayerGetNumFeatures(): Shapefile error. Not an inline layer" > in my map file i wrote the table structure for this specified matter is as > follows... > is this error comes because of my table or not? > > > LAYER > NAME "n_123 " > TYPE POINT > CONNECTIONTYPE OGR > CONNECTION "n_123 .TAB" > STATUS ON > LABELITEM "PLO_900 " > CLASS > STYLE > COLOR 255 0 0 > OUTLINECOLOR 0 0 0 > SYMBOL 'ball' > END > LABEL > COLOR 100 100 255 > FONT arial > TYPE TRUETYPE > SIZE 7 > POSITION LC > WRAP " " > END#LABEL > END# CLASS > END#LAYER > ----- Meenu -- View this message in context: http://n2.nabble.com/select-one-column-values-from-a-table-tp2931342p3193894.html Sent from the Mapserver - User mailing list archive at Nabble.com. From Dejan.Gambin at pula.hr Thu Jul 2 03:32:15 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Thu, 2 Jul 2009 12:32:15 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <4A4C6186.4000604@gmail.com> Message-ID: Thanks Fabio, As I said in my last post, I can't get GeoJSON output using this outputformat: OUTPUTFORMAT NAME 'geojson' DRIVER 'TEMPLATE' MIMETYPE 'application/json; subtype=geojson' FORMATOPTION 'FILE=myTemplate.js' END :-( regards, dejan Fabio D'Ovidio wrote on 02.07.2009 09:28:06: > Hi, > > Dejan.Gambin at pula.hr ha scritto: > > > > Fabio, > > > > Glad to here you are here too :-) > > > > I can certainly use both GeoServer and MapServer but this is not > > something I would like at the end. Since I am still investigating all > > this, I am not in such a hurry to get it working with my data ASAP. > > So, I would rather go with one of your Mapserver solutions. > It is not so difficult...just 2, 3 minutes to load your layer in > GeoServer ;-) > > > > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > > understand Steve correctly, there is no way currently to get GeoJSON > > output from MapServer WFS, only with CGI? So we come to your solution 2. > > If you want to use the second solution you must create the HTTP string > to get GeoJSON from CGI-MapServer and than you must change MapOl request > to receive data and read them. > If you want send me the URL and I'll send you the new MapOl as soon as > possbile! > > > -- > Fabio D'Ovidio > Geospatial solutions > > Inova S.r.l. > Web : http://www.inovaos.it > GeoBI Blog: www.geobi.org > Tel.: 081 197 57 600 > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it > skype: dovidio_fa > -------------- next part -------------- An HTML attachment was scrubbed... URL: From LCLARK at GENASYS.COM Thu Jul 2 05:50:35 2009 From: LCLARK at GENASYS.COM (LewInMadrid) Date: Thu, 2 Jul 2009 05:50:35 -0700 (PDT) Subject: [mapserver-users] gdaltindex with TAB files. Message-ID: <1246539035172-3194851.post@n2.nabble.com> I'm trying to generate a tileindex for a large number of MapInfo raster TAB files and get the following error: ERROR 4: `MYFILE1.TAB' not recognised as a supported file format. gdalinfo gives the same error. I can view the individual TAB files with MapServer without problems. "gdalinfo --version" returns "GDAL 1.5.0, released 2007/12/18" -- View this message in context: http://n2.nabble.com/gdaltindex-with-TAB-files.-tp3194851p3194851.html Sent from the Mapserver - User mailing list archive at Nabble.com. From flavio at tydac.ch Thu Jul 2 07:29:53 2009 From: flavio at tydac.ch (Flavio Hendry) Date: Thu, 02 Jul 2009 16:29:53 +0200 Subject: [mapserver-users] gdaltindex with TAB files. In-Reply-To: <1246539035172-3194851.post@n2.nabble.com> References: <1246539035172-3194851.post@n2.nabble.com> Message-ID: hi just an idea: do not use the TAB extension but the raster extension for feeding gdaltindex (i.e. tif). Mit freundlichem Gruss / Best Regards Flavio Hendry ---------------------------------------------------------------- TYDAC Web-Site: http://www.tydac.ch TYDAC MapServer: http://www.mapserver.ch TYDAC SwissMaps: http://www.mapplus.ch ---------------------------------------------------------------- ############ Mit freundlichen Gruessen / Kind Regards ############ mailto:flavio at tydac.ch ############ TYDAC AG - http://www.tydac.ch #### #### Geographic Information Solutions #### #### Luternauweg 12 -- CH-3006 Bern ############ Tel +41 (0)31 368 0180 - Fax +41 (0)31 368 1860 ---------------------------------------------------------------- Location: http://www.mapplus.ch/adr/bern/luternauweg/12 ---------------------------------------------------------------- -----Original Message----- From: LewInMadrid To: mapserver-users at lists.osgeo.org Date: Thu, 2 Jul 2009 05:50:35 -0700 (PDT) Subject: [mapserver-users] gdaltindex with TAB files. > > I'm trying to generate a tileindex for a large number of MapInfo > raster TAB > files and get the following error: > ERROR 4: `MYFILE1.TAB' not recognised as a supported file format. > gdalinfo gives the same error. > > I can view the individual TAB files with MapServer without problems. > "gdalinfo --version" returns "GDAL 1.5.0, released 2007/12/18" > > > -- > View this message in context: > http://n2.nabble.com/gdaltindex-with-TAB-files.-tp3194851p3194851.htm > l > Sent from the Mapserver - User mailing list archive at Nabble.com. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From andrew.deklerk at gmail.com Thu Jul 2 09:03:13 2009 From: andrew.deklerk at gmail.com (stretch) Date: Thu, 2 Jul 2009 09:03:13 -0700 (PDT) Subject: [mapserver-users] GetFeatureInfo - something not adding up Message-ID: <1246550593612-3195907.post@n2.nabble.com> Hi All I am doing a GetFeatureInfo Through Openlayers. All seems to be working fine (i.e. template comes up) except it is not returning any values. What happens is that template is returned but the values are not populated - i.e Compt No: [Compt_No] instead of Compt_no: A03 etc Here is my URL http://localhost/cgi-bin/masonite.asp?mf=bartonheights.map&LAYERS=Compartments&SERVICE=WMS&VERSION=1.0.0&REQUEST=GetFeatureInfo&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_xml&FORMAT=png&SRS=EPSG%3A2054&BBOX=-81259.386908%2C-3308449.52709%2C-73921.613092%2C-3305902.47291&X=342&Y=226&INFO_FORMAT=text%2Fhtml&QUERY_LAYERS=Compartments&WIDTH=1040&HEIGHT=361 ---------------------------------------------------------------------------- My Map file (parts of it) # WMS server settings METADATA 'wms_title' 'masonite' 'wms_onlineresource' 'http://zzzzz/masonite.asp?' 'wms_srs' 'EPSG:2054' 'wms_feature_info_mime_type' 'text/html' 'ows_include_items' 'all' END LAYER NAME 'Compartments' TYPE POLYGON DATA 'Farms\BartonHeights\Basedata\Compartments.shp' TEMPLATE "Compartments.html" #For select feature TOLERANCE 15 TOLERANCEUNITS PIXELS ------------------------------------------------------------------ And my Template File
Compartment
Compt No: [Compt_No]
Age: [Age]
Area: [Area_ha]
Species: [Species]
Plant Year: [Pd_yy]
Method: [Method]
Can anyone see anything drastically wrong. I have copied the template from a mapserver 5 installation and added the "magic words" at the top - is there anything else required Thanks Andrew -- View this message in context: http://n2.nabble.com/GetFeatureInfo---something-not-adding-up-tp3195907p3195907.html Sent from the Mapserver - User mailing list archive at Nabble.com. From David.Fawcett at state.mn.us Thu Jul 2 09:10:41 2009 From: David.Fawcett at state.mn.us (Fawcett, David) Date: Thu, 2 Jul 2009 11:10:41 -0500 Subject: [mapserver-users] GetFeatureInfo - something not adding up In-Reply-To: <1246550593612-3195907.post@n2.nabble.com> Message-ID: <6246727221874A4FB8D3F9BBC37D9BD5056DA64D@s-sp22.pca.state.mn.us> It may be the case that MapServer isn't recognizing the variables because they are in the wrong case. I believe that when the columns come from a shapefile, the column names are all upper case. Try changing all of the substitution vars in your template to upper case. David. -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of stretch Sent: Thursday, July 02, 2009 11:03 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] GetFeatureInfo - something not adding up Hi All I am doing a GetFeatureInfo Through Openlayers. All seems to be working fine (i.e. template comes up) except it is not returning any values. What happens is that template is returned but the values are not populated - i.e Compt No: [Compt_No] instead of Compt_no: A03 etc Here is my URL http://localhost/cgi-bin/masonite.asp?mf=bartonheights.map&LAYERS=Compar tments&SERVICE=WMS&VERSION=1.0.0&REQUEST=GetFeatureInfo&STYLES=&EXCEPTIO NS=application%2Fvnd.ogc.se_xml&FORMAT=png&SRS=EPSG%3A2054&BBOX=-81259.3 86908%2C-3308449.52709%2C-73921.613092%2C-3305902.47291&X=342&Y=226&INFO _FORMAT=text%2Fhtml&QUERY_LAYERS=Compartments&WIDTH=1040&HEIGHT=361 ------------------------------------------------------------------------ ---- My Map file (parts of it) # WMS server settings METADATA 'wms_title' 'masonite' 'wms_onlineresource' 'http://zzzzz/masonite.asp?' 'wms_srs' 'EPSG:2054' 'wms_feature_info_mime_type' 'text/html' 'ows_include_items' 'all' END LAYER NAME 'Compartments' TYPE POLYGON DATA 'Farms\BartonHeights\Basedata\Compartments.shp' TEMPLATE "Compartments.html" #For select feature TOLERANCE 15 TOLERANCEUNITS PIXELS ------------------------------------------------------------------ And my Template File
Compartment
Compt No: [Compt_No]
Age: [Age]
Area: [Area_ha]
Species: [Species]
Plant Year: [Pd_yy]
Method: [Method]
Can anyone see anything drastically wrong. I have copied the template from a mapserver 5 installation and added the "magic words" at the top - is there anything else required Thanks Andrew -- View this message in context: http://n2.nabble.com/GetFeatureInfo---something-not-adding-up-tp3195907p 3195907.html Sent from the Mapserver - User mailing list archive at Nabble.com. _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From andrew.deklerk at gmail.com Thu Jul 2 09:17:40 2009 From: andrew.deklerk at gmail.com (stretch) Date: Thu, 2 Jul 2009 09:17:40 -0700 (PDT) Subject: [mapserver-users] GetFeatureInfo - something not adding up In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5056DA64D@s-sp22.pca.state.mn.us> References: <1246550593612-3195907.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA64D@s-sp22.pca.state.mn.us> Message-ID: <1246551460911-3195998.post@n2.nabble.com> Bang on the money david! Thanks a million Andrew Fawcett, David wrote: > > It may be the case that MapServer isn't recognizing the variables > because they are in the wrong case. I believe that when the columns > come from a shapefile, the column names are all upper case. Try > changing all of the substitution vars in your template to upper case. > > David. > > -- View this message in context: http://n2.nabble.com/GetFeatureInfo---something-not-adding-up-tp3195907p3195998.html Sent from the Mapserver - User mailing list archive at Nabble.com. From youness.elmedraoui at somei.fr Thu Jul 2 10:27:35 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Thu, 2 Jul 2009 19:27:35 +0200 Subject: [Mapserver-users] programming with visual basic .net Message-ID: An HTML attachment was scrubbed... URL: From Craig.Dillabough at AGR.GC.CA Thu Jul 2 11:56:05 2009 From: Craig.Dillabough at AGR.GC.CA (Dillabough, Craig) Date: Thu, 2 Jul 2009 14:56:05 -0400 Subject: [mapserver-users] Question About WCS Message-ID: <8EA33237DDDB244E860ADDE976124AE50202CBD7@ONOTTAXMS2.AGR.GC.CA> Hi, I am brand new to MapServer, and I am trying to figure out WCS. I've been following the instructions on http://mapserver.org/ogc/wcs_server.html and was making some progress as executing a GetCapabilities request returns what I was expecting. However when I try to execute a DescribeCoverage request I only see the following: Based on the tutorial I am also expecting to see a CoverageOffering element as well with something like: week19 ... Etc .... However, only the the CoverageDescription element shows up. The relevant portions of my .map file are as follows: MAP NAME WeeklyMaxNDVI STATUS ON SIZE 400 300 EXTENT -10007554.677 4447802.079 -3335851.559 6671703.118 UNITS METERS # # Start of web interface definition # WEB IMAGEPATH "/opt/mapserver/ms_data/tmp/" IMAGEURL "../tmp/" METADATA "wcs_label" "WCS Demo Server" ### required "wcs_description" "Some text description of the service" "wcs_onlineresource" "http://127.0.0.1/cgi-bin/mapserv?" .... "wcs_service_onlineresource" "http://127.0.0.1/cgi-bin/mapserv?" END #Metadata END #Web LAYER NAME week19 METADATA "wcs_label" "Week19" "wcs_rangeset_name" "Range" "wcs_rangeset_label" "My label" END #Metadata TYPE RASTER ### required STATUS ON DATA '../imgdata/wcs/AvMaxNDVI.2000-09.wk19.tif' PROJECTION AUTO END DUMP TRUE ### required END #Layer END # Map File If anyone can see anything obvious as to why I am not getting the expected result I would greatly appreciate some advice. Cheers, Craig From richard.greenwood at gmail.com Thu Jul 2 13:31:45 2009 From: richard.greenwood at gmail.com (Richard Greenwood) Date: Thu, 2 Jul 2009 14:31:45 -0600 Subject: [mapserver-users] In msCleanupOnSignal. Message-ID: My Apache error log is full of "In msCleanupOnSignal." entries. Can anyone tell me what it means and if I should be concerned? I built 5.2.2 with the config options below: ./configure --with-postgis=/usr/local/pgsql/bin/pg_config\ --with-geos\ --with-gdal\ --with-proj\ --without-eppl\ --with-ogr Mapserver is running fine, but I figure anything in an error log is worth investigating. Thanks, Rich -- Richard Greenwood richard.greenwood at gmail.com www.greenwoodmap.com From Dejan.Gambin at pula.hr Thu Jul 2 14:15:41 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Thu, 2 Jul 2009 23:15:41 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <4A4C71500200008F00025A23@co5.dnr.state.mn.us> Message-ID: Steve, Is there any GeoJSON example I can see? I must be missing something trivial, When I put: OUTPUTFORMAT NAME 'geojson' DRIVER TEMPLATE MIMETYPE 'application/json; subtype=geojson' TEMPLATE 'myTemplate.js' END in my.map file and call for example "http://localhost/cgi-bin/mapserv.exe?map=/ms4w/apps/pmapper/pmapper-3.2.0/config/default/geojson_demo.map&layer=countries" (this works correctly without geojson part), I get: getString(): Symbol definition error. Parsing error near (TEMPLATE):(line 74) If I put DRIVER 'TEMPLATE' then I get: loadOutputFormat(): Unknown identifier. Parsing error near (TEMPLATE):(line 76) Finally, putting FORMATOPTION 'FILE=myTemplate.js' instead of TEMPLATE gives me: loadOutputFormat(): General error message. OUTPUTFORMAT clause references driver TEMPLATE, but this driver isn't configured. So, I am obviously doing something wrong regardless the myTemplate.js file? (anyway, can you give me an example .js file, anything that could help :-) regards, dejan "Steve Lime" wrote on 02.07.2009 15:35:28: > What does myTemplate.js look like? > > >>> 07/02/09 5:33 AM >>> > Thanks Fabio, > > As I said in my last post, I can't get GeoJSON output using this > outputformat: > > OUTPUTFORMAT > NAME 'geojson' > DRIVER 'TEMPLATE' > MIMETYPE 'application/json; subtype=geojson' > FORMATOPTION 'FILE=myTemplate.js' > END > > :-( > > regards, dejan > > Fabio D'Ovidio wrote on 02.07.2009 09:28:06: > > > Hi, > > > > Dejan.Gambin at pula.hr ha scritto: > > > > > > Fabio, > > > > > > Glad to here you are here too :-) > > > > > > I can certainly use both GeoServer and MapServer but this is not > > > something I would like at the end. Since I am still investigating all > > > this, I am not in such a hurry to get it working with my data ASAP. > > > So, I would rather go with one of your Mapserver solutions. > > It is not so difficult...just 2, 3 minutes to load your layer in > > GeoServer ;-) > > > > > > > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > > > understand Steve correctly, there is no way currently to get GeoJSON > > > output from MapServer WFS, only with CGI? So we come to your solution > 2. > > > > If you want to use the second solution you must create the HTTP string > > to get GeoJSON from CGI-MapServer and than you must change MapOl request > > > to receive data and read them. > > If you want send me the URL and I'll send you the new MapOl as soon as > > possbile! > > > > > > -- > > Fabio D'Ovidio > > Geospatial solutions > > > > Inova S.r.l. > > Web : http://www.inovaos.it > > GeoBI Blog: www.geobi.org > > Tel.: 081 197 57 600 > > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it > > skype: dovidio_fa > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Thu Jul 2 14:31:50 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Thu, 2 Jul 2009 23:31:50 +0200 Subject: [Mapserver-users] programming with visual basic .net In-Reply-To: References: Message-ID: Hi, You can use the MapScript C# wrapper to achieve the desired functionality according to the following steps: 1. Download the binary package which suits best to your compiler and architecture: http://vbkto.dyndns.org:1280/sdk/Default.aspx 2. Add reference to the mapscript_csharp.dll in your Visual Studio project. 3. Copy the dll-s from the /bin and /bin/ms/csharp directory into your target directory. 4. use the classes of the OSGeo.MapServer namespace to make up your application Refer to the following tutorial for more detailed information http://www.paolocorti.net/2006/09/20/mapserver-tutorial-for-c-mapscript-asp-net/ Best regards, Tamas 2009/7/2 > Hello, > > i'm a new member in this list and i have some questions. > i want to construct a web site with mapserver and programming with visual > basic .net (framework 2.0). what i need for that? there is some dlls file to > compile for work with mapscript vb .net? > > help me plz. thanks > > with best regards, > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mlinden at zeelandnet.nl Thu Jul 2 14:38:43 2009 From: mlinden at zeelandnet.nl (Milo van der Linden) Date: Thu, 02 Jul 2009 23:38:43 +0200 Subject: [Mapserver-users] programming with visual basic .net In-Reply-To: References: Message-ID: <4A4D28E3.5090309@zeelandnet.nl> I do not want to be rude to the mapserver community, since I moved to linux 2 years ago I have never abandonned it ;-) but... If you want to create mapping applications from the dotnet framework, you might want to consider sharpmap. I have had some really good experience with their toolkit when I was still programming for windows: http://sharpmap.codeplex.com/ Maybe it can be of use for you. Kind regards, Milo van der Linden Tamas Szekeres wrote: > Hi, > > You can use the MapScript C# wrapper to achieve the desired > functionality according to the following steps: > > 1. Download the binary package which suits best to your compiler and > architecture: http://vbkto.dyndns.org:1280/sdk/Default.aspx > 2. Add reference to the mapscript_csharp.dll in your Visual Studio > project. > 3. Copy the dll-s from the /bin and /bin/ms/csharp directory into your > target directory. > 4. use the classes of the OSGeo.MapServer namespace to make up your > application > > Refer to the following tutorial for more detailed information > http://www.paolocorti.net/2006/09/20/mapserver-tutorial-for-c-mapscript-asp-net/ > > Best regards, > > Tamas > > > > > 2009/7/2 > > > Hello, > > i'm a new member in this list and i have some questions. > i want to construct a web site with mapserver and programming with > visual basic .net (framework 2.0). what i need for that? there is > some dlls file to compile for work with mapscript vb .net? > > help me plz. thanks > > with best regards, > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re > strictement confidentiel et sont exclusivement adress?es au > destinataire mentionn? ci-dessus.Tout usage, reproduction ou > divulgation de cet e-mail est strictement interdit si vous n'en > ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir > imm?diatement par la m?me voie et d?truire l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From lclark at genasys.com Fri Jul 3 00:15:12 2009 From: lclark at genasys.com (Lewis Clark) Date: Fri, 3 Jul 2009 09:15:12 +0200 Subject: [Mapserver-users] programming with visual basic .net In-Reply-To: <4A4D28E3.5090309@zeelandnet.nl> References: <4A4D28E3.5090309@zeelandnet.nl> Message-ID: We've successfully used SharpMap but I would be wary of choosing it today. The project seems to have lost its way after its creator Morten Nielsen left for ESRI. The last stable release, 0.9, is from 2006 when he was still with the project. Regards, Lewis. -----Mensaje original----- De: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] En nombre de Milo van der Linden Enviado el: jueves, 02 de julio de 2009 23:39 Para: mapserver-users at lists.osgeo.org Asunto: Re: [Mapserver-users] programming with visual basic .net I do not want to be rude to the mapserver community, since I moved to linux 2 years ago I have never abandonned it ;-) but... If you want to create mapping applications from the dotnet framework, you might want to consider sharpmap. I have had some really good experience with their toolkit when I was still programming for windows: http://sharpmap.codeplex.com/ Maybe it can be of use for you. Kind regards, Milo van der Linden Tamas Szekeres wrote: > Hi, > > You can use the MapScript C# wrapper to achieve the desired > functionality according to the following steps: > > 1. Download the binary package which suits best to your compiler and > architecture: http://vbkto.dyndns.org:1280/sdk/Default.aspx > 2. Add reference to the mapscript_csharp.dll in your Visual Studio > project. > 3. Copy the dll-s from the /bin and /bin/ms/csharp directory into your > target directory. > 4. use the classes of the OSGeo.MapServer namespace to make up your > application > > Refer to the following tutorial for more detailed information > http://www.paolocorti.net/2006/09/20/mapserver-tutorial-for-c-mapscript-asp-net/ > > Best regards, > > Tamas > > > > > 2009/7/2 > > > Hello, > > i'm a new member in this list and i have some questions. > i want to construct a web site with mapserver and programming with > visual basic .net (framework 2.0). what i need for that? there is > some dlls file to compile for work with mapscript vb .net? > > help me plz. thanks > > with best regards, > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re > strictement confidentiel et sont exclusivement adress?es au > destinataire mentionn? ci-dessus.Tout usage, reproduction ou > divulgation de cet e-mail est strictement interdit si vous n'en > ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir > imm?diatement par la m?me voie et d?truire l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From gju at galigeo.com Fri Jul 3 00:37:13 2009 From: gju at galigeo.com (=?iso-8859-1?Q?Gana=EBl_Jatteau?=) Date: Fri, 3 Jul 2009 09:37:13 +0200 Subject: [mapserver-users] Can't get JOIN to work with Postgis Message-ID: <005801c9fbb1$154e83a0$a301a8c0@avantias.local> Hi, I'm trying to use the tag JOIN in a layer in order to join two tables in POSTGIS. The layer gets displayed on the map but it seems that the join is ignored (a subset of the layer should be displayed normally after the join and when I select some features I don?t see the attributes from the join table). BTW: I use MapServer 5.2.1 on Windows Is there anything wrong with the layer that has been defined: LAYER CONNECTION "host=localhost user=scott dbname=basepiad password='tiger' CONNECTIONTYPE POSTGIS DATA "the_geom from dept_aquitaine using unique oid using SRID=27581" CLASS NAME "classe" STYLE ANGLE 360 COLOR 255 255 255 OPACITY 100 OUTLINECOLOR 180 180 180 SYMBOL 0 END END JOIN NAME "test_join" TABLE "webigeo.wap1" FROM "code_depar" TO "f0" TYPE ONE-TO-ONE END NAME "departements_join" STATUS ON TEMPLATE "ttt" TYPE POLYGON UNITS METERS END Thanks in advance. Gana?l -------------- next part -------------- An HTML attachment was scrubbed... URL: From gju at galigeo.com Fri Jul 3 02:18:15 2009 From: gju at galigeo.com (=?iso-8859-1?Q?Gana=EBl_Jatteau?=) Date: Fri, 3 Jul 2009 11:18:15 +0200 Subject: [mapserver-users] Can't get JOIN to work with Postgis In-Reply-To: <2a37f67a0907030122h4862a5e0p452dfbb655002a47@mail.gmail.com> Message-ID: <006301c9fbbf$32b5a460$a301a8c0@avantias.local> You're right, the two tables are not in the same schema but they have the appropriate select rights. Having a join defined in the data works fine: DATA "the_geom from (SELECT dept_aquitaine.the_geom as the_geom, wap1.f0 as name0, wap1.f1 as name1, dept_aquitaine.oid as oid from dept_aquitaine INNER JOIN webigeo.wap1 on (dept_aquitaine.code_depar = wap1.f0)) as tmp using SRID=27581" However I would have preferred using a JOIN since it is easier to generate in a program and more generic. Cheers Ganael -----Message d'origine----- De?: Pavel Iacovlev [mailto:iacovlev.pavel at gmail.com] Envoy??: vendredi 3 juillet 2009 10:22 ??: Gana?l Jatteau Objet?: Re: [mapserver-users] Can't get JOIN to work with Postgis wap1 is in webigeo schema and dept_aquitaine is in public schema ? Try to do a simple SQL join query, first test in in pgsql and then just paste it in your data sections, easier to debug. DATA "the_geom from ( SELECT dept_aquitaine.the_geom as the_geom, wap1.some_field as name from dept_aquitaine LEFT JOIN webigeo.wap1 on (dept_aquitaine.f0 = wap1.f0) ) as tmp using SRID=YOUR_SRID using unique YOUR_GID" On Fri, Jul 3, 2009 at 10:37 AM, Gana?l Jatteau wrote: > Hi, > > > > I'm trying to use the tag JOIN in a layer in order to join two tables in > POSTGIS. > > > > The layer gets displayed on the map but it seems that the join is ignored (a > subset of the layer should be displayed normally after the join and when I > select some features I don?t see the attributes from the join table). > > > > BTW: I use MapServer 5.2.1 on Windows > > > > Is there anything wrong with the layer that has been defined: > > > > LAYER > > ??? CONNECTION "host=localhost user=scott dbname=basepiad password='tiger' > > ??? CONNECTIONTYPE POSTGIS > > ??? DATA "the_geom from dept_aquitaine using unique oid using SRID=27581" > > ????? CLASS > > ????? NAME "classe" > > ???? ?STYLE > > ??????? ANGLE 360 > > ??????? COLOR 255 255 255 > > ??????? OPACITY 100 > > ??????? OUTLINECOLOR 180 180 180 > > ??????? SYMBOL 0 > > ????? END > > ??? END > > ??? JOIN > > ????? NAME "test_join" > > ????? TABLE "webigeo.wap1" > > ????? FROM "code_depar" > > ????? ? TO "f0" > > ????? TYPE ONE-TO-ONE > > ??? END > > ??? NAME "departements_join" > > ??? STATUS ON > > ??? TEMPLATE "ttt" > > ??? TYPE POLYGON > > ??? UNITS METERS > > ? END > > > > > > Thanks in advance. > > > > Gana?l > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- http://iap.md, The future is open From schroeter at netgis.de Fri Jul 3 02:51:19 2009 From: schroeter at netgis.de (Sven Schroeter) Date: Fri, 3 Jul 2009 11:51:19 +0200 Subject: [mapserver-users] ms_newprojectionobj Message-ID: <8FDF8C63762E42508281CC952663EC69@SVEN> Hi, I'm using php-mapscript to project a point from epsg:31466 (Gauss-Krueger-Zone2) to epsg:4326 (WGS84): //create point $qPoint = ms_newPointObj(); $qPoint->setXY(2521189,5541667); // Calculate -> WGS84 $projInObj = ms_newprojectionobj("init=epsg:31466"); $projOutObj = ms_newprojectionobj("init=epsg:4326"); $qPoint->project($projInObj, $projOutObj); $WGS_X = round($qPoint->x,6); $WGS_Y = round($qPoint->y,6); echo 'WGS84: '.$WGS_Y.','.$WGS_X.' '; I let the script running on two diferent Servers with the same Mapserver-Installation: The first Server calculates the correct coordinates: WGS84: 50.010907,6.295043 http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.010907,6.295043&t=h&ie=UTF8&ll=50.010907,6.295043&spn=0.009542,0.015407&z=16&iwloc=near The second server calculates the wrong coordinates: WGS84: 50.012688,6.295651 http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.012688,6.295651&t=h&ie=UTF8&ll=50.012688,6.295651&spn=0.009542,0.015407&z=16&iwloc=near Both Servers have the same Mapscriptversion: MapServer version 5.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE What is wrong with the second installation? Is there a different geosversion, how can I test this? Thanks Sven From mlinden at zeelandnet.nl Fri Jul 3 03:00:57 2009 From: mlinden at zeelandnet.nl (Milo van der Linden) Date: Fri, 03 Jul 2009 12:00:57 +0200 Subject: [mapserver-users] ms_newprojectionobj In-Reply-To: <8FDF8C63762E42508281CC952663EC69@SVEN> References: <8FDF8C63762E42508281CC952663EC69@SVEN> Message-ID: <4A4DD6D9.7070400@zeelandnet.nl> Hello Sven, I suggest you search for a file called epsg on both systems. It is a text file containing EPSG projection parameters. Search both for <31466> and <4326> Compare the lines and check to see they match. Good luck! Sven Schroeter wrote: > Hi, > > I'm using php-mapscript to project a point from epsg:31466 > (Gauss-Krueger-Zone2) to epsg:4326 (WGS84): > > //create point > $qPoint = ms_newPointObj(); > $qPoint->setXY(2521189,5541667); > > // Calculate -> WGS84 > $projInObj = ms_newprojectionobj("init=epsg:31466"); > $projOutObj = ms_newprojectionobj("init=epsg:4326"); > $qPoint->project($projInObj, $projOutObj); > $WGS_X = round($qPoint->x,6); > $WGS_Y = round($qPoint->y,6); > echo 'WGS84: '.$WGS_Y.','.$WGS_X.' '; > > I let the script running on two diferent Servers with the same > Mapserver-Installation: > > The first Server calculates the correct coordinates: > WGS84: 50.010907,6.295043 > > http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.010907,6.295043&t=h&ie=UTF8&ll=50.010907,6.295043&spn=0.009542,0.015407&z=16&iwloc=near > > > > The second server calculates the wrong coordinates: > WGS84: 50.012688,6.295651 > > http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.012688,6.295651&t=h&ie=UTF8&ll=50.012688,6.295651&spn=0.009542,0.015407&z=16&iwloc=near > > > Both Servers have the same Mapscriptversion: > MapServer version 5.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP > OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG > SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT > SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER > SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS > INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE > > What is wrong with the second installation? Is there a different > geosversion, how can I test this? > Thanks > Sven > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From schroeter at netgis.de Fri Jul 3 03:28:09 2009 From: schroeter at netgis.de (Sven Schroeter) Date: Fri, 3 Jul 2009 12:28:09 +0200 Subject: [mapserver-users] ms_newprojectionobj References: <8FDF8C63762E42508281CC952663EC69@SVEN> <4A4DD6D9.7070400@zeelandnet.nl> Message-ID: <6B140D4AF8D74870AEA93DE1CF4B9EFA@SVEN> Hi, thanks for the hint, but I checkt the proj already, it's the same. I work with Windows and have the same proj-dir under C:\proj installed on both servers. Any idea? Sven ----- Original Message ----- From: "Milo van der Linden" To: "Sven Schroeter" Cc: Sent: Friday, July 03, 2009 12:00 PM Subject: Re: [mapserver-users] ms_newprojectionobj > Hello Sven, > > I suggest you search for a file called epsg on both systems. It is a > text file containing EPSG projection parameters. > Search both for <31466> and <4326> > Compare the lines and check to see they match. > > Good luck! > > Sven Schroeter wrote: >> Hi, >> >> I'm using php-mapscript to project a point from epsg:31466 >> (Gauss-Krueger-Zone2) to epsg:4326 (WGS84): >> >> //create point >> $qPoint = ms_newPointObj(); >> $qPoint->setXY(2521189,5541667); >> >> // Calculate -> WGS84 >> $projInObj = ms_newprojectionobj("init=epsg:31466"); >> $projOutObj = ms_newprojectionobj("init=epsg:4326"); >> $qPoint->project($projInObj, $projOutObj); >> $WGS_X = round($qPoint->x,6); >> $WGS_Y = round($qPoint->y,6); >> echo 'WGS84: '.$WGS_Y.','.$WGS_X.' '; >> >> I let the script running on two diferent Servers with the same >> Mapserver-Installation: >> >> The first Server calculates the correct coordinates: >> WGS84: 50.010907,6.295043 >> >> http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.010907,6.295043&t=h&ie=UTF8&ll=50.010907,6.295043&spn=0.009542,0.015407&z=16&iwloc=near >> >> >> >> The second server calculates the wrong coordinates: >> WGS84: 50.012688,6.295651 >> >> http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.012688,6.295651&t=h&ie=UTF8&ll=50.012688,6.295651&spn=0.009542,0.015407&z=16&iwloc=near >> >> >> Both Servers have the same Mapscriptversion: >> MapServer version 5.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP >> OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG >> SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT >> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER >> SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS >> INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE >> >> What is wrong with the second installation? Is there a different >> geosversion, how can I test this? >> Thanks >> Sven >> >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > From jmckenna at gatewaygeomatics.com Fri Jul 3 04:41:56 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Fri, 03 Jul 2009 08:41:56 -0300 Subject: [mapserver-users] ms_newprojectionobj In-Reply-To: <8FDF8C63762E42508281CC952663EC69@SVEN> References: <8FDF8C63762E42508281CC952663EC69@SVEN> Message-ID: <4A4DEE84.8070606@gatewaygeomatics.com> Sven Schroeter wrote: > > What is wrong with the second installation? Is there a different > geosversion, how can I test this? You could test it on both servers with a Windows package like MS4W (http://www.maptools.org/ms4w), so you are sure that the same library versions are used. -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From hans.wapenaar at gis-innovations.nl Fri Jul 3 05:33:33 2009 From: hans.wapenaar at gis-innovations.nl (Hans Wapenaar (GIS Innovations)) Date: Fri, 3 Jul 2009 14:33:33 +0200 Subject: [mapserver-users] ms_newprojectionobj In-Reply-To: <6B140D4AF8D74870AEA93DE1CF4B9EFA@SVEN> References: <8FDF8C63762E42508281CC952663EC69@SVEN> <4A4DD6D9.7070400@zeelandnet.nl> <6B140D4AF8D74870AEA93DE1CF4B9EFA@SVEN> Message-ID: <000001c9fbda$7ae4d830$70ae8890$@wapenaar@gis-innovations.nl> Hallo Sven, Did you check the environment variables PATH and PROJ_LIB? May be one of your servers refers to another project directory. Hans -----Oorspronkelijk bericht----- Van: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Namens Sven Schroeter Verzonden: vrijdag 3 juli 2009 12:28 Aan: Milo van der Linden CC: mapserver-users at lists.osgeo.org Onderwerp: Re: [mapserver-users] ms_newprojectionobj Hi, thanks for the hint, but I checkt the proj already, it's the same. I work with Windows and have the same proj-dir under C:\proj installed on both servers. Any idea? Sven ----- Original Message ----- From: "Milo van der Linden" To: "Sven Schroeter" Cc: Sent: Friday, July 03, 2009 12:00 PM Subject: Re: [mapserver-users] ms_newprojectionobj > Hello Sven, > > I suggest you search for a file called epsg on both systems. It is a > text file containing EPSG projection parameters. > Search both for <31466> and <4326> > Compare the lines and check to see they match. > > Good luck! > > Sven Schroeter wrote: >> Hi, >> >> I'm using php-mapscript to project a point from epsg:31466 >> (Gauss-Krueger-Zone2) to epsg:4326 (WGS84): >> >> //create point >> $qPoint = ms_newPointObj(); >> $qPoint->setXY(2521189,5541667); >> >> // Calculate -> WGS84 >> $projInObj = ms_newprojectionobj("init=epsg:31466"); >> $projOutObj = ms_newprojectionobj("init=epsg:4326"); >> $qPoint->project($projInObj, $projOutObj); >> $WGS_X = round($qPoint->x,6); >> $WGS_Y = round($qPoint->y,6); >> echo 'WGS84: '.$WGS_Y.','.$WGS_X.' '; >> >> I let the script running on two diferent Servers with the same >> Mapserver-Installation: >> >> The first Server calculates the correct coordinates: >> WGS84: 50.010907,6.295043 >> >> http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.010907,6.29504 3&t=h&ie=UTF8&ll=50.010907,6.295043&spn=0.009542,0.015407&z=16&iwloc=near >> >> >> >> The second server calculates the wrong coordinates: >> WGS84: 50.012688,6.295651 >> >> http://maps.google.de/maps?f=q&source=s_q&hl=de&geocode=&q=50.012688,6.29565 1&t=h&ie=UTF8&ll=50.012688,6.295651&spn=0.009542,0.015407&z=16&iwloc=near >> >> >> Both Servers have the same Mapscriptversion: >> MapServer version 5.0.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP >> OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG >> SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT >> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER >> SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS >> INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE >> >> What is wrong with the second installation? Is there a different >> geosversion, how can I test this? >> Thanks >> Sven >> >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From schroeter at netgis.de Fri Jul 3 05:52:42 2009 From: schroeter at netgis.de (Sven Schroeter) Date: Fri, 3 Jul 2009 14:52:42 +0200 Subject: [mapserver-users] ms_newprojectionobj References: <8FDF8C63762E42508281CC952663EC69@SVEN> <4A4DEE84.8070606@gatewaygeomatics.com> Message-ID: Hi Jeff, thank you for your reply. I got the failure: in my proj-file the epsgcode is following: <31466> +proj=tmerc +lat_0=0 +lon_0=6 +k=1.000000 +x_0=2500000 +y_0=0 +ellps=bessel +units=m +no_defs no_defs <> But it must be: <31466> +proj=tmerc +lat_0=0 +lon_0=6 +k=1.000000 +x_0=2500000 +y_0=0 +ellps=bessel +datum=potsdam +units=m +no_defs <> There is no definition of the datum. That makes the wrong coordinates. I didn't see it because one Server had a PROJ_NAD System variable on the correct proj-file Sven ----- Original Message ----- From: "Jeff McKenna" To: Sent: Friday, July 03, 2009 1:41 PM Subject: Re: [mapserver-users] ms_newprojectionobj > Sven Schroeter wrote: >> >> What is wrong with the second installation? Is there a different >> geosversion, how can I test this? > > You could test it on both servers with a Windows package like MS4W > (http://www.maptools.org/ms4w), so you are sure that the same library > versions are used. > > -jeff > > > > -- > Jeff McKenna > FOSS4G Consulting and Training Services > http://www.gatewaygeomatics.com/ > > > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From info at petersthorsten.de Fri Jul 3 06:38:01 2009 From: info at petersthorsten.de (Thorsten Peters) Date: Fri, 3 Jul 2009 15:38:01 +0200 Subject: [mapserver-users] bgd_i.lib Message-ID: <7ee095bb0907030638g570a3443x9f80a93b06a3144d@mail.gmail.com> Hi, I trying to compile mapserver 5.4.1 for Windows. In the nmake.opt file I need to address the bgd_i.lib file from GDlib. I can't find this file anywhere. Thanks in advance, Thorsten -------------- next part -------------- An HTML attachment was scrubbed... URL: From yassefa at dmsolutions.ca Fri Jul 3 07:01:59 2009 From: yassefa at dmsolutions.ca (Yewondwossen Assefa) Date: Fri, 03 Jul 2009 10:01:59 -0400 Subject: [mapserver-users] SLD-Integration with UMN Mapserver In-Reply-To: References: Message-ID: <4A4E0F57.2050501@dmsolutions.ca> Hi there, The wms_sld_url metadata is used on WMS layers (wms client) in the map file, so that when a GetMap request is done to retrieve the layer from a remote WMS server, the SLD is sent in the request and used by the remote WMS server to style the layer. Is that your understanding and what you attempted? There is no way currently to use the styling out of an sld on a map/layer by specifying it in the map file. There is a possibility to do so using Mapscript's functions applysld (on map and layer objects). Best regards, Sebastian Luhmer wrote: > Hi everybody, > > does anybody know, how I can integrate SLD-Files with the UMN Mapserver? > According to the Mapserver documentation, this can be done by adding > wms_sld_url in the Metadta-Part within the Layer-Description in the > Mapfile and pointing to a remote SLD File. > I have done all this, but the layer ist stylied by the > styling-information contained in the mapfile and not by the SLD-File > (like it sholuld be. > > Can anybody give me a hint, how i can embedd SLD Files with Mapserver? > > Best regards, Sebastian! > > ------------------------------ > Sebastian Luhmer > Student assistant > Center for Development Research > Department of Ecology and Resource Management > Walter-Flex-Strasse 3 > 53113 Bonn (Germany) > > Tel.: +49 (0) 228 - 73-1793 > FAX: +49 (0) 228 - 73-1889 > > E-Mail: sluhmer at uni-bonn.de > Web: http://www.coffee.uni-bonn.de > http://www.zef.de > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From yassefa at dmsolutions.ca Fri Jul 3 07:38:14 2009 From: yassefa at dmsolutions.ca (Yewondwossen Assefa) Date: Fri, 03 Jul 2009 10:38:14 -0400 Subject: [mapserver-users] Problem with WFS Filter In-Reply-To: References: Message-ID: <4A4E17D6.2030309@dmsolutions.ca> Hi, I don't see any obvious problem with your filter. Can you try to set the filter element on your layer to an expression equivalent to your wfs filter, (assuming that the underlying data is a shape/OGR), something like this: FILTER (([von_pegel] >= 70 or [bis_pegel] < > 70) and '[datumzeit]' = '2009-07-09 12:00:00') and see if you get what you expect. If you get what you expect, you can send me off line your map/data and I can look at it using the wfs filter. best regards Erg?n Ayduran (GMX) wrote: > Hi, > > i want to filter set a filter in a wfs request: > I want to get all polygons, where ("von_pegel" >= 70 or "bis_pegel" < > 70) and datumzeit = 2009-07-09 12:00:00. > I tried it with the request: > > http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00 von_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00> > > and with this request (is the same request,without %20 in date) > > http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09 > von_pegel70bis_pegel70datumzeit2009-07-09> > 12:00:00 > > Both requests response me only all polygons. > > Example: > (1) 0 - 50 > (2) 50 - 100 > (3) 100 - 150 > (4) 150 - 200 > > Setting the filter should response only (2), (3) and (4) > Plz, can anyone tell me, what is wrong in my filter. > > EA > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From youness.elmedraoui at somei.fr Fri Jul 3 07:44:42 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Fri, 3 Jul 2009 16:44:42 +0200 Subject: [mapserver-users] display map - mapscript Message-ID: An HTML attachment was scrubbed... URL: From szekerest at gmail.com Fri Jul 3 09:07:53 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Fri, 3 Jul 2009 18:07:53 +0200 Subject: [mapserver-users] bgd_i.lib In-Reply-To: <7ee095bb0907030638g570a3443x9f80a93b06a3144d@mail.gmail.com> References: <7ee095bb0907030638g570a3443x9f80a93b06a3144d@mail.gmail.com> Message-ID: Hi Thorsten, You can download the SDK packages containing all the required files to compile MapServer with Visual Studio: http://vbkto.dyndns.org:1280/sdk/Default.aspx To compile just type 'nmake ms' in the root directory with the Visual Studio command prompt. Best regards, Tamas 2009/7/3 Thorsten Peters > Hi, > I trying to compile mapserver 5.4.1 for Windows. > In the nmake.opt file I need to address the bgd_i.lib file from GDlib. > I can't find this file anywhere. > > Thanks in advance, > > Thorsten > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at pobox.com Fri Jul 3 09:19:42 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Fri, 03 Jul 2009 12:19:42 -0400 Subject: [mapserver-users] Question About WCS In-Reply-To: <8EA33237DDDB244E860ADDE976124AE50202CBD7@ONOTTAXMS2.AGR.GC.CA> References: <8EA33237DDDB244E860ADDE976124AE50202CBD7@ONOTTAXMS2.AGR.GC.CA> Message-ID: <4A4E2F9E.8020706@pobox.com> Dillabough, Craig wrote: > Hi, > I am brand new to MapServer, and I am trying to figure out WCS. > > I've been following the instructions on > http://mapserver.org/ogc/wcs_server.html > and was making some progress as executing a GetCapabilities request > returns what I was expecting. However when I try to execute a > DescribeCoverage request I only see the following: > > > version="1.0.0" > updateSequence="0" > ... Etc .... > xsi:schemaLocation="http://www.opengis.net/wcs > http://schemas.opengis.net/wcs/1.0.0/describeCoverage.xsd"> > > > Based on the tutorial I am also expecting to see a CoverageOffering > element as well with something like: > > > week19 > > ... Etc .... > ... > If anyone can see anything obvious as to why I am not getting the > expected result I would greatly appreciate some advice. Craig, You did not provide the request you issued in your email. I am suspecting there is an issue with the name of the coverage you requested to be described but I would need to see the request issued. If the server is public it would also be helpful to know the url so I could experiment against it. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From Craig.Dillabough at AGR.GC.CA Fri Jul 3 09:52:58 2009 From: Craig.Dillabough at AGR.GC.CA (Dillabough, Craig) Date: Fri, 3 Jul 2009 12:52:58 -0400 Subject: [mapserver-users] Question About WCS In-Reply-To: <4A4E3505.7000101@pobox.com> Message-ID: <8EA33237DDDB244E860ADDE976124AE50202CBD9@ONOTTAXMS2.AGR.GC.CA> Frank, With: http://chernozem.gis.agr.gc.ca/cgi-bin/mapserv?map=%2Fopt%2Fmapserver%2F ms_data%2Fhtdocs%2Fwcs.map&SERVICE=WCS&VERSION=1.0.0&REQUEST=GetCapabili ties I get: Some text description of the service MapServer WCS wcs test ...clipped .... none none application/vnd.ogc.se_xml Craig -----Original Message----- From: Frank Warmerdam [mailto:warmerdam at pobox.com] Sent: Friday, July 03, 2009 12:43 PM To: Dillabough, Craig Subject: Re: [mapserver-users] Question About WCS Dillabough, Craig wrote: > The URL is: > > http://chernozem.gis.agr.gc.ca/cgi-bin/mapserv?map=%2Fopt%2Fmapserver%2F > ms_data%2Fhtdocs%2Fwcs.map&SERVICE=WCS&VERSION=1.0.0&REQUEST=DescribeCov > erage&COVERAGE=week19 > > I am pretty sure this is unavailable to the outside world but you can > try it! Craig, I have reviewed the request url, the .map and the code and I can't see any obvious reason it would not be working. It should be returning a coverage description for the requested layer. You might want to try omitting the &COVERAGE= request in which case it should try to describe all coverages. It might also be helpful to see the capabilities you are getting. I can confirm the service is not externally visible. Best regards, -- ---------------------------------------+-------------------------------- ------ I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From szekerest at gmail.com Fri Jul 3 12:20:22 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Fri, 3 Jul 2009 21:20:22 +0200 Subject: [mapserver-users] display map - mapscript In-Reply-To: References: Message-ID: using(imageObj image = map.draw()) { byte[] img = image.getBytes(); Response.BinaryWrite(img); } Best regards, Tamas 2009/7/3 > Hello, > > i want to displat my data (mapfile) on asp .net page. i programming with vb > .net. > this statement "pMap = New > mapObj("C:\test_mapServ_vb\App_Data\vbmapfilel.map")" is work, but i want to > see my data displayed in my aspx page. what the code source i need to do? > > thanks > > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Fri Jul 3 12:46:23 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Fri, 03 Jul 2009 16:46:23 -0300 Subject: [mapserver-users] bgd_i.lib In-Reply-To: <7ee095bb0907030638g570a3443x9f80a93b06a3144d@mail.gmail.com> References: <7ee095bb0907030638g570a3443x9f80a93b06a3144d@mail.gmail.com> Message-ID: <4A4E600F.5060901@gatewaygeomatics.com> Thorsten Peters wrote: > Hi, > > I trying to compile mapserver 5.4.1 for Windows. > In the nmake.opt file I need to address the bgd_i.lib file from GDlib. > I can't find this file anywhere. > > Thanks in advance, > > Thorsten Hi Thorsten, Here is what I use for that section of nmake.opt: !IFNDEF GD_DIR GD_DIR=$(MS_BASE)\..\gd-2.0.35 GD_LIB=$(GD_DIR)/gd.lib !ENDIF -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From erguen.ay at gmx.de Fri Jul 3 23:47:05 2009 From: erguen.ay at gmx.de (=?iso-8859-1?Q?Erg=FCn_Ayduran_=28GMX=29?=) Date: Sat, 4 Jul 2009 08:47:05 +0200 Subject: [mapserver-users] Problem with WFS Filter References: <4A4E17D6.2030309@dmsolutions.ca> Message-ID: <0D64B792FDED42FEAA9F81368E4AB63B@eapc> Thx for your answer, i have solved the problem. The filter is ok i think the problem was: First, i edited the filter in notepad++ an than copied and pasted it in firefox. I think this caused the problem, because some "undefined" characters were also copied (but i dont know which characters!?!) When i edit the filter in a php-script, i get the right response. ----- Original Message ----- From: "Yewondwossen Assefa" To: ""Erg?n Ayduran (GMX)"" Cc: Sent: Friday, July 03, 2009 4:38 PM Subject: Re: [mapserver-users] Problem with WFS Filter > Hi, > > I don't see any obvious problem with your filter. Can you try to set the > filter element on your layer to an expression equivalent to your wfs > filter, (assuming that the underlying data is a shape/OGR), something like > this: FILTER (([von_pegel] >= 70 or [bis_pegel] < > > 70) and '[datumzeit]' = '2009-07-09 12:00:00') and see if you get > what you expect. If you get what you expect, you can send me off line > your map/data and I can look at it using the wfs filter. > > best regards > > > Erg?n Ayduran (GMX) wrote: >> Hi, >> i want to filter set a filter in a wfs request: >> I want to get all polygons, where ("von_pegel" >= 70 or "bis_pegel" < 70) >> and datumzeit = 2009-07-09 12:00:00. >> I tried it with the request: >> >> http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00> von_pegel70bis_pegel70datumzeit2009-07-09%2012:00:00> >> and with this request (is the same request,without %20 in date) >> >> http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/webgis/mapfile_wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=flood&Filtervon_pegel70bis_pegel70datumzeit2009-07-09 >> von_pegel70bis_pegel70datumzeit2009-07-09> >> 12:00:00 >> Both requests response me only all polygons. >> Example: >> (1) 0 - 50 >> (2) 50 - 100 >> (3) 100 - 150 >> (4) 150 - 200 >> Setting the filter should response only (2), (3) and (4) >> Plz, can anyone tell me, what is wrong in my filter. >> EA >> >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > -- > ---------------------------------------------------------------- > Assefa Yewondwossen > Software Analyst > > Email: assefa at dmsolutions.ca > http://www.dmsolutions.ca/ > > Phone: (613) 565-5056 (ext 14) > Fax: (613) 565-0925 > ---------------------------------------------------------------- From wal3 at mindspring.com Sun Jul 5 14:56:56 2009 From: wal3 at mindspring.com (Worth Lutz) Date: Sun, 5 Jul 2009 17:56:56 -0400 Subject: [mapserver-users] point layer symbols Message-ID: <3684FED92D7A43618E4C56EDCE0ADB93@Worthlaptop> Can anyone help describe how point symbols defined as type vector are placed upon the point on the map. My symbol and layer are listed below. I get a good looking symbols. My problem occurs when clicking on this symbol (and others like a triangle) to query it. If I click at the bottom of the airplane, I often get no results. If I click above the top of the airplane, I can get results. Raising the tolerance causes multiple results when the symbols are close together but not touching. How is the box surrounding the symbol (the bounds of the symbol) placed upon the point on the map? And how does size 9 in the class definition relate to the size of this box? Can anyone shed some light on this for me? Thanks, Worth SYMBOL NAME 'airplane' TYPE vector POINTS 7 0 6 1 6 3 0 4 0 6 6 5 6 8 3 8 3 9 11 9 11 8 8 8 8 5 14 6 14 4 8 3 8 1 7 0 END FILLED TRUE END LAYER NAME "airports" STATUS OFF TYPE POINT DATA "air" PROJECTION "init=epsg:32119" # NAD 83 North Carolina (meters US) END MAXSCALEDENOM 3750001 TOLERANCE 7 CLASSITEM "CLASS" LABELITEM "ARPT_NAME" CLASS NAME "Major Airport" EXPRESSION "MAJOR AIRPORT" COLOR 139 0 139 TEMPLATE 'void' SYMBOL 'airplane' SIZE 9 LABEL TYPE TRUETYPE MINFEATURESIZE 50 MINDISTANCE 150 POSITION UC FONT vera SIZE 7 #SIZE SMALL COLOR 139 0 139 END END # ** MORE SIMILAR CLASSES HERE *** END -------------- next part -------------- An HTML attachment was scrubbed... URL: From rpinho_eng at yahoo.com.br Sun Jul 5 17:30:07 2009 From: rpinho_eng at yahoo.com.br (Ricardo Pinho) Date: Sun, 5 Jul 2009 17:30:07 -0700 (PDT) Subject: [mapserver-users] GISVM Server pre-release available Message-ID: <813483.11620.qm@web65708.mail.ac4.yahoo.com> Dear all, The first public pre-release version of ?GIS Virtual Machine Server? is available at: http://www.gisvm.com GISVM Server is another product based on the GISVM new concept for a Free Open Source GIS Software distribution. With it you get a full feature Free (dom) GIS Server, ready for you to use with your favorite GIS desktop application! GISVM Server includes: - Ubuntu 9.04 Server Edition JeOS (Just enough OS) - LAMP Server bundle (Linux, Apache, MySQL and PHP) - Samba File Server - Tomcat Java Server - PostgreSQL database server - PostGIS (PostgreSQL spatial extension), ZigGIS and FDO ready! - Mapserver - Geoserver - Deegree - Webmin (a web-based interface for GISVM Server administration) If you think this is a useful and interesting product, please help us with your participation on the beta testing forum board: http://gisvm.com/forum/index.php?board=6.0 Thank you for your time and collaboration! Best regards, Ricardo Pinho ____________________________________________________________________________________ Veja quais s?o os assuntos do momento no Yahoo! +Buscados http://br.maisbuscados.yahoo.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From Dejan.Gambin at pula.hr Sun Jul 5 22:11:10 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Mon, 6 Jul 2009 07:11:10 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <4A4C71500200008F00025A23@co5.dnr.state.mn.us> Message-ID: Hi, Sorry to bother again. Is there anyone been successful in getting GeoJSON output from MapServer? Is there any example or documentation on this? best regards, dejan "Steve Lime" wrote on 02.07.2009 15:35:28: > What does myTemplate.js look like? > > >>> 07/02/09 5:33 AM >>> > Thanks Fabio, > > As I said in my last post, I can't get GeoJSON output using this > outputformat: > > OUTPUTFORMAT > NAME 'geojson' > DRIVER 'TEMPLATE' > MIMETYPE 'application/json; subtype=geojson' > FORMATOPTION 'FILE=myTemplate.js' > END > > :-( > > regards, dejan > > Fabio D'Ovidio wrote on 02.07.2009 09:28:06: > > > Hi, > > > > Dejan.Gambin at pula.hr ha scritto: > > > > > > Fabio, > > > > > > Glad to here you are here too :-) > > > > > > I can certainly use both GeoServer and MapServer but this is not > > > something I would like at the end. Since I am still investigating all > > > this, I am not in such a hurry to get it working with my data ASAP. > > > So, I would rather go with one of your Mapserver solutions. > > It is not so difficult...just 2, 3 minutes to load your layer in > > GeoServer ;-) > > > > > > > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > > > understand Steve correctly, there is no way currently to get GeoJSON > > > output from MapServer WFS, only with CGI? So we come to your solution > 2. > > > > If you want to use the second solution you must create the HTTP string > > to get GeoJSON from CGI-MapServer and than you must change MapOl request > > > to receive data and read them. > > If you want send me the URL and I'll send you the new MapOl as soon as > > possbile! > > > > > > -- > > Fabio D'Ovidio > > Geospatial solutions > > > > Inova S.r.l. > > Web : http://www.inovaos.it > > GeoBI Blog: www.geobi.org > > Tel.: 081 197 57 600 > > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it > > skype: dovidio_fa > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Mon Jul 6 03:30:21 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Mon, 6 Jul 2009 12:30:21 +0200 Subject: =?ISO-8859-1?Q?[Mapserver-users]_probl=E8me_with_zoompoint_=28Mapserver?= =?ISO-8859-1?Q?_with_vb_=2Enet=29?= In-Reply-To: References: Message-ID: An HTML attachment was scrubbed... URL: From jkapalczynski at ci.maple-grove.mn.us Mon Jul 6 08:30:46 2009 From: jkapalczynski at ci.maple-grove.mn.us (Jay Kapalczynski) Date: Mon, 6 Jul 2009 10:30:46 -0500 Subject: [mapserver-users] plotting points dynamically In-Reply-To: <4A49E2B8.163B.00A8.0@ci.stpaul.mn.us> References: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15B4@sc-exchange.addisongov.org> <4A49E2B8.163B.00A8.0@ci.stpaul.mn.us> Message-ID: Suman I am doing this another way.... Although I am using GeoMoose/MapServer... I am using an OGR connection in my map file to connect to a MySQL database via a OVF file....this is plotting Points based on XY Coordinates, which is querying the database. I am would have to look up again what I am doing if you are interested in this. Is this something like you are doing Bobb. I am not familiar with the Query/Render engine in map server. Jay From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Bob Basques Sent: Tuesday, June 30, 2009 10:03 AM To: Suman Chatterjee; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] plotting points dynamically The best approach I can think of, would be to figure out how to add the points to the database in a dynamic method, and use MapServer as the Query/Render engine. This is how we do GPS location points for example. The points are loaded into the Database (POSTGIS) and simply (re)read as a display request by MapServer. Just set up both sides, the Database and the MapServer connectivity to the database as two separate processes, and that should get you what you are after. bobb >>> "Suman Chatterjee" wrote: Hi all, I am working on a project which requires adding points to a basic map dynamically. That means the basic map will be read from the map file. Then the points will be queried from a database preferably PostGreSQL and then plotted on the map. I cannot add the query to the map file because the points will be generated dynamically at regular intervals. Is there any way I can do this in mapserver? ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Mon Jul 6 08:47:51 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Mon, 06 Jul 2009 10:47:51 -0500 Subject: [mapserver-users] point layer symbols In-Reply-To: <3684FED92D7A43618E4C56EDCE0ADB93@Worthlaptop> References: <3684FED92D7A43618E4C56EDCE0ADB93@Worthlaptop> Message-ID: <4A51D656.5157.008F.0@dnr.state.mn.us> Hi Worth: When you define a vector symbol you're essentially defining a default size as well (I believe) relative to 0,0. The SIZE you set is then used to scale the symbol based on that default size. If things are anchored to 0,0 then it generally works ok. I always try to work on the unit square (0,0,1,1) when defining symbols although that's not required. Being relative to 0,0 is important. Anyway, a symbol is always centered on the point. Where the actual point is depends on how you laid out the symbol. To see this try adding another styleObj after your main symbol like so: CLASS NAME "Major Airport" EXPRESSION "MAJOR AIRPORT" STYLE COLOR 139 0 139 SYMBOL 'airplane' SIZE 9 END STYLE # a red pixel COLOR 255 0 0 END ... END You should see a red pixel over your airplane. That may help explain why you see the clicking issues you do. The placement is based on the bounds of the symbol (0,0,maxx, maxy) so if a symbol is defined well away from 0,0 then odd things can happen. We hope to fix this in upcoming releases. If you're having trouble with multiple results why not use mode=query instead of nquery? Steve >>> On 7/5/2009 at 4:56 PM, in message <3684FED92D7A43618E4C56EDCE0ADB93 at Worthlaptop>, "Worth Lutz" wrote: > Can anyone help describe how point symbols defined as type vector are placed > upon the point on the map. > > My symbol and layer are listed below. I get a good looking symbols. > > > > My problem occurs when clicking on this symbol (and others like a triangle) > to query it. > > > > If I click at the bottom of the airplane, I often get no results. > > > > If I click above the top of the airplane, I can get results. > > > > Raising the tolerance causes multiple results when the symbols are close > together but not touching. > > > > How is the box surrounding the symbol (the bounds of the symbol) placed upon > the point on the map? And how does size 9 in the class definition relate to > the size of this box? Can anyone shed some light on this for me? > > > > Thanks, > > Worth > > > > SYMBOL > > NAME 'airplane' > > TYPE vector > > POINTS > > 7 0 > > 6 1 > > 6 3 > > 0 4 > > 0 6 > > 6 5 > > 6 8 > > 3 8 > > 3 9 > > 11 9 > > 11 8 > > 8 8 > > 8 5 > > 14 6 > > 14 4 > > 8 3 > > 8 1 > > 7 0 > > END > > FILLED TRUE > > END > > > > LAYER > > NAME "airports" > > STATUS OFF > > TYPE POINT > > DATA "air" > > PROJECTION > > "init=epsg:32119" # NAD 83 North Carolina (meters US) > > END > > MAXSCALEDENOM 3750001 > > TOLERANCE 7 > > CLASSITEM "CLASS" > > LABELITEM "ARPT_NAME" > > CLASS > > NAME "Major Airport" > > EXPRESSION "MAJOR AIRPORT" > > COLOR 139 0 139 > > TEMPLATE 'void' > > SYMBOL 'airplane' > > SIZE 9 > > LABEL > > TYPE TRUETYPE > > MINFEATURESIZE 50 > > MINDISTANCE 150 > > POSITION UC > > FONT vera > > SIZE 7 > > #SIZE SMALL > > COLOR 139 0 139 > > END > > END > > # ** MORE SIMILAR CLASSES HERE *** > > END > > From Steve.Lime at dnr.state.mn.us Mon Jul 6 09:00:03 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Mon, 06 Jul 2009 11:00:03 -0500 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: References: <4A4C71500200008F00025A23@co5.dnr.state.mn.us> Message-ID: <4A51D932.5157.008F.0@dnr.state.mn.us> Two things: 1) TEMPLATE is a keyword and must be quoted at the moment, so use DRIVER 'TEMPLATE' 2) The file to be used in the OUTPUTFORMAT is given like this: FORMATOPTION 'FILE=/some/template/file/...' 3) You're call to MapServer needs to be a query. For example: http://localhost/cgi-bin/mapserv.exe?map=/ms4w/apps/pmapper/pmapper-3.2.0/config/default/geojson_demo.map&layer=countries&mode=nquery&qformat=geojson This call will use all the default EXTENT value in the mapfile to query all eligible layers and run the results through the geojson driver. I'm doing this to produce javascript code that gets executed by an Ext.JS component. Not purely GeoJSON but it works similarly. Steve >>> On 7/2/2009 at 4:15 PM, in message , wrote: > Steve, > > Is there any GeoJSON example I can see? I must be missing something > trivial, > > When I put: > > OUTPUTFORMAT > NAME 'geojson' > DRIVER TEMPLATE > MIMETYPE 'application/json; subtype=geojson' > TEMPLATE 'myTemplate.js' > END > > in my.map file and call for example > "http://localhost/cgi-bin/mapserv.exe?map=/ms4w/apps/pmapper/pmapper-3.2.0/con > fig/default/geojson_demo.map&layer=countries" > (this works correctly without geojson part), I get: getString(): Symbol > definition error. Parsing error near (TEMPLATE):(line 74) > > If I put DRIVER 'TEMPLATE' then I get: loadOutputFormat(): Unknown > identifier. Parsing error near (TEMPLATE):(line 76) > > Finally, putting FORMATOPTION 'FILE=myTemplate.js' instead of TEMPLATE > gives me: loadOutputFormat(): General error message. OUTPUTFORMAT clause > references driver TEMPLATE, but this driver isn't configured. > > So, I am obviously doing something wrong regardless the myTemplate.js > file? (anyway, can you give me an example .js file, anything that could > help :-) > > regards, dejan > "Steve Lime" wrote on 02.07.2009 15:35:28: > >> What does myTemplate.js look like? >> >> >>> 07/02/09 5:33 AM >>> >> Thanks Fabio, >> >> As I said in my last post, I can't get GeoJSON output using this >> outputformat: >> >> OUTPUTFORMAT >> NAME 'geojson' >> DRIVER 'TEMPLATE' >> MIMETYPE 'application/json; subtype=geojson' >> FORMATOPTION 'FILE=myTemplate.js' >> END >> >> :-( >> >> regards, dejan >> >> Fabio D'Ovidio wrote on 02.07.2009 09:28:06: >> >> > Hi, >> > >> > Dejan.Gambin at pula.hr ha scritto: >> > > >> > > Fabio, >> > > >> > > Glad to here you are here too :-) >> > > >> > > I can certainly use both GeoServer and MapServer but this is not >> > > something I would like at the end. Since I am still investigating > all >> > > this, I am not in such a hurry to get it working with my data ASAP. >> > > So, I would rather go with one of your Mapserver solutions. >> > It is not so difficult...just 2, 3 minutes to load your layer in >> > GeoServer ;-) >> > >> > > >> > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > >> > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I >> > > understand Steve correctly, there is no way currently to get GeoJSON > >> > > output from MapServer WFS, only with CGI? So we come to your > solution >> 2. >> > >> > If you want to use the second solution you must create the HTTP string > >> > to get GeoJSON from CGI-MapServer and than you must change MapOl > request >> >> > to receive data and read them. >> > If you want send me the URL and I'll send you the new MapOl as soon as > >> > possbile! >> > >> > >> > -- >> > Fabio D'Ovidio >> > Geospatial solutions >> > >> > Inova S.r.l. >> > Web : http://www.inovaos.it >> > GeoBI Blog: www.geobi.org >> > Tel.: 081 197 57 600 >> > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it >> > skype: dovidio_fa >> > >> From wal3 at mindspring.com Mon Jul 6 18:20:00 2009 From: wal3 at mindspring.com (Worth Lutz) Date: Mon, 6 Jul 2009 21:20:00 -0400 Subject: [mapserver-users] point layer symbols In-Reply-To: <4A51D656.5157.008F.0@dnr.state.mn.us> References: <3684FED92D7A43618E4C56EDCE0ADB93@Worthlaptop> <4A51D656.5157.008F.0@dnr.state.mn.us> Message-ID: <58C27E0A1EE44259B8699FF3F728B336@Worthlaptop> Thanks for the help. The red pixel trick allows me to see the point. It is in the center of the plane and it looks like I have about a 10 pixel wingspan for the chosen SIZE 9. Now my question is about the tolerance. Does "TOLERANCE 5" mean a 5 pixel radius or a 5 pixel diameter? I'm querying with PHP mapscript and expect multiple results in some cases where items are very close together. I'm just seeing some multiples where I do not expect them, but this may be due to the TOLERANCE being set too high. I'm still playing to get a grip on how this works. -----Original Message----- From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Sent: Monday, July 06, 2009 11:48 AM To: mapserver-users at lists.osgeo.org; Worth Lutz Subject: Re: [mapserver-users] point layer symbols Hi Worth: When you define a vector symbol you're essentially defining a default size as well (I believe) relative to 0,0. The SIZE you set is then used to scale the symbol based on that default size. If things are anchored to 0,0 then it generally works ok. I always try to work on the unit square (0,0,1,1) when defining symbols although that's not required. Being relative to 0,0 is important. Anyway, a symbol is always centered on the point. Where the actual point is depends on how you laid out the symbol. To see this try adding another styleObj after your main symbol like so: CLASS NAME "Major Airport" EXPRESSION "MAJOR AIRPORT" STYLE COLOR 139 0 139 SYMBOL 'airplane' SIZE 9 END STYLE # a red pixel COLOR 255 0 0 END ... END You should see a red pixel over your airplane. That may help explain why you see the clicking issues you do. The placement is based on the bounds of the symbol (0,0,maxx, maxy) so if a symbol is defined well away from 0,0 then odd things can happen. We hope to fix this in upcoming releases. If you're having trouble with multiple results why not use mode=query instead of nquery? Steve >>> On 7/5/2009 at 4:56 PM, in message <3684FED92D7A43618E4C56EDCE0ADB93 at Worthlaptop>, "Worth Lutz" wrote: > Can anyone help describe how point symbols defined as type vector are placed > upon the point on the map. > > My symbol and layer are listed below. I get a good looking symbols. > > > > My problem occurs when clicking on this symbol (and others like a triangle) > to query it. > > > > If I click at the bottom of the airplane, I often get no results. > > > > If I click above the top of the airplane, I can get results. > > > > Raising the tolerance causes multiple results when the symbols are close > together but not touching. > > > > How is the box surrounding the symbol (the bounds of the symbol) placed upon > the point on the map? And how does size 9 in the class definition relate to > the size of this box? Can anyone shed some light on this for me? > > > > Thanks, > > Worth > > > > SYMBOL > > NAME 'airplane' > > TYPE vector > > POINTS > > 7 0 > > 6 1 > > 6 3 > > 0 4 > > 0 6 > > 6 5 > > 6 8 > > 3 8 > > 3 9 > > 11 9 > > 11 8 > > 8 8 > > 8 5 > > 14 6 > > 14 4 > > 8 3 > > 8 1 > > 7 0 > > END > > FILLED TRUE > > END > > > > LAYER > > NAME "airports" > > STATUS OFF > > TYPE POINT > > DATA "air" > > PROJECTION > > "init=epsg:32119" # NAD 83 North Carolina (meters US) > > END > > MAXSCALEDENOM 3750001 > > TOLERANCE 7 > > CLASSITEM "CLASS" > > LABELITEM "ARPT_NAME" > > CLASS > > NAME "Major Airport" > > EXPRESSION "MAJOR AIRPORT" > > COLOR 139 0 139 > > TEMPLATE 'void' > > SYMBOL 'airplane' > > SIZE 9 > > LABEL > > TYPE TRUETYPE > > MINFEATURESIZE 50 > > MINDISTANCE 150 > > POSITION UC > > FONT vera > > SIZE 7 > > #SIZE SMALL > > COLOR 139 0 139 > > END > > END > > # ** MORE SIMILAR CLASSES HERE *** > > END > > From tohashmi at gmail.com Mon Jul 6 22:27:52 2009 From: tohashmi at gmail.com (Hussain Hashmi) Date: Tue, 7 Jul 2009 08:27:52 +0300 Subject: [mapserver-users] Fwd: queryByPoint - Street Layer ? In-Reply-To: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> References: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> Message-ID: <28aabd160907062227o2d0fb82y9eee322bc75e4cff@mail.gmail.com> ---------- Forwarded message ---------- From: mir m. Hashmi Date: Mon, Jul 6, 2009 at 4:11 PM Subject: queryByPoint - Street Layer ? To: "mapserver-users at lists.osgeo.org" Hello Can anyone please guide me on this issue. My Objective is to get attribute values for any selected street (Line). My client application is based on KaMap. I have a similar solution for Polygons which works perfectly. I am trying to query a street layer which gives me the following error. Warning: [MapServer Error]: msQueryByPoint(): No matching record(s) found in C:\... on line 84 Warning: [MapServer Error]: msShapefileOpen(): (/ms4w/maps/./city/./city/streets) in c:\... on line 84 MAPFILE ********************** LAYER NAME 'streets_Query' GROUP 'streets_Query' DATA './city/streets' TYPE line MAXSCALE 3001 STATUS ON TOLERANCE 5 TEMPLATE './_templates/Streets_Identify.html' METADATA "queryable" "true" searchfield "ANAME" fields "ZIP_CODE" END END #end layer PHP MAPSCRIPT ********************** //------- Get Input Parameters. if (isset($_REQUEST['map'])) {$szMap = $_REQUEST['map'];} else {echo "map not defined"; die;} if (isset($_REQUEST['coords'])) {$coords = explode(',',$_REQUEST['coords']);} else {echo "coordinate not defined"; die;} //------- Load Mapscript Module. $szPHPMapScriptModule = 'php_mapscript.'.PHP_SHLIB_SUFFIX; if (!extension_loaded('MapScript')) { dl($szPHPMapScriptModule); } //------- Load Current Map file. $szMapFile=str_replace('<>',$szMap,'/ms4w/maps/<>.map'); $oMap = ms_newMapObj($szMapFile); //------- SETTING MAP EXTENT to query extent.. $mapExtent = $oMap->extent; $oMap->setExtent($coords[0],$coords[1], $coords[0]+0.000001,$coords[1]+0.000001); //------- SETTING QUERY POINT $point = ms_newPointObj(); $point->setXY($coords[0], $coords[1]); //------- Initialize map query. $oMap->preparequery(); //------- LOOP ON LAYERS and get identify results. $tot = $oMap->numlayers; for ($i = 0; $i < $tot; $i++) { //------- get map layer. $oLayer = $oMap->getLayer($i); //------- Verify Layer type if ($oLayer->name != 'streets_Query') continue; //------- Validate if query succeeds. $check_query = $oLayer->queryByPoint($point, MS_SINGLE, 0); if ($check_query != MS_SUCCESS) {continue;} //------- Open layer for data input. $oLayer->open(); //------- Get the record values corresponding to a result tileindex. $oResultCache = $oLayer->getResult(0); $oShape = $oLayer->getShape($oResultCache->tileindex, $oResultCache->shapeindex); $aValues = $oShape->values; //------- Get the field value. echo $aValues['ZIP_CODE']; echo ";"; //------- FREE SHAPE $oShape->free(); $oLayer->close(); break; } // for i Best regards, Mir Hashmi ------------------------------ This message may contain confidential and/or privileged information. If you have received this message in error,please notify us immediately by responding to this e-mail and delete it from your system. Thanks for your cooperation. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Dejan.Gambin at pula.hr Mon Jul 6 23:37:54 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Tue, 7 Jul 2009 08:37:54 +0200 Subject: [mapserver-users] GeoJSON output from MapServer In-Reply-To: <4A51D932.5157.008F.0@dnr.state.mn.us> Message-ID: Thanks Steve, I did all that and I get: loadOutputFormat(): General error message. OUTPUTFORMAT clause references driver TEMPLATE, but this driver isn't configured. Do I have an older MapServer version? Currently, I run this on ms4w 2.2.7 (MapServer 5.0.2), but as I remember, I have also tried with 3.0-beta3 (MapServer 5.4.0) and got the same result. Does it mean this driver is not supported in those versions? regards, dejan mapserver-users-bounces at lists.osgeo.org wrote on 06.07.2009 18:00:03: > Two things: > > 1) TEMPLATE is a keyword and must be quoted at the moment, so use > DRIVER 'TEMPLATE' > > 2) The file to be used in the OUTPUTFORMAT is given like this: > > FORMATOPTION 'FILE=/some/template/file/...' > > 3) You're call to MapServer needs to be a query. For example: > > http://localhost/cgi-bin/mapserv.exe? > map=/ms4w/apps/pmapper/pmapper-3.2.0/config/default/geojson_demo. > map&layer=countries&mode=nquery&qformat=geojson > > This call will use all the default EXTENT value in the mapfile to > query all eligible layers and run the > results through the geojson driver. > > I'm doing this to produce javascript code that gets executed by an > Ext.JS component. Not purely > GeoJSON but it works similarly. > > Steve > > >>> On 7/2/2009 at 4:15 PM, in message > , > wrote: > > Steve, > > > > Is there any GeoJSON example I can see? I must be missing something > > trivial, > > > > When I put: > > > > OUTPUTFORMAT > > NAME 'geojson' > > DRIVER TEMPLATE > > MIMETYPE 'application/json; subtype=geojson' > > TEMPLATE 'myTemplate.js' > > END > > > > in my.map file and call for example > > "http://localhost/cgi-bin/mapserv.exe? > map=/ms4w/apps/pmapper/pmapper-3.2.0/con > > fig/default/geojson_demo.map&layer=countries" > > (this works correctly without geojson part), I get: getString(): Symbol > > definition error. Parsing error near (TEMPLATE):(line 74) > > > > If I put DRIVER 'TEMPLATE' then I get: loadOutputFormat(): Unknown > > identifier. Parsing error near (TEMPLATE):(line 76) > > > > Finally, putting FORMATOPTION 'FILE=myTemplate.js' instead of TEMPLATE > > gives me: loadOutputFormat(): General error message. OUTPUTFORMAT clause > > references driver TEMPLATE, but this driver isn't configured. > > > > So, I am obviously doing something wrong regardless the myTemplate.js > > file? (anyway, can you give me an example .js file, anything that could > > help :-) > > > > regards, dejan > > "Steve Lime" wrote on 02.07.2009 15:35:28: > > > >> What does myTemplate.js look like? > >> > >> >>> 07/02/09 5:33 AM >>> > >> Thanks Fabio, > >> > >> As I said in my last post, I can't get GeoJSON output using this > >> outputformat: > >> > >> OUTPUTFORMAT > >> NAME 'geojson' > >> DRIVER 'TEMPLATE' > >> MIMETYPE 'application/json; subtype=geojson' > >> FORMATOPTION 'FILE=myTemplate.js' > >> END > >> > >> :-( > >> > >> regards, dejan > >> > >> Fabio D'Ovidio wrote on 02.07.2009 09:28:06: > >> > >> > Hi, > >> > > >> > Dejan.Gambin at pula.hr ha scritto: > >> > > > >> > > Fabio, > >> > > > >> > > Glad to here you are here too :-) > >> > > > >> > > I can certainly use both GeoServer and MapServer but this is not > >> > > something I would like at the end. Since I am still investigating > > all > >> > > this, I am not in such a hurry to get it working with my data ASAP. > >> > > So, I would rather go with one of your Mapserver solutions. > >> > It is not so difficult...just 2, 3 minutes to load your layer in > >> > GeoServer ;-) > >> > > >> > > > >> > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > > > >> > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > >> > > understand Steve correctly, there is no way currently to get GeoJSON > > > >> > > output from MapServer WFS, only with CGI? So we come to your > > solution > >> 2. > >> > > >> > If you want to use the second solution you must create the HTTP string > > > >> > to get GeoJSON from CGI-MapServer and than you must change MapOl > > request > >> > >> > to receive data and read them. > >> > If you want send me the URL and I'll send you the new MapOl as soon as > > > >> > possbile! > >> > > >> > > >> > -- > >> > Fabio D'Ovidio > >> > Geospatial solutions > >> > > >> > Inova S.r.l. > >> > Web : http://www.inovaos.it > >> > GeoBI Blog: www.geobi.org > >> > Tel.: 081 197 57 600 > >> > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it > >> > skype: dovidio_fa > >> > > >> > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From gito_kribo at yahoo.com Tue Jul 7 02:11:52 2009 From: gito_kribo at yahoo.com (Gito Ginting) Date: Tue, 7 Jul 2009 02:11:52 -0700 (PDT) Subject: [mapserver-users] analysis web using Map Server Message-ID: <139795.54835.qm@web45113.mail.sp1.yahoo.com> Hi all, I am just introduced to Map Server, I've developed a web server with Fedora 7 and would like to develop a tool for map analysis in web by using Map Server. Advise please, how to make a map interpolation with Map Server? and also the requirement for developing the interpolation? Thanks Gito Ginting? -------------- next part -------------- An HTML attachment was scrubbed... URL: From adams at terrestris.de Tue Jul 7 02:23:57 2009 From: adams at terrestris.de (Till Adams) Date: Tue, 07 Jul 2009 11:23:57 +0200 Subject: [mapserver-users] analysis web using Map Server In-Reply-To: <139795.54835.qm@web45113.mail.sp1.yahoo.com> References: <139795.54835.qm@web45113.mail.sp1.yahoo.com> Message-ID: <4A53142D.5050400@terrestris.de> Dear Gito, UMN is not a real "GIS application" itsself, UMN is more capable for showing processed GIS data in the internet. There are some possibilities to interact with PostGIS, but if you really want to interpolate data from points to surfaces, you should think about using a GIS in your backend (e.g. GRASS, which supports a PHP, python (and some others based) interface to web-applications). As an example we use GRASS as backend so that users may interpolate time-series of measured soil-moisture data and present this data via UMN Mapserver in an OpenLayers based client. So, what you need is an architecture, not purely UMN. Correct me, if I'm wrong... -) Hope this points you in a direction Till > Hi all, > > I am just introduced to Map Server, I've developed a web server with > Fedora 7 and would like to develop a tool for map analysis in web by > using Map Server.. Advise please, how to make a map interpolation with > Map Server? and also the requirement for developing the interpolation? > > Thanks > Gito Ginting > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- ---------------------------------------------------------- terrestris GmbH & Co. KG Irmintrudisstrasse 17 53111 Bonn Germany Till Adams Gesch?ftsf?hrung Tel: +49 (0)228 / 962 899-52 Fax: +49 (0)228 / 962 899-57 adams at terrestris.de http://www.terrestris.de Amtsgericht Bonn, HRA 6835 --------------------------------------------------------- Komplement?rin: terrestris Verwaltungs GmbH vertreten durch: Hinrich Paulsen, Till Adams From gito_kribo at yahoo.com Tue Jul 7 03:13:33 2009 From: gito_kribo at yahoo.com (Gito Ginting) Date: Tue, 7 Jul 2009 03:13:33 -0700 (PDT) Subject: [mapserver-users] analysis web using Map Server Message-ID: <702518.33286.qm@web45106.mail.sp1.yahoo.com> Dear Till Thank you for your explanation, my friend alredy told me that I suppose to used a GRASS. But there's another question that being my thought, first, the scripts to connect between mapserver and the GRASS software second, how to interpolate the data [in this case I use Rainfall data] in GRASS then mapserver shows the interpolation result from GRASS in mapserver? I am loooking for ur advice best, Gito --- On Tue, 7/7/09, Till Adams wrote: From: Till Adams Subject: Re: [mapserver-users] analysis web using Map Server To: "Gito Ginting" , "mapserver" Date: Tuesday, July 7, 2009, 4:23 PM Dear Gito, UMN is not a real "GIS application" itsself, UMN is more capable for showing processed GIS data in the internet. There are some possibilities to interact with PostGIS, but if you really want to interpolate data from points to surfaces, you should think about using a GIS in your backend (e.g. GRASS, which supports a PHP, python (and some others based) interface to web-applications). As an example we use GRASS as backend so that users may interpolate time-series of measured soil-moisture data and present this data via UMN Mapserver in an OpenLayers based client. So, what you need is an architecture, not purely UMN. Correct me, if I'm wrong... -) Hope this points you in a direction Till > Hi all, > > I am just introduced to Map Server, I've developed a web server with Fedora 7 and would like to develop a tool for map analysis in web by using Map Server.. Advise please, how to make a map interpolation with Map Server? and also the requirement for developing the interpolation? > > Thanks > Gito Ginting > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users >??? -- ---------------------------------------------------------- terrestris GmbH & Co. KG Irmintrudisstrasse 17 53111 Bonn Germany Till Adams Gesch?ftsf?hrung Tel: +49 (0)228 / 962 899-52 Fax: +49 (0)228 / 962 899-57 adams at terrestris.de http://www.terrestris.de Amtsgericht Bonn, HRA 6835 --------------------------------------------------------- Komplement?rin: terrestris Verwaltungs GmbH vertreten durch: Hinrich Paulsen, Till Adams -------------- next part -------------- An HTML attachment was scrubbed... URL: From nnikolov at gypsii.com Tue Jul 7 04:23:01 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Tue, 7 Jul 2009 12:23:01 +0100 Subject: [mapserver-users] Mapserver 5.2.0 and 5.4.1, QUANTIZE_FORCE or PALETTE_FORCE do not produce 8bit colour PNG file - only reduce the number of colours used. Message-ID: <000801c9fef5$4b2a5d40$0401a8c0@BenefonUK.local> Hi everybody, I have tried unsuccessfully to reduce the size of my PNG image tiles, generated by the Mapserver using the QUANTIZE_FORCE or PALETTE_FORCE options. The resulting file is marginally smaller than the one not using those options. Using "IrfanView" I could get some information about the colours used and the number of bits used to code the colours. The repost shows a decrease of the number of colours used from over 1600 to either 241 (Mapserver defined) or 193 (using palette file containing 71 predefined colours). However, tool reports 24 bits used for colour mapping. If I put the PNG image through tools like "pngquant", "OptiPng" or "pngcrush", the resulting image is much smaller and "IrfanView" reports that only 8 bits are used for colour mapping! The relevant map file part is: IMAGETYPE AGG_PNG24 OUTPUTFORMAT NAME AGG_PNG24 DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END The Mapserver, both 5.2.0 and 5.4.1, has been configured with --with-experimental-png or --enable-experimental-png (I have not noticed any difference in using either option). Please, advise what I am missing here. Many thanks, Nick -------------- next part -------------- An HTML attachment was scrubbed... URL: From Dejan.Gambin at pula.hr Tue Jul 7 04:55:11 2009 From: Dejan.Gambin at pula.hr (Dejan.Gambin at pula.hr) Date: Tue, 7 Jul 2009 13:55:11 +0200 Subject: [mapserver-users] GeoJSON output from MapServer - GOT IT In-Reply-To: <4A51D932.5157.008F.0@dnr.state.mn.us> Message-ID: Hi Steve (and others) Finally I got GeoJSON output from MapServer. I have used the newest ms4w. The point is - I have already tried with this one, but probably didn't use FORMATOPTION or something like this. Now it works correctly. A note - I had to use backslash notation for template FILE (on Windows of course) That's it for now, Thanks very much regards, dejan mapserver-users-bounces at lists.osgeo.org wrote on 06.07.2009 18:00:03: > Two things: > > 1) TEMPLATE is a keyword and must be quoted at the moment, so use > DRIVER 'TEMPLATE' > > 2) The file to be used in the OUTPUTFORMAT is given like this: > > FORMATOPTION 'FILE=/some/template/file/...' > > 3) You're call to MapServer needs to be a query. For example: > > http://localhost/cgi-bin/mapserv.exe? > map=/ms4w/apps/pmapper/pmapper-3.2.0/config/default/geojson_demo. > map&layer=countries&mode=nquery&qformat=geojson > > This call will use all the default EXTENT value in the mapfile to > query all eligible layers and run the > results through the geojson driver. > > I'm doing this to produce javascript code that gets executed by an > Ext.JS component. Not purely > GeoJSON but it works similarly. > > Steve > > >>> On 7/2/2009 at 4:15 PM, in message > , > wrote: > > Steve, > > > > Is there any GeoJSON example I can see? I must be missing something > > trivial, > > > > When I put: > > > > OUTPUTFORMAT > > NAME 'geojson' > > DRIVER TEMPLATE > > MIMETYPE 'application/json; subtype=geojson' > > TEMPLATE 'myTemplate.js' > > END > > > > in my.map file and call for example > > "http://localhost/cgi-bin/mapserv.exe? > map=/ms4w/apps/pmapper/pmapper-3.2.0/con > > fig/default/geojson_demo.map&layer=countries" > > (this works correctly without geojson part), I get: getString(): Symbol > > definition error. Parsing error near (TEMPLATE):(line 74) > > > > If I put DRIVER 'TEMPLATE' then I get: loadOutputFormat(): Unknown > > identifier. Parsing error near (TEMPLATE):(line 76) > > > > Finally, putting FORMATOPTION 'FILE=myTemplate.js' instead of TEMPLATE > > gives me: loadOutputFormat(): General error message. OUTPUTFORMAT clause > > references driver TEMPLATE, but this driver isn't configured. > > > > So, I am obviously doing something wrong regardless the myTemplate.js > > file? (anyway, can you give me an example .js file, anything that could > > help :-) > > > > regards, dejan > > "Steve Lime" wrote on 02.07.2009 15:35:28: > > > >> What does myTemplate.js look like? > >> > >> >>> 07/02/09 5:33 AM >>> > >> Thanks Fabio, > >> > >> As I said in my last post, I can't get GeoJSON output using this > >> outputformat: > >> > >> OUTPUTFORMAT > >> NAME 'geojson' > >> DRIVER 'TEMPLATE' > >> MIMETYPE 'application/json; subtype=geojson' > >> FORMATOPTION 'FILE=myTemplate.js' > >> END > >> > >> :-( > >> > >> regards, dejan > >> > >> Fabio D'Ovidio wrote on 02.07.2009 09:28:06: > >> > >> > Hi, > >> > > >> > Dejan.Gambin at pula.hr ha scritto: > >> > > > >> > > Fabio, > >> > > > >> > > Glad to here you are here too :-) > >> > > > >> > > I can certainly use both GeoServer and MapServer but this is not > >> > > something I would like at the end. Since I am still investigating > > all > >> > > this, I am not in such a hurry to get it working with my data ASAP. > >> > > So, I would rather go with one of your Mapserver solutions. > >> > It is not so difficult...just 2, 3 minutes to load your layer in > >> > GeoServer ;-) > >> > > >> > > > >> > > My first question, to be sure - so MapOl reads/gets the GeoJSON data > > > >> > > from Geoserver WFS and outputs GeoJSON data to WebClient? If I > >> > > understand Steve correctly, there is no way currently to get GeoJSON > > > >> > > output from MapServer WFS, only with CGI? So we come to your > > solution > >> 2. > >> > > >> > If you want to use the second solution you must create the HTTP string > > > >> > to get GeoJSON from CGI-MapServer and than you must change MapOl > > request > >> > >> > to receive data and read them. > >> > If you want send me the URL and I'll send you the new MapOl as soon as > > > >> > possbile! > >> > > >> > > >> > -- > >> > Fabio D'Ovidio > >> > Geospatial solutions > >> > > >> > Inova S.r.l. > >> > Web : http://www.inovaos.it > >> > GeoBI Blog: www.geobi.org > >> > Tel.: 081 197 57 600 > >> > mail: fabiodovidio at gmail.com, f.dovidio at inovaos.it > >> > skype: dovidio_fa > >> > > >> > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From gis at vanbooth.com Tue Jul 7 07:09:25 2009 From: gis at vanbooth.com (Rob) Date: Tue, 7 Jul 2009 15:09:25 +0100 Subject: [mapserver-users] Cascading WMS layer requests in MapServer Message-ID: <2a955f950907070709h626c2cb0neb45c3a1ddb1e744@mail.gmail.com> Hi I was wondering if anybody knew whether it is possible to combine multiple requests to a cascaded WMS service. For example, my WMS service has lots of layers in it. Amongst them are six cascaded layers from a 3rd party service. If a user requests all six of those layers in one request currently, it makes six individual requests to the 3rd party service in order to draw those layers. Whilst this makes sense if the layers= parameter has different layers in between the 3rd party layers, when 2 or more layers are together, surely it would make more sense to make fewer requests where possible. Is this something that Mapserver already does and I havent spotted it(in the WMS_METADATA for example?) , or is this a future requirement ;o) ? MTIA Rob From yassefa at dmsolutions.ca Tue Jul 7 07:23:16 2009 From: yassefa at dmsolutions.ca (Yewondwossen Assefa) Date: Tue, 07 Jul 2009 10:23:16 -0400 Subject: [mapserver-users] Cascading WMS layer requests in MapServer In-Reply-To: <2a955f950907070709h626c2cb0neb45c3a1ddb1e744@mail.gmail.com> References: <2a955f950907070709h626c2cb0neb45c3a1ddb1e744@mail.gmail.com> Message-ID: <4A535A54.1030309@dmsolutions.ca> Hi There, MapServer by default should try to merge WMS requests for adjacent layers unless specifically asked not to using the metedata wms_force_separate_request (http://mapserver.org/ogc/wms_client.html). Do you have an example of the full URL of the GetMap request for 2 adjacent layers that should be merged? Note that all parameters of the 2 request should be the same except parameters such as LAYERS, QUERY_LAYERS, STYLES that could be different. Best Regards, Rob wrote: > Hi > > I was wondering if anybody knew whether it is possible to combine > multiple requests to a cascaded WMS service. > > For example, my WMS service has lots of layers in it. Amongst them > are six cascaded layers from a 3rd party service. If a user requests > all six of those layers in one request currently, it makes six > individual requests to the 3rd party service in order to draw those > layers. > > Whilst this makes sense if the layers= parameter has different layers > in between the 3rd party layers, when 2 or more layers are together, > surely it would make more sense to make fewer requests where possible. > > Is this something that Mapserver already does and I havent spotted > it(in the WMS_METADATA for example?) , or is this a future requirement > ;o) ? > > MTIA > > Rob > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From Steve.Lime at dnr.state.mn.us Tue Jul 7 08:06:51 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 07 Jul 2009 10:06:51 -0500 Subject: [mapserver-users] Mapserver 5.2.0 and 5.4.1,QUANTIZE_FORCE or PALETTE_FORCE do not produce8bit colour PNG file - only reduce the number of colours used. Message-ID: <4A531E3B0200008F00025C36@co5.dnr.state.mn.us> Hi Nikolai: I'm using the exact same output format and it works fine for me (PALETTE_FORCE, 5.4.1). With that format my output images are 1/4 the size of their RGB counterparts. Have you tried a version without any of the experimental PNG options enabled? Steve >>> "Nikolai Nikolov" 07/07/09 6:48 AM >>> Hi everybody, I have tried unsuccessfully to reduce the size of my PNG image tiles, generated by the Mapserver using the QUANTIZE_FORCE or PALETTE_FORCE options. The resulting file is marginally smaller than the one not using those options. Using "IrfanView" I could get some information about the colours used and the number of bits used to code the colours. The repost shows a decrease of the number of colours used from over 1600 to either 241 (Mapserver defined) or 193 (using palette file containing 71 predefined colours). However, tool reports 24 bits used for colour mapping. If I put the PNG image through tools like "pngquant", "OptiPng" or "pngcrush", the resulting image is much smaller and "IrfanView" reports that only 8 bits are used for colour mapping! The relevant map file part is: IMAGETYPE AGG_PNG24 OUTPUTFORMAT NAME AGG_PNG24 DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END The Mapserver, both 5.2.0 and 5.4.1, has been configured with --with-experimental-png or --enable-experimental-png (I have not noticed any difference in using either option). Please, advise what I am missing here. Many thanks, Nick From youness.elmedraoui at somei.fr Tue Jul 7 08:11:09 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Tue, 7 Jul 2009 17:11:09 +0200 Subject: [mapserver-users] problem with connection to oracle Message-ID: An HTML attachment was scrubbed... URL: From Tim.Nolte at ipcswirelessinc.com Tue Jul 7 08:14:28 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Tue, 7 Jul 2009 11:14:28 -0400 Subject: [mapserver-users] problem with connection to oracle In-Reply-To: References: Message-ID: This means that you have not compiled MapServer with support for Oracle Spatial. Are you using a binary distribution, if so you'll need to compile from source and include that path to your local Oracle Client install. What OS are you running under? - Tim ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com ________________________________ From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of youness.elmedraoui at somei.fr Sent: Tuesday, July 07, 2009 11:11 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] problem with connection to oracle Hello, I have a problem with oracle connection. I use this script: LAYER ... CONNECTIONTYPE oraclespatial CONNECTION ".../... at ..." ... END and I have these errors for: - oraclespatial: msDrawMap(): Image handling error. Failed to draw layer named .... msOracleSpatialLayerOpen(): OracleSpatial error. OracleSpatial is not supported . Can you help me plz? thanks Best Regards Youness ELMEDRAOUI Les informations figurant sur cet e-mail ont un caract?re strictement confidentiel et sont exclusivement adress?es au destinataire mentionn? ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir imm?diatement par la m?me voie et d?truire l'original. Merci From youness.elmedraoui at somei.fr Tue Jul 7 08:19:19 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Tue, 7 Jul 2009 17:19:19 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_RE=3A_[mapserver-users]_problem_with?= =?ISO-8859-1?Q?_connection_to_oracle?= In-Reply-To: References: , Message-ID: An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Tue Jul 7 08:21:59 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Tue, 07 Jul 2009 12:21:59 -0300 Subject: [mapserver-users] problem with connection to oracle In-Reply-To: References: Message-ID: <4A536817.6060902@gatewaygeomatics.com> youness.elmedraoui at somei.fr wrote: > Hello, > > I have a problem with oracle connection. > > I use this script: > > | > LAYER > ...| > | CONNECTIONTYPE oraclespatial > CONNECTION ".../... at ... " > ...| > |END| > > > > and I have these errors for: > > - oraclespatial: > msDrawMap(): Image handling error. Failed to draw layer named .... > msOracleSpatialLayerOpen(): OracleSpatial error. OracleSpatial is not > supported . > If you are a windows user then you can follow the MS4W instructions for Oracle support: http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL_3.0.html#oracle-10g-11g -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From Tim.Nolte at ipcswirelessinc.com Tue Jul 7 08:25:42 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Tue, 7 Jul 2009 11:25:42 -0400 Subject: =?iso-8859-1?Q?RE=3A_R=E9f=2E_=3A_RE=3A_=5Bmapserver-users=5D_problem?= =?iso-8859-1?Q?_with_connection_to_oracle?= In-Reply-To: References: , Message-ID: I don't work with Windows myself, only Linux/Unix, and that is all I've done compiles on. The first step would be to try and following the following guides to compile for Windows: http://mapserver.org/installation/win32.html http://mapserver.org/installation/oracle.html Perhaps someone else here on the list has first-hand experience compiling on Windows with Oracle Spatial support. - Tim ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com -----Original Message----- From: youness.elmedraoui at somei.fr [mailto:youness.elmedraoui at somei.fr] Sent: Tuesday, July 07, 2009 11:19 AM To: Nolte, Tim Cc: mapserver-users at lists.osgeo.org Subject: R?f. : RE: [mapserver-users] problem with connection to oracle yes, i'm using a binary MS4W on OS Windows. how ca i compile mapserver with oracle spatial? Youness Les informations figurant sur cet e-mail ont un caract?re strictement confidentiel et sont exclusivement adress?es au destinataire mentionn? ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir imm?diatement par la m?me voie et d?truire l'original. Merci From jmckenna at gatewaygeomatics.com Tue Jul 7 08:25:48 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Tue, 07 Jul 2009 12:25:48 -0300 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_RE=3A_=5Bmapserver-users=5D?= =?ISO-8859-1?Q?_problem_with_connection_to_oracle?= In-Reply-To: References: , Message-ID: <4A5368FC.8020707@gatewaygeomatics.com> youness.elmedraoui at somei.fr wrote: > yes, i'm using a binary MS4W on OS Windows. - use the latest installer (currently MS4W 3.0 beta4) and follow the instructions in the README document inside that package (or online at http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL_3.0.html#oracle-10g-11g) - if you have configuration questions please use the MS4W mailing list: http://lists.maptools.org/mailman/listinfo/ms4w-users -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From youness.elmedraoui at somei.fr Tue Jul 7 08:43:06 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Tue, 7 Jul 2009 17:43:06 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_Re=3A_R=E9f=2E_=3A_RE=3A_[mapserver-users]_?= =?ISO-8859-1?Q?problem_with_connection_to_oracle?= In-Reply-To: <4A5368FC.8020707@gatewaygeomatics.com> References: , , <4A5368FC.8020707@gatewaygeomatics.com> Message-ID: An HTML attachment was scrubbed... URL: From peter.hopfgartner at r3-gis.com Tue Jul 7 08:08:37 2009 From: peter.hopfgartner at r3-gis.com (Peter Hopfgartner) Date: Tue, 07 Jul 2009 17:08:37 +0200 Subject: [mapserver-users] analysis web using Map Server In-Reply-To: <139795.54835.qm@web45113.mail.sp1.yahoo.com> References: <139795.54835.qm@web45113.mail.sp1.yahoo.com> Message-ID: <4A5364F5.9090304@r3-gis.com> Gito Ginting wrote: > Hi all, > > I am just introduced to Map Server, I've developed a web server with > Fedora 7 and would like to develop a tool for map analysis in web by > using Map Server.. Advise please, how to make a map interpolation with > Map Server? and also the requirement for developing the interpolation? > > Thanks > Gito Ginting > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > MapServer relies on GDAL for many data formats. GDAL can be configured in a way that it can access directly the GRASS database. In case, some googling should help. http://grass.itc.it/start.html http://www.google.com/search?q=GDAL+GRASS+mapserver Regards, Peter -- Dott. Peter Hopfgartner R3 GIS Srl - GmbH Via Johann Kravogl-Str. 2 I-39012 Meran/Merano (BZ) Email: peter.hopfgartner at r3-gis.com Tel. : +39 0473 494949 Fax : +39 0473 069902 www : http://www.r3-gis.com From peter at peterse-uithuizen.com Tue Jul 7 12:10:22 2009 From: peter at peterse-uithuizen.com (Peter Peterse) Date: Tue, 07 Jul 2009 21:10:22 +0200 Subject: [mapserver-users] compiling mapserv 5.4.1 with PNG driver In-Reply-To: <2922382e0907010048g53ad9bfmcdc99acd27c57f4a@mail.gmail.com> References: <2922382e0906302222t58fd18cbjc86dfee9a3e9b82c@mail.gmail.com> <2922382e0907010037j44510700v2b3fc594f01a7548@mail.gmail.com> <2922382e0907010048g53ad9bfmcdc99acd27c57f4a@mail.gmail.com> Message-ID: <4A539D9E.4090901@peterse-uithuizen.com> Hello Thomas, I've compiled all the source again on a clean system and now I've got: ./mapserv -v MapServer version 5.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE so it looks better to me. Thanks for your help. Peter. >>>> Thanks, but I'm not that far. >>>> >>>> I've just compiled mapserv >>>> After that I call the next command's: >>>> $ ./mapserv -v >>>> MapServer version 5.4.1 OUTPUT=GIF OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG >>>> SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV >>>> SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER >>>> SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER >>>> SUPPORTS=THREADS SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS >>>> INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE >>>> >>>> From nnikolov at gypsii.com Wed Jul 8 00:19:20 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Wed, 8 Jul 2009 08:19:20 +0100 Subject: [mapserver-users] Mapserver 5.2.0 and 5.4.1, QUANTIZE_FORCEor PALETTE_FORCE do not produce8bit colour PNG file - onlyreduce the number of colours used. In-Reply-To: <4A531E3B0200008F00025C36@co5.dnr.state.mn.us> References: <4A531E3B0200008F00025C36@co5.dnr.state.mn.us> Message-ID: Hi Steve, and everyone else, Thanks for your responce! Late last night I discovered what the issue was. It took me several days of reading other people's problems and solutins in this area. It turned up that it is not the Mapserver settings, but the PHP functions I use to save the immage on the HD. I am using PHP "imagepng" after cropping the original image to remove the "gutter". However the function always seems to saves the image using 24 bits for colour mapping even if a palette is used and the colours are less than 256. The solution was to use "imagetruecolortopalette" PHP function like this - imagetruecolortopalette($tile_image, false, 256) I have to do some more investigation, but the PNG file now is using 8 bits for colours and is dramaticaly amaller. Best regards, Nick -----Original Message----- From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Sent: 07 July 2009 16:07 To: nnikolov at gypsii.com; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Mapserver 5.2.0 and 5.4.1,QUANTIZE_FORCEor PALETTE_FORCE do not produce8bit colour PNG file - onlyreduce the number of colours used. Hi Nikolai: I'm using the exact same output format and it works fine for me (PALETTE_FORCE, 5.4.1). With that format my output images are 1/4 the size of their RGB counterparts. Have you tried a version without any of the experimental PNG options enabled? Steve >>> "Nikolai Nikolov" 07/07/09 6:48 AM >>> Hi everybody, I have tried unsuccessfully to reduce the size of my PNG image tiles, generated by the Mapserver using the QUANTIZE_FORCE or PALETTE_FORCE options. The resulting file is marginally smaller than the one not using those options. Using "IrfanView" I could get some information about the colours used and the number of bits used to code the colours. The repost shows a decrease of the number of colours used from over 1600 to either 241 (Mapserver defined) or 193 (using palette file containing 71 predefined colours). However, tool reports 24 bits used for colour mapping. If I put the PNG image through tools like "pngquant", "OptiPng" or "pngcrush", the resulting image is much smaller and "IrfanView" reports that only 8 bits are used for colour mapping! The relevant map file part is: IMAGETYPE AGG_PNG24 OUTPUTFORMAT NAME AGG_PNG24 DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END The Mapserver, both 5.2.0 and 5.4.1, has been configured with --with-experimental-png or --enable-experimental-png (I have not noticed any difference in using either option). Please, advise what I am missing here. Many thanks, Nick From nnikolov at gypsii.com Wed Jul 8 01:05:33 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Wed, 8 Jul 2009 09:05:33 +0100 Subject: [mapserver-users] Smaller polygon sizes when using mapserver 5.4.1 compare to 5.2.0 Message-ID: <65D1C555BE9443A180F3B1697EF7E69F@BenefonUK.local> Hi everyone, I've just upgraded one of my test servers from 5.2.0 to 5.4.1. I have an issue there and I wonder whether anybody have noticed it. My map polygones seems to be fractionaly smaller (compare to those drawned by 5.2.0). I am using the same maps, map files, PHP scripts, etc. The plygons which belong to the same layer, do not quite well "fit" with each other - their borders match perfectly before the upgarde to 5.4.1. Also, I use BACKGROUNDCOLOR in my map file to create shield like square behind a label. Those squares are now significantly smaller too. I wander what causes this effect and what I should do to achieve the same image as with 5.2.0? Thanks, Nick -------------- next part -------------- An HTML attachment was scrubbed... URL: From nnikolov at gypsii.com Wed Jul 8 07:23:01 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Wed, 8 Jul 2009 15:23:01 +0100 Subject: [mapserver-users] RE: Smaller polygon sizes when using mapserver 5.4.1 compare to 5.2.0 Message-ID: Hi everyone, Thanks to Thomas Bonfort I have resolved the issue of the smaller polygons - he advised me to define the OUTLINECOLOUR with the same as COLOUR for the polygon layer in the map file and it works. I wonder what has changed in the new Mapserver version 5.4.1? However, the issue with the "background rectangle (i.e. billboard) shadow" created using BACKGROUNDCOLOR in the LABEL definition is still unresolved. I have two different maps one using DRIVER AGG/PNG in the OUTPUTFORMAT definition and another with DRIVER GD/PNG. For the first one I have the problem with BACKGROUNDCOLOR size, in contrast, in the other (GD) map, the size is good, i.e. the same as for Mapserver 5.2.0 (regardless of the use of AGG or GD). I have not changed the AGG library or any other library, only the Mpserver code. Thanks, Nick _____ From: Nikolai Nikolov [mailto:nnikolov at gypsii.com] Sent: 08 July 2009 09:06 To: 'mapserver-users at lists.osgeo.org' Subject: Smaller polygon sizes when using mapserver 5.4.1 compare to 5.2.0 Hi everyone, I've just upgraded one of my test servers from 5.2.0 to 5.4.1. I have an issue there and I wonder whether anybody have noticed it. My map polygones seems to be fractionaly smaller (compare to those drawned by 5.2.0). I am using the same maps, map files, PHP scripts, etc. The plygons which belong to the same layer, do not quite well "fit" with each other - their borders match perfectly before the upgarde to 5.4.1. Also, I use BACKGROUNDCOLOR in my map file to create shield like square behind a label. Those squares are now significantly smaller too. I wander what causes this effect and what I should do to achieve the same image as with 5.2.0? Thanks, Nick -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Wed Jul 8 07:28:42 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 08 Jul 2009 09:28:42 -0500 Subject: [mapserver-users] Smaller polygon sizes when using mapserver 5.4.1compare to 5.2.0 In-Reply-To: <65D1C555BE9443A180F3B1697EF7E69F@BenefonUK.local> References: <65D1C555BE9443A180F3B1697EF7E69F@BenefonUK.local> Message-ID: <4A5466C9.5157.008F.0@dnr.state.mn.us> Perhaps you could post image samples and a mapfile? Steve >>> On 7/8/2009 at 3:05 AM, in message <65D1C555BE9443A180F3B1697EF7E69F at BenefonUK.local>, "Nikolai Nikolov" wrote: > Hi everyone, > > > > I've just upgraded one of my test servers from 5.2.0 to 5.4.1. I have an > issue there and I wonder whether anybody have noticed it. My map polygones > seems to be fractionaly smaller (compare to those drawned by 5.2.0). > > > > I am using the same maps, map files, PHP scripts, etc. The plygons which > belong to the same layer, do not quite well "fit" with each other - their > borders match perfectly before the upgarde to 5.4.1. > > > > Also, I use BACKGROUNDCOLOR in my map file to create shield like square > behind a label. Those squares are now significantly smaller too. > > > > I wander what causes this effect and what I should do to achieve the same > image as with 5.2.0? > > > > Thanks, > > Nick > > > > From youness.elmedraoui at somei.fr Wed Jul 8 08:30:23 2009 From: youness.elmedraoui at somei.fr (youness.elmedraoui at somei.fr) Date: Wed, 8 Jul 2009 17:30:23 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_Re=3A_R=E9f=2E_=3A_RE=3A_[mapserver-users]_?= =?ISO-8859-1?Q?problem_with_connection_to_oracle?= In-Reply-To: <4A5368FC.8020707@gatewaygeomatics.com> References: , , <4A5368FC.8020707@gatewaygeomatics.com> Message-ID: An HTML attachment was scrubbed... URL: From tohashmi at gmail.com Wed Jul 8 10:20:25 2009 From: tohashmi at gmail.com (Hussain Hashmi) Date: Wed, 8 Jul 2009 20:20:25 +0300 Subject: [mapserver-users] Fwd: queryByPoint - Street Layer ? In-Reply-To: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> References: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> Message-ID: <28aabd160907081020g1a1482f4mabdfe3c24d7472cc@mail.gmail.com> hi Can someone here guide me on this issue please. My Objective is to get attribute values for any selected street (Line). My client application is based on KaMap. I have a similar solution for Polygons which works perfectly. I am trying to query a street layer which gives me the following error. Warning: [MapServer Error]: msQueryByPoint(): No matching record(s) found in C:\... on line 84 Warning: [MapServer Error]: msShapefileOpen(): (/ms4w/maps/./city/./city/streets) in c:\... on line 84 MAPFILE ********************** LAYER NAME 'streets_Query' GROUP 'streets_Query' DATA './city/streets' TYPE line MAXSCALE 3001 STATUS ON TOLERANCE 5 TEMPLATE './_templates/Streets_Identify.html' METADATA "queryable" "true" searchfield "ANAME" fields "ZIP_CODE" END END #end layer PHP MAPSCRIPT ********************** //------- Get Input Parameters. if (isset($_REQUEST['map'])) {$szMap = $_REQUEST['map'];} else {echo "map not defined"; die;} if (isset($_REQUEST['coords'])) {$coords = explode(',',$_REQUEST['coords']);} else {echo "coordinate not defined"; die;} //------- Load Mapscript Module. $szPHPMapScriptModule = 'php_mapscript.'.PHP_SHLIB_SUFFIX; if (!extension_loaded('MapScript')) { dl($szPHPMapScriptModule); } //------- Load Current Map file. $szMapFile=str_replace('<>',$szMap,'/ms4w/maps/<>.map'); $oMap = ms_newMapObj($szMapFile); //------- SETTING MAP EXTENT to query extent.. $mapExtent = $oMap->extent; $oMap->setExtent($coords[0],$coords[1], $coords[0]+0.000001,$coords[1]+0.000001); //------- SETTING QUERY POINT $point = ms_newPointObj(); $point->setXY($coords[0], $coords[1]); //------- Initialize map query. $oMap->preparequery(); //------- LOOP ON LAYERS and get identify results. $tot = $oMap->numlayers; for ($i = 0; $i < $tot; $i++) { //------- get map layer. $oLayer = $oMap->getLayer($i); //------- Verify Layer type if ($oLayer->name != 'streets_Query') continue; //------- Validate if query succeeds. $check_query = $oLayer->queryByPoint($point, MS_SINGLE, 0); if ($check_query != MS_SUCCESS) {continue;} //------- Open layer for data input. $oLayer->open(); //------- Get the record values corresponding to a result tileindex. $oResultCache = $oLayer->getResult(0); $oShape = $oLayer->getShape($oResultCache->tileindex, $oResultCache->shapeindex); $aValues = $oShape->values; //------- Get the field value. echo $aValues['ZIP_CODE']; echo ";"; //------- FREE SHAPE $oShape->free(); $oLayer->close(); break; } // for i Best regards, Mir Hashmi ------------------------------ This message may contain confidential and/or privileged information. If you have received this message in error,please notify us immediately by responding to this e-mail and delete it from your system. Thanks for your cooperation. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Wed Jul 8 10:56:38 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 08 Jul 2009 12:56:38 -0500 Subject: [mapserver-users] Fwd: queryByPoint - Street Layer ? In-Reply-To: <28aabd160907081020g1a1482f4mabdfe3c24d7472cc@mail.gmail.com> References: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> <28aabd160907081020g1a1482f4mabdfe3c24d7472cc@mail.gmail.com> Message-ID: <4A549786.5157.008F.0@dnr.state.mn.us> May well be a tolerance issue. By default it's in pixels and based on the extent you're setting (I don't know what the map SIZE is set to) it's probably a super tiny value. Have you tried setting a tolerance in map units? E.g. TOLERANCE 5 TOLERANCEUNITS meters # or whatever Just an idea... Steve >>> On 7/8/2009 at 12:20 PM, in message <28aabd160907081020g1a1482f4mabdfe3c24d7472cc at mail.gmail.com>, Hussain Hashmi wrote: > hi > > Can someone here guide me on this issue please. > My Objective is to get attribute values for any selected street (Line). > My client application is based on KaMap. > I have a similar solution for Polygons which works perfectly. > > > I am trying to query a street layer which gives me the following error. > > Warning: [MapServer Error]: msQueryByPoint(): No matching record(s) found in > C:\... on line 84 > Warning: [MapServer Error]: msShapefileOpen(): > (/ms4w/maps/./city/./city/streets) in c:\... on line 84 > > > MAPFILE > ********************** > LAYER > NAME 'streets_Query' > GROUP 'streets_Query' > DATA './city/streets' > TYPE line > MAXSCALE 3001 > STATUS ON > > TOLERANCE 5 > TEMPLATE './_templates/Streets_Identify.html' > METADATA > "queryable" "true" > searchfield "ANAME" > fields "ZIP_CODE" > END > END #end layer > > > > PHP MAPSCRIPT > ********************** > //------- Get Input Parameters. > if (isset($_REQUEST['map'])) {$szMap = $_REQUEST['map'];} else {echo "map > not defined"; die;} > if (isset($_REQUEST['coords'])) {$coords = > explode(',',$_REQUEST['coords']);} else {echo "coordinate not defined"; > die;} > > > //------- Load Mapscript Module. > $szPHPMapScriptModule = 'php_mapscript.'.PHP_SHLIB_SUFFIX; > if (!extension_loaded('MapScript')) { > dl($szPHPMapScriptModule); > } > > //------- Load Current Map file. > $szMapFile=str_replace('<>',$szMap,'/ms4w/maps/<>.map'); > $oMap = ms_newMapObj($szMapFile); > > > //------- SETTING MAP EXTENT to query extent.. > $mapExtent = $oMap->extent; > $oMap->setExtent($coords[0],$coords[1], > $coords[0]+0.000001,$coords[1]+0.000001); > > //------- SETTING QUERY POINT > $point = ms_newPointObj(); > $point->setXY($coords[0], $coords[1]); > > //------- Initialize map query. > $oMap->preparequery(); > > //------- LOOP ON LAYERS and get identify results. > $tot = $oMap->numlayers; > for ($i = 0; $i < $tot; $i++) { > //------- get map layer. > $oLayer = $oMap->getLayer($i); > > //------- Verify Layer type > if ($oLayer->name != 'streets_Query') continue; > > //------- Validate if query succeeds. > $check_query = $oLayer->queryByPoint($point, MS_SINGLE, 0); > if ($check_query != MS_SUCCESS) {continue;} > > //------- Open layer for data input. > $oLayer->open(); > > //------- Get the record values corresponding to a result tileindex. > $oResultCache = $oLayer->getResult(0); > $oShape = $oLayer->getShape($oResultCache->tileindex, > $oResultCache->shapeindex); > $aValues = $oShape->values; > > //------- Get the field value. > echo $aValues['ZIP_CODE']; echo ";"; > > //------- FREE SHAPE > $oShape->free(); > $oLayer->close(); > break; > } // for i > > > Best regards, > Mir Hashmi > > > > ------------------------------ > This message may contain confidential and/or privileged information. If you > have received this message in error,please notify us immediately by > responding to this e-mail and delete it from your system. Thanks for your > cooperation. From mikesaunt at gmail.com Wed Jul 8 12:25:44 2009 From: mikesaunt at gmail.com (Mike Saunt) Date: Wed, 8 Jul 2009 20:25:44 +0100 Subject: [mapserver-users] Sample Google Maps styled map file Message-ID: <5a9686e80907081225j313c46beu5ccf32162866d5a6@mail.gmail.com> Hi All Long time since I've posted! Does anyone know where I can get a sample MapServer map file with Google Maps style styling? Much appreciated Mike -------------- next part -------------- An HTML attachment was scrubbed... URL: From Tim.Nolte at ipcswirelessinc.com Wed Jul 8 12:33:22 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Wed, 8 Jul 2009 15:33:22 -0400 Subject: [mapserver-users] Sample Google Maps styled map file In-Reply-To: <5a9686e80907081225j313c46beu5ccf32162866d5a6@mail.gmail.com> References: <5a9686e80907081225j313c46beu5ccf32162866d5a6@mail.gmail.com> Message-ID: This was posted awhile back on the ka-map list. " http://boston.freemap.in/ is an example that gets it reasonably close to nice looking. Mapfile is linked from the about page. " - Christopher Schmidt - Tim ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Mike Saunt Sent: Wednesday, July 08, 2009 3:26 PM To: MAPSERVER USERS Subject: [mapserver-users] Sample Google Maps styled map file Hi All Long time since I've posted! Does anyone know where I can get a sample MapServer map file with Google Maps style styling? Much appreciated Mike From Tim.Nolte at ipcswirelessinc.com Wed Jul 8 12:38:15 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Wed, 8 Jul 2009 15:38:15 -0400 Subject: [mapserver-users] Sample Google Maps styled map file In-Reply-To: <5a9686e80907081225j313c46beu5ccf32162866d5a6@mail.gmail.com> References: <5a9686e80907081225j313c46beu5ccf32162866d5a6@mail.gmail.com> Message-ID: Here is another posting from Bob, posted here last year, All, I'm done with the cartography, I think. Anyone see any problems with it that are obvious? Again, this is only the road network, and it's only for a local dataset. http://gis.ci.stpaul.mn.us/gis/gismo_public/html/?mapbook=/datasets/CONF IGS/SAINT_PAUL/PUBLIC_WORKS/MAPBOOKS/TS/gismo3_test_public.xml# Unless someone comes up with an errors somewhere, I think I may post this tomorrow sometime. It still needs some work and I'll be adding to the comments the rest of the week. I think I'll version the releases until I get to something stable, but I think it's usable as is already, and I got a couple of requests for it already. I'm also planning on adding in the TIGER lines to this test interface, I only got out as far as six steps away from the world view in Google. I'll finish it off with the TIGER data. ------- Some stuff that came up this week, I've done all the thresholding based on FEET as the units of measure, and our data is in a local County coordinate system. Anyone have an idea for a good neutral coordinate system to use for the TIGER line dataset that would be the most flexible for folks? Another item I wondered about, would it help to separate up the MAPFILE for clarity into sections and use the INCLUDE parameter? This should make it a lot easier to follow some of the cartography settings, but maybe I'm making too much of it. I was wondering if this might be some sort of performance hit as well, I doubt it though. I'm also planning on doing some performance tuning, and separate up some of the TIGER data into road classes for performance reasons. I'm doing this for a couple of reasons, but the community gets to reap the results, so if there is interest, I'll keep going with the intention of publishing the TIGER data in a performance enhanced version. Otherwise, I'll just move onto the Railroad, Parks, and water layers to complete the look. If anyone wants to help out after taking a look at the thresholding I already have set up in the MapFile, it would be appreciated, we can pull all these layers together into a single package for distribution. Let me know your thoughts . . . bobb (Bob Basques [Bob.Basques at CI.STPAUL.MN.US]) ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Mike Saunt Sent: Wednesday, July 08, 2009 3:26 PM To: MAPSERVER USERS Subject: [mapserver-users] Sample Google Maps styled map file Hi All Long time since I've posted! Does anyone know where I can get a sample MapServer map file with Google Maps style styling? Much appreciated Mike From schatterjee at addisontx.gov Wed Jul 8 14:18:59 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Wed, 8 Jul 2009 16:18:59 -0500 Subject: [mapserver-users] Object reference not set to an instance of an object Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BD@sc-exchange.addisongov.org> Hi all, I am trying to develop an application in C# (VS2005) with mapscript. I saw the material of Paolo. But I am facing a problem In the line mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Ap ache/htdocs/mapservertest/Addison.map"].toString()) It is generating the error " Object reference not set to an instance of an object" How can I correct this? If anyone helps me in correcting it, it will be great. Suman ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at UDel.Edu Wed Jul 8 14:47:07 2009 From: john.callahan at UDel.Edu (John Callahan) Date: Wed, 08 Jul 2009 17:47:07 -0400 Subject: [mapserver-users] mapserver or MS4W package on Windows x64 Message-ID: <4A5513DB.4000702@udel.edu> I have an existing server running x64 Windows Server 2008. I've been running x64 version sof Apache 2.2.10 and PHP 5.2.5 as downloaded and described here: http://www.elxis.org/guides/developers-guides/64bit-apache-php-mysql-windows.html (PHP is currently running as an apache module) My question is could I use MS4W and follow the instructions under Installing for other Environments (http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL_3.0.html#j-installing-the-ms4w-mapserver-binaries-in-other-environments) Or, should I install the pieces (mapserver, gdal, etc...) separately, and possibly got the x64 versions from http://vbkto.dyndns.org:1280/sdk/Default.aspx ? At the start, I'll be using Mapserver for viewing of basic WMS services, nothing fancy. Not too far in the future though, I'll be using PHP or Python mapscript code, and/or implementing a package like GeoMoose. My data will be shapefiles, PostGIs features, and a few raster formats. Any suggestions on where I should start with setting up my server? Thanks. - John ************************************************** John Callahan, Geospatial Application Developer Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************** From szekerest at gmail.com Wed Jul 8 16:21:33 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Thu, 9 Jul 2009 01:21:33 +0200 Subject: [mapserver-users] Object reference not set to an instance of an object In-Reply-To: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BD@sc-exchange.addisongov.org> References: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BD@sc-exchange.addisongov.org> Message-ID: Hi Suman, I suspect System.Configuration.ConfigurationManager.AppSettings[?C:/ms4w/Apache/htdocs/mapservertest/Addison.map?] evaluates to null in your case, and therefore the ToString() operation on the null reference is failing which problem is not related to the MapScript library itself. Best regards, Tamas 2009/7/8 Suman Chatterjee > Hi all, > > I am trying to develop an application in C# (VS2005) with mapscript. I saw > the material of Paolo. But I am facing a problem > > > > In the line > > > > mapObj map= new > mapObj(System.Configuration.ConfigurationManager.AppSettings[?C:/ms4w/Apache/htdocs/mapservertest/Addison.map?].toString()) > > > > It is generating the error ? Object reference not set to an instance of an > object? > > > > How can I correct this? If anyone helps me in correcting it, it will be > great. > > > > Suman > > > > > > ******************************************************************************************************************* > > > This e-mail and any files or attachments transmitted with it contains > Information that is confidential and privileged. This document may contain > Protected Health Information (PHI) or other information that is intended > only for the use of the individual(s) and entity(ies) to whom it is > addressed. If you are the intended recipient, further disclosures are > prohibited without proper authorization. If you are not the intended > recipient, any disclosure, copying, printing, or use of this information is > strictly prohibited and possibly a violation of federal or state law and > regulations. If you have received this information in error, please delete > it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. > > ******************************************************************************************************************* > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Bob.Basques at ci.stpaul.mn.us Wed Jul 8 18:52:46 2009 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Wed, 08 Jul 2009 20:52:46 -0500 Subject: [mapserver-users] Sample Google Maps styled map file Message-ID: <4A551551020000A800014C7E@jeckle> All, The link posted below, is an old testing link. I'll dig out a link at the office in the morning for a MAPFILE download. If you don't want to wait, a copy of the finished product ended up tacked on to the end of this PDF: http://download.osgeo.org/mapserver/docs/mapserver-users-manual.pdf bobb >>> "Nolte, Tim" 07/08/09 2:38 PM >>> Here is another posting from Bob, posted here last year, All, I'm done with the cartography, I think. Anyone see any problems with it that are obvious? Again, this is only the road network, and it's only for a local dataset. http://gis.ci.stpaul.mn.us/gis/gismo_public/html/?mapbook=/datasets/CONF IGS/SAINT_PAUL/PUBLIC_WORKS/MAPBOOKS/TS/gismo3_test_public.xml# Unless someone comes up with an errors somewhere, I think I may post this tomorrow sometime. It still needs some work and I'll be adding to the comments the rest of the week. I think I'll version the releases until I get to something stable, but I think it's usable as is already, and I got a couple of requests for it already. I'm also planning on adding in the TIGER lines to this test interface, I only got out as far as six steps away from the world view in Google. I'll finish it off with the TIGER data. ------- Some stuff that came up this week, I've done all the thresholding based on FEET as the units of measure, and our data is in a local County coordinate system. Anyone have an idea for a good neutral coordinate system to use for the TIGER line dataset that would be the most flexible for folks? Another item I wondered about, would it help to separate up the MAPFILE for clarity into sections and use the INCLUDE parameter? This should make it a lot easier to follow some of the cartography settings, but maybe I'm making too much of it. I was wondering if this might be some sort of performance hit as well, I doubt it though. I'm also planning on doing some performance tuning, and separate up some of the TIGER data into road classes for performance reasons. I'm doing this for a couple of reasons, but the community gets to reap the results, so if there is interest, I'll keep going with the intention of publishing the TIGER data in a performance enhanced version. Otherwise, I'll just move onto the Railroad, Parks, and water layers to complete the look. If anyone wants to help out after taking a look at the thresholding I already have set up in the MapFile, it would be appreciated, we can pull all these layers together into a single package for distribution. Let me know your thoughts . . . bobb (Bob Basques [Bob.Basques at CI.STPAUL.MN.US]) ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Mike Saunt Sent: Wednesday, July 08, 2009 3:26 PM To: MAPSERVER USERS Subject: [mapserver-users] Sample Google Maps styled map file Hi All Long time since I've posted! Does anyone know where I can get a sample MapServer map file with Google Maps style styling? Much appreciated Mike _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From nnikolov at gypsii.com Thu Jul 9 00:42:06 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Thu, 9 Jul 2009 08:42:06 +0100 Subject: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 In-Reply-To: <4A5466C9.5157.008F.0@dnr.state.mn.us> References: <65D1C555BE9443A180F3B1697EF7E69F@BenefonUK.local> <4A5466C9.5157.008F.0@dnr.state.mn.us> Message-ID: <005e01ca0068$c2e49700$0401a8c0@BenefonUK.local> Hi Steve and everyone, The images below are from Mapserver 5.2.0 (left) and 5.4.1 (right) of the same map using AGG. Please note the difference in the size of the road shields (green shields). The following are images from the same servers (Mapserver 5.2.0 (left) and 5.4.1 (right)) of the same map (different zoom) using GD. Please note that the two maps are practically the same. The complete map-file used for the first example is attached to this e-mail. The parts of it specific to the issue are like that: OUTPUTFORMAT NAME AGG_PNG DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" #FORMATOPTION "QUANTIZE_FORCE=TRUE" #FORMATOPTION "QUANTIZE_COLORS=256" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END and CLASS EXPRESSION /^E/ LABEL PRIORITY 4 PARTIALS false MINFEATURESIZE 10 MINDISTANCE 300 COLOR 255 255 255 BACKGROUNDCOLOR 128 208 100 BACKGROUNDSHADOWCOLOR 81 145 58 ANGLE 0 BUFFER 2 FONT arial-bold TYPE truetype SIZE 7 END END The difference for the second examples is in the output format used: OUTPUTFORMAT NAME PNG DRIVER GD/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" #FORMATOPTION "QUANTIZE_FORCE=TRUE" #FORMATOPTION "QUANTIZE_COLORS=256" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END Many thanks, Nick -----Original Message----- From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Sent: 08 July 2009 15:29 To: Nikolai Nikolov; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 Perhaps you could post image samples and a mapfile? Steve >>> On 7/8/2009 at 3:05 AM, in message <65D1C555BE9443A180F3B1697EF7E69F at BenefonUK.local>, "Nikolai Nikolov" wrote: > Hi everyone, > > > > I've just upgraded one of my test servers from 5.2.0 to 5.4.1. I have an > issue there and I wonder whether anybody have noticed it. My map polygones > seems to be fractionaly smaller (compare to those drawned by 5.2.0). > > > > I am using the same maps, map files, PHP scripts, etc. The plygons which > belong to the same layer, do not quite well "fit" with each other - their > borders match perfectly before the upgarde to 5.4.1. > > > > Also, I use BACKGROUNDCOLOR in my map file to create shield like square > behind a label. Those squares are now significantly smaller too. > > > > I wander what causes this effect and what I should do to achieve the same > image as with 5.2.0? > > > > Thanks, > > Nick > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.gif Type: image/gif Size: 11234 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image002.gif Type: image/gif Size: 12319 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image003.gif Type: image/gif Size: 11626 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image004.gif Type: image/gif Size: 12970 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: zm9.map Type: application/octet-stream Size: 25582 bytes Desc: not available URL: From Tim.Nolte at ipcswirelessinc.com Thu Jul 9 06:04:25 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Thu, 9 Jul 2009 09:04:25 -0400 Subject: [mapserver-users] Serving Shapefiles via NFS, Protocol Version? Message-ID: I'm looking to put our map data on a storage device using NFS. I'm curious if there are any NFS settings to tweak for best performance and if I should be using NFSv3 or NFSv4? - Tim ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com From john.callahan at UDel.Edu Thu Jul 9 06:46:48 2009 From: john.callahan at UDel.Edu (John Callahan) Date: Thu, 09 Jul 2009 09:46:48 -0400 Subject: [mapserver-users] mapserver or MS4W package on Windows x64 In-Reply-To: <4A5513DB.4000702@udel.edu> References: <4A5513DB.4000702@udel.edu> Message-ID: <4A55F4C8.3050505@udel.edu> I started working with the x64 binaries from Tamas' site at http://vbkto.dyndns.org:1280/sdk/Default.aspx. MSVC2005 (Win64) seemed most appropriate for me. However, I did not see php mapscript support. Is that true? I did see mapscript for java, python, and csharp. Can php mapscript run at all with x64 versions of Apache/PHP and/or Mapserver? If not, then I'll have to give up x64 or PHP. Bummer. I've also been reading that I should run Mapserver in fastcgi mode, in either Win32 or Win64 versions. Does that mean to use PHP mapscript that I need to run PHP in cgi/fastcgi mode and NOT as an apache module? Thanks for any advice. It's a bit confusing. - John ************************************************** John Callahan, Geospatial Application Developer Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************** John Callahan wrote: > I have an existing server running x64 Windows Server 2008. I've been > running x64 version sof Apache 2.2.10 and PHP 5.2.5 as downloaded and > described here: > http://www.elxis.org/guides/developers-guides/64bit-apache-php-mysql-windows.html > (PHP is currently running as an apache module) > > > My question is could I use MS4W and follow the instructions under > Installing for other Environments > (http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL_3.0.html#j-installing-the-ms4w-mapserver-binaries-in-other-environments) > > > Or, should I install the pieces (mapserver, gdal, etc...) separately, > and possibly got the x64 versions from > http://vbkto.dyndns.org:1280/sdk/Default.aspx ? > > > At the start, I'll be using Mapserver for viewing of basic WMS > services, nothing fancy. Not too far in the future though, I'll be > using PHP or Python mapscript code, and/or implementing a package like > GeoMoose. My data will be shapefiles, PostGIs features, and a few > raster formats. > > Any suggestions on where I should start with setting up my server? > Thanks. > > - John > > ************************************************** > John Callahan, Geospatial Application Developer > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************** > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From bfraser at geoanalytic.com Thu Jul 9 07:44:27 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Thu, 09 Jul 2009 08:44:27 -0600 Subject: [mapserver-users] An example of GeoPDF output (not from Mapserver... yet) Message-ID: <4A56024B.7060706@geoanalytic.com> This post likely belongs in Geowanking (http://geowanking.org), but since we're getting close to releasing Mapserver with Cairo/PDF, I thought I'd stir the pot. The Canadian federal government's mapping department released a new rendered map product CanTopo (http://geogratis.cgdi.gc.ca/geogratis/en/collection/detail.do?id=37505) last week. So far they've only released about 50 of a possible 13,000 1:50k map sheets. Some interesting points: - The PDF info is vector (not simply a scanned map stuffed into a PDF) - they are GeoPDFs (if you use Acrobat Reader on Windows there will be a dynamic Lat/Lon/MGRS readout) - the info is organized onto layers you can switch on/off - the map is based on their CanVec GIS data (http://geogratis.cgdi.gc.ca/geogratis/en/product/search.do?id=28954) but the feature name label placement must have been done by hand! You can download them from the .ca link above, but here's one I've made available on my server: http://139.142.13.163/Download/Mapserver/092b12_0601_geo.pdf It will be interesting to see how close we can get to similar output with Mapserver 6.0... Best Regards, Brent Fraser GeoAnalytic Inc. From schatterjee at addisontx.gov Thu Jul 9 07:49:52 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Thu, 9 Jul 2009 09:49:52 -0500 Subject: [mapserver-users] Object reference not set to an instance of an object Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BE@sc-exchange.addisongov.org> Hi, I corrected my problem. Actually, I changed the code a little bit. Const string MAP_FILE = "c:/inetpub/wwwroot/Addison.map" Map= new mapObj(MAP_FILE) The line System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] Is throwing error. No idea what it is trying to do. Now my application is working fine in IIS and C#. Suman -----Original Message----- From: Tamas Szekeres [mailto:szekerest at gmail.com] Sent: Wednesday, July 08, 2009 6:22 PM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Object reference not set to an instance of an object Hi Suman, I suspect System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] evaluates to null in your case, and therefore the ToString() operation on the null reference is failing which problem is not related to the MapScript library itself. Best regards, Tamas 2009/7/8 Suman Chatterjee Hi all, I am trying to develop an application in C# (VS2005) with mapscript. I saw the material of Paolo. But I am facing a problem In the line mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Ap ache/htdocs/mapservertest/Addison.map"].toString()) It is generating the error " Object reference not set to an instance of an object" How can I correct this? If anyone helps me in correcting it, it will be great. Suman ************************************************************************ ******************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ************************************************************************ ******************************************* _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Thu Jul 9 08:10:33 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Thu, 9 Jul 2009 17:10:33 +0200 Subject: [mapserver-users] mapserver or MS4W package on Windows x64 In-Reply-To: <4A55F4C8.3050505@udel.edu> References: <4A5513DB.4000702@udel.edu> <4A55F4C8.3050505@udel.edu> Message-ID: 2009/7/9 John Callahan > I started working with the x64 binaries from Tamas' site at > http://vbkto.dyndns.org:1280/sdk/Default.aspx. MSVC2005 (Win64) seemed > most appropriate for me. However, I did not see php mapscript support. Is > that true? I did see mapscript for java, python, and csharp. > Can php mapscript run at all with x64 versions of Apache/PHP and/or > Mapserver? If not, then I'll have to give up x64 or PHP. Bummer. > Hi John, PHP support is lacking at the moment. I think if libphp could be compiled for x64 then it wouldn't be a problem to compile php mapscript against it. I'll give it a try this weekend if I have enough time. > > I've also been reading that I should run Mapserver in fastcgi mode, in > either Win32 or Win64 versions. Does that mean to use PHP mapscript that I > need to run PHP in cgi/fastcgi mode and NOT as an apache module? > I think that's not a strong requirement, you could either use fastcgi and cgi equally well, however fastcgi will perform better. Best regards, Tamas -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Thu Jul 9 08:13:59 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Thu, 9 Jul 2009 17:13:59 +0200 Subject: [mapserver-users] Object reference not set to an instance of an object In-Reply-To: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BE@sc-exchange.addisongov.org> References: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BE@sc-exchange.addisongov.org> Message-ID: 2009/7/9 Suman Chatterjee > > The line > System.Configuration.ConfigurationManager.AppSettings[?C:/ms4w/Apache/htdocs/mapservertest/Addison.map?] > > > Is throwing error. No idea what it is trying to do. > > You probably have to give the variable name of the application configuration in the indexer to the value. Best regards, Tamas -------------- next part -------------- An HTML attachment was scrubbed... URL: From pvoudouris at gaiocorp.com Thu Jul 9 09:48:06 2009 From: pvoudouris at gaiocorp.com (Pano Voudouris) Date: Thu, 9 Jul 2009 19:48:06 +0300 Subject: [mapserver-users] Object reference not set to an instance of an object In-Reply-To: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BE@sc-exchange.addisongov.org> References: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15BE@sc-exchange.addisongov.org> Message-ID: <003801ca00b5$0a344a00$1e9cde00$@com> Hi Suman, Check your web.config file- You probably have an entry similar to: . In your code you want to create the mapfile object by reading the mapfile path from web.config. So what you need to do is: mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["mapfile"].toSt ring()) (or whatever the variable in the web.config is called) You don't really want to use a constant to point to the mapfile... Pano From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Suman Chatterjee Sent: 09 July 2009 17:50 To: Tamas Szekeres Cc: mapserver-users at lists.osgeo.org Subject: RE: [mapserver-users] Object reference not set to an instance of an object Hi, I corrected my problem. Actually, I changed the code a little bit. Const string MAP_FILE = "c:/inetpub/wwwroot/Addison.map" Map= new mapObj(MAP_FILE) The line System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/htdocs /mapservertest/Addison.map"] Is throwing error. No idea what it is trying to do. Now my application is working fine in IIS and C#. Suman -----Original Message----- From: Tamas Szekeres [mailto:szekerest at gmail.com] Sent: Wednesday, July 08, 2009 6:22 PM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Object reference not set to an instance of an object Hi Suman, I suspect System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/htdocs /mapservertest/Addison.map"] evaluates to null in your case, and therefore the ToString() operation on the null reference is failing which problem is not related to the MapScript library itself. Best regards, Tamas 2009/7/8 Suman Chatterjee Hi all, I am trying to develop an application in C# (VS2005) with mapscript. I saw the material of Paolo. But I am facing a problem In the line mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache /htdocs/mapservertest/Addison.map"].toString()) It is generating the error " Object reference not set to an instance of an object" How can I correct this? If anyone helps me in correcting it, it will be great. Suman **************************************************************************** *************************************** This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. **************************************************************************** *************************************** _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at UDel.Edu Thu Jul 9 13:59:40 2009 From: john.callahan at UDel.Edu (John Callahan) Date: Thu, 09 Jul 2009 16:59:40 -0400 Subject: [mapserver-users] GetCapabilities response being truncated Message-ID: <4A565A3C.2060905@udel.edu> This seems to be a strange problem... I can generate maps fine through the browser and mode=map. However, responses to GetCapabilities requests are being truncated. They are being truncated to 4053 characters. I've tried this using two separate map files, using different data, both WMS 1.1.0 and 1.1.1 versions, and the same result every time. I found some references to old posts but they didn't seem to apply here. My data in each map file is just one shapefile. My map file symbology is also very simple; it's listed below. When run from the command line (mapserv "QUERY_STRING=map=...REQUEST=GetCapabilities"), it works perfectly. I'm using the x64 stable build from http://vbkto.dyndns.org:1280/sdk/Default.aspx (MSVC2005 Win64) Apache 2.2.10 and PHP 5.2.5 (x64 versions) if that matters. I just don't know what's going on. Sounds like a problem with my server setup. Has anyone experienced this before? Any suggestions on what I can check? Thanks. - John ***** start of mapfile # Map file created from QGIS project file C:/Apache2.2/cgi-bin/maps/geomap12.qgs # Edit this file to customize for your map interface # (Created with PyQgis MapServer Export plugin) MAP NAME 'geomap12' # Map image size SIZE 600 600 UNITS meters CONFIG "PROJ_LIB" "C:/programs/proj/nad/" EXTENT 213919.523729 80938.404739 236765.007609 99539.050324 PROJECTION "init=epsg:26957" END # Background color for the map canvas -- change as desired TRANSPARENT ON IMAGECOLOR 192 192 192 IMAGEQUALITY 95 IMAGETYPE png OUTPUTFORMAT NAME png DRIVER 'GD/PNG' MIMETYPE 'image/png' #IMAGEMODE PC256 EXTENSION 'png' END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH 'C:/Apache2.2/htdocs/output/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/output/' # WMS server settings METADATA 'wms_title' 'geomap12' 'wms_onlineresource' 'http://diagproweb01/cgi-bin/mapserv.exe?map=c:/webgis/mapfiles/geomap12.map&' 'wms_srs' 'EPSG:26957 EPSG:4326' END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation END LAYER NAME 'geounits' TYPE POLYGON DATA 'C:\webgis\data\geomap_pubs\geomap12.shp' METADATA 'wms_title' 'geounits' END STATUS DEFAULT TRANSPARENCY 100 PROJECTION "init=epsg:26957" END CLASS NAME 'geomap12' STYLE SYMBOL 0 SIZE 2 OUTLINECOLOR 0 0 0 COLOR 144 50 207 END END END END ***** end of mapfile ************************************************** John Callahan, Geospatial Application Developer Delaware Geological Survey, University of Delaware URL: http://www.dgs.udel.edu ************************************************** From john.callahan at UDel.Edu Thu Jul 9 15:29:15 2009 From: john.callahan at UDel.Edu (John Callahan) Date: Thu, 09 Jul 2009 18:29:15 -0400 Subject: [mapserver-users] GetCapabilities response being truncated In-Reply-To: <4A565A3C.2060905@udel.edu> References: <4A565A3C.2060905@udel.edu> Message-ID: <4A566F3B.1020804@udel.edu> Update: I should rephrase my statements... When run from the command line, c:\apache2.2\cgi-bin\mapserv "QUERY_STRING=map=...REQUEST=GetCapabilities" only works when output is to the screen. When directing the output to a file, like c:\apache2.2\cgi-bin\mapserv "QUERY_STRING=map=...REQUEST=GetCapabilities" > geomap.xml, then the output is again truncated. The limit is not 4053 characters but rather 4096 characters. At least the number makes more sense. Using MapServer 5.4.1, x64 in Windows 2008 Server. More details on the environment is: http://vbkto.dyndns.org:1280/sdk/PackageInfo.aspx?file=release-1400-x64-gdal-1-6-mapserver-5-4.zip - John John Callahan wrote: > This seems to be a strange problem... I can generate maps fine > through the browser and mode=map. However, responses to > GetCapabilities requests are being truncated. They are being > truncated to 4053 characters. I've tried this using two separate map > files, using different data, both WMS 1.1.0 and 1.1.1 versions, and > the same result every time. > I found some references to old posts but they didn't seem to apply > here. My data in each map file is just one shapefile. My map file > symbology is also very simple; it's listed below. > > When run from the command line (mapserv > "QUERY_STRING=map=...REQUEST=GetCapabilities"), it works perfectly. > > > I'm using the x64 stable build from > http://vbkto.dyndns.org:1280/sdk/Default.aspx (MSVC2005 Win64) Apache > 2.2.10 and PHP 5.2.5 (x64 versions) if that matters. > > > I just don't know what's going on. Sounds like a problem with my > server setup. Has anyone experienced this before? Any suggestions on > what I can check? Thanks. > > - John > > > ***** start of mapfile > # Map file created from QGIS project file > C:/Apache2.2/cgi-bin/maps/geomap12.qgs > # Edit this file to customize for your map interface > # (Created with PyQgis MapServer Export plugin) > MAP > NAME 'geomap12' > # Map image size > SIZE 600 600 > UNITS meters > > CONFIG "PROJ_LIB" "C:/programs/proj/nad/" > > EXTENT 213919.523729 80938.404739 236765.007609 99539.050324 > PROJECTION > "init=epsg:26957" > END > > # Background color for the map canvas -- change as desired > TRANSPARENT ON > IMAGECOLOR 192 192 192 > IMAGEQUALITY 95 > IMAGETYPE png > OUTPUTFORMAT > NAME png > DRIVER 'GD/PNG' > MIMETYPE 'image/png' > #IMAGEMODE PC256 > EXTENSION 'png' > END > > # Web interface definition. Only the template parameter > # is required to display a map. See MapServer documentation > WEB > # Set IMAGEPATH to the path where MapServer should > # write its output. > IMAGEPATH 'C:/Apache2.2/htdocs/output/' > > # Set IMAGEURL to the url that points to IMAGEPATH > # as defined in your web server configuration > IMAGEURL '/output/' > > # WMS server settings > METADATA > 'wms_title' 'geomap12' > 'wms_onlineresource' > 'http://diagproweb01/cgi-bin/mapserv.exe?map=c:/webgis/mapfiles/geomap12.map&' > > 'wms_srs' 'EPSG:26957 EPSG:4326' > END > > #Scale range at which web interface will operate > # Template and header/footer settings > # Only the template parameter is required to display a map. See > MapServer documentation > END > > LAYER > NAME 'geounits' > TYPE POLYGON > DATA 'C:\webgis\data\geomap_pubs\geomap12.shp' > METADATA > 'wms_title' 'geounits' > END > STATUS DEFAULT > TRANSPARENCY 100 > PROJECTION > "init=epsg:26957" > END > CLASS > NAME 'geomap12' > STYLE > SYMBOL 0 > SIZE 2 > OUTLINECOLOR 0 0 0 > COLOR 144 50 207 > END > END END > END > ***** end of mapfile > > ************************************************** > John Callahan, Geospatial Application Developer > Delaware Geological Survey, University of Delaware > URL: http://www.dgs.udel.edu > ************************************************** > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From trencoluis at gmail.com Fri Jul 10 01:08:09 2009 From: trencoluis at gmail.com (=?ISO-8859-1?Q?Luis_Almer=EDa_Trenco?=) Date: Fri, 10 Jul 2009 10:08:09 +0200 Subject: [mapserver-users] Raster layer with png legend Message-ID: <28efbb70907100108p5f2b0034g15bd20c5da9ebeb0@mail.gmail.com> Hi, anybody knows how to associate an image legend (.png) to a raster layer? I?m trying to do so with this .map, but it doesn?t work. LAYER NAME Mapabase20 TYPE raster STATUS on DATA "mapa_base20.png" MINSCALE 60000 MAXSCALE 400000 PROJECTION "init=epsg:23030" END METADATA "wms_title" "Mapa Base 20" "wms_abstract" "Imagen raster" "wms_keywordlist" "WMS imagen raster" "wms_srs" "EPSG:23030" "wms_style" "leyendaMapabase20" "wms_style_leyendaMapabase20_legendurl_href" " http://192.168.13.221/leyendaMapaBase/Leyendas/Leyenda_mapabase20.png" "wms_style_leyendaMapabase20_legendurl_width" "75" "wms_style_leyendaMapabase20_legendurl_height" "50" "wms_style_leyendaMapabase20_legendurl_format" "image/png" END END #fin de mapabase20 Is there anything left? Is it possible to do it? Thank you. Luis -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at camptocamp.com Fri Jul 10 01:18:29 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Fri, 10 Jul 2009 10:18:29 +0200 Subject: [mapserver-users] Raster layer with png legend In-Reply-To: <28efbb70907100108p5f2b0034g15bd20c5da9ebeb0@mail.gmail.com> References: <28efbb70907100108p5f2b0034g15bd20c5da9ebeb0@mail.gmail.com> Message-ID: <2922382e0907100118y30463fdfn3b0d317f4a048948@mail.gmail.com> http://mapserver.org/mapfile/class.html -> KEYIMAGE regards, thomas www.camptocamp.com +33 4 79 26 57 97 2009/7/10 Luis Almer?a Trenco : > Hi, > > > > anybody knows how to associate an image legend (.png) to a raster layer? I?m > trying to do so with this .map, but it doesn?t work. > > > > LAYER > > ??????????? NAME Mapabase20 > > ??????????? TYPE raster > > ??????????? STATUS on > > ??????????? DATA "mapa_base20.png" > > ? ????????? MINSCALE 60000 > > ? ????????? MAXSCALE 400000 > > > > ??????????? PROJECTION > > ??????????? "init=epsg:23030" > > ??????????? END > > > > ??????????? METADATA > > ??????????? "wms_title" "Mapa Base 20" > > ??????????? "wms_abstract" "Imagen raster" > > ??????????? "wms_keywordlist" "WMS imagen raster" > > ??????????? "wms_srs" "EPSG:23030" > > ??????????? "wms_style" "leyendaMapabase20" > > ??????????? "wms_style_leyendaMapabase20_legendurl_href" > "http://192.168.13.221/leyendaMapaBase/Leyendas/Leyenda_mapabase20.png" > > ??????????? "wms_style_leyendaMapabase20_legendurl_width" "75" > > ??????????? "wms_style_leyendaMapabase20_legendurl_height" "50" > > ??????????? "wms_style_leyendaMapabase20_legendurl_format" "image/png" > > ??????????? END > > END #fin de mapabase20 > > > > Is there anything left? Is it possible to do it? Thank you. > > Luis > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From youness.elmedraoui at somei.fr Fri Jul 10 03:32:07 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Fri, 10 Jul 2009 12:32:07 +0200 Subject: [mapserver-users] Oracle native / Oracle OGR Message-ID: An HTML attachment was scrubbed... URL: From schatterjee at addisontx.gov Fri Jul 10 06:41:50 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Fri, 10 Jul 2009 08:41:50 -0500 Subject: [mapserver-users] Object reference not set to an instance of an object Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D002797755@sc-exchange.addisongov.org> -----Original Message----- From: Pano Voudouris [mailto:pvoudouris at gaiocorp.com] Sent: Thursday, July 09, 2009 11:48 AM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: RE: [mapserver-users] Object reference not set to an instance of an object Hi Suman, Check your web.config file- You probably have an entry similar to: ... In your code you want to create the mapfile object by reading the mapfile path from web.config. So what you need to do is: mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["mapfile"]. toString()) (or whatever the variable in the web.config is called) You don't really want to use a constant to point to the mapfile... Pano From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Suman Chatterjee Sent: 09 July 2009 17:50 To: Tamas Szekeres Cc: mapserver-users at lists.osgeo.org Subject: RE: [mapserver-users] Object reference not set to an instance of an object Hi, I corrected my problem. Actually, I changed the code a little bit. Const string MAP_FILE = "c:/inetpub/wwwroot/Addison.map" Map= new mapObj(MAP_FILE) The line System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] Is throwing error. No idea what it is trying to do. Now my application is working fine in IIS and C#. Suman -----Original Message----- From: Tamas Szekeres [mailto:szekerest at gmail.com] Sent: Wednesday, July 08, 2009 6:22 PM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Object reference not set to an instance of an object Hi Suman, I suspect System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] evaluates to null in your case, and therefore the ToString() operation on the null reference is failing which problem is not related to the MapScript library itself. Best regards, Tamas 2009/7/8 Suman Chatterjee Hi all, I am trying to develop an application in C# (VS2005) with mapscript. I saw the material of Paolo. But I am facing a problem In the line mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Ap ache/htdocs/mapservertest/Addison.map"].toString()) It is generating the error " Object reference not set to an instance of an object" How can I correct this? If anyone helps me in correcting it, it will be great. Suman ************************************************************************ ******************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ************************************************************************ ******************************************* _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From schatterjee at addisontx.gov Fri Jul 10 06:47:08 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Fri, 10 Jul 2009 08:47:08 -0500 Subject: [mapserver-users] Object reference not set to an instance of an object Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D002797756@sc-exchange.addisongov.org> Hi Pano, Thank you very much. It worked. Yes, it was the thing I wanted to do. Now I understand the meaning of the ConfigurationManager. Thank You once again. Suman -----Original Message----- From: Pano Voudouris [mailto:pvoudouris at gaiocorp.com] Sent: Thursday, July 09, 2009 11:48 AM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: RE: [mapserver-users] Object reference not set to an instance of an object Hi Suman, Check your web.config file- You probably have an entry similar to: ... In your code you want to create the mapfile object by reading the mapfile path from web.config. So what you need to do is: mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["mapfile"]. toString()) (or whatever the variable in the web.config is called) You don't really want to use a constant to point to the mapfile... Pano From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Suman Chatterjee Sent: 09 July 2009 17:50 To: Tamas Szekeres Cc: mapserver-users at lists.osgeo.org Subject: RE: [mapserver-users] Object reference not set to an instance of an object Hi, I corrected my problem. Actually, I changed the code a little bit. Const string MAP_FILE = "c:/inetpub/wwwroot/Addison.map" Map= new mapObj(MAP_FILE) The line System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] Is throwing error. No idea what it is trying to do. Now my application is working fine in IIS and C#. Suman -----Original Message----- From: Tamas Szekeres [mailto:szekerest at gmail.com] Sent: Wednesday, July 08, 2009 6:22 PM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Object reference not set to an instance of an object Hi Suman, I suspect System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Apache/ht docs/mapservertest/Addison.map"] evaluates to null in your case, and therefore the ToString() operation on the null reference is failing which problem is not related to the MapScript library itself. Best regards, Tamas 2009/7/8 Suman Chatterjee Hi all, I am trying to develop an application in C# (VS2005) with mapscript. I saw the material of Paolo. But I am facing a problem In the line mapObj map= new mapObj(System.Configuration.ConfigurationManager.AppSettings["C:/ms4w/Ap ache/htdocs/mapservertest/Addison.map"].toString()) It is generating the error " Object reference not set to an instance of an object" How can I correct this? If anyone helps me in correcting it, it will be great. Suman ************************************************************************ ******************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ************************************************************************ ******************************************* _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Fri Jul 10 06:58:21 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Fri, 10 Jul 2009 15:58:21 +0200 Subject: [mapserver-users] [mapserver/ .net] connection to db oracle with OGR Message-ID: An HTML attachment was scrubbed... URL: From geomartino at gmail.com Fri Jul 10 07:36:06 2009 From: geomartino at gmail.com (Martin Ouellet) Date: Fri, 10 Jul 2009 10:36:06 -0400 Subject: [mapserver-users] how to ignore tag from the getcapabilities Message-ID: <28d70b140907100736x3869fc92xdb6f909cb0c01ce@mail.gmail.com> Hi, I have a URL (which is good and functionnal) but the GetCapabilities return a invalid URL in the tag. Is there a way to tell Mapserver to use the url specified in the mapfile (tag CONNECTION) instead of the url return in the of the getcapabilities request? Thank you in advance! MartinO -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at pobox.com Fri Jul 10 08:36:47 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Fri, 10 Jul 2009 11:36:47 -0400 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: References: Message-ID: <4A57600F.4000103@pobox.com> YOUNESS ELMEDRAOUI wrote: > Hello everybody, > > i have a question: > what's the difference between a connection to oracle DB with native > oraclespatial and OGR? > performance, ...?? Youness, Generally speaking the direct connection should be faster since it avoids a lot of OGR overhead. They are completely distict implementations so you might find each has quirks and strengths though I can't really identify them off hand. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From joel.d.schlagel at usace.army.mil Fri Jul 10 08:59:16 2009 From: joel.d.schlagel at usace.army.mil (Schlagel, Joel D IWR) Date: Fri, 10 Jul 2009 11:59:16 -0400 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: <4A57600F.4000103@pobox.com> Message-ID: For what it's worth - we've used the oracle direct connect in a production environment all day, every day for several years with no quirks to report. -joel On 7/10/09 11:36 AM, "Frank Warmerdam" wrote: > YOUNESS ELMEDRAOUI wrote: >> Hello everybody, >> >> i have a question: >> what's the difference between a connection to oracle DB with native >> oraclespatial and OGR? >> performance, ...?? > > Youness, > > Generally speaking the direct connection should be faster since it avoids > a lot of OGR overhead. They are completely distict implementations so > you might find each has quirks and strengths though I can't really identify > them off hand. > > Best regards, -joel -- Joel D. Schlagel US Army Engineer Institute for Water Resources http://www.iwr.usace.army.mil From gis at vanbooth.com Fri Jul 10 09:23:28 2009 From: gis at vanbooth.com (Rob) Date: Fri, 10 Jul 2009 17:23:28 +0100 Subject: [mapserver-users] Reprojecting cascading WMS requests Message-ID: <2a955f950907100923m1ad368b7m8eb9e00727d29baa@mail.gmail.com> Hi I'm obviously having Friday afternoon blindness, as I can't see what I am doing wrong! I am trying to set up a basic Mapserver install (MS4W v3.0 Beta 4) MapServer version 5.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICO NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUP PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE which points to a WMS service which only supports a single projection. I want to get my Mapserver to reproject that data on the fly to other projection systems, but don't seem to be doing it right! This is my mapfile MAP NAME SPIRIT STATUS ON SIZE 600 600 EXTENT 0 0 650000 1300000 UNITS METERS SHAPEPATH "temp" IMAGECOLOR 255 255 255 #FONTSET 'fontset.txt' #SYMBOLSET 'temp/examples.sym' IMAGETYPE JPEG IMAGEQUALITY 75 IMAGETYPE png OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE rgb END IMAGETYPE jpeg OUTPUTFORMAT NAME jpeg DRIVER "GD/JPEG" MIMETYPE "image/jpeg" IMAGEMODE rgb END PROJECTION "init=epsg:27700" END WEB IMAGEPATH "c:\temp\" METADATA WMS_TITLE "WMS Server" WMS_ABSTRACT "WMS Server." WMS_ONLINERESOURCE "http://localhost/cgi-bin/mapserv.exe?map=example.map&" WMS_SRS "EPSG:27700 ESPG:4326" END END LAYER NAME "layer" TYPE RASTER STATUS ON CONNECTION "http://externalwmshost/&" CONNECTIONTYPE WMS METADATA "wms_srs" "EPSG:27700" "wms_name" "layername" "wms_server_version" "1.1.1" "wms_formatlist" "image/png,image/jpeg" END END END END # Map File but when I make a WMS request against it http://localhost/cgi-bin/mapserv.exe?map=example.map&request=getmap&service=wms&layers=layer&bbox=53.5,1.4,53.51,1.41&width=400&height=400&version=1.1.1&srs=EPSG:4326&format=jpeg I get msWMSLoadGetMapParams(): WMS server error. Invalid SRS given : SRS must be valid for all requested layers. I'm guessing I'm missing something simple, but I don't know what it is. Any help gratefully accepted! Thanks Rob From jevoudrais0418 at gmail.com Fri Jul 10 09:28:03 2009 From: jevoudrais0418 at gmail.com (rmaurer) Date: Fri, 10 Jul 2009 09:28:03 -0700 (PDT) Subject: [mapserver-users] access problems from cgi-bin on Mac OS X 10.4.11 / MAMP Message-ID: <1247243283076-3236919.post@n2.nabble.com> So I'm a first time MapServer user and have been trying to navigate the installation process. I think I almost have it, but I am having some last problems. When I access my executable mapserv file from the command line, I get this: This script can only be used to decode form results and should be initiated as a CGI process via a httpd server. All sounds good, right? Well, I am using MAMP to host an Apache2.0 server. The httpd.conf file has the following in it: Alias /cgi-bin/ "[rootfile]/cgi-bin/" Directory "[rootfile]/cgi-bin/\> AllowOverride None Options ExecCGI FollowSymLinks Indexes Order allow,deny Allow from all /Directory\> AddHandler cgi-script .cgi .py I know that first line should probably be ScriptAlias, but I kept getting a "Permission Denied" message and read in a forum that this was a solution somebody had come up with, and indeed it worked for me as well. Anyways, the problem is that in this cgi-bin I have my mapserv executable (though one of the things I'm thinking is that maybe I need to add something else to AddHandler to make it think that this file is executable?). But when I got to //localhost/cgi-bin/mapserv it tries to download the file as "Untyped Binary Data" and it doesn't execute anthing. In case its of any help the ls -l for my cgi-bin gives the following information: -rwxr-xr-x 1 Rebecca Rebecca 51244 Jul 9 07:52 mapserv Do I not have this installed correctly? Or is my server just not realizing that this is executable. I would be thrilled if I could just get to the point where //localhost/cgi-bin/mapserv just brought up a "No query information to decode" message, since I think I can handle it from there. Thank you very much, Rebecca -- View this message in context: http://n2.nabble.com/access-problems-from-cgi-bin-on-Mac-OS-X-10.4.11---MAMP-tp3236919p3236919.html Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Fri Jul 10 09:59:01 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Fri, 10 Jul 2009 18:59:01 +0200 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: References: Message-ID: Hi, I've already tested these 2 methods with a couple of mapfiles on Windows, but I haven't found significant differences in the rendering speed. In my special case the OGR option was more compelling, since in this case we can use STYLEITEM "AUTO" option. Therefore I could easily migrate all the stuff from OGR TAB files to Oracle spatial by keeping the labeling and style information and only some trivial replaces had to be done in the existing mapfiles to switch from the tabfiles to the Oracle data sources. Best regards, Tamas 2009/7/10 YOUNESS ELMEDRAOUI > Hello everybody, > > i have a question: > what's the difference between a connection to oracle DB with native > oraclespatial and OGR? > performance, ...?? > > thanks > > > Best regards > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From woklist at kyngchaos.com Fri Jul 10 10:10:40 2009 From: woklist at kyngchaos.com (William Kyngesburye) Date: Fri, 10 Jul 2009 12:10:40 -0500 Subject: [mapserver-users] access problems from cgi-bin on Mac OS X 10.4.11 / MAMP In-Reply-To: <1247243283076-3236919.post@n2.nabble.com> References: <1247243283076-3236919.post@n2.nabble.com> Message-ID: On Jul 10, 2009, at 11:28 AM, rmaurer wrote: > So I'm a first time MapServer user and have been trying to navigate > the installation process. I think I almost have it, but I am having > some last problems. Just a check: are you using my installer, or compiling from source? What OSX version? If you are using my installer, and are on OSX 10.4, Mapserver is built for Apache 1.3, as found in the system, and it probably won't work correctly, if at all with an added-on Apache 2. If you are on OSX 10.5, why not just use the system Apache 2? > When I access my executable mapserv file from the command line, I > get this: > > This script can only be used to decode form results and should be > initiated as a CGI process via a httpd server. > > All sounds good, right? Well, I am using MAMP to host an Apache2.0 > server. The httpd.conf file has the following in it: > Alias /cgi-bin/ "[rootfile]/cgi-bin/" > > Directory "[rootfile]/cgi-bin/\> > AllowOverride None > Options ExecCGI FollowSymLinks Indexes > Order allow,deny > Allow from all > /Directory\> > Are the starting '<' really missing, or did Mail strip them out? I also see closing quotes missing and extra \ chars. Should be: AllowOverride None Options ExecCGI FollowSymLinks Indexes Order allow,deny Allow from all > AddHandler cgi-script .cgi .py > > I know that first line should probably be ScriptAlias, but I kept > getting a "Permission Denied" message and read in a forum that this > was a solution somebody had come up with, and indeed it worked for > me as well. > > Anyways, the problem is that in this cgi-bin I have my mapserv > executable (though one of the things I'm thinking is that maybe I > need to add something else to AddHandler to make it think that this > file is executable?). That addhandler is to run scripts as CGI. Mapserv is a binary, so all it should need is ExecCGI. > But when I got to //localhost/cgi-bin/mapserv it tries to download > the file as "Untyped Binary Data" and it doesn't execute anthing. > I'm not sure, but you may need to load the mod_cgi module in your httpd.conf. Though it may only apply to script CGIs also. > In case its of any help the ls -l for my cgi-bin gives the following > information: -rwxr-xr-x 1 Rebecca Rebecca 51244 Jul 9 07:52 mapserv > > Do I not have this installed correctly? Or is my server just not > realizing that this is executable. I would be thrilled if I could > just get to the point where //localhost/cgi-bin/mapserv just brought > up a "No query information to decode" message, since I think I can > handle it from there. > And, make sure to restart Apache after changing httpd.conf ;) Oh, and make sure that the system Apache is not running (System Preferences->Sharing->Web Sharing), as it will be using the same port and your MAMP Apache won't even start. ----- William Kyngesburye http://www.kyngchaos.com/ Earth: "Mostly harmless" - revised entry in the HitchHiker's Guide to the Galaxy From thomas.bonfort at camptocamp.com Fri Jul 10 11:38:03 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Fri, 10 Jul 2009 20:38:03 +0200 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: References: <4A57600F.4000103@pobox.com> Message-ID: <2922382e0907101138v4c6ce246p8b8f67893800c49e@mail.gmail.com> some of our clients have come up with a few quirks in the native oracle driver that should be taken into account: * the strings storing the fields returned by the database have a fixed length in mapserver, so that might have to be overridden at compile time if you are planning to return data longer than a certain value (2048 bytes from memory). For normal map rendering this shouldn't be a problem, but problems may arise when doing wfs queries and returning a paragraph of text for example in an attribute. * I haven't investigated this much more, but we've also had problems with long query strings (we're talking DATA mapfile strings of several kbytes here) regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Fri, Jul 10, 2009 at 17:59, Schlagel, Joel D IWR wrote: > For what it's worth - we've used the oracle direct connect in a production > environment all day, every day for several years with no quirks to report. > > -joel > > > > On 7/10/09 11:36 AM, "Frank Warmerdam" wrote: > >> YOUNESS ELMEDRAOUI wrote: >>> Hello everybody, >>> >>> i have a question: >>> what's the difference between a connection to oracle DB with native >>> oraclespatial and OGR? >>> performance, ...?? >> >> Youness, >> >> Generally speaking the direct connection should be faster since it avoids >> a lot of OGR overhead. ?They are completely distict implementations so >> you might find each has quirks and strengths though I can't really identify >> them off hand. >> >> Best regards, > > > -joel > > -- > Joel D. Schlagel > US Army Engineer Institute for Water Resources > http://www.iwr.usace.army.mil > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From jamador at sonomatech.com Fri Jul 10 12:27:04 2009 From: jamador at sonomatech.com (Jason M. Amador) Date: Fri, 10 Jul 2009 12:27:04 -0700 Subject: [mapserver-users] Displaying attribute data and Message-ID: <7FCA68A9CE5FD5459475C05E555FA2CB026FA1D5@exchange.sonomatech.com> Hi, I'm new to GIS and MapServer and was hoping I could get some help with a few questions. Any help is greatly appreciated. 1. From a high level, how do you display attribute data after clicking on a map? I've seen examples but am unsure how this is accomplished. Is this done by using a WMS GetFeatureInfo request or through querying? 2. Is it possible to change the attribute data (whether in files or a spatial database) and what is the method to do this? Thanks, Jason -------------- next part -------------- An HTML attachment was scrubbed... URL: From michael.smith at usace.army.mil Fri Jul 10 12:29:12 2009 From: michael.smith at usace.army.mil (Smith, Michael ERDC-CRREL-NH) Date: Fri, 10 Jul 2009 15:29:12 -0400 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: <2922382e0907101138v4c6ce246p8b8f67893800c49e@mail.gmail.com> Message-ID: Thomas, To solve the second issue, use a view. Mike -- Michael Smith Remote Sensing GIS Center CRREL - ERDC US Army Corps of Engineers Hanover, NH On 7/10/09 2:38 PM, "Thomas Bonfort" wrote: > some of our clients have come up with a few quirks in the native > oracle driver that should be taken into account: > > * the strings storing the fields returned by the database have a fixed > length in mapserver, so that might have to be overridden at compile > time if you are planning to return data longer than a certain value > (2048 bytes from memory). For normal map rendering this shouldn't be a > problem, but problems may arise when doing wfs queries and returning a > paragraph of text for example in an attribute. > > * I haven't investigated this much more, but we've also had problems > with long query strings (we're talking DATA mapfile strings of several > kbytes here) > > regards, > > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Fri, Jul 10, 2009 at 17:59, Schlagel, Joel D > IWR wrote: >> For what it's worth - we've used the oracle direct connect in a production >> environment all day, every day for several years with no quirks to report. >> >> -joel >> >> >> >> On 7/10/09 11:36 AM, "Frank Warmerdam" wrote: >> >>> YOUNESS ELMEDRAOUI wrote: >>>> Hello everybody, >>>> >>>> i have a question: >>>> what's the difference between a connection to oracle DB with native >>>> oraclespatial and OGR? >>>> performance, ...?? >>> >>> Youness, >>> >>> Generally speaking the direct connection should be faster since it avoids >>> a lot of OGR overhead. ?They are completely distict implementations so >>> you might find each has quirks and strengths though I can't really identify >>> them off hand. >>> >>> Best regards, >> >> >> -joel >> >> -- >> Joel D. Schlagel >> US Army Engineer Institute for Water Resources >> http://www.iwr.usace.army.mil >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From thomas.bonfort at camptocamp.com Fri Jul 10 12:46:47 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Fri, 10 Jul 2009 21:46:47 +0200 Subject: [mapserver-users] Oracle native / Oracle OGR In-Reply-To: References: <2922382e0907101138v4c6ce246p8b8f67893800c49e@mail.gmail.com> Message-ID: <2922382e0907101246o3cc1ec5ch6535bc15b3e51330@mail.gmail.com> this can be a solution in some cases yes. In ours the the query is dynamically built and passed on through the url, so it isn't as simple as that. thomas On Fri, Jul 10, 2009 at 21:29, Smith, Michael ERDC-CRREL-NH wrote: > Thomas, > > To solve the second issue, use a view. > > Mike > > > -- > Michael Smith > Remote Sensing GIS Center > CRREL - ERDC > US Army Corps of Engineers > Hanover, NH > > > > > On 7/10/09 2:38 PM, "Thomas Bonfort" wrote: > >> some of our clients have come up with a few quirks in the native >> oracle driver that should be taken into account: >> >> * the strings storing the fields returned by the database have a fixed >> length in mapserver, so that might have to be overridden at compile >> time if you are planning to return data longer than a certain value >> (2048 bytes from memory). For normal map rendering this shouldn't be a >> problem, but problems may arise when doing wfs queries and returning a >> paragraph of text for example in an attribute. >> >> * I haven't investigated this much more, but we've also had problems >> with long query strings (we're talking DATA mapfile strings of several >> kbytes here) >> >> regards, >> >> thomas >> >> www.camptocamp.com >> +33 4 79 26 57 97 >> >> >> >> On Fri, Jul 10, 2009 at 17:59, Schlagel, Joel D >> IWR wrote: >>> For what it's worth - we've used the oracle direct connect in a production >>> environment all day, every day for several years with no quirks to report. >>> >>> -joel >>> >>> >>> >>> On 7/10/09 11:36 AM, "Frank Warmerdam" wrote: >>> >>>> YOUNESS ELMEDRAOUI wrote: >>>>> Hello everybody, >>>>> >>>>> i have a question: >>>>> what's the difference between a connection to oracle DB with native >>>>> oraclespatial and OGR? >>>>> performance, ...?? >>>> >>>> Youness, >>>> >>>> Generally speaking the direct connection should be faster since it avoids >>>> a lot of OGR overhead. ?They are completely distict implementations so >>>> you might find each has quirks and strengths though I can't really identify >>>> them off hand. >>>> >>>> Best regards, >>> >>> >>> -joel >>> >>> -- >>> Joel D. Schlagel >>> US Army Engineer Institute for Water Resources >>> http://www.iwr.usace.army.mil >>> >>> >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From MarkVolz at co.lyon.mn.us Fri Jul 10 12:57:58 2009 From: MarkVolz at co.lyon.mn.us (Mark Volz) Date: Fri, 10 Jul 2009 14:57:58 -0500 Subject: [mapserver-users] RE: Reprojecting cascading WMS requests (Rob) In-Reply-To: <20090710192731.03B14E01E84@lists.osgeo.org> References: <20090710192731.03B14E01E84@lists.osgeo.org> Message-ID: <3D56274B4A7874468F58FADDBFD09801078AF885@llmhs02.r8nssis.local> Rob, Anyone can correct me if I am wrong on this however I think you have to enter projection information in 3 times. 1) the projection of your map 2) the projection of your data, in this case the wms service so that mapserver knows what to reproject from. 3) the projection that you are requesting from the wms service - in the metadata section. I am doing this on some of my applications so let me know if your having trouble, otherwise if someone has a better thought let me know if I am wasting lines of code. Example: MAP ... Projection # of the Map End Projection ... .. Layer Projection # of the Source End Projection ... Metadata "wms_srs" "ESPG:27700" #projection you are requesting in WMS .... End #Metadata ... End #layer Mark Volz GIS Specialist Lyon County, MN (507) 532-8218 ---------------------------------------------------------------------- Message: 1 Date: Fri, 10 Jul 2009 17:23:28 +0100 From: Rob Subject: [mapserver-users] Reprojecting cascading WMS requests To: mapserver-users at lists.osgeo.org Message-ID: <2a955f950907100923m1ad368b7m8eb9e00727d29baa at mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 Hi I'm obviously having Friday afternoon blindness, as I can't see what I am doing wrong! I am trying to set up a basic Mapserver install (MS4W v3.0 Beta 4) MapServer version 5.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICO NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUP PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE which points to a WMS service which only supports a single projection. I want to get my Mapserver to reproject that data on the fly to other projection systems, but don't seem to be doing it right! This is my mapfile MAP NAME SPIRIT STATUS ON SIZE 600 600 EXTENT 0 0 650000 1300000 UNITS METERS SHAPEPATH "temp" IMAGECOLOR 255 255 255 #FONTSET 'fontset.txt' #SYMBOLSET 'temp/examples.sym' IMAGETYPE JPEG IMAGEQUALITY 75 IMAGETYPE png OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE rgb END IMAGETYPE jpeg OUTPUTFORMAT NAME jpeg DRIVER "GD/JPEG" MIMETYPE "image/jpeg" IMAGEMODE rgb END PROJECTION "init=epsg:27700" END WEB IMAGEPATH "c:\temp\" METADATA WMS_TITLE "WMS Server" WMS_ABSTRACT "WMS Server." WMS_ONLINERESOURCE "http://localhost/cgi-bin/mapserv.exe?map=example.map&" WMS_SRS "EPSG:27700 ESPG:4326" END END LAYER NAME "layer" TYPE RASTER STATUS ON CONNECTION "http://externalwmshost/&" CONNECTIONTYPE WMS METADATA "wms_srs" "EPSG:27700" "wms_name" "layername" "wms_server_version" "1.1.1" "wms_formatlist" "image/png,image/jpeg" END END END END # Map File but when I make a WMS request against it http://localhost/cgi-bin/mapserv.exe?map=example.map&request=getmap&service=w ms&layers=layer&bbox=53.5,1.4,53.51,1.41&width=400&height=400&version=1.1.1&s rs=EPSG:4326&format=jpeg I get msWMSLoadGetMapParams(): WMS server error. Invalid SRS given : SRS must be valid for all requested layers. I'm guessing I'm missing something simple, but I don't know what it is. Any help gratefully accepted! Thanks Rob From tohashmi at gmail.com Fri Jul 10 23:22:39 2009 From: tohashmi at gmail.com (Hussain Hashmi) Date: Sat, 11 Jul 2009 09:22:39 +0300 Subject: [mapserver-users] Fwd: queryByPoint - Street Layer ? In-Reply-To: <4A549786.5157.008F.0@dnr.state.mn.us> References: <0F058FF13E3C0C468E932D15ABF604DA0DB367C844@RHCLMLBX00.sp.local> <28aabd160907081020g1a1482f4mabdfe3c24d7472cc@mail.gmail.com> <4A549786.5157.008F.0@dnr.state.mn.us> Message-ID: <28aabd160907102322u2751a3b4v5b1ae5070e57acda@mail.gmail.com> On Wed, Jul 8, 2009 at 8:56 PM, Steve Lime wrote: > May well be a tolerance issue. By default it's in pixels and based on the > extent you're setting (I don't > know what the map SIZE is set to) it's probably a super tiny value. Have > you tried setting a tolerance > in map units? E.g. > > TOLERANCE 5 > TOLERANCEUNITS meters # or whatever > > Just an idea... > > Steve > > >>> On 7/8/2009 at 12:20 PM, in message > <28aabd160907081020g1a1482f4mabdfe3c24d7472cc at mail.gmail.com>, Hussain > Hashmi > wrote: > > hi > > > > Can someone here guide me on this issue please. > > My Objective is to get attribute values for any selected street (Line). > > My client application is based on KaMap. > > I have a similar solution for Polygons which works perfectly. > > > > > > I am trying to query a street layer which gives me the following error. > > > > Warning: [MapServer Error]: msQueryByPoint(): No matching record(s) found > in > > C:\... on line 84 > > Warning: [MapServer Error]: msShapefileOpen(): > > (/ms4w/maps/./city/./city/streets) in c:\... on line 84 > > > > > > MAPFILE > > ********************** > > LAYER > > NAME 'streets_Query' > > GROUP 'streets_Query' > > DATA './city/streets' > > TYPE line > > MAXSCALE 3001 > > STATUS ON > > > > TOLERANCE 5 > > TEMPLATE './_templates/Streets_Identify.html' > > METADATA > > "queryable" "true" > > searchfield "ANAME" > > fields "ZIP_CODE" > > END > > END #end layer > > > > > > > > PHP MAPSCRIPT > > ********************** > > //------- Get Input Parameters. > > if (isset($_REQUEST['map'])) {$szMap = $_REQUEST['map'];} else {echo > "map > > not defined"; die;} > > if (isset($_REQUEST['coords'])) {$coords = > > explode(',',$_REQUEST['coords']);} else {echo "coordinate not defined"; > > die;} > > > > > > //------- Load Mapscript Module. > > $szPHPMapScriptModule = 'php_mapscript.'.PHP_SHLIB_SUFFIX; > > if (!extension_loaded('MapScript')) { > > dl($szPHPMapScriptModule); > > } > > > > //------- Load Current Map file. > > $szMapFile=str_replace('<>',$szMap,'/ms4w/maps/<>.map'); > > $oMap = ms_newMapObj($szMapFile); > > > > > > //------- SETTING MAP EXTENT to query extent.. > > $mapExtent = $oMap->extent; > > $oMap->setExtent($coords[0],$coords[1], > > $coords[0]+0.000001,$coords[1]+0.000001); > > > > //------- SETTING QUERY POINT > > $point = ms_newPointObj(); > > $point->setXY($coords[0], $coords[1]); > > > > //------- Initialize map query. > > $oMap->preparequery(); > > > > //------- LOOP ON LAYERS and get identify results. > > $tot = $oMap->numlayers; > > for ($i = 0; $i < $tot; $i++) { > > //------- get map layer. > > $oLayer = $oMap->getLayer($i); > > > > //------- Verify Layer type > > if ($oLayer->name != 'streets_Query') continue; > > > > //------- Validate if query succeeds. > > $check_query = $oLayer->queryByPoint($point, MS_SINGLE, 0); > > if ($check_query != MS_SUCCESS) {continue;} > > > > //------- Open layer for data input. > > $oLayer->open(); > > > > //------- Get the record values corresponding to a result tileindex. > > $oResultCache = $oLayer->getResult(0); > > $oShape = $oLayer->getShape($oResultCache->tileindex, > > $oResultCache->shapeindex); > > $aValues = $oShape->values; > > > > //------- Get the field value. > > echo $aValues['ZIP_CODE']; echo ";"; > > > > //------- FREE SHAPE > > $oShape->free(); > > $oLayer->close(); > > break; > > } // for i > > > > > > Best regards, > > Mir Hashmi > > > > > > > > ------------------------------ > > This message may contain confidential and/or privileged information. If > you > > have received this message in error,please notify us immediately by > > responding to this e-mail and delete it from your system. Thanks for your > > cooperation. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Sun Jul 12 12:16:11 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Sun, 12 Jul 2009 21:16:11 +0200 Subject: [mapserver-users] OGR error:File not found or unsupported format. Message-ID: An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Mon Jul 13 03:50:59 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Mon, 13 Jul 2009 12:50:59 +0200 Subject: [mapserver-users] tool to generate a mapfile Message-ID: An HTML attachment was scrubbed... URL: From yjacolin at free.fr Mon Jul 13 04:58:37 2009 From: yjacolin at free.fr (Jacolin Yves) Date: Mon, 13 Jul 2009 13:58:37 +0200 Subject: [mapserver-users] tool to generate a mapfile In-Reply-To: References: Message-ID: <200907131358.37816.yjacolin@free.fr> Le Monday 13 July 2009 12:50:59 YOUNESS ELMEDRAOUI, vous avez ?crit?: > Hi everybody, > ? > Is there a tool to generate a mapfile? > > Best regards, > Youness?ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci As I think you are speaking and reading french, here a link which lists some of application to create mapfile : http://georezo.net/blog/geolibre/2008/10/02/interface-graphique-pour-realiser-un-mapfile/ Regards, Y. -- Yves Jacolin Ne demandez pas si vous pouvez contribuer, contribuez ! :) --- http://softlibre.gloobe.org From paul_everton at hotmail.com Mon Jul 13 05:35:00 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Mon, 13 Jul 2009 12:35:00 +0000 Subject: [mapserver-users] .map file wont display in Open Layers Message-ID: Hi, If anyone can help would be greatly appreciated i have been have difficulties displaying my map in Open Layers for little while now. I have a map file (uk.map) pulling in one layer which is a .shp file consisting of .tiff files i created using FWTools. However i call the .map file from my html page and the map will not display in openlayers just a blank screen within the Open Layers Window. Can anyone see where i am going wrong? Here is my map file MAP NAME ukmap STATUS ON IMAGETYPE PNG IMAGECOLOR 153 204 255 # Map image size SIZE 800 800 UNITS METERS EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 PROJECTION "AUTO" END # Background color for the map canvas -- change as desired IMAGECOLOR 192 192 192 IMAGEQUALITY 95 IMAGETYPE gif OUTPUTFORMAT NAME gif DRIVER 'GD/GIF' MIMETYPE 'image/gif' #IMAGEMODE PC256 EXTENSION 'gif' END # Legend LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END # Web interface definition. Only the template parameter # is required to display a map. See MapServer documentation WEB # Set IMAGEPATH to the path where MapServer should # write its output. IMAGEPATH '/tmp/' # Set IMAGEURL to the url that points to IMAGEPATH # as defined in your web server configuration IMAGEURL '/tmp/' # WMS server settings METADATA 'wms_title' 'ukmap' 'wms_onlineresource' 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' 'wms_srs' 'EPSG:4326' END #Scale range at which web interface will operate # Template and header/footer settings # Only the template parameter is required to display a map. See MapServer documentation END LAYER NAME 'map' TYPE POLYGON DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' METADATA 'wms_title' 'map' END STATUS DEFAULT TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'datum=WGS84' 'no_defs' '' END CLASS NAME 'map' STYLE SYMBOL 0 SIZE 2 OUTLINECOLOR 0 0 0 COLOR 144 50 207 END END END END And my html page: NARIMS MAPPING TEST
Any help much appreciated. Thanks in advance _________________________________________________________________ Get the best of MSN on your mobile http://clk.atdmt.com/UKM/go/147991039/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Mon Jul 13 06:03:09 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 13 Jul 2009 10:03:09 -0300 Subject: [mapserver-users] tool to generate a mapfile In-Reply-To: References: Message-ID: <4A5B308D.60406@gatewaygeomatics.com> YOUNESS ELMEDRAOUI wrote: > Hi everybody, > > Is there a tool to generate a mapfile? > Hello, Yes the most stable and recommended tool to use is QGIS (http://qgis.org/)...create your map through that and then choose in the menus Plugins/MapServer Export. Have fun! -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From fsozzi at intercad.ch Mon Jul 13 06:42:12 2009 From: fsozzi at intercad.ch (Francesco Sozzi) Date: Mon, 13 Jul 2009 06:42:12 -0700 Subject: [mapserver-users] ArcSDE compilation and connectivity problems Message-ID: Hi all, I've just compiled mapserver 5.0.3 changing nmake.opt ArcSDE section into: SDE_OPT=-DUSE_SDE SDE_OPT= -DUSE_SDE_PLUGIN SDE_VERSION = 91 SDE_DIR = "C:\Program Files\ArcGIS\ArcSDE" SDE_INC = -I$(SDE_SDK)\include The complation has been succesful for both mapserver and php_mapscript. I have the following problems: 1) if I run mapserv.exe -v I got no INPUT=SDE (or something similar) 2) from my PHP app I get "msSDELayerOpen(): SDE support is not available" on trying openig ArcSDE layer Please note that ArcSDE is on and I can get data from ArcCatalog. Any idea or suggestions?... Best regards Francesco From bfraser at geoanalytic.com Mon Jul 13 07:17:21 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Mon, 13 Jul 2009 08:17:21 -0600 Subject: [mapserver-users] .map file wont display in Open Layers In-Reply-To: References: Message-ID: <4A5B41F1.10207@geoanalytic.com> Paul, You may need to define your output projection instead of using "AUTO" (I didn't know mapserver would tolerate that in the MAP section!). And IMAGEPATH is the file-system path to a folder writable by mapserver. Here's an example using standard ms4w: IMAGEPATH '\ms4w\tmp\ms_tmp\' with IMAGEURL being its web-based equivalent (the same location on disk but access via your web server): IMAGEURL '\ms_tmp\' since "ms_tmp" is set as an alias in Apache's httd.conf: Alias /ms_tmp/ "C:/ms4w/tmp/ms_tmp/" Best Regards, Brent Fraser Paul Curran wrote: > Hi, If anyone can help would be greatly appreciated i have been have > difficulties displaying my map in Open Layers for little while now. > > I have a map file (uk.map) pulling in one layer which is a .shp file > consisting of .tiff files i created using FWTools. > > However i call the .map file from my html page and the map > will not display in openlayers just a blank screen within the > Open Layers Window. Can anyone see where i am going wrong? > > Here is my map file > > MAP > NAME ukmap > STATUS ON > IMAGETYPE PNG > IMAGECOLOR 153 204 255 > # Map image size > SIZE 800 800 > UNITS METERS > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > PROJECTION > "AUTO" > END > # Background color for the map canvas -- change as desired > IMAGECOLOR 192 192 192 > IMAGEQUALITY 95 > IMAGETYPE gif > OUTPUTFORMAT > NAME gif > DRIVER 'GD/GIF' > MIMETYPE 'image/gif' > #IMAGEMODE PC256 > EXTENSION 'gif' > END > # Legend > LEGEND > IMAGECOLOR 255 255 255 > STATUS ON > KEYSIZE 18 12 > LABEL > TYPE BITMAP > SIZE MEDIUM > COLOR 0 0 89 > END > END > # Web interface definition. Only the template parameter > # is required to display a map. See MapServer documentation > WEB > # Set IMAGEPATH to the path where MapServer should > # write its output. > IMAGEPATH '/tmp/' > # Set IMAGEURL to the url that points to IMAGEPATH > # as defined in your web server configuration > IMAGEURL '/tmp/' > # WMS server settings > METADATA > 'wms_title' 'ukmap' > 'wms_onlineresource' > 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' > 'wms_srs' 'EPSG:4326' > END > #Scale range at which web interface will operate > # Template and header/footer settings > # Only the template parameter is required to display a map. See > MapServer documentation > END > LAYER > NAME 'map' > TYPE POLYGON > DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' > METADATA > 'wms_title' 'map' > END > STATUS DEFAULT > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'ellps=WGS84' > 'datum=WGS84' > 'no_defs' > '' > END > CLASS > NAME 'map' > STYLE > SYMBOL 0 > SIZE 2 > OUTLINECOLOR 0 0 0 > COLOR 144 50 207 > END > END > END > END > > And my html page: > > > NARIMS MAPPING TEST > > > > > >
> > > > > Any help much appreciated. Thanks in advance > > > > > ------------------------------------------------------------------------ > Upgrade to Internet Explorer 8 Optimised for MSN. Download Now > > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at dnr.state.mn.us Mon Jul 13 07:44:14 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Mon, 13 Jul 2009 09:44:14 -0500 Subject: [mapserver-users] tool to generate a mapfile In-Reply-To: References: Message-ID: <4A5B01ED.5157.008F.0@dnr.state.mn.us> Besides those mentioned there's also: 1) MSCompanion. It's relatively new and I've not had occasion to use it but it might be worth checking out. 2) Camptocamp's MapFish Studio has a mapfile builder as well... Steve >>> YOUNESS ELMEDRAOUI 7/13/2009 5:50 AM >>> Hi everybody, Is there a tool to generate a mapfile? Best regards, Youness ELMEDRAOUI Les informations figurant sur cet e-mail ont un caract?re strictement confidentiel et sont exclusivement adress?es au destinataire mentionn? ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir imm?diatement par la m?me voie et d?truire l'original. Merci From zhaops at hotmail.com Mon Jul 13 13:14:29 2009 From: zhaops at hotmail.com (Peisheng Zhao) Date: Mon, 13 Jul 2009 20:14:29 +0000 Subject: [mapserver-users] Building GDAL error Message-ID: Hi all, I am trying to compile GDAL-1.6.1 with lipdap 3.8.2: ./configure --with-threads --with-ogr --with-geos --without-libtool --with-proj=/tools/share/COTS/proj-4.6.1 --without-python --without-perl --with-libtiff=internal --with-geotiff=internal --with-hdf4=/tools/share/COTS/HDF4.2r4 --with-hdf5=/tools/share/COTS/hdf5-1.8.2 --with-pg=/usr/bin/pg_config --with-dods-root=/var/tmp/www/libdap-3.8.2 --without-ogdi --without-geos --prefix=/var/tmp/www/gdal-1.6.1 But I always get the error: /var/tmp/www/gdal-1.6.1/libgdal.so: undefined reference to `libdap::DAS::DAS(libdap::AttrTable*, unsigned int)' Who can help me figure it out? Thanks a lot. Peisheng _________________________________________________________________ Lauren found her dream laptop. Find the PC that?s right for you. http://www.microsoft.com/windows/choosepc/?ocid=ftp_val_wl_290 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Mon Jul 13 18:01:43 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Mon, 13 Jul 2009 20:01:43 -0500 Subject: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 Message-ID: <4A5B92A70200008F00026028@co5.dnr.state.mn.us> Wonder if it's the same issue as with the polygon size you noted. Even though the shield is a rect it's rendered as a polygon. Thomas, should polygons be drawn with an outline same as the fill color if no outline color is specifiied? Steve >>> "Nikolai Nikolov" 07/09/09 2:43 AM >>> Hi Steve and everyone, The images below are from Mapserver 5.2.0 (left) and 5.4.1 (right) of the same map using AGG. Please note the difference in the size of the road shields (green shields). The following are images from the same servers (Mapserver 5.2.0 (left) and 5.4.1 (right)) of the same map (different zoom) using GD. Please note that the two maps are practically the same. The complete map-file used for the first example is attached to this e-mail. The parts of it specific to the issue are like that: OUTPUTFORMAT NAME AGG_PNG DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" #FORMATOPTION "QUANTIZE_FORCE=TRUE" #FORMATOPTION "QUANTIZE_COLORS=256" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END and CLASS EXPRESSION /^E/ LABEL PRIORITY 4 PARTIALS false MINFEATURESIZE 10 MINDISTANCE 300 COLOR 255 255 255 BACKGROUNDCOLOR 128 208 100 BACKGROUNDSHADOWCOLOR 81 145 58 ANGLE 0 BUFFER 2 FONT arial-bold TYPE truetype SIZE 7 END END The difference for the second examples is in the output format used: OUTPUTFORMAT NAME PNG DRIVER GD/PNG MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" #FORMATOPTION "QUANTIZE_FORCE=TRUE" #FORMATOPTION "QUANTIZE_COLORS=256" FORMATOPTION "PALETTE_FORCE=TRUE" FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" FORMATOPTION "INTERLACE=OFF" END Many thanks, Nick -----Original Message----- From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Sent: 08 July 2009 15:29 To: Nikolai Nikolov; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 Perhaps you could post image samples and a mapfile? Steve >>> On 7/8/2009 at 3:05 AM, in message <65D1C555BE9443A180F3B1697EF7E69F at BenefonUK.local>, "Nikolai Nikolov" wrote: > Hi everyone, > > > > I've just upgraded one of my test servers from 5.2.0 to 5.4.1. I have an > issue there and I wonder whether anybody have noticed it. My map polygones > seems to be fractionaly smaller (compare to those drawned by 5.2.0). > > > > I am using the same maps, map files, PHP scripts, etc. The plygons which > belong to the same layer, do not quite well "fit" with each other - their > borders match perfectly before the upgarde to 5.4.1. > > > > Also, I use BACKGROUNDCOLOR in my map file to create shield like square > behind a label. Those squares are now significantly smaller too. > > > > I wander what causes this effect and what I should do to achieve the same > image as with 5.2.0? > > > > Thanks, > > Nick > > > > From adrian_gh.popa at romtelecom.ro Mon Jul 13 23:15:19 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 14 Jul 2009 09:15:19 +0300 Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features Message-ID: <4A5C2277.80204@romtelecom.ro> Hello everyone, Here's my problem: I'm trying to highlight segments from a line layer by using an expression in a specific class. This portion of the mapfile is dynamically generated and when it is done, it is sent to mapserver for rendering. My problem is that I have to select between 10 - 400 features at a time and I noticed when I have a lot of features there is a severe performance degradation in mapserver (takes a lot of time to render or even times out). Right now, my expression is built using regular expressions: something like: *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* This works ok, but as I said has a performance penalty when you reach ~400 items. My data is selected from a shapefile layer which has about 5500 items. Since I wouldn't be using the regular expressions at full capacity (I'm matching the full name), I might rewrite the expression using something like: *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* From the documentation I see that: /Regular expression with MapServer work similarly to string comparison, but allow more complex operation. They are slower than pure string comparisons, but might be still faster than logical expression. As with the string comparison use regular expressions, a FILTERITEM or a CLASSITEM has to defined, respectively. /I would like to know if there is an efficient way of selecting a list of elements from a layer, or what are your recommendations. Also - have there been significant changes in performance for this issue from mapserver 4.10 (I am now migrating to mapserver 5.4)? Thanks, Adrian -------------- next part -------------- An HTML attachment was scrubbed... URL: From nnikolov at gypsii.com Tue Jul 14 01:54:03 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Tue, 14 Jul 2009 09:54:03 +0100 Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features In-Reply-To: <4A5C2277.80204@romtelecom.ro> References: <4A5C2277.80204@romtelecom.ro> Message-ID: <007f01ca0460$a419b480$0401a8c0@BenefonUK.local> Hi Adrian, I have used long EXPRESSION list in the past, but my data are "static", so eventually I modified the map data and removed the polygons I didn't want to render. I could suggest to you to use in your map file several LAYERs or CLASSes to "spread around" long EXPRESSION lists. Those LAYERs or CLASSes would be identical but for the EXPRESSION lists. You could put a limit of let's say 10 selected features per CLASS definition. Best regards, Nick _____ From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Adrian Popa Sent: 14 July 2009 07:15 To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features Hello everyone, Here's my problem: I'm trying to highlight segments from a line layer by using an expression in a specific class. This portion of the mapfile is dynamically generated and when it is done, it is sent to mapserver for rendering. My problem is that I have to select between 10 - 400 features at a time and I noticed when I have a lot of features there is a severe performance degradation in mapserver (takes a lot of time to render or even times out). Right now, my expression is built using regular expressions: something like: EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/ This works ok, but as I said has a performance penalty when you reach ~400 items. My data is selected from a shapefile layer which has about 5500 items. Since I wouldn't be using the regular expressions at full capacity (I'm matching the full name), I might rewrite the expression using something like: EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") ) >From the documentation I see that: Regular expression with MapServer work similarly to string comparison, but allow more complex operation. They are slower than pure string comparisons, but might be still faster than logical expression. As with the string comparison use regular expressions, a FILTERITEM or a CLASSITEM has to defined, respectively. I would like to know if there is an efficient way of selecting a list of elements from a layer, or what are your recommendations. Also - have there been significant changes in performance for this issue from mapserver 4.10 (I am now migrating to mapserver 5.4)? Thanks, Adrian -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Tue Jul 14 02:05:10 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 14 Jul 2009 12:05:10 +0300 Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features In-Reply-To: <007f01ca0460$a419b480$0401a8c0@BenefonUK.local> References: <4A5C2277.80204@romtelecom.ro> <007f01ca0460$a419b480$0401a8c0@BenefonUK.local> Message-ID: <4A5C4A46.5030600@romtelecom.ro> Hello Nikolai, As far as you know - the Layers/Classes are processed in paralel (threads)? Would it even be more efficient not to use expressions, but to use simple string matchings and dynamically generate 10-400 Classes in a layer (one class per item)? What would be the best/most scalable approach? Thank you, Adrian Nikolai Nikolov wrote: > > Hi Adrian, > > > > I have used long EXPRESSION list in the past, but my data are > ?static?, so eventually I modified the map data and removed the > polygons I didn?t want to render. > > > > I could suggest to you to use in your map file several LAYERs or > CLASSes to ?spread around? long EXPRESSION lists. Those LAYERs or > CLASSes would be identical but for the EXPRESSION lists. You could > put a limit of let?s say 10 selected features per CLASS definition. > > > > Best regards, > > Nick > > > > ------------------------------------------------------------------------ > > *From:* mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] *On Behalf Of *Adrian > Popa > *Sent:* 14 July 2009 07:15 > *To:* mapserver-users at lists.osgeo.org > *Subject:* [mapserver-users] Performance in regular expressions or an > alternative way to select a list of features > > > > Hello everyone, > > Here's my problem: I'm trying to highlight segments from a line layer > by using an expression in a specific class. This portion of the > mapfile is dynamically generated and when it is done, it is sent to > mapserver for rendering. > My problem is that I have to select between 10 - 400 features at a > time and I noticed when I have a lot of features there is a severe > performance degradation in mapserver (takes a lot of time to render or > even times out). > Right now, my expression is built using regular expressions: something > like: > *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* > This works ok, but as I said has a performance penalty when you reach > ~400 items. My data is selected from a shapefile layer which has > about 5500 items. > > Since I wouldn't be using the regular expressions at full capacity > (I'm matching the full name), I might rewrite the expression using > something like: > *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR > ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* > > >From the documentation I see that: > /Regular expression with MapServer work similarly to string > comparison, but allow more complex operation. They are slower than > pure string comparisons, but might be still faster than logical > expression. As with the string comparison use regular expressions, a > FILTERITEM or a CLASSITEM has to defined, respectively. > > /I would like to know if there is an efficient way of selecting a list > of elements from a layer, or what are your recommendations. > > Also - have there been significant changes in performance for this > issue from mapserver 4.10 (I am now migrating to mapserver 5.4)? > > Thanks, > Adrian > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gis at vanbooth.com Tue Jul 14 02:11:07 2009 From: gis at vanbooth.com (Rob) Date: Tue, 14 Jul 2009 10:11:07 +0100 Subject: [mapserver-users] Re: Reprojecting cascading WMS requests (Rob) In-Reply-To: <3D56274B4A7874468F58FADDBFD09801078AF885@llmhs02.r8nssis.local> References: <20090710192731.03B14E01E84@lists.osgeo.org> <3D56274B4A7874468F58FADDBFD09801078AF885@llmhs02.r8nssis.local> Message-ID: <2a955f950907140211sbe153cch76568acdbda34e03@mail.gmail.com> Hi Mark Thanks for the reply. But I am already putting the projection information in three places arent I? MAP PROJECTION "init=epsg:27700" END WEB METADATA "http://localhost/cgi-bin/mapserv.exe?map=example.map&" WMS_SRS "EPSG:27700 ESPG:4326" END END LAYER NAME "layer" CONNECTION "http://externalwmshost/&" CONNECTIONTYPE WMS METADATA "wms_srs" "EPSG:27700" END END The external WMS only supports 27700 - thats why I want to reproject in my mapserver instance. Any other clues? Thanks Rob 2009/7/10 Mark Volz : > Rob, > > Anyone can correct me if I am wrong on this however I think you have to enter > projection information in 3 times. > > 1) the projection of your map > 2) the projection of your data, in this case the wms service so that > mapserver knows what to reproject from. > 3) the projection that you are requesting from the wms service - in the > metadata section. > > I am doing this on some of my applications so let me know if your having > trouble, otherwise if someone has a better thought let me know if I am > wasting lines of code. > > Example: > > MAP > ... > Projection # of the Map > End Projection > ... > .. > ? ? ? ?Layer > ? ? ? ?Projection # of the Source > ? ? ? ?End Projection > ? ? ? ?... > ? ? ? ?Metadata > ? ? ? ? ? ? ? ?"wms_srs" "ESPG:27700" ?#projection you are requesting in WMS > ? ? ? ?.... > ? ? ? ?End #Metadata > ? ? ? ?... > End #layer > > Mark Volz > GIS Specialist > Lyon County, MN > (507) 532-8218 > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 10 Jul 2009 17:23:28 +0100 > From: Rob > Subject: [mapserver-users] Reprojecting cascading WMS requests > To: mapserver-users at lists.osgeo.org > Message-ID: > ? ? ? ?<2a955f950907100923m1ad368b7m8eb9e00727d29baa at mail.gmail.com> > Content-Type: text/plain; charset=ISO-8859-1 > > Hi > > I'm obviously having Friday afternoon blindness, as I can't see what I > am doing wrong! ?I am trying to set up a basic Mapserver install (MS4W > v3.0 Beta 4) > > MapServer version 5.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP > OUTPUT=PDF > ?OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE > SUPPORTS=ICO > NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT > SUPPORTS=WFS_SERVER > SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI > SUP > PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS > INPUT=OGR > ?INPUT=GDAL INPUT=SHAPEFILE > > > which points to a WMS service which only supports a single projection. > I want to get my Mapserver to reproject that data on the fly to other > projection systems, but don't seem to be doing it right! > > This is my mapfile > > MAP > NAME SPIRIT > STATUS ON > SIZE 600 600 > EXTENT 0 0 650000 1300000 > UNITS METERS > SHAPEPATH "temp" > IMAGECOLOR 255 255 255 > #FONTSET 'fontset.txt' > > #SYMBOLSET 'temp/examples.sym' > > IMAGETYPE JPEG > IMAGEQUALITY 75 > > IMAGETYPE png > OUTPUTFORMAT > ? NAME png > ? DRIVER "GD/PNG" > ? MIMETYPE "image/png" > ? IMAGEMODE rgb > END > > IMAGETYPE jpeg > OUTPUTFORMAT > ? NAME jpeg > ? DRIVER "GD/JPEG" > ? MIMETYPE "image/jpeg" > ? IMAGEMODE rgb > END > > PROJECTION > ?"init=epsg:27700" > END > > WEB > ?IMAGEPATH "c:\temp\" > ?METADATA > ? ?WMS_TITLE "WMS Server" > ? ?WMS_ABSTRACT "WMS Server." > ? ? ? ?WMS_ONLINERESOURCE > "http://localhost/cgi-bin/mapserv.exe?map=example.map&" > ? ?WMS_SRS "EPSG:27700 ESPG:4326" > ?END > END > > ?LAYER > ? ? ? ?NAME "layer" > ? ? ? ?TYPE RASTER > ? ? ? ?STATUS ON > ? ? ? ?CONNECTION "http://externalwmshost/&" > ? ? ? ?CONNECTIONTYPE WMS > ? ? ? ?METADATA > ? ? ? ? ? ? ? ?"wms_srs" ? ? ? ? ? ? ? ? ? ? ? "EPSG:27700" > ? ? ? ? ? ? ? ?"wms_name" ? ? ? ? ? ? ? ? ? ? ?"layername" > ? ? ? ? ? ? ? ?"wms_server_version" ? ?"1.1.1" > ? ? ? ? ? ? ? ?"wms_formatlist" ? ? ? ?"image/png,image/jpeg" > ? ? ? ? END > ? END > > END > > END # Map File > > > but when I make a WMS request against it > > http://localhost/cgi-bin/mapserv.exe?map=example.map&request=getmap&service=w > ms&layers=layer&bbox=53.5,1.4,53.51,1.41&width=400&height=400&version=1.1.1&s > rs=EPSG:4326&format=jpeg > > I get > > > > "http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd"> > > > msWMSLoadGetMapParams(): WMS server error. Invalid SRS given : SRS > must be valid for all requested layers. > > > > I'm guessing I'm missing something simple, but I don't know what it > is. ?Any help gratefully accepted! > > Thanks > > Rob > > From youness.elmedraoui at somei.fr Tue Jul 14 04:11:22 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Tue, 14 Jul 2009 13:11:22 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_Re=3A_[mapserver-users]_tool_to_generate_a?= =?ISO-8859-1?Q?_mapfile?= In-Reply-To: <4A5B01ED.5157.008F.0@dnr.state.mn.us> References: , <4A5B01ED.5157.008F.0@dnr.state.mn.us> Message-ID: An HTML attachment was scrubbed... URL: From hrodriguez at siscat.com.ar Tue Jul 14 05:26:31 2009 From: hrodriguez at siscat.com.ar (Rodriguez, Heraldo) Date: Tue, 14 Jul 2009 09:26:31 -0300 Subject: [mapserver-users] support for projectioin=NONE or CRS:1 In-Reply-To: <4A5B92A70200008F00026028@co5.dnr.state.mn.us> Message-ID: <296E5F9B6BB1C445BDDC9C94FC83835E1B13E7@ZEUS-Exchg2k3.sc.com> Hi everyone, We are using mapserver 5.4 with openlayers 2.7 and tilecache 2.10. Mapserver is running as a CGI application. Our data are in planar coordinates ,and since we are using mapserver as a WMS server and a WFS server we must set a projection in the mapfile. We are cheating mapserver and setting a fake projection in order to make WFS and WMS features work. When we use mapserver via mapscript ( using tilecache ) the results are what we expected. The problem arises when we try to invoke mapserver via wms. Those layers that have maxscale , minscale ,etc setted are not drawed or don?t behave as expected. We are running in a lot of problems to make the application works ( not listed in this post) and all of them would easily solved if mapserver supported CRS:1 or SRS=NONE. The only reference I found regarding this topic was the ticket #485 from 2003 and mentioned in the MS RFC 30: Support for WMS 1.3.0. I will really appreciate if someone could tell me if there is a chance that this feature will be added in a (near) future version of mapserver . Or if there exist some guidelines to workaround this. Thanks in advance . regards. Lic. Heraldo G. Rodriguez hrodriguez at siscat.com.ar TEL: 54-11-4326-4002 int 255 Dpto. Desarrollo Sistemas Catastrales S.A From winwaed at gmail.com Tue Jul 14 05:42:56 2009 From: winwaed at gmail.com (winwaed at gmail.com) Date: Tue, 14 Jul 2009 12:42:56 +0000 Subject: [mapserver-users] Backgrounds and Graticules in Pseudo-cylindrical Projections Message-ID: <00151750ed981f591c046ea9c767@google.com> I am using MapServer to create some web maps using equal area projections. Most of these are pseudo-cylindrical, and I am currently using Mollweide for the initial development. This works fine and I even have it working with WMS to OpenLayers (OpenLayers and adding layers from different projections is a different kettle of fish, but I've asked that question elsewhere!). With a projection like this, a zoomed out map has two areas: projected space, and non-projected space. Ie. the projected globe does not take up the entire map "canvas". To me, this means we have two background colors: the background for the shapes in projected space, and the true background of non-projected space. I hope that makes sense? I'll try with a real world example. I have a layer that shows land masses. This is green. The mapfile is set to have a blue background (for the oceans). These are being drawn correctly, but the blue is also used for areas outside the projected globe. Is it possible to specify a different color (or "transparent") for the area outside the projected globe? The best idea I have is that I create a new layer of three shapes that cover the entire globe completely. This would be drawn as blue as the lowest layer in the mapfile, and the mapfile's background would be set to white. Is there a more efficient way? I would also like to add a geographic graticule (ie. meridians and parallels). I've tried the GRID definition in the mapserver map file, but this simply draws a cartesian grid in projected space. Can this be done in MapServer? I guess I could again solve this with a new layer of shapes. Otherwise it is OpenLayers (with a dev version of a graticule control, or more likely - write my own code) Richard Marsden -------------- next part -------------- An HTML attachment was scrubbed... URL: From David.Fawcett at state.mn.us Tue Jul 14 06:34:30 2009 From: David.Fawcett at state.mn.us (Fawcett, David) Date: Tue, 14 Jul 2009 08:34:30 -0500 Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features In-Reply-To: <4A5C2277.80204@romtelecom.ro> Message-ID: <6246727221874A4FB8D3F9BBC37D9BD5056DA681@s-sp22.pca.state.mn.us> Adrian, One method that I have used is to use an IN statement in my expression and then use a variable to populate the list of IDs in the statement. I create a class like this: CLASS NAME "Low" EXPRESSION ('[COUNTY_FIP]' in '%group1%') OUTLINECOLOR 0 0 0 COLOR 255 204 204 END And then in the URL calling the map, I include &group1=27001,27003,27005 I actually use this with five classes (five different URL vars) to create a thematic map of counties based entirely on data passed in through the URL. I have no idea on how the performance of this method compares to what you have done, but it might be worth a try. There are only 87 counties in Minnesota, so that is the largest number it gets, but the performance isn't bad. David. -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Adrian Popa Sent: Tuesday, July 14, 2009 1:15 AM To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features Hello everyone, Here's my problem: I'm trying to highlight segments from a line layer by using an expression in a specific class. This portion of the mapfile is dynamically generated and when it is done, it is sent to mapserver for rendering. My problem is that I have to select between 10 - 400 features at a time and I noticed when I have a lot of features there is a severe performance degradation in mapserver (takes a lot of time to render or even times out). Right now, my expression is built using regular expressions: something like: EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/ This works ok, but as I said has a performance penalty when you reach ~400 items. My data is selected from a shapefile layer which has about 5500 items. Since I wouldn't be using the regular expressions at full capacity (I'm matching the full name), I might rewrite the expression using something like: EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") ) From the documentation I see that: Regular expression with MapServer work similarly to string comparison, but allow more complex operation. They are slower than pure string comparisons, but might be still faster than logical expression. As with the string comparison use regular expressions, a FILTERITEM or a CLASSITEM has to defined, respectively. I would like to know if there is an efficient way of selecting a list of elements from a layer, or what are your recommendations. Also - have there been significant changes in performance for this issue from mapserver 4.10 (I am now migrating to mapserver 5.4)? Thanks, Adrian -------------- next part -------------- An HTML attachment was scrubbed... URL: From tom at eryr.com Tue Jul 14 06:53:12 2009 From: tom at eryr.com (Tom Chase) Date: Tue, 14 Jul 2009 14:53:12 +0100 Subject: [mapserver-users] (min/max)scaledenom for WFS layers In-Reply-To: <20090714090520.A6DE5E01B2B@lists.osgeo.org> References: <20090714090520.A6DE5E01B2B@lists.osgeo.org> Message-ID: <4A5C8DC8.9080206@eryr.com> Is it possible to switch WFS layers on/off on a zoom basis in the same way as you can with WMS layers? If I specify the individual layers in my request, the layer is returned, regardless of zoom, and if I request the group name, I get Typename doesn't exist error. Should this work, and if so what am I doing wrong? Cheers! LAYER #Detailed routes for zoomed in view NAME "route_detail" GROUP "route" METADATA "wfs_title" "Routes" ##required "wfs_featureid" "id" "wfs_srs" "EPSG:27700" "gml_include_items" "all" "gml_featureid" "id" "gml_groups" "route" END #MetaData CONNECTIONTYPE POSTGIS CONNECTION "user=postgres dbname=xns host=127.0.0.1 port=5432" DATA "wkb_geom from (select id, route as wkb_geom, st_astext(location) as location, classification from routes) as subquery using unique id using srid=27700" MAXSCALEDENOM 30000 TYPE LINE STATUS ON PROJECTION "init=epsg:27700" ##recommended END #Projection DUMP TRUE TEMPLATE "/opt/mapfiles/template.html" END #Layer LAYER #simplified routes for zoomed out view NAME "route_simple" GROUP "route" MINSCALEDENOM 30001 METADATA "wfs_title" "Routes" ##required "wfs_featureid" "id" "wfs_srs" "EPSG:27700" "gml_include_items" "all" "gml_featureid" "id" "gml_groups" "route" END #MetaData CONNECTIONTYPE POSTGIS CONNECTION "user=postgres dbname=xns host=127.0.0.1 port=5432" DATA "wkb_geom from (select id, simpleroute as wkb_geom, st_astext(location) as location, classification from routes) as subquery using unique id using srid=27700" TYPE LINE STATUS ON PROJECTION "init=epsg:27700" ##recommended END #Projection DUMP TRUE TEMPLATE "/opt/mapfiles/template.html" END #Layer From dmorissette at mapgears.com Tue Jul 14 07:04:08 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Tue, 14 Jul 2009 10:04:08 -0400 Subject: [mapserver-users] (min/max)scaledenom for WFS layers In-Reply-To: <4A5C8DC8.9080206@eryr.com> References: <20090714090520.A6DE5E01B2B@lists.osgeo.org> <4A5C8DC8.9080206@eryr.com> Message-ID: <4A5C9058.9050603@mapgears.com> Tom Chase wrote: > Is it possible to switch WFS layers on/off on a zoom basis in the same > way as you can with WMS layers? > If I specify the individual layers in my request, the layer is returned, > regardless of zoom, and if I request the group name, I get Typename > doesn't exist error. > Should this work, and if so what am I doing wrong? > There is no concept of zoom or scale in the WFS spec... that's why the min/max scaledenom are ignored. Not a MapServer problem, it's the way WFS works. -- Daniel Morissette http://www.mapgears.com/ From Steve.Lime at dnr.state.mn.us Tue Jul 14 07:38:31 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 14 Jul 2009 09:38:31 -0500 Subject: [mapserver-users] Performance in regular expressions or analternative way to select a list of features In-Reply-To: <4A5C2277.80204@romtelecom.ro> References: <4A5C2277.80204@romtelecom.ro> Message-ID: <4A5C5216.5157.008F.0@dnr.state.mn.us> Have you tried a simplified version of your regex? I think you can do: EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ You might also consider writing a temporary set of geometries if a user will continually display from that set. In that case your overhead would be in managing the set of features which would be higher the first time but then very fast to render. Your dynamic portion of the mapfile would reference the temporary data. Steve >>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian Popa wrote: > Hello everyone, > > Here's my problem: I'm trying to highlight segments from a line layer by > using an expression in a specific class. This portion of the mapfile is > dynamically generated and when it is done, it is sent to mapserver for > rendering. > My problem is that I have to select between 10 - 400 features at a time > and I noticed when I have a lot of features there is a severe > performance degradation in mapserver (takes a lot of time to render or > even times out). > Right now, my expression is built using regular expressions: something like: > *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* > This works ok, but as I said has a performance penalty when you reach > ~400 items. My data is selected from a shapefile layer which has about > 5500 items. > > Since I wouldn't be using the regular expressions at full capacity (I'm > matching the full name), I might rewrite the expression using something > like: > *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR > ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* > > From the documentation I see that: > /Regular expression with MapServer work similarly to string comparison, > but allow more complex operation. They are slower than pure string > comparisons, but might be still faster than logical expression. As with > the string comparison use regular expressions, a FILTERITEM or a > CLASSITEM has to defined, respectively. > > /I would like to know if there is an efficient way of selecting a list > of elements from a layer, or what are your recommendations. > > Also - have there been significant changes in performance for this issue > from mapserver 4.10 (I am now migrating to mapserver 5.4)? > > Thanks, > Adrian From pramsey at cleverelephant.ca Tue Jul 14 07:50:32 2009 From: pramsey at cleverelephant.ca (Paul Ramsey) Date: Tue, 14 Jul 2009 07:50:32 -0700 Subject: [mapserver-users] Backgrounds and Graticules in Pseudo-cylindrical Projections In-Reply-To: <00151750ed981f591c046ea9c767@google.com> References: <00151750ed981f591c046ea9c767@google.com> Message-ID: <30fe546d0907140750n3f32edc8id466d99d48128cd6@mail.gmail.com> The way I would approach this would be to generate a physical graticule. That is, an actual polygonal lat/lon grid on the spacing desired and with vertex densification between the corners. The polygons can then be added and projected, color filled for the effect you want, and the outlines highlighted (or not) to form a graticule. P On Tue, Jul 14, 2009 at 5:42 AM, wrote: > I am using MapServer to create some web maps using equal area projections. > Most of these are pseudo-cylindrical, and I am currently using Mollweide for > the initial development. > > This works fine and I even have it working with WMS to OpenLayers > (OpenLayers and adding layers from different projections is a different > kettle of fish, but I've asked that question elsewhere!). > > With a projection like this, a zoomed out map has two areas: projected > space, and non-projected space. Ie. the projected globe does not take up the > entire map "canvas". > To me, this means we have two background colors: the background for the > shapes in projected space, and the true background of non-projected space. I > hope that makes sense? > I'll try with a real world example. I have a layer that shows land masses. > This is green. The mapfile is set to have a blue background (for the > oceans). These are being drawn correctly, but the blue is also used for > areas outside the projected globe. > > Is it possible to specify a different color (or "transparent") for the area > outside the projected globe? > The best idea I have is that I create a new layer of three shapes that cover > the entire globe completely. This would be drawn as blue as the lowest layer > in the mapfile, and the mapfile's background would be set to white. Is there > a more efficient way? > > I would also like to add a geographic graticule (ie. meridians and > parallels). I've tried the GRID definition in the mapserver map file, but > this simply draws a cartesian grid in projected space. Can this be done in > MapServer? I guess I could again solve this with a new layer of shapes. > Otherwise it is OpenLayers (with a dev version of a graticule control, or > more likely - write my own code) > > > Richard Marsden > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From vagner.uru at gmail.com Tue Jul 14 08:41:53 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 12:41:53 -0300 Subject: [mapserver-users] Problems with shape.index after layer.addFeature (MS 5.4.1 and C#) Message-ID: <3ead4aba0907140841t7ccce1cejacec034975a44c78@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. You may take a quick look at the excerpt of code bellow: if (ret == (int)MS_RETURN_VALUE.MS_SUCCESS) { resultCacheObj results = layer.getResults(); for (int i = 0; i < results.numresults; i++) { int shpidx = results.getResult(i).shapeindex; layer.open(); shapeObj shape = layer.getFeature(shpidx, -1); layer.close(); ... But I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} classindex: 1 shapeindex: 1 tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above hereand here in my blog. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia -------------- next part -------------- An HTML attachment was scrubbed... URL: From andy at squeakycode.net Tue Jul 14 10:27:21 2009 From: andy at squeakycode.net (Andy Colson) Date: Tue, 14 Jul 2009 12:27:21 -0500 Subject: [mapserver-users] mapfile projection Message-ID: <4A5CBFF9.2000200@squeakycode.net> Hi all, I'm working on my first mapping project, so IANAM (I am no a mapper). Here is the projection info from a shapefile I'm using: PROJCS["NAD_1983_StatePlane_Iowa_North_FIPS_1401_Feet", GEOGCS["GCS_North_American_1983", DATUM["D_North_American_1983", SPHEROID["GRS_1980",6378137.0,298.257222101]], PRIMEM["Greenwich",0.0], UNIT["Degree",0.017453292519943295]], PROJECTION["Lambert_Conformal_Conic"], PARAMETER["False_Easting",4921250.0], PARAMETER["False_Northing",3280833.333333333], PARAMETER["Central_Meridian",-93.5], PARAMETER["Standard_Parallel_1",42.06666666666667], PARAMETER["Standard_Parallel_2",43.26666666666667], PARAMETER["Latitude_Of_Origin",41.5], UNIT["Foot_US",0.30480060960121924], PARAMETER["scale_factor",1.0]] I used QGIS to create a mapfile, and it generated this: PROJECTION 'proj=longlat' 'ellps=WGS84' 'datum=WGS84' 'no_defs' '' END I was kind of thinking this (Thanks to FrankW for helping me find the right epsg code): PROJECTION 'init=epsg:3417' END Is the first one even right? Would there be a difference? Why might I choose one over the other? I'm going to put this into postgis, with srid = 3417, will that make any difference. (I'd like to avoid re-projections.. I think... don't I?) -Andy From vagner.uru at gmail.com Tue Jul 14 10:28:09 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 14:28:09 -0300 Subject: [mapserver-users] Problems with shape.index after layer.addFeature (MS 5.4.1 and C#) Message-ID: <3ead4aba0907141028n5e6df449j7fd5a6588a0ead66@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. You may take a quick look at the excerpt of code bellow: if (ret == (int)MS_RETURN_VALUE.MS_SUCCESS) { resultCacheObj results = layer.getResults(); for (int i = 0; i < results.numresults; i++) { int shpidx = results.getResult(i).shapeindex; layer.open(); shapeObj shape = layer.getFeature(shpidx, -1); layer.close(); ... But I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} classindex: 1 shapeindex: 1 tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above hereand here in my blog. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia -------------- next part -------------- An HTML attachment was scrubbed... URL: From pauljame at gmail.com Tue Jul 14 11:19:20 2009 From: pauljame at gmail.com (Paul james) Date: Tue, 14 Jul 2009 15:19:20 -0300 Subject: [mapserver-users] Zoom to given coordinate(lat/lon) using Mapscript... Message-ID: <33fad6880907141119g52be040as3068ef13e3721d30@mail.gmail.com> How can I do that? Paul -------------- next part -------------- An HTML attachment was scrubbed... URL: From ryan at monadnock.org Tue Jul 14 12:09:33 2009 From: ryan at monadnock.org (cupofnestor) Date: Tue, 14 Jul 2009 12:09:33 -0700 (PDT) Subject: [mapserver-users] Mapserver Developer Needed Message-ID: <1247598573646-3258812.post@n2.nabble.com> I am Ryan Nestor, of Monadnock Media in Sunderland, MA, USA. We are looking for an experienced Mapserver developer to configure a server for us. We plan on putting together a system which will serve watershed data as well as DEMs and several other layers. The final product is a computer interactive for an educational museum environment. If you are interested, please email me at the below address. Ryan Nestor, MonadnockMedia ryan [at] monadnockmedia [dot] com -- View this message in context: http://n2.nabble.com/Mapserver-Developer-Needed-tp3258812p3258812.html Sent from the Mapserver - User mailing list archive at Nabble.com. From winwaed at gmail.com Tue Jul 14 12:55:50 2009 From: winwaed at gmail.com (Richard Marsden) Date: Tue, 14 Jul 2009 14:55:50 -0500 Subject: [mapserver-users] Backgrounds and Graticules in Pseudo-cylindrical Projections In-Reply-To: <30fe546d0907140750n3f32edc8id466d99d48128cd6@mail.gmail.com> References: <00151750ed981f591c046ea9c767@google.com> <30fe546d0907140750n3f32edc8id466d99d48128cd6@mail.gmail.com> Message-ID: Thanks Paul. Good thinking - combine both problems with the same solution! Cheers, Richard On Tue, Jul 14, 2009 at 9:50 AM, Paul Ramsey wrote: > The way I would approach this would be to generate a physical > graticule. That is, an actual polygonal lat/lon grid on the spacing > desired and with vertex densification between the corners. The > polygons can then be added and projected, color filled for the effect > you want, and the outlines highlighted (or not) to form a graticule. > > P > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vagner.uru at gmail.com Tue Jul 14 13:13:49 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 17:13:49 -0300 Subject: [mapserver-users] Problems with shape.index after using layer.addFeature (MapServer 5.4.1 and .net C#) Message-ID: <3ead4aba0907141313s18d53398t864ab5f887297a6c@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. You may take a quick look at the excerpt of code bellow: if (ret == (int)MS_RETURN_VALUE.MS_SUCCESS) { resultCacheObj results = layer.getResults(); for (int i = 0; i < results.numresults; i++) { int shpidx = results.getResult(i).shapeindex; layer.open(); shapeObj shape = layer.getFeature(shpidx, -1); layer.close(); ... But I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} classindex: 1 shapeindex: 1 tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above hereand here in my blog. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia -------------- next part -------------- An HTML attachment was scrubbed... URL: From vagner.uru at gmail.com Tue Jul 14 13:29:41 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 17:29:41 -0300 Subject: [mapserver-users] Problems with shape.index after layer.addFeature (MS 5.4.1 and C#) In-Reply-To: <3ead4aba0907141318s6459cc6at8560c60486fe5205@mail.gmail.com> References: <3ead4aba0907141318s6459cc6at8560c60486fe5205@mail.gmail.com> Message-ID: <3ead4aba0907141329x50c2cd25sc1c968f7ec738a8f@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} classindex: 1 shapeindex: 1 tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} classindex: 0 shapeindex: 1 tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above hereand here in my blog. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. (I've tried to include some piece of code to give you more details, but my message have been blocked.) Thank you very much. Best regards, Vagner Sousa AGX Tecnologia -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Tue Jul 14 13:30:27 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Tue, 14 Jul 2009 22:30:27 +0200 Subject: [mapserver-users] Zoom to given coordinate(lat/lon) using Mapscript... In-Reply-To: <33fad6880907141119g52be040as3068ef13e3721d30@mail.gmail.com> References: <33fad6880907141119g52be040as3068ef13e3721d30@mail.gmail.com> Message-ID: Paul, Assuming the desired coordinates are in the same spatial reference system as the layer you could use mapObj.setCenter and mapObj.scaleExtent. Best regards, Tamas 2009/7/14 Paul james > How can I do that? > > Paul > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Tue Jul 14 13:58:37 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Tue, 14 Jul 2009 22:58:37 +0200 Subject: [mapserver-users] Problems with shape.index after layer.addFeature (MS 5.4.1 and C#) In-Reply-To: <3ead4aba0907141329x50c2cd25sc1c968f7ec738a8f@mail.gmail.com> References: <3ead4aba0907141318s6459cc6at8560c60486fe5205@mail.gmail.com> <3ead4aba0907141329x50c2cd25sc1c968f7ec738a8f@mail.gmail.com> Message-ID: Hi, In my understanding it's up to the driver how the index is specified and it 's not safe to expose the setter of the shape index value. The most trivial option of setting the indexes to different values by the driver is to increment the index in each addfeature for the inline layers. Otherwise the shapes cannot be distinguished in the query result sets. Best regards, Tamas 2009/7/14 Vagner Sousa > Hi, there. > > I'm experiencing some troubles with the new release of MapServer. I got the > following while debugging that (Visual Studio IDE): > > results.getResult(0) > {OSGeo.MapServer.resultCacheMemberObj} > classindex: 0 > shapeindex: 1 > tileindex: -1 > results.getResult(1) > {OSGeo.MapServer.resultCacheMemberObj} > classindex: 1 > shapeindex: 1 > tileindex: -1 > results.getResult(2) > {OSGeo.MapServer.resultCacheMemberObj} > classindex: 0 > shapeindex: 1 > tileindex: -1 > > The new version of MapServer auto-increments the index property of a > feature as soon as it's added to a layer (unlike older releases). I know > there's a couple of shape.setValue() and shape.getValue() functions one may > use to store and recover values, but I'm not able to get the actual index > value (unlike this, my classindex values are correct). > > am I missing or doing something wrong? It used to work fine before the last > release (namely, the auto-incremented shape.index property). > > I've posted a little bit more detailed investigations of the above hereand > herein my blog. > > I'd really appreciate if anyone could spend some time to help me with that. > If you need more details, just let me know. > > (I've tried to include some piece of code to give you more details, but my > message have been blocked.) > > Thank you very much. Best regards, > > Vagner Sousa > AGX Tecnologia > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vagner.uru at gmail.com Tue Jul 14 14:46:07 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 18:46:07 -0300 Subject: [mapserver-users] How do I get a feature's index after inserting it in a layer using addFeature in the new release of MapServer? (MS 5.4.1 and C#) Message-ID: <3ead4aba0907141446r1a554a4euc86179a587d3aefc@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. You may take a quick look at the excerpt of code bellow: if (ret == (int)MS_RETURN_VALUE.MS_SUCCESS) { ? ? resultCacheObj results = layer.getResults(); ??? for (int i = 0; i < results.numresults; i++) ? ? { ? ?? ?? int shpidx = results.getResult(i).shapeindex; ?? ? ?? layer.open(); ? ? ? ? shapeObj shape = layer.getFeature(shpidx, -1); ? ?? ?? layer.close(); ?? ? ?? ... But I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} ??? classindex: 0 ??? shapeindex: 1 ??? tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} ??? classindex: 1 ??? shapeindex: 1 ??? tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} ??? classindex: 0 ??? shapeindex: 1 ??? tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above in my blog [http://cubicpurunga.blogspot.com]. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia [http://www.agx.com.br] From vagner.uru at gmail.com Tue Jul 14 14:58:11 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 18:58:11 -0300 Subject: [mapserver-users] How do I get a feature's index after inserting it in a layer using addFeature in MapServer 5.4.1? (and C#) Message-ID: <3ead4aba0907141458v46a619d4n5c85e35e01d3b6dc@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. You may take a quick look at the excerpt of code bellow: if (ret == (int)MS_RETURN_VALUE.MS_SUCCESS) { ? ?resultCacheObj results = layer.getResults(); ? ?for (int i = 0; i < results.numresults; i++) ? ?{ ? ? ? ?int shpidx = results.getResult(i).shapeindex; ? ? ? ?layer.open(); ? ? ? ?shapeObj shape = layer.getFeature(shpidx, -1); ? ? ? ?layer.close(); ? ? ? ?... But I got the following while debugging that (Visual Studio IDE): results.getResult(0) {OSGeo.MapServer.resultCacheMemberObj} ? ?classindex: 0 ? ?shapeindex: 1 ? ?tileindex: -1 results.getResult(1) {OSGeo.MapServer.resultCacheMemberObj} ? ?classindex: 1 ? ?shapeindex: 1 ? ?tileindex: -1 results.getResult(2) {OSGeo.MapServer.resultCacheMemberObj} ? ?classindex: 0 ? ?shapeindex: 1 ? ?tileindex: -1 The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above in my blog [cubicpurunga dot blogspot dot com]. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia From vagner.uru at gmail.com Tue Jul 14 15:02:30 2009 From: vagner.uru at gmail.com (Vagner Sousa) Date: Tue, 14 Jul 2009 19:02:30 -0300 Subject: [mapserver-users] How do I get a feature's index after inserting it in a layer using addFeature in MapServer 5.4.1? (and C#) Message-ID: <3ead4aba0907141502j26c26cfcwccd939cf3966293c@mail.gmail.com> Hi, there. I'm experiencing some troubles with the new release of MapServer. The new version of MapServer auto-increments the index property of a feature as soon as it's added to a layer (unlike older releases). I know there's a couple of shape.setValue() and shape.getValue() functions one may use to store and recover values, but I'm not able to get the actual index value (unlike this, my classindex values are correct). am I missing or doing something wrong? It used to work fine before the last release (namely, the auto-incremented shape.index property). I've posted a little bit more detailed investigations of the above in my blog [cubicpurunga.blogspot.com]. I'd really appreciate if anyone could spend some time to help me with that. If you need more details, just let me know. Thank you very much. Best regards, Vagner Sousa AGX Tecnologia From thomas.bonfort at camptocamp.com Tue Jul 14 22:36:22 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Wed, 15 Jul 2009 07:36:22 +0200 Subject: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 In-Reply-To: <4A5B92A70200008F00026028@co5.dnr.state.mn.us> References: <4A5B92A70200008F00026028@co5.dnr.state.mn.us> Message-ID: <2922382e0907142236j45c6ac50y53763e1b5bea8435@mail.gmail.com> the previous versions of mapserver (incorrectly I think) used the value of the label buffer to expand the background billboard. You'd get nice results whith a 1 or 2 px buffer like in your case, but unusable ones when you added larger buffers. I hope we can work around this for 5.6 with the possible label style rewrite. regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Tue, Jul 14, 2009 at 03:01, Steve Lime wrote: > Wonder if it's the same issue as with the polygon size you noted. Even though the shield > is a rect it's rendered as a polygon. Thomas, should polygons be drawn with an outline > same as the fill color if no outline color is specifiied? > > Steve > >>>> "Nikolai Nikolov" 07/09/09 2:43 AM >>> > Hi Steve and everyone, > > The images below are from Mapserver 5.2.0 (left) and 5.4.1 (right) of the > same map using AGG. Please note the difference in the size of the road > shields (green shields). > > The following are images from the same servers (Mapserver 5.2.0 (left) and > 5.4.1 (right)) of the same map (different zoom) using GD. ?Please note that > the two maps are practically the same. > > The complete map-file used for the first example is attached to this e-mail. > The parts of it specific to the issue are like that: > > > > ? ?OUTPUTFORMAT > > ? ? ? ?NAME AGG_PNG > > ? ? ? ?DRIVER AGG/PNG > > ? ? ? ?MIMETYPE ?"image/png" > > ? ? ? ?IMAGEMODE RGB > > ? ? ? ?EXTENSION ?"png" > > ? ? ? ?#FORMATOPTION "QUANTIZE_FORCE=TRUE" > > ? ? ? ?#FORMATOPTION "QUANTIZE_COLORS=256" > > ? ? ? ?FORMATOPTION "PALETTE_FORCE=TRUE" > > ? ? ? ?FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" > > ? ? ? ?FORMATOPTION "INTERLACE=OFF" > > ? ?END > > > > and > > ? ? ? ?CLASS > > ? ? ? ? ? ?EXPRESSION /^E/ > > ? ? ? ? ? ?LABEL > > ? ? ? ? ? ? ? ?PRIORITY 4 > > ? ? ? ? ? ? ? ?PARTIALS false > > ? ? ? ? ? ? ? ?MINFEATURESIZE 10 > > ? ? ? ? ? ? ? ?MINDISTANCE 300 > > ? ? ? ? ? ? ? ?COLOR 255 255 255 > > ? ? ? ? ? ? ? ?BACKGROUNDCOLOR 128 208 100 > > ? ? ? ? ? ? ? ?BACKGROUNDSHADOWCOLOR 81 145 58 > > ? ? ? ? ? ? ? ?ANGLE 0 > > ? ? ? ? ? ? ? ?BUFFER 2 > > ? ? ? ? ? ? ? ?FONT arial-bold > > ? ? ? ? ? ? ? ?TYPE truetype > > ? ? ? ? ? ? ? ?SIZE 7 > > ? ? ? ? ? ?END > > ? ? ? ?END > > > > The difference for the second examples is in the output format used: > > > > ? ?OUTPUTFORMAT > > ? ? ? ?NAME PNG > > ? ? ? ?DRIVER GD/PNG > > ? ? ? ?MIMETYPE ?"image/png" > > ? ? ? ?IMAGEMODE RGB > > ? ? ? ?EXTENSION ?"png" > > ? ? ? ?#FORMATOPTION "QUANTIZE_FORCE=TRUE" > > ? ? ? ?#FORMATOPTION "QUANTIZE_COLORS=256" > > ? ? ? ?FORMATOPTION "PALETTE_FORCE=TRUE" > > ? ? ? ?FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" > > ? ? ? ?FORMATOPTION "INTERLACE=OFF" > > ? ?END > > > > Many thanks, > > Nick > > > > > > -----Original Message----- > From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] > Sent: 08 July 2009 15:29 > To: Nikolai Nikolov; mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Smaller polygon sizes when usingmapserver > 5.4.1compare to 5.2.0 > > > > Perhaps you could post image samples and a mapfile? > > > > Steve > > > >>>> On 7/8/2009 at 3:05 AM, in message > > <65D1C555BE9443A180F3B1697EF7E69F at BenefonUK.local>, "Nikolai Nikolov" > > wrote: > >> Hi everyone, > >> > >> > >> > >> I've just upgraded one of my test servers from 5.2.0 to 5.4.1. ?I have an > >> issue there and I wonder whether anybody have noticed it. ?My map > polygones > >> seems to be fractionaly smaller (compare to those drawned by 5.2.0). > >> > >> > >> > >> I am using the same maps, map files, PHP scripts, etc. ?The plygons which > >> belong to the same layer, do not quite well "fit" with each other - their > >> borders match perfectly before the upgarde to 5.4.1. > >> > >> > >> > >> Also, I use BACKGROUNDCOLOR in my map file to create shield like square > >> behind a label. ?Those squares are now significantly smaller too. > >> > >> > >> > >> I wander what causes this effect and what I should do to achieve the same > >> image as with 5.2.0? > >> > >> > >> > >> Thanks, > >> > >> Nick > >> > >> > >> > >> > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From adrian_gh.popa at romtelecom.ro Tue Jul 14 23:09:00 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Wed, 15 Jul 2009 09:09:00 +0300 Subject: [mapserver-users] Performance in regular expressions or an alternative way to select a list of features In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5056DA681@s-sp22.pca.state.mn.us> References: <6246727221874A4FB8D3F9BBC37D9BD5056DA681@s-sp22.pca.state.mn.us> Message-ID: <4A5D727C.2080508@romtelecom.ro> Hello David, I wasn't aware of the "IN" syntax. It looks cleaner, and hopefully will be better. I think in the end I will try all sollutions and see which one is the fastest for a given (large) expression. Thangs again, Adrian Fawcett, David wrote: > Adrian, > > One method that I have used is to use an IN statement in my expression > and then use a variable to populate the list of IDs in the statement. > > I create a class like this: > > CLASS > NAME "Low" > EXPRESSION ('[COUNTY_FIP]' in '%group1%') > OUTLINECOLOR 0 0 0 > COLOR 255 204 204 > END > > And then in the URL calling the map, I include &group1=27001,27003,27005 > > I actually use this with five classes (five different URL vars) to > create a thematic map of counties based entirely on data passed in > through the URL. > > I have no idea on how the performance of this method compares to what > you have done, but it might be worth a try. There are only 87 > counties in Minnesota, so that is the largest number it gets, but the > performance isn't bad. > > David. > > -----Original Message----- > *From:* mapserver-users-bounces at lists.osgeo.org > [mailto:mapserver-users-bounces at lists.osgeo.org] *On Behalf Of > *Adrian Popa > *Sent:* Tuesday, July 14, 2009 1:15 AM > *To:* mapserver-users at lists.osgeo.org > *Subject:* [mapserver-users] Performance in regular expressions or > an alternative way to select a list of features > > Hello everyone, > > Here's my problem: I'm trying to highlight segments from a line > layer by using an expression in a specific class. This portion of > the mapfile is dynamically generated and when it is done, it is > sent to mapserver for rendering. > My problem is that I have to select between 10 - 400 features at a > time and I noticed when I have a lot of features there is a severe > performance degradation in mapserver (takes a lot of time to > render or even times out). > Right now, my expression is built using regular expressions: > something like: > *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* > This works ok, but as I said has a performance penalty when you > reach ~400 items. My data is selected from a shapefile layer > which has about 5500 items. > > Since I wouldn't be using the regular expressions at full capacity > (I'm matching the full name), I might rewrite the expression using > something like: > *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR > ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* > > From the documentation I see that: > /Regular expression with MapServer work similarly to string > comparison, but allow more complex operation. They are slower than > pure string comparisons, but might be still faster than logical > expression. As with the string comparison use regular expressions, > a FILTERITEM or a CLASSITEM has to defined, respectively. > > /I would like to know if there is an efficient way of selecting a > list of elements from a layer, or what are your recommendations. > > Also - have there been significant changes in performance for this > issue from mapserver 4.10 (I am now migrating to mapserver 5.4)? > > Thanks, > Adrian > -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Tue Jul 14 23:15:41 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Wed, 15 Jul 2009 09:15:41 +0300 Subject: [mapserver-users] Performance in regular expressions or analternative way to select a list of features In-Reply-To: <4A5C5216.5157.008F.0@dnr.state.mn.us> References: <4A5C2277.80204@romtelecom.ro> <4A5C5216.5157.008F.0@dnr.state.mn.us> Message-ID: <4A5D740D.10605@romtelecom.ro> Hello Steve, I haven't tried out the simplified regex so I don't know if it will be faster. I will try to test it as part of a speed test of the various methods... I'm not sure what you mean by writing a temporary set of geometries. Do you mean adding an index to my data so that I can select it by a different (grouping) field instead? Unfortunately I can't do that because the same item can be part of 10-20 groups, so there would not be an easy way to group items apart from duplicating them in the shapefile/dbf. I'm not sure if there's a problem if the same feature appears 12 times in the same shapefile. In the end data reorganizing might be the fastest method available. Problem is some items will belong to groups dinamically, so I will have to implement a selection mechanism based on item id... Regards, Adrian Steve Lime wrote: > Have you tried a simplified version of your regex? I think you can do: > > EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ > > You might also consider writing a temporary set of geometries if a user will continually display from > that set. In that case your overhead would be in managing the set of features which would be higher > the first time but then very fast to render. Your dynamic portion of the mapfile would reference the > temporary data. > > Steve > > >>>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian Popa >>>> > wrote: > >> Hello everyone, >> >> Here's my problem: I'm trying to highlight segments from a line layer by >> using an expression in a specific class. This portion of the mapfile is >> dynamically generated and when it is done, it is sent to mapserver for >> rendering. >> My problem is that I have to select between 10 - 400 features at a time >> and I noticed when I have a lot of features there is a severe >> performance degradation in mapserver (takes a lot of time to render or >> even times out). >> Right now, my expression is built using regular expressions: something like: >> *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* >> This works ok, but as I said has a performance penalty when you reach >> ~400 items. My data is selected from a shapefile layer which has about >> 5500 items. >> >> Since I wouldn't be using the regular expressions at full capacity (I'm >> matching the full name), I might rewrite the expression using something >> like: >> *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR >> ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* >> >> From the documentation I see that: >> /Regular expression with MapServer work similarly to string comparison, >> but allow more complex operation. They are slower than pure string >> comparisons, but might be still faster than logical expression. As with >> the string comparison use regular expressions, a FILTERITEM or a >> CLASSITEM has to defined, respectively. >> >> /I would like to know if there is an efficient way of selecting a list >> of elements from a layer, or what are your recommendations. >> >> Also - have there been significant changes in performance for this issue >> from mapserver 4.10 (I am now migrating to mapserver 5.4)? >> >> Thanks, >> Adrian >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Tue Jul 14 23:15:41 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Wed, 15 Jul 2009 09:15:41 +0300 Subject: [mapserver-users] Performance in regular expressions or analternative way to select a list of features In-Reply-To: <4A5C5216.5157.008F.0@dnr.state.mn.us> References: <4A5C2277.80204@romtelecom.ro> <4A5C5216.5157.008F.0@dnr.state.mn.us> Message-ID: <4A5D740D.10605@romtelecom.ro> Hello Steve, I haven't tried out the simplified regex so I don't know if it will be faster. I will try to test it as part of a speed test of the various methods... I'm not sure what you mean by writing a temporary set of geometries. Do you mean adding an index to my data so that I can select it by a different (grouping) field instead? Unfortunately I can't do that because the same item can be part of 10-20 groups, so there would not be an easy way to group items apart from duplicating them in the shapefile/dbf. I'm not sure if there's a problem if the same feature appears 12 times in the same shapefile. In the end data reorganizing might be the fastest method available. Problem is some items will belong to groups dinamically, so I will have to implement a selection mechanism based on item id... Regards, Adrian Steve Lime wrote: > Have you tried a simplified version of your regex? I think you can do: > > EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ > > You might also consider writing a temporary set of geometries if a user will continually display from > that set. In that case your overhead would be in managing the set of features which would be higher > the first time but then very fast to render. Your dynamic portion of the mapfile would reference the > temporary data. > > Steve > > >>>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian Popa >>>> > wrote: > >> Hello everyone, >> >> Here's my problem: I'm trying to highlight segments from a line layer by >> using an expression in a specific class. This portion of the mapfile is >> dynamically generated and when it is done, it is sent to mapserver for >> rendering. >> My problem is that I have to select between 10 - 400 features at a time >> and I noticed when I have a lot of features there is a severe >> performance degradation in mapserver (takes a lot of time to render or >> even times out). >> Right now, my expression is built using regular expressions: something like: >> *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* >> This works ok, but as I said has a performance penalty when you reach >> ~400 items. My data is selected from a shapefile layer which has about >> 5500 items. >> >> Since I wouldn't be using the regular expressions at full capacity (I'm >> matching the full name), I might rewrite the expression using something >> like: >> *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR >> ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* >> >> From the documentation I see that: >> /Regular expression with MapServer work similarly to string comparison, >> but allow more complex operation. They are slower than pure string >> comparisons, but might be still faster than logical expression. As with >> the string comparison use regular expressions, a FILTERITEM or a >> CLASSITEM has to defined, respectively. >> >> /I would like to know if there is an efficient way of selecting a list >> of elements from a layer, or what are your recommendations. >> >> Also - have there been significant changes in performance for this issue >> from mapserver 4.10 (I am now migrating to mapserver 5.4)? >> >> Thanks, >> Adrian >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Tue Jul 14 23:20:04 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Wed, 15 Jul 2009 09:20:04 +0300 Subject: [mapserver-users] Displaying a string instead of a label Message-ID: <4A5D7514.5060002@romtelecom.ro> Hi everybody, Can someone point me to the relevant part of the documentation/example that shows how to display a static string (set at the layer level) for a layer instead of displaying a label? Does 'annotation' have anything to do with this? Thanks, Adrian From nnikolov at gypsii.com Wed Jul 15 00:02:26 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Wed, 15 Jul 2009 08:02:26 +0100 Subject: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 In-Reply-To: <2922382e0907142236j45c6ac50y53763e1b5bea8435@mail.gmail.com> References: <4A5B92A70200008F00026028@co5.dnr.state.mn.us> <2922382e0907142236j45c6ac50y53763e1b5bea8435@mail.gmail.com> Message-ID: <00fe01ca051a$36ab3940$0401a8c0@BenefonUK.local> Hi Thomas, Please note, that this Mapserver behaviour (correct or incorrect) still exists in 5.4.1 version, when the GD library is used. The change of behaviour affects the rendering of the background when AGG library is used. Also, in the documentation, the use of BACKGROUNDCOLOR is regarded as creating a "billboard" effect. It would be nice to have capability to control the size (and appearance) of this "billboard", which seems to exist in the older 5.2.0 version, but have been partially removed in the new 5.4.1 version. The other point was about the rendering of polygons. I would suggest to put some kind of a note or explanation for the 5.4.1 version, that when the OUTLINECOLOR is not specified, the polygon will be one pixel smaller in size in all directions, from the real one and to avoid this, the OUTLINECOLOR needs to be always defined either with the same colour as the rest of the polygon or with another desired colour. Best regards, Nick -----Original Message----- From: Thomas Bonfort [mailto:thomas.bonfort at camptocamp.com] Sent: 15 July 2009 06:36 To: Steve Lime Cc: nnikolov at gypsii.com; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Smaller polygon sizes when usingmapserver 5.4.1compare to 5.2.0 the previous versions of mapserver (incorrectly I think) used the value of the label buffer to expand the background billboard. You'd get nice results whith a 1 or 2 px buffer like in your case, but unusable ones when you added larger buffers. I hope we can work around this for 5.6 with the possible label style rewrite. regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Tue, Jul 14, 2009 at 03:01, Steve Lime wrote: > Wonder if it's the same issue as with the polygon size you noted. Even though the shield > is a rect it's rendered as a polygon. Thomas, should polygons be drawn with an outline > same as the fill color if no outline color is specifiied? > > Steve > >>>> "Nikolai Nikolov" 07/09/09 2:43 AM >>> > Hi Steve and everyone, > > The images below are from Mapserver 5.2.0 (left) and 5.4.1 (right) of the > same map using AGG. Please note the difference in the size of the road > shields (green shields). > > The following are images from the same servers (Mapserver 5.2.0 (left) and > 5.4.1 (right)) of the same map (different zoom) using GD. ?Please note that > the two maps are practically the same. > > The complete map-file used for the first example is attached to this e-mail. > The parts of it specific to the issue are like that: > > > > ? ?OUTPUTFORMAT > > ? ? ? ?NAME AGG_PNG > > ? ? ? ?DRIVER AGG/PNG > > ? ? ? ?MIMETYPE ?"image/png" > > ? ? ? ?IMAGEMODE RGB > > ? ? ? ?EXTENSION ?"png" > > ? ? ? ?#FORMATOPTION "QUANTIZE_FORCE=TRUE" > > ? ? ? ?#FORMATOPTION "QUANTIZE_COLORS=256" > > ? ? ? ?FORMATOPTION "PALETTE_FORCE=TRUE" > > ? ? ? ?FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" > > ? ? ? ?FORMATOPTION "INTERLACE=OFF" > > ? ?END > > > > and > > ? ? ? ?CLASS > > ? ? ? ? ? ?EXPRESSION /^E/ > > ? ? ? ? ? ?LABEL > > ? ? ? ? ? ? ? ?PRIORITY 4 > > ? ? ? ? ? ? ? ?PARTIALS false > > ? ? ? ? ? ? ? ?MINFEATURESIZE 10 > > ? ? ? ? ? ? ? ?MINDISTANCE 300 > > ? ? ? ? ? ? ? ?COLOR 255 255 255 > > ? ? ? ? ? ? ? ?BACKGROUNDCOLOR 128 208 100 > > ? ? ? ? ? ? ? ?BACKGROUNDSHADOWCOLOR 81 145 58 > > ? ? ? ? ? ? ? ?ANGLE 0 > > ? ? ? ? ? ? ? ?BUFFER 2 > > ? ? ? ? ? ? ? ?FONT arial-bold > > ? ? ? ? ? ? ? ?TYPE truetype > > ? ? ? ? ? ? ? ?SIZE 7 > > ? ? ? ? ? ?END > > ? ? ? ?END > > > > The difference for the second examples is in the output format used: > > > > ? ?OUTPUTFORMAT > > ? ? ? ?NAME PNG > > ? ? ? ?DRIVER GD/PNG > > ? ? ? ?MIMETYPE ?"image/png" > > ? ? ? ?IMAGEMODE RGB > > ? ? ? ?EXTENSION ?"png" > > ? ? ? ?#FORMATOPTION "QUANTIZE_FORCE=TRUE" > > ? ? ? ?#FORMATOPTION "QUANTIZE_COLORS=256" > > ? ? ? ?FORMATOPTION "PALETTE_FORCE=TRUE" > > ? ? ? ?FORMATOPTION "PALETTE=/var/www/html/maps_gypsii/palette.txt" > > ? ? ? ?FORMATOPTION "INTERLACE=OFF" > > ? ?END > > > > Many thanks, > > Nick > > > > > > -----Original Message----- > From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] > Sent: 08 July 2009 15:29 > To: Nikolai Nikolov; mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Smaller polygon sizes when usingmapserver > 5.4.1compare to 5.2.0 > > > > Perhaps you could post image samples and a mapfile? > > > > Steve > > > >>>> On 7/8/2009 at 3:05 AM, in message > > <65D1C555BE9443A180F3B1697EF7E69F at BenefonUK.local>, "Nikolai Nikolov" > > wrote: > >> Hi everyone, > >> > >> > >> > >> I've just upgraded one of my test servers from 5.2.0 to 5.4.1. ?I have an > >> issue there and I wonder whether anybody have noticed it. ?My map > polygones > >> seems to be fractionaly smaller (compare to those drawned by 5.2.0). > >> > >> > >> > >> I am using the same maps, map files, PHP scripts, etc. ?The plygons which > >> belong to the same layer, do not quite well "fit" with each other - their > >> borders match perfectly before the upgarde to 5.4.1. > >> > >> > >> > >> Also, I use BACKGROUNDCOLOR in my map file to create shield like square > >> behind a label. ?Those squares are now significantly smaller too. > >> > >> > >> > >> I wander what causes this effect and what I should do to achieve the same > >> image as with 5.2.0? > >> > >> > >> > >> Thanks, > >> > >> Nick > >> > >> > >> > >> > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From paul_everton at hotmail.com Wed Jul 15 00:29:03 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Wed, 15 Jul 2009 07:29:03 +0000 Subject: [mapserver-users] .map file wont display in Open Layers In-Reply-To: <4A5B41F1.10207@geoanalytic.com> References: <4A5B41F1.10207@geoanalytic.com> Message-ID: Thanks for your reply. I have set up the IMAGEPATH and IMAGE URL as you have suggested and i can now view the outline of my map however it is in red. As you suggested is is probably my projection which i causing this. Any ideas what the correct projection setting might be? Thanks again Paul > Date: Mon, 13 Jul 2009 08:17:21 -0600 > From: bfraser at geoanalytic.com > To: paul_everton at hotmail.com > CC: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] .map file wont display in Open Layers > > Paul, > > You may need to define your output projection instead of using "AUTO" (I > didn't know mapserver would tolerate that in the MAP section!). > > > And IMAGEPATH is the file-system path to a folder writable by mapserver. Here's > an example using standard ms4w: > > IMAGEPATH '\ms4w\tmp\ms_tmp\' > > with IMAGEURL being its web-based equivalent (the same location on disk but > access via your web server): > > IMAGEURL '\ms_tmp\' > > since "ms_tmp" is set as an alias in Apache's httd.conf: > > Alias /ms_tmp/ "C:/ms4w/tmp/ms_tmp/" > > > Best Regards, > Brent Fraser > > > Paul Curran wrote: > > Hi, If anyone can help would be greatly appreciated i have been have > > difficulties displaying my map in Open Layers for little while now. > > > > I have a map file (uk.map) pulling in one layer which is a .shp file > > consisting of .tiff files i created using FWTools. > > > > However i call the .map file from my html page and the map > > will not display in openlayers just a blank screen within the > > Open Layers Window. Can anyone see where i am going wrong? > > > > Here is my map file > > > > MAP > > NAME ukmap > > STATUS ON > > IMAGETYPE PNG > > IMAGECOLOR 153 204 255 > > # Map image size > > SIZE 800 800 > > UNITS METERS > > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > > PROJECTION > > "AUTO" > > END > > # Background color for the map canvas -- change as desired > > IMAGECOLOR 192 192 192 > > IMAGEQUALITY 95 > > IMAGETYPE gif > > OUTPUTFORMAT > > NAME gif > > DRIVER 'GD/GIF' > > MIMETYPE 'image/gif' > > #IMAGEMODE PC256 > > EXTENSION 'gif' > > END > > # Legend > > LEGEND > > IMAGECOLOR 255 255 255 > > STATUS ON > > KEYSIZE 18 12 > > LABEL > > TYPE BITMAP > > SIZE MEDIUM > > COLOR 0 0 89 > > END > > END > > # Web interface definition. Only the template parameter > > # is required to display a map. See MapServer documentation > > WEB > > # Set IMAGEPATH to the path where MapServer should > > # write its output. > > IMAGEPATH '/tmp/' > > # Set IMAGEURL to the url that points to IMAGEPATH > > # as defined in your web server configuration > > IMAGEURL '/tmp/' > > # WMS server settings > > METADATA > > 'wms_title' 'ukmap' > > 'wms_onlineresource' > > 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' > > 'wms_srs' 'EPSG:4326' > > END > > #Scale range at which web interface will operate > > # Template and header/footer settings > > # Only the template parameter is required to display a map. See > > MapServer documentation > > END > > LAYER > > NAME 'map' > > TYPE POLYGON > > DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' > > METADATA > > 'wms_title' 'map' > > END > > STATUS DEFAULT > > TRANSPARENCY 100 > > PROJECTION > > 'proj=longlat' > > 'ellps=WGS84' > > 'datum=WGS84' > > 'no_defs' > > '' > > END > > CLASS > > NAME 'map' > > STYLE > > SYMBOL 0 > > SIZE 2 > > OUTLINECOLOR 0 0 0 > > COLOR 144 50 207 > > END > > END > > END > > END > > > > And my html page: > > > > > > NARIMS MAPPING TEST > > > > > > > > > > > >
> > > > > > > > > > Any help much appreciated. Thanks in advance > > > > > > > > > > ------------------------------------------------------------------------ > > Upgrade to Internet Explorer 8 Optimised for MSN. Download Now > > > > > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users _________________________________________________________________ Share your photos with Windows Live Photos ? Free. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From c.declercq at alkante.com Wed Jul 15 01:19:03 2009 From: c.declercq at alkante.com (Charlotte Declercq) Date: Wed, 15 Jul 2009 10:19:03 +0200 Subject: [mapserver-users] Displaying a string instead of a label In-Reply-To: <4A5D7514.5060002@romtelecom.ro> References: <4A5D7514.5060002@romtelecom.ro> Message-ID: <4A5D90F7.3070902@alkante.com> Hi Adrian, You can set the TEXT property of the CLASS object like this : CLASS NAME "departement" LABEL ANGLE 0.000000 ANTIALIAS TRUE FONT "Arial" MAXSIZE 256 MINSIZE 4 SIZE 8 TYPE TRUETYPE BUFFER 0 COLOR 0 0 0 FORCE FALSE MINDISTANCE -1 MINFEATURESIZE -1 OFFSET 1 1 PARTIALS TRUE POSITION CC SHADOWCOLOR 0 0 0 END STYLE ANGLE 360 COLOR 232 246 9 OPACITY 100 SIZE 10 SYMBOL "Carre" END TEXT "my static text" END It will override the label. You don't need CLASSITEM, LABELITEM, LABELMAXSCALEDENOM and LABELMINSCADENOM but you need the LABEL object. The documentation is here : http://mapserver.org/mapfile/class.html /TEXT [string]/ /Static text to label features in this class with. This overrides values obtained from the LABELTIEM. The string may be given as an expression delimited using the ()?s. This allows you to concatenate multiple attributes into a single label. For example: ([FIRSTNAME],[LASTNAME])./ I think you can set the TEXT property on classical layer types such as POLYGON, LINE, POINT, not only ANNOTATION. If you use ANNOTATION, then the text will be placed at the centroid of the polygon of the middle of the line. Regards, -- Charlotte DECLERCQ ALKANTE SAS Ing?nieur R&D SIG 1, rue du Ch?ne Morand 35 510 Cesson-S?vign? Bur: + 33 (0) 2 99 22 25 70 fax : + 33 (0) 2 99 32 12 76 Adrian Popa a ?crit : > Hi everybody, > > Can someone point me to the relevant part of the documentation/example > that shows how to display a static string (set at the layer level) for > a layer instead of displaying a label? Does 'annotation' have anything > to do with this? > > Thanks, > Adrian > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From adrian_gh.popa at romtelecom.ro Wed Jul 15 01:49:02 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Wed, 15 Jul 2009 11:49:02 +0300 Subject: [mapserver-users] Displaying a string instead of a label In-Reply-To: <4A5D90F7.3070902@alkante.com> References: <4A5D7514.5060002@romtelecom.ro> <4A5D90F7.3070902@alkante.com> Message-ID: <4A5D97FE.5000607@romtelecom.ro> Thank you Charlotte, I will give it a try! Regards, Adrian Charlotte Declercq wrote: > Hi Adrian, > > You can set the TEXT property of the CLASS object like this : > > CLASS > NAME "departement" > LABEL > ANGLE 0.000000 > ANTIALIAS TRUE > FONT "Arial" > MAXSIZE 256 > MINSIZE 4 > SIZE 8 > TYPE TRUETYPE > BUFFER 0 > COLOR 0 0 0 > FORCE FALSE > MINDISTANCE -1 > MINFEATURESIZE -1 > OFFSET 1 1 > PARTIALS TRUE > POSITION CC > SHADOWCOLOR 0 0 0 > END > STYLE > ANGLE 360 > COLOR 232 246 9 > OPACITY 100 > SIZE 10 > SYMBOL "Carre" > END > TEXT "my static text" > END > > It will override the label. You don't need CLASSITEM, LABELITEM, > LABELMAXSCALEDENOM and LABELMINSCADENOM but you need the LABEL object. > The documentation is here : http://mapserver.org/mapfile/class.html > > /TEXT [string]/ > /Static text to label features in this class with. This overrides > values obtained from the LABELTIEM. The string may be given as an > expression delimited using the ()?s. This allows you to concatenate > multiple attributes into a single label. For example: > ([FIRSTNAME],[LASTNAME])./ > > > I think you can set the TEXT property on classical layer types such as > POLYGON, LINE, POINT, not only ANNOTATION. > If you use ANNOTATION, then the text will be placed at the centroid of > the polygon of the middle of the line. > > Regards, > From paul_everton at hotmail.com Wed Jul 15 03:19:41 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Wed, 15 Jul 2009 10:19:41 +0000 Subject: [mapserver-users] Mapfile displaying in red Message-ID: Hi When i load my map file which can be seen below i can view the outline of map but the actual map displays as red. I am viewing the map via the mapserver.exe (e.g.http://localhost/cgi-bin/mapserv.exe?mode=map&map=c:/ms4w/apps/openlayers-2.5/data/test.map&layer='map') Here is my map file, Can anyone spot were i am going wrong? any help greatly appreciated. The uk.shp file i am attempting to load consists of .tiff images amd was put together using FWTools MAP NAME test # Map image size SIZE 400 600 IMAGECOLOR 249 245 186 IMAGETYPE PNG24 OUTPUTFORMAT NAME PNG24 DRIVER 'GD/PNG' MIMETYPE 'image/PNG' #IMAGEMODE PC256 EXTENSION 'png' END EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 WEB IMAGEPATH "\ms4w\tmp\ms_tmp\" IMAGEURL "\ms_tmp\" METADATA WMS_SRS "EPSG:4326 EPSG:900913" END END LAYER NAME 'map' DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' TYPE polygon STATUS DEFAULT TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'datum=WGS84' 'no_defs' '' END CLASS NAME 'map' STYLE COLOR 255 0 0 END LABEL TYPE bitmap END END END END _________________________________________________________________ Get the best of MSN on your mobile http://clk.atdmt.com/UKM/go/147991039/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Wed Jul 15 03:24:46 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Wed, 15 Jul 2009 12:24:46 +0200 Subject: [mapserver-users] symbolset Message-ID: An HTML attachment was scrubbed... URL: From damarmo at gmail.com Wed Jul 15 04:21:07 2009 From: damarmo at gmail.com (David Martinez Morata) Date: Wed, 15 Jul 2009 13:21:07 +0200 Subject: [mapserver-users] symbolset In-Reply-To: References: Message-ID: <9771eb540907150421r670b43eah8cff902f30122809@mail.gmail.com> Hello Try this: http://mapserver.org/mapfile/symbology/construction.html?highlight=symbol 2009/7/15 YOUNESS ELMEDRAOUI > Hi, > > what's the format (content) of symbolset file (.sym)? > do you have some exemple, plz? > Best regards; > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- Martinez Morata David Thinking GIS -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Wed Jul 15 04:36:08 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Wed, 15 Jul 2009 13:36:08 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_Re=3A_[mapserver-users]_symbolset?= In-Reply-To: <9771eb540907150421r670b43eah8cff902f30122809@mail.gmail.com> References: , <9771eb540907150421r670b43eah8cff902f30122809@mail.gmail.com> Message-ID: An HTML attachment was scrubbed... URL: From pauljame at gmail.com Wed Jul 15 06:07:07 2009 From: pauljame at gmail.com (Paul james) Date: Wed, 15 Jul 2009 10:07:07 -0300 Subject: [mapserver-users] Zoom to given coordinate(lat/lon) using Mapscript... In-Reply-To: References: <33fad6880907141119g52be040as3068ef13e3721d30@mail.gmail.com> Message-ID: <33fad6880907150607h1c338084j39e55947b40fd3a0@mail.gmail.com> Thanks Tamas! On Tue, Jul 14, 2009 at 5:30 PM, Tamas Szekeres wrote: > Paul, > > Assuming the desired coordinates are in the same spatial reference system > as the layer you could use mapObj.setCenter and mapObj.scaleExtent. > > Best regards, > > Tamas > > > > 2009/7/14 Paul james > >> How can I do that? >> >> Paul >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Wed Jul 15 06:53:17 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Wed, 15 Jul 2009 07:53:17 -0600 Subject: [mapserver-users] .map file wont display in Open Layers In-Reply-To: References: <4A5B41F1.10207@geoanalytic.com> Message-ID: <4A5DDF4D.10401@geoanalytic.com> Paul, The PROJECTION in the MAP portion refers to your desired output map projection. It's whatever you want it to be. The EXTENT values (and UNITS) must be relevant for your chosen projection. Brent Fraser Paul Curran wrote: > Thanks for your reply. > > > > I have set up the IMAGEPATH and IMAGE URL as you have suggested and i > can now view the outline of my map however it is in red. As you > suggested is is probably my projection which i causing this. Any ideas > what the correct projection setting might be? > > Thanks again > > Paul > >> Date: Mon, 13 Jul 2009 08:17:21 -0600 >> From: bfraser at geoanalytic.com >> To: paul_everton at hotmail.com >> CC: mapserver-users at lists.osgeo.org >> Subject: Re: [mapserver-users] .map file wont display in Open Layers >> >> Paul, >> >> You may need to define your output projection instead of using "AUTO" (I >> didn't know mapserver would tolerate that in the MAP section!). >> >> >> And IMAGEPATH is the file-system path to a folder writable by > mapserver. Here's >> an example using standard ms4w: >> >> IMAGEPATH '\ms4w\tmp\ms_tmp\' >> >> with IMAGEURL being its web-based equivalent (the same location on > disk but >> access via your web server): >> >> IMAGEURL '\ms_tmp\' >> >> since "ms_tmp" is set as an alias in Apache's httd.conf: >> >> Alias /ms_tmp/ "C:/ms4w/tmp/ms_tmp/" >> >> >> Best Regards, >> Brent Fraser >> >> >> Paul Curran wrote: >> > Hi, If anyone can help would be greatly appreciated i have been have >> > difficulties displaying my map in Open Layers for little while now. >> > >> > I have a map file (uk.map) pulling in one layer which is a .shp file >> > consisting of .tiff files i created using FWTools. >> > >> > However i call the .map file from my html page and the map >> > will not display in openlayers just a blank screen within the >> > Open Layers Window. Can anyone see where i am going wrong? >> > >> > Here is my map file >> > >> > MAP >> > NAME ukmap >> > STATUS ON >> > IMAGETYPE PNG >> > IMAGECOLOR 153 204 255 >> > # Map image size >> > SIZE 800 800 >> > UNITS METERS >> > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 >> > PROJECTION >> > "AUTO" >> > END >> > # Background color for the map canvas -- change as desired >> > IMAGECOLOR 192 192 192 >> > IMAGEQUALITY 95 >> > IMAGETYPE gif >> > OUTPUTFORMAT >> > NAME gif >> > DRIVER 'GD/GIF' >> > MIMETYPE 'image/gif' >> > #IMAGEMODE PC256 >> > EXTENSION 'gif' >> > END >> > # Legend >> > LEGEND >> > IMAGECOLOR 255 255 255 >> > STATUS ON >> > KEYSIZE 18 12 >> > LABEL >> > TYPE BITMAP >> > SIZE MEDIUM >> > COLOR 0 0 89 >> > END >> > END >> > # Web interface definition. Only the template parameter >> > # is required to display a map. See MapServer documentation >> > WEB >> > # Set IMAGEPATH to the path where MapServer should >> > # write its output. >> > IMAGEPATH '/tmp/' >> > # Set IMAGEURL to the url that points to IMAGEPATH >> > # as defined in your web server configuration >> > IMAGEURL '/tmp/' >> > # WMS server settings >> > METADATA >> > 'wms_title' 'ukmap' >> > 'wms_onlineresource' >> > 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' >> > 'wms_srs' 'EPSG:4326' >> > END >> > #Scale range at which web interface will operate >> > # Template and header/footer settings >> > # Only the template parameter is required to display a map. See >> > MapServer documentation >> > END >> > LAYER >> > NAME 'map' >> > TYPE POLYGON >> > DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' >> > METADATA >> > 'wms_title' 'map' >> > END >> > STATUS DEFAULT >> > TRANSPARENCY 100 >> > PROJECTION >> > 'proj=longlat' >> > 'ellps=WGS84' >> > 'datum=WGS84' >> > 'no_defs' >> > '' >> > END >> > CLASS >> > NAME 'map' >> > STYLE >> > SYMBOL 0 >> > SIZE 2 >> > OUTLINECOLOR 0 0 0 >> > COLOR 144 50 207 >> > END >> > END >> > END >> > END >> > >> > And my html page: >> > >> > >> > NARIMS MAPPING TEST >> > >> > >> > >> > >> > >> >
>> > >> > >> > >> > >> > Any help much appreciated. Thanks in advance >> > >> > >> > >> > >> > ------------------------------------------------------------------------ >> > Upgrade to Internet Explorer 8 Optimised for MSN. Download Now >> > >> > >> > >> > ------------------------------------------------------------------------ >> > >> > _______________________________________________ >> > mapserver-users mailing list >> > mapserver-users at lists.osgeo.org >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > ------------------------------------------------------------------------ > View your Twitter and Flickr updates from one place ? Learn more! > From bfraser at geoanalytic.com Wed Jul 15 06:59:39 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Wed, 15 Jul 2009 07:59:39 -0600 Subject: [mapserver-users] Mapfile displaying in red In-Reply-To: References: Message-ID: <4A5DE0CB.7020704@geoanalytic.com> Paul, Read the Mapserver documentation on tile indexing (http://mapserver.org/input/raster.html#rasters-and-tile-indexing). Best Regards, Brent Fraser Paul Curran wrote: > Hi > > When i load my map file which can be seen below i can view the outline > of map but the actual map displays as red. I am viewing the map via the > mapserver.exe > (e.g.http://localhost/cgi-bin/mapserv.exe?mode=map&map=c:/ms4w/apps/openlayers-2.5/data/test.map&layer='map' > ) > > Here is my map file, Can anyone spot were i am going wrong? any help > greatly appreciated. > > The uk.shp file i am attempting to load consists of .tiff images amd was > put together using FWTools > > MAP > NAME test > # Map image size > SIZE 400 600 > IMAGECOLOR 249 245 186 > IMAGETYPE PNG24 > OUTPUTFORMAT > NAME PNG24 > DRIVER 'GD/PNG' > MIMETYPE 'image/PNG' > #IMAGEMODE PC256 > EXTENSION 'png' > END > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > > WEB > IMAGEPATH "\ms4w\tmp\ms_tmp\" > IMAGEURL "\ms_tmp\" > METADATA > WMS_SRS "EPSG:4326 EPSG:900913" > END > END > LAYER > NAME 'map' > DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' > TYPE polygon > STATUS DEFAULT > TRANSPARENCY 100 > PROJECTION > 'proj=longlat' > 'ellps=WGS84' > 'datum=WGS84' > 'no_defs' > '' > END > CLASS > NAME 'map' > STYLE > COLOR 255 0 0 > END > LABEL > TYPE bitmap > END > END > END > END > > > ------------------------------------------------------------------------ > Upgrade to Internet Explorer 8 Optimised for MSN. Download Now > > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From David.Fawcett at state.mn.us Wed Jul 15 06:59:45 2009 From: David.Fawcett at state.mn.us (Fawcett, David) Date: Wed, 15 Jul 2009 08:59:45 -0500 Subject: [mapserver-users] Mapfile displaying in red In-Reply-To: Message-ID: <6246727221874A4FB8D3F9BBC37D9BD5056DA68C@s-sp22.pca.state.mn.us> Paul, Your polygon data is red because you are telling MapServer to color it red. In the class in your layer 'map' (probably not a great layer or class name), you are using a style to color your polygons. CLASS NAME 'map' STYLE COLOR 255 0 0 END LABEL TYPE bitmap END END You have set the value of the color property to be 255 0 0. Colors are set as RGB (Red Green Blue) triplets. In that line, you are saying, 'color it with the full amount of red and don't use any green or blue'. If you change the value to 0 0 255, you will see blue polygons. For an easy way to come up with prettier colors, take a look at ColorBrewer: http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer_intro.html David. -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Paul Curran Sent: Wednesday, July 15, 2009 5:20 AM To: mapser all users Subject: [mapserver-users] Mapfile displaying in red Hi When i load my map file which can be seen below i can view the outline of map but the actual map displays as red. I am viewing the map via the mapserver.exe (e.g.http://localhost/cgi-bin/mapserv.exe?mode=map&map=c:/ms4w/apps/open layers-2.5/data/test.map&layer='map') Here is my map file, Can anyone spot were i am going wrong? any help greatly appreciated. The uk.shp file i am attempting to load consists of .tiff images amd was put together using FWTools MAP NAME test # Map image size SIZE 400 600 IMAGECOLOR 249 245 186 IMAGETYPE PNG24 OUTPUTFORMAT NAME PNG24 DRIVER 'GD/PNG' MIMETYPE 'image/PNG' #IMAGEMODE PC256 EXTENSION 'png' END EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 WEB IMAGEPATH "\ms4w\tmp\ms_tmp\" IMAGEURL "\ms_tmp\" METADATA WMS_SRS "EPSG:4326 EPSG:900913" END END LAYER NAME 'map' DATA 'C:\ms4w\apps\openlayers-2.5\data\map.shp' TYPE polygon STATUS DEFAULT TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=WGS84' 'datum=WGS84' 'no_defs' '' END CLASS NAME 'map' STYLE COLOR 255 0 0 END LABEL TYPE bitmap END END END END ________________________________ Upgrade to Internet Explorer 8 Optimised for MSN. Download Now -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Wed Jul 15 07:04:16 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Wed, 15 Jul 2009 11:04:16 -0300 Subject: [mapserver-users] Mapfile displaying in red In-Reply-To: References: Message-ID: <4A5DE1E0.4080207@gatewaygeomatics.com> Hello Paul, Comments inline below: Paul Curran wrote: > Hi > > When i load my map file which can be seen below i can view the outline > of map but the actual map displays as red. I am viewing the map via the > mapserver.exe > (e.g.http://localhost/cgi-bin/mapserv.exe?mode=map&map=c:/ms4w/apps/openlayers-2.5/data/test.map&layer='map' > ) For testing your mapfile, just use the shp2img commandline utility, included in MS4W (http://www.mapserver.org/utilities/shp2img.html). > Here is my map file, Can anyone spot were i am going wrong? any help > greatly appreciated. > > The uk.shp file i am attempting to load consists of .tiff images amd was > put together using FWTools > Make sure the EXTENT parameter is set to the extents of your shapefile - you can use the ogrinfo utility (also included in MS4W) to grab the shp's extents. I would also remove all projection objects, if you only have one layer. Also, I don't understand what data your layer consists of. Are you saying that the shapefile is an indexfile of the extents of the tiffs? (if yes, note that all the tools you needed to create it are also included in MS4W) If you have any questions about the tools in MS4W feel free to fire an email to its mailing list: http://lists.maptools.org/mailman/listinfo/ms4w-users -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From jmckenna at gatewaygeomatics.com Wed Jul 15 07:27:11 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Wed, 15 Jul 2009 11:27:11 -0300 Subject: [mapserver-users] symbolset In-Reply-To: References: Message-ID: <4A5DE73F.7050209@gatewaygeomatics.com> YOUNESS ELMEDRAOUI wrote: > Hi, > > what's the format (content) of symbolset file (.sym)? > do you have some exemple, plz? Since I have seen you asking MS4W questions before, you're best examples will be in the MS4W add-on packages that you can download for MS4W. (I recommend studying one of the mapfiles in the "PHP/MapScript Sample Application", and you can even just use its font files. If you have any questions about using MS4W add-on packages or MS4W configuration, please send questions to its mailing list at: http://lists.maptools.org/mailman/listinfo/ms4w-users -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From andy at squeakycode.net Wed Jul 15 07:44:04 2009 From: andy at squeakycode.net (Andy Colson) Date: Wed, 15 Jul 2009 09:44:04 -0500 Subject: [mapserver-users] mapfile projection In-Reply-To: References: <4A5CBFF9.2000200@squeakycode.net> Message-ID: <4A5DEB34.1010302@squeakycode.net> Richard Greenwood wrote: > > > On Tue, Jul 14, 2009 at 11:27 AM, Andy Colson > wrote: > > Hi all, > > I'm working on my first mapping project, so IANAM (I am no a > mapper). Here is the projection info from a shapefile I'm using: > > PROJCS["NAD_1983_StatePlane_Iowa_North_FIPS_1401_Feet", > GEOGCS["GCS_North_American_1983", > DATUM["D_North_American_1983", > SPHEROID["GRS_1980",6378137.0,298.257222101]], > PRIMEM["Greenwich",0.0], > UNIT["Degree",0.017453292519943295]], > PROJECTION["Lambert_Conformal_Conic"], > PARAMETER["False_Easting",4921250.0], > PARAMETER["False_Northing",3280833.333333333], > PARAMETER["Central_Meridian",-93.5], > PARAMETER["Standard_Parallel_1",42.06666666666667], > PARAMETER["Standard_Parallel_2",43.26666666666667], > PARAMETER["Latitude_Of_Origin",41.5], > UNIT["Foot_US",0.30480060960121924], > PARAMETER["scale_factor",1.0]] > > I used QGIS to create a mapfile, and it generated this: > > PROJECTION > 'proj=longlat' > 'ellps=WGS84' > 'datum=WGS84' > 'no_defs' > '' > END > > I was kind of thinking this (Thanks to FrankW for helping me find > the right epsg code): > > PROJECTION > 'init=epsg:3417' > END > > > Is the first one even right? > > > No > > > Would there be a difference? > > > The first one is spherical, but State Plane is Cartesian (on a plane). > > > Why might I choose one over the other? I'm going to put this into > postgis, with srid = 3417, will that make any difference. > > > Yes. > > > (I'd like to avoid re-projections.. I think... don't I?) > > > Reprojection isn't evil. You may as well do it right, but the main thing > with postgis is that you put it in, and take it out, calling the same > projection. Which could be -1 if you really don't know/care. MapServer > doesn't set a layer's projection from postgis. If you have a layer(s) > that's different from the map's overall projection, then you'd need to > set the projection in the layer definition, not necessarily in postgis. > Setting a layer's projection different from the map's projection is what > will trigger reprojection. > > HTH, > -- > Richard Greenwood > richard.greenwood at gmail.com > www.greenwoodmap.com Ahh, so QGIS didn't export a projection that matched my data. (I assume its a default that it always exports...) > The first one is spherical, but State Plane is Cartesian (on a plane). Heh.. that's one of those answers that brings up more questions. But google is helping me out. Thanks for the help, -Andy From danlittle at yahoo.com Wed Jul 15 08:36:20 2009 From: danlittle at yahoo.com (Dan Little) Date: Wed, 15 Jul 2009 08:36:20 -0700 (PDT) Subject: [mapserver-users] access problems from cgi-bin on Mac OS X 10.4.11 / MAMP In-Reply-To: <1247243283076-3236919.post@n2.nabble.com> References: <1247243283076-3236919.post@n2.nabble.com> Message-ID: <224934.8701.qm@web51401.mail.re2.yahoo.com> I'm on 10.5 and never played with 10.4, but I'll see if I can help as it's all just UNIX, right? :-) I'm also assuming that your directory definition was not copied, pasted and emailed correctly so the superfluous "\" are not really in that file. Have you checked the permissions on the directory itself? It may not be possible for the apache user to cd into the directory where the cgi-bin directory resides. > >From: rmaurer >To: mapserver-users at lists.osgeo.org >Sent: Friday, July 10, 2009 11:28:03 AM >Subject: [mapserver-users] access problems from cgi-bin on Mac OS X 10.4.11 / MAMP > >> >So I'm a first time MapServer user and have been trying to navigate the installation process. I think I almost have it, but I am having some last problems. When I access my executable mapserv file from the command line, I get this: > > >This script can only be used to decode form results and should be initiated as a CGI process via a httpd server. > >>All sounds good, right? Well, I am using MAMP to host an Apache2.0 server. The httpd.conf file has the following in it: > >Alias /cgi-bin/ "[rootfile]/cgi-bin/" > >Directory "[rootfile]/cgi-bin/\> > >AllowOverride None > >Options ExecCGI FollowSymLinks Indexes > >Order allow,deny > >Allow from all > >/Directory\> > >AddHandler cgi-script .cgi .py > >>I know that first line should probably be ScriptAlias, but I kept getting a "Permission Denied" message and read in a forum that this was a solution somebody had come up with, and indeed it worked for me as well. > > >>Anyways, the problem is that in this cgi-bin I have my mapserv executable (though one of the things I'm thinking is that maybe I need to add something else to AddHandler to make it think that this file is executable?). But when I got to //localhost/cgi-bin/mapserv it tries to download the file as "Untyped Binary Data" and it doesn't execute anthing. > >>In case its of any help the ls -l for my cgi-bin gives the following information: >-rwxr-xr-x 1 Rebecca Rebecca 51244 Jul 9 07:52 mapserv > >>Do I not have this installed correctly? Or is my server just not realizing that this is executable. I would be thrilled if I could just get to the point where //localhost/cgi-bin/mapserv just brought up a "No query information to decode" message, since I think I can handle it from there. > > >>Thank you very much, > >Rebecca > >________________________________ >View this message in context: access problems from cgi-bin on Mac OS X 10.4.11 / MAMP >>Sent from the Mapserver - User mailing list archive at Nabble.com. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gju at galigeo.com Wed Jul 15 10:24:11 2009 From: gju at galigeo.com (=?iso-8859-1?Q?Gana=EBl_Jatteau?=) Date: Wed, 15 Jul 2009 19:24:11 +0200 Subject: [mapserver-users] Java mapscript on Linux Message-ID: <011b01ca0571$11b74ff0$a301a8c0@avantias.local> Hello, I?m trying to deploy on Linux (Ubuntu 8.04) a Java application that uses mapscript. And I can?t find any libmapscript.so for Java (Ubuntu has some packages for Perl, Python PhP but not Java). Is there any other choice than getting the source code and compile it? (I believe that mapscript for PhP5 won?t contain the correct JNI headers to be used by mapscript.jar) Thanks in advance! -------------- next part -------------- An HTML attachment was scrubbed... URL: From umberto.nicoletti at gmail.com Wed Jul 15 10:59:23 2009 From: umberto.nicoletti at gmail.com (Umberto Nicoletti) Date: Wed, 15 Jul 2009 19:59:23 +0200 Subject: [mapserver-users] Java mapscript on Linux In-Reply-To: <011b01ca0571$11b74ff0$a301a8c0@avantias.local> References: <011b01ca0571$11b74ff0$a301a8c0@avantias.local> Message-ID: <75b4b93e0907151059r262d887doe215b51135018964@mail.gmail.com> Hi, I am afraid you have to compile java mapscript from the sources. Good luck, Umberto On Wed, Jul 15, 2009 at 7:24 PM, Gana?l Jatteau wrote: > Hello, > > > > I?m trying to deploy on Linux (Ubuntu 8.04) a Java application that uses > mapscript. > > > > And I can?t find any libmapscript.so for Java (Ubuntu has some packages for > Perl, Python PhP but not Java). Is there any other choice than getting the > source code and compile it? > > > > (I believe that mapscript for PhP5 won?t contain the correct JNI headers to > be used by mapscript.jar) > > > > Thanks in advance! > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From stelaanders at gmail.com Wed Jul 15 12:41:46 2009 From: stelaanders at gmail.com (stela anders) Date: Wed, 15 Jul 2009 16:41:46 -0300 Subject: [mapserver-users] Delete feature... Message-ID: Hello ^^ I?ve defined a Marker layer like that: LAYER NAME MarkerLayer TYPE POINT FEATURE END STATUS ON TEMPLATE "dummy" CLASS SYMBOL "circle" SIZE 15 COLOR 255 120 0 END END Now, with mapscript I add several points (with method addFeature) ... How can I delete that points? Stella =_- -------------- next part -------------- An HTML attachment was scrubbed... URL: From john.callahan at UDel.Edu Wed Jul 15 15:36:36 2009 From: john.callahan at UDel.Edu (John Callahan) Date: Wed, 15 Jul 2009 18:36:36 -0400 Subject: [mapserver-users] GetCapabilities response being truncated In-Reply-To: <4A566F3B.1020804@udel.edu> References: <4A565A3C.2060905@udel.edu> <4A566F3B.1020804@udel.edu> Message-ID: <4A5E59F4.9080709@udel.edu> I'm still struggling to find the cause of this strange problem. Has anyone successfully run x64 MapServer (from http://vbkto.dyndns.org:1280/sdk/) on Windows? Has anyone ever seen the 4096 character truncating problem before? Thanks for any help you can provide. - John John Callahan wrote: > Update: I should rephrase my statements... > > When run from the command line, c:\apache2.2\cgi-bin\mapserv > "QUERY_STRING=map=...REQUEST=GetCapabilities" only works when output > is to the screen. > When directing the output to a file, like c:\apache2.2\cgi-bin\mapserv > "QUERY_STRING=map=...REQUEST=GetCapabilities" > geomap.xml, then the > output is again truncated. > > The limit is not 4053 characters but rather 4096 characters. At least > the number makes more sense. > > Using MapServer 5.4.1, x64 in Windows 2008 Server. More details on > the environment is: > http://vbkto.dyndns.org:1280/sdk/PackageInfo.aspx?file=release-1400-x64-gdal-1-6-mapserver-5-4.zip > > > > - John > > > > > John Callahan wrote: >> This seems to be a strange problem... I can generate maps fine >> through the browser and mode=map. However, responses to >> GetCapabilities requests are being truncated. They are being >> truncated to 4053 characters. I've tried this using two separate map >> files, using different data, both WMS 1.1.0 and 1.1.1 versions, and >> the same result every time. >> I found some references to old posts but they didn't seem to apply >> here. My data in each map file is just one shapefile. My map file >> symbology is also very simple; it's listed below. >> >> When run from the command line (mapserv >> "QUERY_STRING=map=...REQUEST=GetCapabilities"), it works perfectly. >> >> >> I'm using the x64 stable build from >> http://vbkto.dyndns.org:1280/sdk/Default.aspx (MSVC2005 Win64) >> Apache 2.2.10 and PHP 5.2.5 (x64 versions) if that matters. >> >> >> I just don't know what's going on. Sounds like a problem with my >> server setup. Has anyone experienced this before? Any suggestions >> on what I can check? Thanks. >> >> - John >> >> >> ***** start of mapfile >> # Map file created from QGIS project file >> C:/Apache2.2/cgi-bin/maps/geomap12.qgs >> # Edit this file to customize for your map interface >> # (Created with PyQgis MapServer Export plugin) >> MAP >> NAME 'geomap12' >> # Map image size >> SIZE 600 600 >> UNITS meters >> >> CONFIG "PROJ_LIB" "C:/programs/proj/nad/" >> >> EXTENT 213919.523729 80938.404739 236765.007609 99539.050324 >> PROJECTION >> "init=epsg:26957" >> END >> >> # Background color for the map canvas -- change as desired >> TRANSPARENT ON >> IMAGECOLOR 192 192 192 >> IMAGEQUALITY 95 >> IMAGETYPE png >> OUTPUTFORMAT >> NAME png >> DRIVER 'GD/PNG' >> MIMETYPE 'image/png' >> #IMAGEMODE PC256 >> EXTENSION 'png' >> END >> >> # Web interface definition. Only the template parameter >> # is required to display a map. See MapServer documentation >> WEB >> # Set IMAGEPATH to the path where MapServer should >> # write its output. >> IMAGEPATH 'C:/Apache2.2/htdocs/output/' >> >> # Set IMAGEURL to the url that points to IMAGEPATH >> # as defined in your web server configuration >> IMAGEURL '/output/' >> >> # WMS server settings >> METADATA >> 'wms_title' 'geomap12' >> 'wms_onlineresource' >> 'http://diagproweb01/cgi-bin/mapserv.exe?map=c:/webgis/mapfiles/geomap12.map&' >> >> 'wms_srs' 'EPSG:26957 EPSG:4326' >> END >> >> #Scale range at which web interface will operate >> # Template and header/footer settings >> # Only the template parameter is required to display a map. See >> MapServer documentation >> END >> >> LAYER >> NAME 'geounits' >> TYPE POLYGON >> DATA 'C:\webgis\data\geomap_pubs\geomap12.shp' >> METADATA >> 'wms_title' 'geounits' >> END >> STATUS DEFAULT >> TRANSPARENCY 100 >> PROJECTION >> "init=epsg:26957" >> END >> CLASS >> NAME 'geomap12' >> STYLE >> SYMBOL 0 >> SIZE 2 >> OUTLINECOLOR 0 0 0 >> COLOR 144 50 207 >> END >> END END >> END >> ***** end of mapfile >> >> ************************************************** >> John Callahan, Geospatial Application Developer >> Delaware Geological Survey, University of Delaware >> URL: http://www.dgs.udel.edu >> ************************************************** >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > From szekerest at gmail.com Wed Jul 15 15:58:08 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Thu, 16 Jul 2009 00:58:08 +0200 Subject: [mapserver-users] Delete feature... In-Reply-To: References: Message-ID: There's no such function at the moment, the only chance is to remove and re-create the entire layer in order to remove all features. Best regards, Tamas 2009/7/15 stela anders > Hello ^^ > > I?ve defined a Marker layer like that: > LAYER > NAME MarkerLayer > TYPE POINT > FEATURE > END > STATUS ON > TEMPLATE "dummy" > CLASS > SYMBOL "circle" > SIZE 15 > COLOR 255 120 0 > END > END > > > Now, with mapscript I add several points (with method addFeature) ... > How can I delete that points? > > Stella =_- > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Thu Jul 16 02:27:15 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Thu, 16 Jul 2009 11:27:15 +0200 Subject: [mapserver-users] mapserver/openlayers Message-ID: An HTML attachment was scrubbed... URL: From bartvde at osgis.nl Thu Jul 16 02:35:20 2009 From: bartvde at osgis.nl (bartvde at osgis.nl) Date: Thu, 16 Jul 2009 11:35:20 +0200 (CEST) Subject: [mapserver-users] mapserver/openlayers In-Reply-To: References: Message-ID: <11352.145.50.39.11.1247736920.squirrel@webmail.hostingdiscounter.nl> Hi, no you can also use OpenLayers.Layer.Mapserver, but this is not the recommended way. Mapserver has a native CGI interface, e.g. stuff like mapserv?map=/mymap.map&layers=all&mode=map But there is also a standard way of getting maps out of a web mapping server, and this is called WMS. The parameters are then something like: mapserv?map=/mymap.map&service=WMS&request=GetMap&layers=mylayer1,mylayer2&styles=,&bbox=...... etc. Setting up a WMS with Mapserver is quite easy, check the Mapserver WMS Server HOWTO on the website. It just requires a few extra entries in the MAP file. http://mapserver.org/ogc/wms_server.html Also check the OpenLayers tutorial by OpenGeo: http://workshops.opengeo.org/openlayers-intro/ Best regards, Bart > size=2>
Hi,
 
how can i use openlayers with > mapserver? it's necessarly to create a wms server?
if yes, i > can't understand a concept of a wms server. can you help me > plz?

Best > regards,
Youness ELMEDRAOUI
Les informations figurant > sur cet e-mail ont un caract?re strictement confidentiel et sont > exclusivement adress?es au destinataire mentionn? ci-dessus.Tout > usage, reproduction ou divulgation de cet e-mail est strictement > interdit si vous n'en ?tes pas le destinataire.Dans ce cas, veuillez > nous en avertir imm?diatement par la m?me voie et d?truire l'original. > Merci
_______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From Michael.Pfeiffer at bd.so.ch Thu Jul 16 04:26:42 2009 From: Michael.Pfeiffer at bd.so.ch (Michael Pfeiffer) Date: Thu, 16 Jul 2009 04:26:42 -0700 (PDT) Subject: [mapserver-users] Problems with non-square pixels Message-ID: <1247743602628-3268002.post@n2.nabble.com> Hi everybody, we have problems with one of our WMS services. The wms services delivers a map for our printing tool. Map extents from A1-A4 are working fine and fast. As a example try these two wms requests: http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BBOX=605110.844342816,226276.93355594442,609035.4971205938,229116.79466705554&WIDTH=6181&HEIGHT=4472&SRS=EPSG:21781 A1 landscape http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BBOX=605653.2401761494,225734.5377226111,608493.1012872604,229659.19050038885&WIDTH=4472&HEIGHT=6181&SRS=EPSG:21781 A1 portrait But with A0 map extent we have problems. Landscape is still working fine. Try this wms request. The map should be displayed after ca. 10 seconds in your browser. http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BBOX=604241.2471205938,225659.57244483332,609905.094342816,229734.15577816663&WIDTH=8921&HEIGHT=6417&SRS=EPSG:21781 A0 landscape In contrast portrait needs now much longer than landscape. From A1-A4 it needs exactly the same time. Try this wms request http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BBOX=605035.8790650383,224864.94050038885,609110.4623983715,230528.7877226111&WIDTH=6417&HEIGHT=8921&SRS=EPSG:21781 A0 portrait This request needs over 1 minute. It seems that mapserver gets in the non-square pixels mode for this request. See the outcome of the Debugger for the request [Thu Jul 16 11:59:59 2009].111090 msWMSLoadGetMapParams(): enabling non-square pixels.[Thu Jul 16 11:59:59 2009].452278 msDrawMap(): kicking into non-squarepixel preserving mode.[Thu Jul 16 11:59:59 2009].452334 msDrawRasterLayerLow(Orthofoto07): entering. [Thu Jul 16 12:01:15 2009].757262 msDrawMap(): Layer 1 (Orthofoto07), 76.305s [Thu Jul 16 12:01:15 2009].757304 msDrawMap(): Drawing Label Cache, 0.000s [Thu Jul 16 12:01:15 2009].757313 msDrawMap() total time: 76.638s [Thu Jul 16 12:01:41 2009].955410 msSaveImage() total time: 26.198s [Thu Jul 16 12:01:41 2009].956887 mapserv request processing time (msLoadMap not incl.): 102.846s [Thu Jul 16 12:01:41 2009].956896 msFreeMap(): freeing map at 0x82c1688. In all the other wms requests mapserver does not enable non square pixels [Thu Jul 16 13:00:47 2009].107521 msDrawRasterLayerLow(Orthofoto07): entering. [Thu Jul 16 13:00:49 2009].925029 msDrawMap(): Layer 1 (Orthofoto07), 2.818s [Thu Jul 16 13:00:49 2009].925076 msDrawMap(): Drawing Label Cache, 0.000s [Thu Jul 16 13:00:49 2009].925085 msDrawMap() total time: 3.160s [Thu Jul 16 13:00:52 2009].543021 msSaveImage() total time: 2.618s [Thu Jul 16 13:00:52 2009].544066 mapserv request processing time (msLoadMap not incl.): 5.787s [Thu Jul 16 13:00:52 2009].544073 msFreeMap(): freeing map at 0x8486740. So the question for me is: Why is this happening? I think the ratio is OK. Width and height are the same. I only swap them between portrait and landscape. I've tried with CONFIG "MS_NONSQUARE" NO and with CONFIG "MS_NONSQUARE" YES but nothing changed Any help is much appreciated. We're using MapServer 5.2.1 with an apache server on Linux I've attached the mapfile of the WMS. http://n2.nabble.com/file/n3268002/wms_print_test.map wms_print_test.map The relevant layers are Orthofoto07 and Orthofoto5m thx for the help Michael -- View this message in context: http://n2.nabble.com/Problems-with-non-square-pixels-tp3268002p3268002.html Sent from the Mapserver - User mailing list archive at Nabble.com. From andrew.deklerk at gmail.com Thu Jul 16 05:21:40 2009 From: andrew.deklerk at gmail.com (stretch) Date: Thu, 16 Jul 2009 05:21:40 -0700 (PDT) Subject: [mapserver-users] Dynamic Label Size Message-ID: <1247746900943-3268099.post@n2.nabble.com> Hi A couple of weeks ago, i posted a question about dynamically changing the label field through the URL. Steve pointed me to the answer of using a VALIDATION pattern and Substitution. This worked very well. I am now in another instance needing to look at changing the label size. I have tried adding a "size" validation pattern -i.e.: VALIDATION 'size' '^7|8|9|10|11|12$' END as well as tried "map.layer[Compartments].class[0].label[0]=SIZE+10" both to no joy Could some please lead me in the right direction Thanks in advance Andrew -- View this message in context: http://n2.nabble.com/Dynamic-Label-Size-tp3268099p3268099.html Sent from the Mapserver - User mailing list archive at Nabble.com. From mschulz at webgis.de Thu Jul 16 06:34:21 2009 From: mschulz at webgis.de (Michael Schulz) Date: Thu, 16 Jul 2009 15:34:21 +0200 Subject: [mapserver-users] wfs getcapabilities doesn't use namespace in featuretype's name? Message-ID: Hi, I am wondering why mapserver doesn't specify a featuretypes name with it's namespace in the getcapabilities response (e.g. the default "ms" namespace)? I have tested it with the latest 5.4.1 version, neither wfs 1.0 nor 1.1 do that. Is this intended behaviour? Because as far as i read in the specs, it should output the namespace qualified name of the feature type. Any clarification is appreciated. Cheers, Michael -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Aufwind durch Wissen! Qualifizierte Open Source Schulungen bei der http://www.foss-akademie.de/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------------------------------------- Michael Schulz mschulz at webgis.de in medias res Gesellschaft f?r Informationstechnologie mbH +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ Schwimmbadstra?e 2 D-79100 Freiburg i. Br. Tel: +49 (0)761 705798-102 Tel: +49 (0)761 705798-0 Fax: +49 (0)761 705798-09 +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ http://www.webgis.de / http://www.zopecms.de -------------------------------------------------------------- Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg From jasonbeverage at gmail.com Thu Jul 16 10:08:14 2009 From: jasonbeverage at gmail.com (Jason Beverage) Date: Thu, 16 Jul 2009 13:08:14 -0400 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG Message-ID: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> Hi all, I'm trying to build Mapserver 5.4.1 against AGG 2.4 with Python Mapscript on Centos 5 and I'm having some trouble. I followed the instructions on http://mapserver.org/installation/unix.htmland modified the Makefile.in.Linux of AGG to include the -fPIC option to support mapscript. AGG seems to build libagg.a just fine in the src directory. When I build mapserver against that version of AGG, it compiles fine and so do the python bindings. However, when I install and try to use mapscript in python, I get an error when I try to import the mapscript module: ImportError: /usr/lib/python2.4/site-packages/_mapscript.so: undefined symbol: _ZN3agg12g_sqrt_tableE This appears to be an error due to the -fPIC option not being specified in the AGG build, which I've done. Are there any other steps that must be done to successfully compile Mapserver against AGG to get the python bindings to work? Thanks, Jason -------------- next part -------------- An HTML attachment was scrubbed... URL: From nnikolov at gypsii.com Thu Jul 16 10:14:15 2009 From: nnikolov at gypsii.com (Nikolai Nikolov) Date: Thu, 16 Jul 2009 18:14:15 +0100 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> Message-ID: <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> Hi Jason, Mapserver 5.2.0 and later versions build successfully with AGG 2.5 !!! So I would suggest, as the best option for you, to get AGG 2.5 and then build AGG and Mapserver. Best regards, Nick _____ From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Jason Beverage Sent: 16 July 2009 18:08 To: mapserver-users at lists.osgeo.org Subject: [mapserver-users] Building Mapserver with Mapscript and AGG Hi all, I'm trying to build Mapserver 5.4.1 against AGG 2.4 with Python Mapscript on Centos 5 and I'm having some trouble. I followed the instructions on http://mapserver.org/installation/unix.html and modified the Makefile.in.Linux of AGG to include the -fPIC option to support mapscript. AGG seems to build libagg.a just fine in the src directory. When I build mapserver against that version of AGG, it compiles fine and so do the python bindings. However, when I install and try to use mapscript in python, I get an error when I try to import the mapscript module: ImportError: /usr/lib/python2.4/site-packages/_mapscript.so: undefined symbol: _ZN3agg12g_sqrt_tableE This appears to be an error due to the -fPIC option not being specified in the AGG build, which I've done. Are there any other steps that must be done to successfully compile Mapserver against AGG to get the python bindings to work? Thanks, Jason -------------- next part -------------- An HTML attachment was scrubbed... URL: From jasonbeverage at gmail.com Thu Jul 16 10:26:37 2009 From: jasonbeverage at gmail.com (Jason Beverage) Date: Thu, 16 Jul 2009 13:26:37 -0400 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> Message-ID: <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> Hi Nick, I've also tried AGG 2.5 and get the same result. I can build it just fine, its just that the Python bindings don't work correctly. Thanks, Jason On Thu, Jul 16, 2009 at 1:14 PM, Nikolai Nikolov wrote: > Hi Jason, > > > > Mapserver 5.2.0 and later versions build successfully with AGG 2.5 !!! So > I would suggest, as the best option for you, to get AGG 2.5 and then build > AGG and Mapserver. > > > > Best regards, > > Nick > > > ------------------------------ > > *From:* mapserver-users-bounces at lists.osgeo.org [mailto: > mapserver-users-bounces at lists.osgeo.org] *On Behalf Of *Jason Beverage > *Sent:* 16 July 2009 18:08 > *To:* mapserver-users at lists.osgeo.org > *Subject:* [mapserver-users] Building Mapserver with Mapscript and AGG > > > > Hi all, > > I'm trying to build Mapserver 5.4.1 against AGG 2.4 with Python Mapscript > on Centos 5 and I'm having some trouble. > > I followed the instructions on http://mapserver.org/installation/unix.htmland modified the Makefile.in.Linux of AGG to include the -fPIC option to > support mapscript. AGG seems to build libagg.a just fine in the src > directory. > > When I build mapserver against that version of AGG, it compiles fine and so > do the python bindings. However, when I install and try to use mapscript in > python, I get an error when I try to import the mapscript module: > ImportError: /usr/lib/python2.4/site-packages/_mapscript.so: undefined > symbol: _ZN3agg12g_sqrt_tableE > > This appears to be an error due to the -fPIC option not being specified in > the AGG build, which I've done. > > Are there any other steps that must be done to successfully compile > Mapserver against AGG to get the python bindings to work? > > Thanks, > > Jason > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andy at squeakycode.net Thu Jul 16 10:32:26 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 16 Jul 2009 12:32:26 -0500 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> Message-ID: <4A5F642A.4050303@squeakycode.net> Jason Beverage wrote: > Hi Nick, > > I've also tried AGG 2.5 and get the same result. I can build it just > fine, its just that the Python bindings don't work correctly. > > Thanks, > > Jason > > On Thu, Jul 16, 2009 at 1:14 PM, Nikolai Nikolov > wrote: > > Hi Jason, > > > > Mapserver 5.2.0 and later versions build successfully with AGG 2.5 > !!! So I would suggest, as the best option for you, to get AGG 2.5 > and then build AGG and Mapserver. > > > > Best regards, > > Nick > > > > ------------------------------------------------------------------------ > > *From:* mapserver-users-bounces at lists.osgeo.org > > [mailto:mapserver-users-bounces at lists.osgeo.org > ] *On Behalf Of > *Jason Beverage > *Sent:* 16 July 2009 18:08 > *To:* mapserver-users at lists.osgeo.org > > *Subject:* [mapserver-users] Building Mapserver with Mapscript and AGG > > > > Hi all, > > I'm trying to build Mapserver 5.4.1 against AGG 2.4 with Python > Mapscript on Centos 5 and I'm having some trouble. > > I followed the instructions on > http://mapserver.org/installation/unix.html and modified the > Makefile.in.Linux of AGG to include the -fPIC option to support > mapscript. AGG seems to build libagg.a just fine in the src directory. > > When I build mapserver against that version of AGG, it compiles fine > and so do the python bindings. However, when I install and try to > use mapscript in python, I get an error when I try to import the > mapscript module: > ImportError: /usr/lib/python2.4/site-packages/_mapscript.so: > undefined symbol: _ZN3agg12g_sqrt_tableE > > This appears to be an error due to the -fPIC option not being > specified in the AGG build, which I've done. > > Are there any other steps that must be done to successfully compile > Mapserver against AGG to get the python bindings to work? > > Thanks, > > Jason > > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users When you do a make, if you scroll back up into the output do you see -fpic on the command line? You say you modified Makefile.in.Linux? Do you use the automake stuff? I didnt, I used the normal Makefile, which includes src/Makefile. I modified src/Makefile and changed: CXXFLAGS= $(AGGCXXFLAGS) -I../include -L./ to CXXFLAGS= $(AGGCXXFLAGS) -fPIC -I../include -L./ and then just did: make -Andy From jasonbeverage at gmail.com Thu Jul 16 10:44:13 2009 From: jasonbeverage at gmail.com (Jason Beverage) Date: Thu, 16 Jul 2009 13:44:13 -0400 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <4A5F642A.4050303@squeakycode.net> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> <4A5F642A.4050303@squeakycode.net> Message-ID: <2c4bbbeb0907161044w17a65b36lf7ea6f22c81cadc0@mail.gmail.com> Hi Andy, I tried modifying both the Makefile.in.Linux as well as the regular makefile. I can see -fPIC on the command line, so it appears to be doing what I want, but I still get the same error in both cases. Jason On Thu, Jul 16, 2009 at 1:32 PM, Andy Colson wrote: > Jason Beverage wrote: > >> Hi Nick, >> >> I've also tried AGG 2.5 and get the same result. I can build it just >> fine, its just that the Python bindings don't work correctly. >> >> Thanks, >> >> Jason >> >> On Thu, Jul 16, 2009 at 1:14 PM, Nikolai Nikolov > nnikolov at gypsii.com>> wrote: >> >> Hi Jason, >> >> >> Mapserver 5.2.0 and later versions build successfully with AGG 2.5 >> !!! So I would suggest, as the best option for you, to get AGG 2.5 >> and then build AGG and Mapserver. >> >> >> Best regards, >> >> Nick >> >> >> >> ------------------------------------------------------------------------ >> >> *From:* mapserver-users-bounces at lists.osgeo.org >> >> [mailto:mapserver-users-bounces at lists.osgeo.org >> ] *On Behalf Of >> *Jason Beverage >> *Sent:* 16 July 2009 18:08 >> *To:* mapserver-users at lists.osgeo.org >> >> *Subject:* [mapserver-users] Building Mapserver with Mapscript and AGG >> >> >> Hi all, >> >> I'm trying to build Mapserver 5.4.1 against AGG 2.4 with Python >> Mapscript on Centos 5 and I'm having some trouble. >> >> I followed the instructions on >> http://mapserver.org/installation/unix.html and modified the >> Makefile.in.Linux of AGG to include the -fPIC option to support >> mapscript. AGG seems to build libagg.a just fine in the src directory. >> >> When I build mapserver against that version of AGG, it compiles fine >> and so do the python bindings. However, when I install and try to >> use mapscript in python, I get an error when I try to import the >> mapscript module: >> ImportError: /usr/lib/python2.4/site-packages/_mapscript.so: >> undefined symbol: _ZN3agg12g_sqrt_tableE >> >> This appears to be an error due to the -fPIC option not being >> specified in the AGG build, which I've done. >> >> Are there any other steps that must be done to successfully compile >> Mapserver against AGG to get the python bindings to work? >> >> Thanks, >> >> Jason >> >> >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > When you do a make, if you scroll back up into the output do you see -fpic > on the command line? > > You say you modified Makefile.in.Linux? Do you use the automake stuff? > > I didnt, I used the normal Makefile, which includes src/Makefile. I > modified src/Makefile and changed: > > CXXFLAGS= $(AGGCXXFLAGS) -I../include -L./ > > to > > CXXFLAGS= $(AGGCXXFLAGS) -fPIC -I../include -L./ > > and then just did: > > make > > > > -Andy > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andy at squeakycode.net Thu Jul 16 10:49:25 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 16 Jul 2009 12:49:25 -0500 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <2c4bbbeb0907161044w17a65b36lf7ea6f22c81cadc0@mail.gmail.com> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> <4A5F642A.4050303@squeakycode.net> <2c4bbbeb0907161044w17a65b36lf7ea6f22c81cadc0@mail.gmail.com> Message-ID: <4A5F6825.2090903@squeakycode.net> Jason Beverage wrote: > Hi Andy, > > I tried modifying both the Makefile.in.Linux as well as the regular > makefile. I can see -fPIC on the command line, so it appears to be > doing what I want, but I still get the same error in both cases. > > Jason > Did you build mapserver with agg first, before mapscript? I'm using the perl stuff, but saw a similar error. I went back and did a 'make clean' and make for each of agg, mapserver and then mapscript/perl. (in that order) Otherwise, I'm afraid I dunno... -Andy From jasonbeverage at gmail.com Thu Jul 16 10:55:14 2009 From: jasonbeverage at gmail.com (Jason Beverage) Date: Thu, 16 Jul 2009 13:55:14 -0400 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <4A5F6825.2090903@squeakycode.net> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> <4A5F642A.4050303@squeakycode.net> <2c4bbbeb0907161044w17a65b36lf7ea6f22c81cadc0@mail.gmail.com> <4A5F6825.2090903@squeakycode.net> Message-ID: <2c4bbbeb0907161055j22edebdch2986fb2033430b39@mail.gmail.com> Nick, Thanks for your suggestion of updating to AGG 2.5 from rpm forge! Doing so gave me a nice shared library of AGG and I've got my mapscript Python working now, thanks! >From what I've been reading on the mailing list, there are talks of just including AGG directly into the Mapserver source, which would be wonderful. The less dependencies the better :) Thanks again! Jason On Thu, Jul 16, 2009 at 1:49 PM, Andy Colson wrote: > Jason Beverage wrote: > >> Hi Andy, >> >> I tried modifying both the Makefile.in.Linux as well as the regular >> makefile. I can see -fPIC on the command line, so it appears to be doing >> what I want, but I still get the same error in both cases. >> >> Jason >> >> > Did you build mapserver with agg first, before mapscript? I'm using the > perl stuff, but saw a similar error. I went back and did a 'make clean' and > make for each of agg, mapserver and then mapscript/perl. (in that order) > > Otherwise, I'm afraid I dunno... > > -Andy > -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at camptocamp.com Thu Jul 16 11:25:44 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Thu, 16 Jul 2009 20:25:44 +0200 Subject: [mapserver-users] Building Mapserver with Mapscript and AGG In-Reply-To: <2c4bbbeb0907161055j22edebdch2986fb2033430b39@mail.gmail.com> References: <2c4bbbeb0907161008x574bd4d9w6b114fab9296bece@mail.gmail.com> <017001ca0638$d96831a0$0401a8c0@BenefonUK.local> <2c4bbbeb0907161026o16899ee5k7a3f0c396b17c478@mail.gmail.com> <4A5F642A.4050303@squeakycode.net> <2c4bbbeb0907161044w17a65b36lf7ea6f22c81cadc0@mail.gmail.com> <4A5F6825.2090903@squeakycode.net> <2c4bbbeb0907161055j22edebdch2986fb2033430b39@mail.gmail.com> Message-ID: <2922382e0907161125h101a04d3ta7c6e18f2cda9b5c@mail.gmail.com> Yes, version 5.6 or 6.0, whatever it's called, will include the agg tree, in a hope to cut down on the multiple problems that folks were having with compiling agg correctly. you can already try it out by using a trunk version of mapserver and report back to us if any problems arise. regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Thu, Jul 16, 2009 at 19:55, Jason Beverage wrote: > Nick, > > Thanks for your suggestion of updating to AGG 2.5 from rpm forge!? Doing so > gave me a nice shared library of AGG and I've got my mapscript Python > working now, thanks! > > From what I've been reading on the mailing list, there are talks of just > including AGG directly into the Mapserver source, which would be wonderful. > The less dependencies the better :) > > Thanks again! > > Jason > > On Thu, Jul 16, 2009 at 1:49 PM, Andy Colson wrote: >> >> Jason Beverage wrote: >>> >>> Hi Andy, >>> >>> I tried modifying both the Makefile.in.Linux as well as the regular >>> makefile. ?I can see -fPIC on the command line, so it appears to be doing >>> what I want, but I still get the same error in both cases. >>> >>> Jason >>> >> >> Did you build mapserver with agg first, before mapscript? ?I'm using the >> perl stuff, but saw a similar error. ?I went back and did a 'make clean' and >> make for each of agg, mapserver and then mapscript/perl. ?(in that order) >> >> Otherwise, I'm afraid I dunno... >> >> -Andy > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From Steve.Lime at dnr.state.mn.us Thu Jul 16 11:27:05 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 16 Jul 2009 13:27:05 -0500 Subject: [mapserver-users] Dynamic Label Size In-Reply-To: <1247746900943-3268099.post@n2.nabble.com> References: <1247746900943-3268099.post@n2.nabble.com> Message-ID: <4A5F2AA9.5157.008F.0@dnr.state.mn.us> Try... map.layer[Compartments].class[0]=LABEL+SIZE+10+END Steve >>> On 7/16/2009 at 7:21 AM, in message <1247746900943-3268099.post at n2.nabble.com>, stretch wrote: > Hi > > A couple of weeks ago, i posted a question about dynamically changing the > label field through the URL. Steve pointed me to the answer of using a > VALIDATION pattern and Substitution. This worked very well. > > I am now in another instance needing to look at changing the label size. > > I have tried adding a "size" validation pattern -i.e.: > VALIDATION > 'size' '^7|8|9|10|11|12$' > END > > as well as tried "map.layer[Compartments].class[0].label[0]=SIZE+10" > > both to no joy > > Could some please lead me in the right direction > > Thanks in advance > Andrew From andrew.deklerk at gmail.com Thu Jul 16 12:02:32 2009 From: andrew.deklerk at gmail.com (Andrew de Klerk) Date: Thu, 16 Jul 2009 21:02:32 +0200 Subject: [mapserver-users] Dynamic Label Size In-Reply-To: <4A5F2AA9.5157.008F.0@dnr.state.mn.us> References: <1247746900943-3268099.post@n2.nabble.com> <4A5F2AA9.5157.008F.0@dnr.state.mn.us> Message-ID: <4a5f7aac.161e640a.1342.6ea7@mx.google.com> That worked - thanks steve -----Original Message----- From: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Sent: 16 July 2009 08:27 PM To: stretch; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Dynamic Label Size Try... map.layer[Compartments].class[0]=LABEL+SIZE+10+END Steve >>> On 7/16/2009 at 7:21 AM, in message <1247746900943-3268099.post at n2.nabble.com>, stretch wrote: > Hi > > A couple of weeks ago, i posted a question about dynamically changing the > label field through the URL. Steve pointed me to the answer of using a > VALIDATION pattern and Substitution. This worked very well. > > I am now in another instance needing to look at changing the label size. > > I have tried adding a "size" validation pattern -i.e.: > VALIDATION > 'size' '^7|8|9|10|11|12$' > END > > as well as tried "map.layer[Compartments].class[0].label[0]=SIZE+10" > > both to no joy > > Could some please lead me in the right direction > > Thanks in advance > Andrew Checked by AVG - www.avg.com Version: 8.5.375 / Virus Database: 270.13.13/2236 - Release Date: 07/16/09 05:58:00 From warmerdam at pobox.com Thu Jul 16 12:40:32 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Thu, 16 Jul 2009 15:40:32 -0400 Subject: [mapserver-users] Problems with non-square pixels In-Reply-To: <1247743602628-3268002.post@n2.nabble.com> References: <1247743602628-3268002.post@n2.nabble.com> Message-ID: <4A5F8230.2080704@pobox.com> Michael Pfeiffer wrote: > Try this wms request > > http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BBOX=605035.8790650383,224864.94050038885,609110.4623983715,230528.7877226111&WIDTH=6417&HEIGHT=8921&SRS=EPSG:21781 > A0 portrait > > This request needs over 1 minute. Michael, There seems to be a modest difference in the aspect ratio of the BBOX and the SIZE in the given request. The logic in mapwms.c that tests whether non-square mode needs to be used looks like this: /* Check whether requested BBOX and width/height result in non-square pixels */ nonsquare_enabled = msTestConfigOption( map, "MS_NONSQUARE", MS_FALSE ); if (!nonsquare_enabled) { double dx, dy, reqy; dx = MS_ABS(map->extent.maxx - map->extent.minx); dy = MS_ABS(map->extent.maxy - map->extent.miny); reqy = ((double)map->width) * dy / dx; /* Allow up to 1 pixel of error on the width/height ratios. */ /* If more than 1 pixel then enable non-square pixels */ if ( MS_ABS((reqy - (double)map->height)) > 1.0 ) { if (map->debug) msDebug("msWMSLoadGetMapParams(): enabling non-square pixels.\n"); msSetConfigOption(map, "MS_NONSQUARE", "YES"); nonsquare_enabled = MS_TRUE; } } I suspect the asymmetry is just enough to amount more than one pixel at this size. I didn't run all the numbers but I suspect at smaller paper sizes (smaller SIZE values) the assymmetry amounts to less than one pixel. I'm not sure why it would affect portrait and not landscape. I only ran the ratios on the case you mentioned was slow. So there are a couple of possibilities here. 1) It is possible the above computation is wrong. I vaguely recall there is an issue with map->extent actually being from the center of edge pixel to the center of edge pixel, not the outer edges, in which case the calculation should perhaps be: reqy = MS_ABS(((map->width - 1) * dy / dx) + 1); which might or might not make a difference in this case. 2) Perhaps you just need to generate your WMS requests with more precise BBOXes corresponding to the aspect ratio of the SIZE requested. Well, I'm sure there could be other possibilities too. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From jhevenor at rogers.com Thu Jul 16 13:35:58 2009 From: jhevenor at rogers.com (Josh Hevenor) Date: Thu, 16 Jul 2009 16:35:58 -0400 Subject: [mapserver-users] MapScript ShapFileObj Message-ID: <4A5F8F2E.1010707@rogers.com> I have a quick question about the ShapeFileObj class in PHP mapscript then I'd like to throw out an offer and see who wants to take me up on it. First my question. I'm trying to write a quick data exporter. The general process is, query a spatial database, loop through the results and build a shapefile, export the shapefile. I'm not having any run-time failures but my result has only .SHP, .SHX files. When I look at the shapefile in ogrinfo I see my points but no projection, and when I use ogr2ogr to add a projection I see that there's no attribute information...only the points. My code looks similar to this: // Open map object $map = ms_newmapobj($mapPath); $layer = $map->getLayerByName($layerName); // Create shapefileobj with random name $rnd = time(); $filePath = "C:\\Inetpub\\wwwroot\\tmp\\Extract\\$rnd"; $fileName = $filePath . "somename"; // no extension $oShapeFile = ms_newShapefileObj($fileName, $layerType); // assume MS_SHP_POINT for this example $status = $layer->open(); $status = $layer->whichShapes($map->extent); while ($shape = $layer->nextShape()) { $id = $shape->values[$idField]; echo "Adding shape with ID = $id\n"; $oShapeFile->addShape($shape); $shape->free(); } $layer->close(); $oShapeFile->free(); // zip up and return to browser Any suggestions would be appreciated. Now my offer. I usually get by with the available documentation and a decent archive of old projects to compare from. The documentation for this object is pretty sparse: http://mapserver.org/mapscript/php/index.html#shapefileobj-class The SWIG api doc looks about the same. I'd like to put together an example for each class function to flesh out the doc. If there are a lot of interested participants we could do all the classes, but for now I'll start with ShapeFileObj. If there's something like this on the go already, let me know how I can help. Thanks, Josh Hevenor -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Thu Jul 16 13:47:59 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 16 Jul 2009 15:47:59 -0500 Subject: [mapserver-users] MapScript ShapFileObj In-Reply-To: <4A5F8F2E.1010707@rogers.com> References: <4A5F8F2E.1010707@rogers.com> Message-ID: <4A5F4BAE.5157.008F.0@dnr.state.mn.us> Most scripting languages have nice DBF interface modules already so we elected to leverage those instead of writing one. So, you'd need to find your favorite for PHP and use that to initialize a table and add records. It's probably just a few additional lines of code as you've done most of the hard work already. Also, any one willing to help with documentation would be most welcome! (Should take that offer to mapserver-dev...) Steve >>> On 7/16/2009 at 3:35 PM, in message <4A5F8F2E.1010707 at rogers.com>, Josh Hevenor wrote: > I have a quick question about the ShapeFileObj class in PHP mapscript > then I'd like to throw out an offer and see who wants to take me up on it. > > First my question. I'm trying to write a quick data exporter. The > general process is, query a spatial database, loop through the results > and build a shapefile, export the shapefile. I'm not having any run-time > failures but my result has only .SHP, .SHX files. When I look at the > shapefile in ogrinfo I see my points but no projection, and when I use > ogr2ogr to add a projection I see that there's no attribute > information...only the points. > > My code looks similar to this: > > // Open map object > $map = ms_newmapobj($mapPath); > $layer = $map->getLayerByName($layerName); > > // Create shapefileobj with random name > $rnd = time(); > $filePath = "C:\\Inetpub\\wwwroot\\tmp\\Extract\\$rnd"; > $fileName = $filePath . "somename"; // no extension > > $oShapeFile = ms_newShapefileObj($fileName, $layerType); // assume > MS_SHP_POINT for this example > > $status = $layer->open(); > $status = $layer->whichShapes($map->extent); > while ($shape = $layer->nextShape()) > { > $id = $shape->values[$idField]; > echo "Adding shape with ID = $id\n"; > $oShapeFile->addShape($shape); > $shape->free(); > } > $layer->close(); > $oShapeFile->free(); > > // zip up and return to browser > > Any suggestions would be appreciated. > > Now my offer. I usually get by with the available documentation and a > decent archive of old projects to compare from. The documentation for > this object is pretty sparse: > http://mapserver.org/mapscript/php/index.html#shapefileobj-class The > SWIG api doc looks about the same. I'd like to put together an example > for each class function to flesh out the doc. If there are a lot of > interested participants we could do all the classes, but for now I'll > start with ShapeFileObj. If there's something like this on the go > already, let me know how I can help. > > Thanks, > > Josh Hevenor From Steve.Lime at dnr.state.mn.us Thu Jul 16 15:21:00 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 16 Jul 2009 17:21:00 -0500 Subject: [mapserver-users] Problems with non-square pixels In-Reply-To: <4A5F8230.2080704@pobox.com> References: <1247743602628-3268002.post@n2.nabble.com> <4A5F8230.2080704@pobox.com> Message-ID: <4A5F617C.5157.008F.0@dnr.state.mn.us> The nonsquare_enabled check is occurring *before* the WMS bbox (in map->extent) is converted to the MapServer extent model so I believe the code is correct. I'd lean towards option 2 below. Steve >>> On 7/16/2009 at 2:40 PM, in message <4A5F8230.2080704 at pobox.com>, Frank Warmerdam wrote: > Michael Pfeiffer wrote: >> Try this wms request >> >> > http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION= > 1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BB > OX=605035.8790650383,224864.94050038885,609110.4623983715,230528.7877226111&WI > DTH=6417&HEIGHT=8921&SRS=EPSG:21781 >> A0 portrait >> >> This request needs over 1 minute. > > Michael, > > There seems to be a modest difference in the aspect ratio of the BBOX > and the SIZE in the given request. The logic in mapwms.c that tests whether > non-square mode needs to be used looks like this: > > /* Check whether requested BBOX and width/height result in non-square > pixels > */ > nonsquare_enabled = msTestConfigOption( map, "MS_NONSQUARE", MS_FALSE ); > if (!nonsquare_enabled) > { > double dx, dy, reqy; > dx = MS_ABS(map->extent.maxx - map->extent.minx); > dy = MS_ABS(map->extent.maxy - map->extent.miny); > > reqy = ((double)map->width) * dy / dx; > > /* Allow up to 1 pixel of error on the width/height ratios. */ > /* If more than 1 pixel then enable non-square pixels */ > if ( MS_ABS((reqy - (double)map->height)) > 1.0 ) > { > if (map->debug) > msDebug("msWMSLoadGetMapParams(): enabling non-square > pixels.\n"); > msSetConfigOption(map, "MS_NONSQUARE", "YES"); > nonsquare_enabled = MS_TRUE; > } > } > > I suspect the asymmetry is just enough to amount more than one pixel at > this size. I didn't run all the numbers but I suspect at smaller paper > sizes (smaller SIZE values) the assymmetry amounts to less than one pixel. > I'm not sure why it would affect portrait and not landscape. I only ran > the ratios on the case you mentioned was slow. > > So there are a couple of possibilities here. > > 1) It is possible the above computation is wrong. I vaguely recall there > is an issue with map->extent actually being from the center of edge > pixel to the center of edge pixel, not the outer edges, in which case > the calculation should perhaps be: > reqy = MS_ABS(((map->width - 1) * dy / dx) + 1); > which might or might not make a difference in this case. > > 2) Perhaps you just need to generate your WMS requests with more precise > BBOXes corresponding to the aspect ratio of the SIZE requested. > > Well, I'm sure there could be other possibilities too. > > Best regards, From David at itbeyond.com.au Thu Jul 16 17:24:24 2009 From: David at itbeyond.com.au (David Martin) Date: Fri, 17 Jul 2009 08:24:24 +0800 Subject: [mapserver-users] Scaling Image Symbol Offset Message-ID: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> I am developing a new application and am rendering around a load of graphic symbol layers using a Map file layer such as LAYER NAME cape_headland_point STATUS ON GROUP all DATA 'ExplorOz/Places/Cape,Headland,Point' TYPE POINT SYMBOLSCALE 1000000 CLASS STYLE SYMBOL [POIImage] MAXSIZE 15 MINSIZE 4 SIZE 8 END END METADATA "wms_title" "Capes, Headlands & Points" END PROJECTION "+proj=longlat +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +no_defs" END END As you can see I am sizing the output symbol which is a 20x20px PIXMAP image - this is working great however the position of the image needs to be OFFSET up by half the size of the image (to make the actual point be the center of the image) - I have tried using OFFSET however when the image size changes (based on SYMBOLSCALE)the offsets are wrong. Is there a way to OFFSET image symbols based on the SYMBOLSCALE and MAX/MIN SIZES? Regards David -------------- next part -------------- An HTML attachment was scrubbed... URL: From Michael.Pfeiffer at bd.so.ch Fri Jul 17 00:27:22 2009 From: Michael.Pfeiffer at bd.so.ch (Pfeiffer Michael) Date: Fri, 17 Jul 2009 09:27:22 +0200 Subject: [mapserver-users] Problems with non-square pixels In-Reply-To: <4A5F617C.5157.008F.0@dnr.state.mn.us> Message-ID: <612169113.17101247815642993.JavaMail.root@srsofaioi13477.ktso.ch> Hi, thx for your answers. It seems that possibility 2 solves the problem. Although I can't understand wherefore this is only a problem for portrait and not for landscape. Now we have the problem that we do need exactly this BBOX because we want to print a user given scale. So is it possible to send a float width and height to mapserver or do we have to change the logic in mapwms.c? thx best regards Michael >-----Urspr?ngliche Nachricht----- >Von: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] >Gesendet am: Freitag, 17. Juli 2009 00:21 >An: Pfeiffer Michael; Frank Warmerdam >Cc: mapserver-users at lists.osgeo.org >Betreff: Re: [mapserver-users] Problems with non-square pixels > >The nonsquare_enabled check is occurring *before* the WMS bbox (in map->extent) is converted >to the MapServer extent model so I believe the code is correct. I'd lean towards option 2 below. > >Steve > >>> On 7/16/2009 at 2:40 PM, in message <4A5F8230.2080704 at pobox.com>, Frank Warmerdam wrote: >> Michael Pfeiffer wrote: >>> Try this wms request >>> >>> >> http://www.sogis1.so.ch/cgi-bin/sogis/sogis_print_test.wms?SERVICE=WMS&VERSION= >> 1.1.1&REQUEST=GetMap&FORMAT=image/jpeg&LAYERS=Orthofoto&STYLES=&TRANSPARENT=true&BB >> OX=605035.8790650383,224864.94050038885,609110.4623983715,230528.7877226111&WI >> DTH=6417&HEIGHT=8921&SRS=EPSG:21781 >>> A0 portrait >>> >>> This request needs over 1 minute. >> >> Michael, >> >> There seems to be a modest difference in the aspect ratio of the BBOX >> and the SIZE in the given request. The logic in mapwms.c that tests whether >> non-square mode needs to be used looks like this: >> >> /* Check whether requested BBOX and width/height result in non-square >> pixels >> */ >> nonsquare_enabled = msTestConfigOption( map, "MS_NONSQUARE", MS_FALSE ); >> if (!nonsquare_enabled) >> { >> double dx, dy, reqy; >> dx = MS_ABS(map->extent.maxx - map->extent.minx); >> dy = MS_ABS(map->extent.maxy - map->extent.miny); >> >> reqy = ((double)map->width) * dy / dx; >> >> /* Allow up to 1 pixel of error on the width/height ratios. */ >> /* If more than 1 pixel then enable non-square pixels */ >> if ( MS_ABS((reqy - (double)map->height)) > 1.0 ) >> { >> if (map->debug) >> msDebug("msWMSLoadGetMapParams(): enabling non-square >> pixels.\n"); >> msSetConfigOption(map, "MS_NONSQUARE", "YES"); >> nonsquare_enabled = MS_TRUE; >> } >> } >> >> I suspect the asymmetry is just enough to amount more than one pixel at >> this size. I didn't run all the numbers but I suspect at smaller paper >> sizes (smaller SIZE values) the assymmetry amounts to less than one pixel. >> I'm not sure why it would affect portrait and not landscape. I only ran >> the ratios on the case you mentioned was slow. >> >> So there are a couple of possibilities here. >> >> 1) It is possible the above computation is wrong. I vaguely recall there >> is an issue with map->extent actually being from the center of edge >> pixel to the center of edge pixel, not the outer edges, in which case >> the calculation should perhaps be: >> reqy = MS_ABS(((map->width - 1) * dy / dx) + 1); >> which might or might not make a difference in this case. >> >> 2) Perhaps you just need to generate your WMS requests with more precise >> BBOXes corresponding to the aspect ratio of the SIZE requested. >> >> Well, I'm sure there could be other possibilities too. >> >> Best regards, From andreas.albarello at territoriumonline.com Fri Jul 17 00:56:10 2009 From: andreas.albarello at territoriumonline.com (Andreas Albarello) Date: Fri, 17 Jul 2009 09:56:10 +0200 Subject: [mapserver-users] Scaling Image Symbol Offset In-Reply-To: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> References: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> Message-ID: <4A602E9A.8020203@territoriumonline.com> David Martin wrote: > As you can see I am sizing the output symbol which is a 20x20px PIXMAP > image ? this is working great however the position of the image needs to > be OFFSET up by half the size of the image (to make the actual point be > the center of the image) ? I have tried using OFFSET however when the > image size changes (based on SYMBOLSCALE)the offsets are wrong. Is there > a way to OFFSET image symbols based on the SYMBOLSCALE and MAX/MIN SIZES? David, unfortunately, OFFSET behaves exactly the way you are pointing out, that is, it doesn't scale because it's values are expressed in pixels no matter what SIZEUNITS or SYMBOLSCALE. As to the task you would like to accomplish, though, what about making the image itself twice as tall and moving the symbol into the upper half of the image, thus having the center of your image located beneath the symbol itself? The image would still scale correctly and account for offsetting the symbol by itself. Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi Str. 12 I 39100 Bolzano/Bozen Phone: +39 0471 068611 Fax: +39 0471 068619 email: andreas.albarello at territoriumonline.com web: http://www.territoriumonline.com -------------------------------------------------------------------- From andreas.albarello at territoriumonline.com Fri Jul 17 01:48:01 2009 From: andreas.albarello at territoriumonline.com (Andreas Albarello) Date: Fri, 17 Jul 2009 10:48:01 +0200 Subject: [mapserver-users] Scaling Image Symbol Offset In-Reply-To: <9C37154DC7C8074FBC34214363755B7C3308A0@ITB-SVR-01.itbeyond.local> References: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> Message-ID: <4A603AC1.1060509@territoriumonline.com> David Martin wrote: > Thanks for the clarification however how would that solution actually > work? I would have thought that this would offset the location even > further! Where does MS put the PIXMAP symbol on output? From my > testing it appears to the UC (using label location rules) is this > true - I would have thought it should be centered CC of the PIXMAP > but this does not appear to be the case. David, I've always seen Mapserver/AGG putting the PIXMAP symbol centered CC onto the point geometry, and this seems to be confirmed by a quick look at the code in mapagg.cpp. I might add, though, that I always define a symbol for any PIXMAP in my symbol file before using it in my mapfiles. If the path to the image is given directly inside the mapfile or there's a binding to a field as in your case, things might actually be different. Still, it would seem quite odd to me... Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi Str. 12 I 39100 Bolzano/Bozen Phone: +39 0471 068611 Fax: +39 0471 068619 email: andreas.albarello at territoriumonline.com web: http://www.territoriumonline.com -------------------------------------------------------------------- From havard.tveite at umb.no Fri Jul 17 01:50:13 2009 From: havard.tveite at umb.no (Havard Tveite) Date: Fri, 17 Jul 2009 10:50:13 +0200 Subject: [mapserver-users] Scaling Image Symbol Offset In-Reply-To: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> References: <9C37154DC7C8074FBC34214363755B7C330883@ITB-SVR-01.itbeyond.local> Message-ID: <4A603B45.5020403@umb.no> RFC 45 suggests several rendering improvements for Mapserver, including adding a tag (CENTER/ORIGIN) for specifying the centre of a symbol. This feature has, however, not been given priority yet (there are workarounds for the most important cases). http://mapserver.org/development/rfc/ms-rfc-45.html -------------------------------------------------------------- CENTER/ORIGIN [x y] Defines the centre of the symbol using decimal pixels (x axis increasing to the right, y axis increasing downwards). * Is used for placing a point symbol on the map or on a ?decorated? line * Defines the center of rotation if an ANGLE is specified for point symbols. * Default value is the centre of the symbol?s bounding box. * Applies to TYPE ellipse, vector, pixmap, truetype. -------------------------------------------------------------- H?vard David Martin wrote: > I am developing a new application and am rendering around a load of > graphic symbol layers using a Map file layer such as > > LAYER > > NAME cape_headland_point > > STATUS ON > > GROUP all > > DATA 'ExplorOz/Places/Cape,Headland,Point' > > TYPE POINT > > SYMBOLSCALE 1000000 > > CLASS > > STYLE > > SYMBOL [POIImage] > > MAXSIZE 15 > > MINSIZE 4 > > SIZE 8 > > END > > END > > METADATA > > "wms_title" "Capes, Headlands & Points" > > END > > PROJECTION > > "+proj=longlat +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +no_defs" > > END > > END > > As you can see I am sizing the output symbol which is a 20x20px PIXMAP > image ? this is working great however the position of the image needs to > be OFFSET up by half the size of the image (to make the actual point be > the center of the image) ? I have tried using OFFSET however when the > image size changes (based on SYMBOLSCALE)the offsets are wrong. Is there > a way to OFFSET image symbols based on the SYMBOLSCALE and MAX/MIN SIZES? > > Regards > > David > -- H?vard Tveite Department of Mathematical Sciences and Technology, UMB Dr?bakveien 31, POBox 5003, N-1432 ?s, NORWAY Phone: +47 64965483 Fax: +47 64965401 http://www.umb.no/imt/ From adrian_gh.popa at romtelecom.ro Fri Jul 17 03:05:20 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Fri, 17 Jul 2009 13:05:20 +0300 Subject: [mapserver-users] Performance in regular expressions or analternative way to select a list of features In-Reply-To: <4A5D740D.10605@romtelecom.ro> References: <4A5C2277.80204@romtelecom.ro> <4A5C5216.5157.008F.0@dnr.state.mn.us> <4A5D740D.10605@romtelecom.ro> Message-ID: <4A604CE0.3090704@romtelecom.ro> Here's how I "fixed" this issue. I ended up regenerating the shapefile and dbf and adding a separate column with the grouping I desired. Now, my map file selects from that column, and the syntax is much simpler (by one or two orders of magnitude). I am happy with the results, however, I didn't get the chance to try out all the other methods because of lack of time. Thanks again, Adrian Adrian Popa wrote: > Hello Steve, > > I haven't tried out the simplified regex so I don't know if it will be > faster. I will try to test it as part of a speed test of the various > methods... > > I'm not sure what you mean by writing a temporary set of geometries. > Do you mean adding an index to my data so that I can select it by a > different (grouping) field instead? Unfortunately I can't do that > because the same item can be part of 10-20 groups, so there would not > be an easy way to group items apart from duplicating them in the > shapefile/dbf. I'm not sure if there's a problem if the same feature > appears 12 times in the same shapefile. > > In the end data reorganizing might be the fastest method available. > Problem is some items will belong to groups dinamically, so I will > have to implement a selection mechanism based on item id... > > Regards, > Adrian > > Steve Lime wrote: >> Have you tried a simplified version of your regex? I think you can do: >> >> EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ >> >> You might also consider writing a temporary set of geometries if a user will continually display from >> that set. In that case your overhead would be in managing the set of features which would be higher >> the first time but then very fast to render. Your dynamic portion of the mapfile would reference the >> temporary data. >> >> Steve >> >> >>>>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian Popa >>>>> >> wrote: >> >>> Hello everyone, >>> >>> Here's my problem: I'm trying to highlight segments from a line layer by >>> using an expression in a specific class. This portion of the mapfile is >>> dynamically generated and when it is done, it is sent to mapserver for >>> rendering. >>> My problem is that I have to select between 10 - 400 features at a time >>> and I noticed when I have a lot of features there is a severe >>> performance degradation in mapserver (takes a lot of time to render or >>> even times out). >>> Right now, my expression is built using regular expressions: something like: >>> *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* >>> This works ok, but as I said has a performance penalty when you reach >>> ~400 items. My data is selected from a shapefile layer which has about >>> 5500 items. >>> >>> Since I wouldn't be using the regular expressions at full capacity (I'm >>> matching the full name), I might rewrite the expression using something >>> like: >>> *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR >>> ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* >>> >>> From the documentation I see that: >>> /Regular expression with MapServer work similarly to string comparison, >>> but allow more complex operation. They are slower than pure string >>> comparisons, but might be still faster than logical expression. As with >>> the string comparison use regular expressions, a FILTERITEM or a >>> CLASSITEM has to defined, respectively. >>> >>> /I would like to know if there is an efficient way of selecting a list >>> of elements from a layer, or what are your recommendations. >>> >>> Also - have there been significant changes in performance for this issue >>> from mapserver 4.10 (I am now migrating to mapserver 5.4)? >>> >>> Thanks, >>> Adrian >>> >> >> >> > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Fri Jul 17 04:06:05 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Fri, 17 Jul 2009 13:06:05 +0200 Subject: [mapserver-users] openlayers/mapserver Message-ID: An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: openlayersDisplayData.JPG Type: image/jpeg Size: 7004 bytes Desc: not available URL: From paul_everton at hotmail.com Fri Jul 17 04:13:01 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Fri, 17 Jul 2009 11:13:01 +0000 Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver Message-ID: Hi, i am having trouble trying to display my map in Open Layers via OpenLayers.Layer.wms. Firstly I Built a shape file of the UK as a raster tileindex. I can now view my map via "//localhost/cgi-bin/mapserv.exe/mymapfile.map" and the map looks fine. I am now trying to view my map via OpenLayers. Firstly I used Openlayers.Layer.MapServer which displayed my map however zoomed in very close. However I have read Layer.Mapserver should be avoided and Layer.WMS should be used instead. I attempted to amend both my map and openlayers files to display via WMS by Including: METADATA ?wms_srs? ?EPSG: 32119 EPSG: 4326? END within the WEB section of my map file and adding OpenLayers.WMS within my OpenLayers file. However I now get the following error message within the openlayers map window ?msWMSLoadGetMapParams(): WMS Server Error? I also added ?projection: "epsg: 32119 epsg:4326? into my openlayers file which hasn?t made any difference Does anyone have any idea where I am going wrong? Any help greatly appreciated. My map and openlayers files are below. Cheers p.s. I ahve installed ms4w on windows which i tihnk supports WMS MAP NAME UK1 SIZE 1600 1200 IMAGECOLOR 153 204 255 IMAGETYPE JPEG SHAPEPATH "http://localhost/openlayers/data/" EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 UNITS METERS WEB TEMPLATE "http://localhost/openlayers/examples/test.html" LOG "\ms4w\tmp\ms_tmp\log.txt" IMAGEPATH "\ms4w\tmp\ms_tmp\" IMAGEURL "/ms_tmp/" METADATA 'wms_srs' "epsg: 32119 epsg: 4326" END END LAYER NAME "UK" STATUS DEFAULT TYPE raster TILEINDEX "map" TILEITEM "Location" CLASS STYLE COLOR 0 0 0 END LABEL COLOR 0 0 0 SIZE SMALL END END END END NARIMS MAPPING TEST
_________________________________________________________________ Share your photos with Windows Live Photos ? Free. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From bartvde at osgis.nl Fri Jul 17 04:22:04 2009 From: bartvde at osgis.nl (bartvde at osgis.nl) Date: Fri, 17 Jul 2009 13:22:04 +0200 (CEST) Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver In-Reply-To: References: Message-ID: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> Hi, there are several things wrong here. 'wms_srs' "epsg: 32119 epsg: 4326" should be (uppercase EPSG for METADATA and no space in between): 'wms_srs' "EPSG:32119 EPSG:4326" however Mapserver cannot reproject your data if you do not add a PROJECTION block to your LAYER stating the projection in which your data resides. Also, in OpenLayers the syntax is (your map can only be in 1 projection): {projection: "EPSG:32119"} Best regards, Bart > > Hi, i am having trouble trying to display my map in Open Layers via > OpenLayers.Layer.wms. > > > Firstly I Built a shape file of the UK as a raster tileindex. I can now > view my map via "//localhost/cgi-bin/mapserv.exe/mymapfile.map" and the > map looks fine. > I am now trying to view my map via OpenLayers. Firstly I used > Openlayers.Layer.MapServer which displayed my map however zoomed in very > close. However I have read Layer.Mapserver should be avoided and Layer.WMS > should be used instead. > > I attempted to amend both my map and openlayers files to display via WMS > by > Including: > > METADATA > ?wms_srs? ?EPSG: 32119 EPSG: 4326? > END > within the WEB section of my map file and adding OpenLayers.WMS within my > OpenLayers file. > > > However I now get the following error message within the openlayers map > window ?msWMSLoadGetMapParams(): WMS Server Error? > > I also added ?projection: "epsg: 32119 epsg:4326? into my openlayers file > which hasn?t made any difference > > Does anyone have any idea where I am going wrong? Any help greatly > appreciated. My map and openlayers files are below. > > Cheers > > p.s. I ahve installed ms4w on windows which i tihnk supports WMS > > MAP > > NAME UK1 > SIZE 1600 1200 > IMAGECOLOR 153 204 255 > IMAGETYPE JPEG > SHAPEPATH "http://localhost/openlayers/data/" > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > UNITS METERS > > WEB > TEMPLATE "http://localhost/openlayers/examples/test.html" > LOG "\ms4w\tmp\ms_tmp\log.txt" > IMAGEPATH "\ms4w\tmp\ms_tmp\" > IMAGEURL "/ms_tmp/" > METADATA > 'wms_srs' "epsg: 32119 epsg: 4326" > END > END > > LAYER > > NAME "UK" > STATUS DEFAULT > TYPE raster > TILEINDEX "map" > TILEITEM "Location" > CLASS > STYLE > COLOR 0 0 0 > END > LABEL > COLOR 0 0 0 > SIZE SMALL > END > END > > END > END > > > NARIMS MAPPING TEST > > > > > >
> > > _________________________________________________________________ > Share your photos with Windows Live Photos ? Free. > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From paul_everton at hotmail.com Fri Jul 17 06:13:28 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Fri, 17 Jul 2009 13:13:28 +0000 Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver In-Reply-To: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> References: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> Message-ID: Thanks for the quick reply. You mentioned adding a projection block to the layer. Is that done by the following: PROJECTION "epsg:32119" END Thanks again > Date: Fri, 17 Jul 2009 13:22:04 +0200 > Subject: Re: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver > From: bartvde at osgis.nl > To: paul_everton at hotmail.com > CC: mapserver-users at lists.osgeo.org > > Hi, > > there are several things wrong here. > > 'wms_srs' "epsg: 32119 epsg: 4326" > > should be (uppercase EPSG for METADATA and no space in between): > > 'wms_srs' "EPSG:32119 EPSG:4326" > > however Mapserver cannot reproject your data if you do not add a > PROJECTION block to your LAYER stating the projection in which your data > resides. > > Also, in OpenLayers the syntax is (your map can only be in 1 projection): > > {projection: "EPSG:32119"} > > Best regards, > Bart > > > > > Hi, i am having trouble trying to display my map in Open Layers via > > OpenLayers.Layer.wms. > > > > > > Firstly I Built a shape file of the UK as a raster tileindex. I can now > > view my map via "//localhost/cgi-bin/mapserv.exe/mymapfile.map" and the > > map looks fine. > > I am now trying to view my map via OpenLayers. Firstly I used > > Openlayers.Layer.MapServer which displayed my map however zoomed in very > > close. However I have read Layer.Mapserver should be avoided and Layer.WMS > > should be used instead. > > > > I attempted to amend both my map and openlayers files to display via WMS > > by > > Including: > > > > METADATA > > ?wms_srs? ?EPSG: 32119 EPSG: 4326? > > END > > within the WEB section of my map file and adding OpenLayers.WMS within my > > OpenLayers file. > > > > > > However I now get the following error message within the openlayers map > > window ?msWMSLoadGetMapParams(): WMS Server Error? > > > > I also added ?projection: "epsg: 32119 epsg:4326? into my openlayers file > > which hasn?t made any difference > > > > Does anyone have any idea where I am going wrong? Any help greatly > > appreciated. My map and openlayers files are below. > > > > Cheers > > > > p.s. I ahve installed ms4w on windows which i tihnk supports WMS > > > > MAP > > > > NAME UK1 > > SIZE 1600 1200 > > IMAGECOLOR 153 204 255 > > IMAGETYPE JPEG > > SHAPEPATH "http://localhost/openlayers/data/" > > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > > UNITS METERS > > > > WEB > > TEMPLATE "http://localhost/openlayers/examples/test.html" > > LOG "\ms4w\tmp\ms_tmp\log.txt" > > IMAGEPATH "\ms4w\tmp\ms_tmp\" > > IMAGEURL "/ms_tmp/" > > METADATA > > 'wms_srs' "epsg: 32119 epsg: 4326" > > END > > END > > > > LAYER > > > > NAME "UK" > > STATUS DEFAULT > > TYPE raster > > TILEINDEX "map" > > TILEITEM "Location" > > CLASS > > STYLE > > COLOR 0 0 0 > > END > > LABEL > > COLOR 0 0 0 > > SIZE SMALL > > END > > END > > > > END > > END > > > > > > NARIMS MAPPING TEST > > > > > > > > > > > >
> > > > > > _________________________________________________________________ > > Share your photos with Windows Live Photos ? Free. > > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > _________________________________________________________________ Share your photos with Windows Live Photos ? Free. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From ivan.lucena at pmldnet.com Fri Jul 17 06:20:08 2009 From: ivan.lucena at pmldnet.com (=?utf-8?Q?Lucena,=20Ivan?=) Date: Fri, 17 Jul 2009 08:20:08 -0500 Subject: [mapserver-users] Openning mapserv.exe "Would you like to save this file? Message-ID: <20090717132008.24493.qmail@s466.sureserver.com> From ivan.lucena at pmldnet.com Fri Jul 17 06:26:47 2009 From: ivan.lucena at pmldnet.com (=?utf-8?Q?Lucena,=20Ivan?=) Date: Fri, 17 Jul 2009 08:26:47 -0500 Subject: =?utf-8?B?UmU6IFttYXBzZXJ2ZXItdXNlcnNdIE9wZW5uaW5nIG1hcHNlcnYuZXhlICJXb3VsZCB5b3UgbGlrZSB0byBzYXZlIHRoaXMJZmlsZT8=?= Message-ID: <20090717132647.5109.qmail@s466.sureserver.com> Sorry for my fat finger mistake. When I run a GetCapabilities request it results in the download of mapserv.exe. I decided to investigate more before put the question on the list but I clicked some wrong short cut key on Chrome. > -------Original Message------- > From: Lucena, Ivan > Subject: [mapserver-users] Openning mapserv.exe "Would you like to save this file? > Sent: Jul 17 '09 08:20 > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From bartvde at osgis.nl Fri Jul 17 06:29:03 2009 From: bartvde at osgis.nl (bartvde at osgis.nl) Date: Fri, 17 Jul 2009 15:29:03 +0200 (CEST) Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver In-Reply-To: References: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> Message-ID: <32091.145.50.39.11.1247837343.squirrel@webmail.hostingdiscounter.nl> Almost, PROJECTION "init=epsg:28992" END Best regards, Bart > > Thanks for the quick reply. > > > > You mentioned adding a projection block to the layer. > > > > Is that done by the following: > > > > PROJECTION > > "epsg:32119" > > END > > > > Thanks again > >> Date: Fri, 17 Jul 2009 13:22:04 +0200 >> Subject: Re: [mapserver-users] Changing to Layers.WMS from >> Layers.Mapserver >> From: bartvde at osgis.nl >> To: paul_everton at hotmail.com >> CC: mapserver-users at lists.osgeo.org >> >> Hi, >> >> there are several things wrong here. >> >> 'wms_srs' "epsg: 32119 epsg: 4326" >> >> should be (uppercase EPSG for METADATA and no space in between): >> >> 'wms_srs' "EPSG:32119 EPSG:4326" >> >> however Mapserver cannot reproject your data if you do not add a >> PROJECTION block to your LAYER stating the projection in which your data >> resides. >> >> Also, in OpenLayers the syntax is (your map can only be in 1 >> projection): >> >> {projection: "EPSG:32119"} >> >> Best regards, >> Bart >> >> > >> > Hi, i am having trouble trying to display my map in Open Layers via >> > OpenLayers.Layer.wms. >> > >> > >> > Firstly I Built a shape file of the UK as a raster tileindex. I can >> now >> > view my map via "//localhost/cgi-bin/mapserv.exe/mymapfile.map" and >> the >> > map looks fine. >> > I am now trying to view my map via OpenLayers. Firstly I used >> > Openlayers.Layer.MapServer which displayed my map however zoomed in >> very >> > close. However I have read Layer.Mapserver should be avoided and >> Layer.WMS >> > should be used instead. >> > >> > I attempted to amend both my map and openlayers files to display via >> WMS >> > by >> > Including: >> > >> > METADATA >> > ?wms_srs? ?EPSG: 32119 EPSG: 4326? >> > END >> > within the WEB section of my map file and adding OpenLayers.WMS within >> my >> > OpenLayers file. >> > >> > >> > However I now get the following error message within the openlayers >> map >> > window ?msWMSLoadGetMapParams(): WMS Server Error? >> > >> > I also added ?projection: "epsg: 32119 epsg:4326? into my openlayers >> file >> > which hasn?t made any difference >> > >> > Does anyone have any idea where I am going wrong? Any help greatly >> > appreciated. My map and openlayers files are below. >> > >> > Cheers >> > >> > p.s. I ahve installed ms4w on windows which i tihnk supports WMS >> > >> > MAP >> > >> > NAME UK1 >> > SIZE 1600 1200 >> > IMAGECOLOR 153 204 255 >> > IMAGETYPE JPEG >> > SHAPEPATH "http://localhost/openlayers/data/" >> > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 >> > UNITS METERS >> > >> > WEB >> > TEMPLATE "http://localhost/openlayers/examples/test.html" >> > LOG "\ms4w\tmp\ms_tmp\log.txt" >> > IMAGEPATH "\ms4w\tmp\ms_tmp\" >> > IMAGEURL "/ms_tmp/" >> > METADATA >> > 'wms_srs' "epsg: 32119 epsg: 4326" >> > END >> > END >> > >> > LAYER >> > >> > NAME "UK" >> > STATUS DEFAULT >> > TYPE raster >> > TILEINDEX "map" >> > TILEITEM "Location" >> > CLASS >> > STYLE >> > COLOR 0 0 0 >> > END >> > LABEL >> > COLOR 0 0 0 >> > SIZE SMALL >> > END >> > END >> > >> > END >> > END >> > >> > >> > NARIMS MAPPING TEST >> > >> > >> > >> > >> > >> >
>> > >> > >> > _________________________________________________________________ >> > Share your photos with Windows Live Photos ? Free. >> > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ >> > mapserver-users mailing list >> > mapserver-users at lists.osgeo.org >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > >> >> > > _________________________________________________________________ > Share your photos with Windows Live Photos ? Free. > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From paul_everton at hotmail.com Fri Jul 17 06:49:05 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Fri, 17 Jul 2009 13:49:05 +0000 Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver - Error 'msWMSLoadGetMapParams(): WMS ' In-Reply-To: <32091.145.50.39.11.1247837343.squirrel@webmail.hostingdiscounter.nl> References: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> <32091.145.50.39.11.1247837343.squirrel@webmail.hostingdiscounter.nl> Message-ID: Ive implemented your changes but im still getting the msWMSLoadGetMapParams(): WMS Server Error message repeatedly thorughout the open layers map window. My map file now looks like this (i have hihglighted your changes in bold), do you think i have put them in correclty? Cheers MAP NAME UK1 SIZE 1600 1200 IMAGECOLOR 153 204 255 IMAGETYPE JPEG SHAPEPATH "http://localhost/openlayers/data/" EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 UNITS METERS WEB TEMPLATE "http://localhost/openlayers/examples/test.html" LOG "\ms4w\tmp\ms_tmp\log.txt" IMAGEPATH "\ms4w\tmp\ms_tmp\" IMAGEURL "/ms_tmp/" METADATA 'wms_srs' "EPSG:32119 EPSG:4326" END END LAYER NAME "UK" STATUS DEFAULT TYPE raster TILEINDEX "map" TILEITEM "Location" CLASS STYLE COLOR 0 0 0 END LABEL COLOR 0 0 0 SIZE SMALL END END PROJECTION "init=epsg:28992" END END END MAPPING TEST
> Date: Fri, 17 Jul 2009 15:29:03 +0200 > Subject: RE: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver > From: bartvde at osgis.nl > To: paul_everton at hotmail.com > CC: mapserver-users at lists.osgeo.org > > Almost, > > PROJECTION > "init=epsg:28992" > END > > Best regards, > Bart > > > > > Thanks for the quick reply. > > > > > > > > You mentioned adding a projection block to the layer. > > > > > > > > Is that done by the following: > > > > > > > > PROJECTION > > > > "epsg:32119" > > > > END > > > > > > > > Thanks again > > > >> Date: Fri, 17 Jul 2009 13:22:04 +0200 > >> Subject: Re: [mapserver-users] Changing to Layers.WMS from > >> Layers.Mapserver > >> From: bartvde at osgis.nl > >> To: paul_everton at hotmail.com > >> CC: mapserver-users at lists.osgeo.org > >> > >> Hi, > >> > >> there are several things wrong here. > >> > >> 'wms_srs' "epsg: 32119 epsg: 4326" > >> > >> should be (uppercase EPSG for METADATA and no space in between): > >> > >> 'wms_srs' "EPSG:32119 EPSG:4326" > >> > >> however Mapserver cannot reproject your data if you do not add a > >> PROJECTION block to your LAYER stating the projection in which your data > >> resides. > >> > >> Also, in OpenLayers the syntax is (your map can only be in 1 > >> projection): > >> > >> {projection: "EPSG:32119"} > >> > >> Best regards, > >> Bart > >> > >> > > >> > Hi, i am having trouble trying to display my map in Open Layers via > >> > OpenLayers.Layer.wms. > >> > > >> > > >> > Firstly I Built a shape file of the UK as a raster tileindex. I can > >> now > >> > view my map via "//localhost/cgi-bin/mapserv.exe/mymapfile.map" and > >> the > >> > map looks fine. > >> > I am now trying to view my map via OpenLayers. Firstly I used > >> > Openlayers.Layer.MapServer which displayed my map however zoomed in > >> very > >> > close. However I have read Layer.Mapserver should be avoided and > >> Layer.WMS > >> > should be used instead. > >> > > >> > I attempted to amend both my map and openlayers files to display via > >> WMS > >> > by > >> > Including: > >> > > >> > METADATA > >> > ?wms_srs? ?EPSG: 32119 EPSG: 4326? > >> > END > >> > within the WEB section of my map file and adding OpenLayers.WMS within > >> my > >> > OpenLayers file. > >> > > >> > > >> > However I now get the following error message within the openlayers > >> map > >> > window ?msWMSLoadGetMapParams(): WMS Server Error? > >> > > >> > I also added ?projection: "epsg: 32119 epsg:4326? into my openlayers > >> file > >> > which hasn?t made any difference > >> > > >> > Does anyone have any idea where I am going wrong? Any help greatly > >> > appreciated. My map and openlayers files are below. > >> > > >> > Cheers > >> > > >> > p.s. I ahve installed ms4w on windows which i tihnk supports WMS > >> > > >> > MAP > >> > > >> > NAME UK1 > >> > SIZE 1600 1200 > >> > IMAGECOLOR 153 204 255 > >> > IMAGETYPE JPEG > >> > SHAPEPATH "http://localhost/openlayers/data/" > >> > EXTENT -888385.321101 -31000.000000 1548385.321101 1271000.000000 > >> > UNITS METERS > >> > > >> > WEB > >> > TEMPLATE "http://localhost/openlayers/examples/test.html" > >> > LOG "\ms4w\tmp\ms_tmp\log.txt" > >> > IMAGEPATH "\ms4w\tmp\ms_tmp\" > >> > IMAGEURL "/ms_tmp/" > >> > METADATA > >> > 'wms_srs' "epsg: 32119 epsg: 4326" > >> > END > >> > END > >> > > >> > LAYER > >> > > >> > NAME "UK" > >> > STATUS DEFAULT > >> > TYPE raster > >> > TILEINDEX "map" > >> > TILEITEM "Location" > >> > CLASS > >> > STYLE > >> > COLOR 0 0 0 > >> > END > >> > LABEL > >> > COLOR 0 0 0 > >> > SIZE SMALL > >> > END > >> > END > >> > > >> > END > >> > END > >> > > >> > > >> > MAPPING TEST > >> > > >> > > >> > > >> > > >> > > >> >
> >> > > >> > > >> > _________________________________________________________________ > >> > Share your photos with Windows Live Photos ? Free. > >> > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ > >> > mapserver-users mailing list > >> > mapserver-users at lists.osgeo.org > >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users > >> > > >> > >> > > > > _________________________________________________________________ > > Share your photos with Windows Live Photos ? Free. > > http://clk.atdmt.com/UKM/go/134665338/direct/01/_______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > _________________________________________________________________ Share your photos with Windows Live Photos ? Free. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Fri Jul 17 07:00:07 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Fri, 17 Jul 2009 11:00:07 -0300 Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver - Error 'msWMSLoadGetMapParams(): WMS ' In-Reply-To: References: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> <32091.145.50.39.11.1247837343.squirrel@webmail.hostingdiscounter.nl> Message-ID: <4A6083E7.1050004@gatewaygeomatics.com> Paul Curran wrote: > Ive implemented your changes but im still getting the > msWMSLoadGetMapParams(): WMS Server Error message repeatedly thorughout > the open layers map window. > > My map file now looks like this (i have hihglighted your changes in > bold), do you think i have put them in correclty? > Paul, If you are trying to serve your mapfile through WMS then you should follow this document: http://www.mapserver.org/ogc/wms_server.html Also, you should read the following page on MapServer projection use: http://www.mapserver.org/mapfile/projection.html -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From oliver.christen at camptocamp.com Fri Jul 17 07:54:12 2009 From: oliver.christen at camptocamp.com (Oliver Christen) Date: Fri, 17 Jul 2009 16:54:12 +0200 Subject: [mapserver-users] reprojected layer = changed min/max scale ? Message-ID: <23D5759506D14051BD68FEDDB30E2F31@maunakea> Hello This is probably a silly question but I cant find an answer for it. I have a mapfile with a given EPSG projection (EPSG:27582) In this mapfile I have a WMS layer with a different projection (EPSG:4326) when displayed, the max scale of the wms layer is different from the max scale value specified in the layer's definition in the mapfile so I would like to know, when mapserver does the reprojection of the wms layer from EPSG:4326 to EPSG:27582, the min/max scale are also modified in the process ? thanks in advance Oliver From warmerdam at pobox.com Fri Jul 17 09:53:52 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Fri, 17 Jul 2009 12:53:52 -0400 Subject: [mapserver-users] Problems with non-square pixels In-Reply-To: <612169113.17101247815642993.JavaMail.root@srsofaioi13477.ktso.ch> References: <612169113.17101247815642993.JavaMail.root@srsofaioi13477.ktso.ch> Message-ID: <4A60ACA0.1030509@pobox.com> Pfeiffer Michael wrote: > Hi, > > thx for your answers. It seems that possibility 2 solves the problem. > Although I can't understand wherefore this is only a problem for portrait > and not for landscape. Now we have the problem that we do need exactly this > BBOX because we want to print a user given scale. So is it possible to send > a float width and height to mapserver or do we have to change the logic in > mapwms.c? Michael, It is not possible to send floating point WIDTH and HEIGHT values to MapServer. I'm not sure why you want the exact BBOX instead of adjusting it a bit to reflect the actual aspect ratio of the raster requested, but if you feel strongly about it just let things go into non-square pixel mode. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From andy at squeakycode.net Fri Jul 17 11:28:41 2009 From: andy at squeakycode.net (Andy Colson) Date: Fri, 17 Jul 2009 13:28:41 -0500 Subject: [mapserver-users] duplicate labels Message-ID: <4A60C2D9.6090609@squeakycode.net> Hi All, Here is a screen shot: http://maps.camavision.com/map.jpg There are, as far as I can tell, 4 lines. The label is duplicating and I dont want it too. Here is the layer from the mapfile: LAYER NAME annotate_pin TYPE line STATUS on CLASS NAME "HIGHLIGHT" STYLE COLOR 0 255 0 OUTLINECOLOR 0 255 0 WIDTH 3 END LABEL TYPE truetype FONT "Vera" SIZE 10 COLOR 0 0 0 ANGLE follow POSITION auto BACKGROUNDCOLOR 255 255 255 MINDISTANCE 900 END END END I have played with MINDISTANCE from 0 to 99,000 and it does not seem to make a difference. I googled a little but have not found a useful answer. I am adding features to this layer in perl mapscript using something like: my $shape = new mapscript::shapeObj($mapscript::MS_SHAPE_LINE); $shape->add($line); $shape->{text} = sprintf('%.2f', $p1->distanceToPoint($p2)); $shape->setBounds(); $newlayer->addFeature($shape); Any hints would be appreciated, -Andy From ml at lingner.eu Fri Jul 17 11:55:11 2009 From: ml at lingner.eu (Lars Lingner) Date: Fri, 17 Jul 2009 20:55:11 +0200 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60C2D9.6090609@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> Message-ID: <4A60C90F.60601@lingner.eu> Andy Colson schrieb: > Hi All, > > > Here is a screen shot: > > http://maps.camavision.com/map.jpg > > > There are, as far as I can tell, 4 lines. The label is duplicating and > I dont want it too. Here is the layer from the mapfile: > > > LAYER > NAME annotate_pin > TYPE line > STATUS on > CLASS > NAME "HIGHLIGHT" > STYLE > COLOR 0 255 0 > OUTLINECOLOR 0 255 0 > WIDTH 3 > END > LABEL > TYPE truetype > FONT "Vera" > SIZE 10 > COLOR 0 0 0 > ANGLE follow > POSITION auto > BACKGROUNDCOLOR 255 255 255 > MINDISTANCE 900 > END > END > END > > > I have played with MINDISTANCE from 0 to 99,000 and it does not seem to > make a difference. I googled a little but have not found a useful answer. > If you want to use MINDISTANCE you have to set the SIZEUNITS parameter at layer level like this: LAYER ... SIZEUNITS meters # one of [pixels|feet|inches|kilometers|meters|miles] ... LABEL ... MINDISTANCE 500 ... END ... END So the label wouldn't repeated for distances smaller than 500 meter. Lars From andy at squeakycode.net Fri Jul 17 12:05:15 2009 From: andy at squeakycode.net (Andy Colson) Date: Fri, 17 Jul 2009 14:05:15 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60C90F.60601@lingner.eu> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> Message-ID: <4A60CB6B.1050504@squeakycode.net> Lars Lingner wrote: > Andy Colson schrieb: >> Hi All, >> >> >> Here is a screen shot: >> >> http://maps.camavision.com/map.jpg >> >> >> There are, as far as I can tell, 4 lines. The label is duplicating and >> I dont want it too. Here is the layer from the mapfile: >> >> >> LAYER >> NAME annotate_pin >> TYPE line >> STATUS on >> CLASS >> NAME "HIGHLIGHT" >> STYLE >> COLOR 0 255 0 >> OUTLINECOLOR 0 255 0 >> WIDTH 3 >> END >> LABEL >> TYPE truetype >> FONT "Vera" >> SIZE 10 >> COLOR 0 0 0 >> ANGLE follow >> POSITION auto >> BACKGROUNDCOLOR 255 255 255 >> MINDISTANCE 900 >> END >> END >> END >> >> >> I have played with MINDISTANCE from 0 to 99,000 and it does not seem to >> make a difference. I googled a little but have not found a useful answer. >> > > If you want to use MINDISTANCE you have to set the SIZEUNITS parameter > at layer level like this: > > LAYER > ... > SIZEUNITS meters # one of [pixels|feet|inches|kilometers|meters|miles] > ... > LABEL > ... > MINDISTANCE 500 > ... > END > ... > END > > So the label wouldn't repeated for distances smaller than 500 meter. > > > Lars > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users That didn't seem to work. It made all my fonts really small, but the labels still duped. The help says layer.sizeUnits "Sets the unit of CLASS object SIZE", does that include label font size? It defaults to pixels, yes? Wouldnt a really big MINDISTANCE still have removed dups? -Andy From ml at lingner.eu Fri Jul 17 12:25:48 2009 From: ml at lingner.eu (Lars Lingner) Date: Fri, 17 Jul 2009 21:25:48 +0200 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60CB6B.1050504@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> Message-ID: <4A60D03C.1090509@lingner.eu> Andy Colson schrieb: > Lars Lingner wrote: >> Andy Colson schrieb: >>> Hi All, >>> >>> >>> Here is a screen shot: >>> >>> http://maps.camavision.com/map.jpg >>> >>> >>> There are, as far as I can tell, 4 lines. The label is duplicating and >>> I dont want it too. Here is the layer from the mapfile: >>> >>> >>> LAYER >>> NAME annotate_pin >>> TYPE line >>> STATUS on >>> CLASS >>> NAME "HIGHLIGHT" >>> STYLE >>> COLOR 0 255 0 >>> OUTLINECOLOR 0 255 0 >>> WIDTH 3 >>> END >>> LABEL >>> TYPE truetype >>> FONT "Vera" >>> SIZE 10 >>> COLOR 0 0 0 >>> ANGLE follow >>> POSITION auto >>> BACKGROUNDCOLOR 255 255 255 >>> MINDISTANCE 900 >>> END >>> END >>> END >>> >>> >>> I have played with MINDISTANCE from 0 to 99,000 and it does not seem to >>> make a difference. I googled a little but have not found a useful >>> answer. >>> >> >> If you want to use MINDISTANCE you have to set the SIZEUNITS parameter >> at layer level like this: >> >> LAYER >> ... >> SIZEUNITS meters # one of [pixels|feet|inches|kilometers|meters|miles] >> ... >> LABEL >> ... >> MINDISTANCE 500 >> ... >> END >> ... >> END >> >> So the label wouldn't repeated for distances smaller than 500 meter. >> >> >> Lars >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > That didn't seem to work. It made all my fonts really small, but the > labels still duped. > Do you have at MAP level the UNITS parameter? [feet|inches|kilometers|meters|miles|dd] Please try that, I should have told you that in my last reply ;) also: which projection have you set at MAP level? > The help says layer.sizeUnits "Sets the unit of CLASS object SIZE", does > that include label font size? it sets the unit of the object size, not the size itself. The font size is controlled by the SIZE parameter (LABEL object) > > It defaults to pixels, yes? Wouldnt a really big MINDISTANCE still have > removed dups? > Not necessarily... Often they are different in orders of magnitude Lars From andy at squeakycode.net Fri Jul 17 12:33:06 2009 From: andy at squeakycode.net (Andy Colson) Date: Fri, 17 Jul 2009 14:33:06 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60D03C.1090509@lingner.eu> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> Message-ID: <4A60D1F2.9060207@squeakycode.net> Lars Lingner wrote: > Andy Colson schrieb: >> Lars Lingner wrote: >>> Andy Colson schrieb: >>>> Hi All, >>>> >>>> >>>> Here is a screen shot: >>>> >>>> http://maps.camavision.com/map.jpg >>>> >>>> >>>> There are, as far as I can tell, 4 lines. The label is duplicating and >>>> I dont want it too. Here is the layer from the mapfile: >>>> >>>> >>>> LAYER >>>> NAME annotate_pin >>>> TYPE line >>>> STATUS on >>>> CLASS >>>> NAME "HIGHLIGHT" >>>> STYLE >>>> COLOR 0 255 0 >>>> OUTLINECOLOR 0 255 0 >>>> WIDTH 3 >>>> END >>>> LABEL >>>> TYPE truetype >>>> FONT "Vera" >>>> SIZE 10 >>>> COLOR 0 0 0 >>>> ANGLE follow >>>> POSITION auto >>>> BACKGROUNDCOLOR 255 255 255 >>>> MINDISTANCE 900 >>>> END >>>> END >>>> END >>>> >>>> >>>> I have played with MINDISTANCE from 0 to 99,000 and it does not seem to >>>> make a difference. I googled a little but have not found a useful >>>> answer. >>>> >>> If you want to use MINDISTANCE you have to set the SIZEUNITS parameter >>> at layer level like this: >>> >>> LAYER >>> ... >>> SIZEUNITS meters # one of [pixels|feet|inches|kilometers|meters|miles] >>> ... >>> LABEL >>> ... >>> MINDISTANCE 500 >>> ... >>> END >>> ... >>> END >>> >>> So the label wouldn't repeated for distances smaller than 500 meter. >>> >>> >>> Lars >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> That didn't seem to work. It made all my fonts really small, but the >> labels still duped. >> > > Do you have at MAP level the UNITS parameter? > [feet|inches|kilometers|meters|miles|dd] Yes, its feet. > > Please try that, I should have told you that in my last reply ;) > > also: which projection have you set at MAP level? PROJECTION "init=epsg:3417" END > >> The help says layer.sizeUnits "Sets the unit of CLASS object SIZE", does >> that include label font size? > > it sets the unit of the object size, not the size itself. The font size > is controlled by the SIZE parameter (LABEL object) > Then why did the labels font size change? >> It defaults to pixels, yes? Wouldnt a really big MINDISTANCE still have >> removed dups? >> > > Not necessarily... Often they are different in orders of magnitude > Here is my entire mapfile, the annotate_pin layer is at the bottom: MAP NAME bremer SIZE 800 800 UNITS feet SHAPEPATH '/pub/maps/bremerIA' FONTSET "/pub/www/fonts/fonts.txt" # full extent EXTENT 5166680.718750 3687027.837500 5306080.031250 3802972.662500 # testing #EXTENT 5191357.283967 3726454.400032 5205566.339522 3738272.725606 PROJECTION "init=epsg:3417" END IMAGECOLOR 192 192 192 IMAGEQUALITY 95 IMAGETYPE jpeg OUTPUTFORMAT NAME jpeg DRIVER 'GD/JPEG' MIMETYPE 'image/jpeg' #IMAGEMODE PC256 EXTENSION 'jpeg' END LEGEND IMAGECOLOR 255 255 255 STATUS ON KEYSIZE 18 12 LABEL TYPE BITMAP SIZE MEDIUM COLOR 0 0 89 END END WEB IMAGEPATH '/tmp/' IMAGEURL '/tmp/' METADATA 'wms_title' 'bremer' 'wms_onlineresource' 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' 'wms_srs' 'EPSG:3417' END END #Circle symbol SYMBOL NAME 'CIRCLE' TYPE ellipse FILLED true POINTS 1 1 END END LAYER NAME "raster" STATUS off TILEINDEX "raster.shp" TILEITEM "location" TYPE RASTER END LAYER NAME 'parcel_point' STATUS off TYPE POINT CONNECTIONTYPE postgis CONNECTION "dbname=gis user=andy" DATA 'the_geom FROM bremeria.parcelpoint using unique gid using srid=3417' PROCESSING "CLOSE_CONNECTION=DEFER" METADATA 'wms_title' 'parcelpoint' END TRANSPARENCY 100 LABELITEM pin PROJECTION "init=epsg:3417" END CLASS NAME 'parcelpoint' STYLE SYMBOL 'CIRCLE' SIZE 1 OUTLINECOLOR 0 0 0 COLOR 150 123 90 END LABEL TYPE truetype FONT "Vera" SIZE 7 COLOR 0 0 0 #BACKGROUNDCOLOR 255 255 255 #BUFFER 3 #ANGLE 45 POSITION auto PARTIALS false #FORCE true END END END LAYER NAME 'parcels' TYPE POLYGON CONNECTIONTYPE postgis CONNECTION "dbname=gis user=andy" DATA 'the_geom FROM bremeria.parcelpoly using unique gid using srid=3417' PROCESSING "CLOSE_CONNECTION=DEFER" METADATA 'wms_title' 'parcelpoly' END STATUS off TRANSPARENCY 100 PROJECTION "init=epsg:3417" END CLASS NAME 'parcelpoly' STYLE SYMBOL 0 SIZE 2 OUTLINECOLOR 0 0 0 COLOR 229 210 191 END END END LAYER NAME 'cadastral_line' TYPE LINE CONNECTIONTYPE postgis CONNECTION "dbname=gis user=andy" DATA 'the_geom FROM bremeria.cadastral_line using unique gid using srid=3417' PROCESSING "CLOSE_CONNECTION=DEFER" METADATA 'wms_title' 'cadastral_line' END STATUS on TRANSPARENCY 100 PROJECTION "init=epsg:3417" END CLASSITEM 'alphatag' CLASS NAME 'alphatag = ' EXPRESSION '' STYLE SYMBOL 0 SIZE 2 OUTLINECOLOR 0 0 0 COLOR 0 0 0 END END CLASS NAME 'alphatag = Corp Line' EXPRESSION 'Corp Line' STYLE SYMBOL 0 SIZE 2 COLOR 177 214 186 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = County Line' EXPRESSION 'County Line' STYLE SYMBOL 0 SIZE 2 COLOR 124 53 190 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Geo Twp Line' EXPRESSION 'Geo Twp Line' STYLE SYMBOL 0 SIZE 2 COLOR 120 117 243 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Lot Line' EXPRESSION 'Lot Line' STYLE SYMBOL 0 SIZE 2 COLOR 190 28 153 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Misc Line' EXPRESSION 'Misc Line' STYLE SYMBOL 0 SIZE 2 COLOR 99 188 156 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Parcel Line' EXPRESSION 'Parcel Line' STYLE SYMBOL 0 SIZE 2 COLOR 146 93 39 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Pol Twp Line' EXPRESSION 'Pol Twp Line' STYLE SYMBOL 0 SIZE 2 COLOR 58 109 205 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Railroad Centerline' EXPRESSION 'Railroad Centerline' STYLE SYMBOL 0 SIZE 2 COLOR 132 253 192 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Railroad ROW' EXPRESSION 'Railroad ROW' STYLE SYMBOL 0 SIZE 2 COLOR 148 148 148 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Road Centerline' EXPRESSION 'Road Centerline' STYLE SYMBOL 0 SIZE 2 COLOR 126 17 179 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Road ROW' EXPRESSION 'Road ROW' STYLE SYMBOL 0 SIZE 2 COLOR 129 38 243 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Section Line' EXPRESSION 'Section Line' STYLE SYMBOL 0 SIZE 2 COLOR 37 231 177 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Sub Line 100' EXPRESSION 'Sub Line 100' STYLE SYMBOL 0 SIZE 2 COLOR 78 109 18 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Sub Line 400' EXPRESSION 'Sub Line 400' STYLE SYMBOL 0 SIZE 2 COLOR 247 175 40 OUTLINECOLOR 0 0 0 END END CLASS NAME 'alphatag = Water Line' EXPRESSION 'Water Line' STYLE SYMBOL 0 SIZE 2 COLOR 0 0 255 OUTLINECOLOR 0 0 0 END END END LAYER NAME annotate_pin TYPE line STATUS on # if I comment the SIZEUNITS out it only changes the label size SIZEUNITS feet CLASS NAME "HIGHLIGHT" STYLE COLOR 0 255 0 OUTLINECOLOR 0 255 0 WIDTH 3 END LABEL TYPE truetype FONT "Vera" SIZE 10 COLOR 0 0 0 BACKGROUNDCOLOR 255 255 255 ANGLE follow POSITION auto PARTIALS false MINDISTANCE 95000 END END END END Thanks for the help, -Andy From arnd.wippermann at web.de Fri Jul 17 12:47:40 2009 From: arnd.wippermann at web.de (Arnd Wippermann) Date: Fri, 17 Jul 2009 21:47:40 +0200 Subject: AW: [mapserver-users] openlayers/mapserver In-Reply-To: Message-ID: Hi, with a right click on the pink tile you can get the url of the image. Test it in the browser and you should get an error message. Perhaps it's the wrong parameter SRS (it's a wms parameter) or the absent parameter map_projection (mapserver parameter). You should also declare options for your map object. I think by default OpenLayers uses EPSG:4326 with the extent -180,-90,180,90. Arnd _____ Von: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] Im Auftrag von YOUNESS ELMEDRAOUI Gesendet: Freitag, 17. Juli 2009 13:06 An: mapserver-users at lists.osgeo.org Betreff: [mapserver-users] openlayers/mapserver Hi, i created my wms server and i test them with a GetCapabilities and GetMap REQUEST : http://localhost:81/cgi-bin/mapserv.exe?map=C:/OLWebSite/App_Data/olvbmapfil el.map &REQUEST=GetCapabilities&SERVICE=WMS&VERSiON=1.1.0 http://localhost:81/cgi-bin/mapserv.exe?map=C:/OLWebSite/App_Data/olvbmapfil el.map &REQUEST=GetMap&SERVICE=WMS&VERSiON=1.1.0&Layers=compfun,zone&SRS=EPSG:32632 &STYLE=&BBox=1143759,4417539,1146436,4420390&FORMAT=image/png&WIDTH=400&HEIG HT=400 and my tests is ok. now, i want to displat data with openlayers. i tested this code but it doesn't work. map = new OpenLayers.Map( 'map' ); layer = new OpenLayers.Layer.MapServer("ol demo", "http://localhost:81/cgi-bin/mapserv.exe?map=C:\OLWebSite\App_Data\olvbmapfi lel.map&", {Layers:'compfun',SRS:'EPSG:32632'} ); see result in attachement. can any one help me plz? do you have an exemple for displayind data with openlayers based on mapfile? Best regards, Youness ELMEDRAOUI Les informations figurant sur cet e-mail ont un caract?re strictement confidentiel et sont exclusivement adress?es au destinataire mentionn? ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, veuillez nous en avertir imm?diatement par la m?me voie et d?truire l'original. Merci -------------- next part -------------- An HTML attachment was scrubbed... URL: From rebecca.a.maurer at gmail.com Fri Jul 17 14:03:33 2009 From: rebecca.a.maurer at gmail.com (Rebecca Maurer) Date: Fri, 17 Jul 2009 16:03:33 -0500 Subject: [mapserver-users] Geo-Referencing questions Message-ID: Alright, so after some great help last week from some people on this listhost, I have mapserver up and running on my local apache webserver. Now, however, I have tons of newbie questions, so sorry if these are painfully obvious/ignorant. I've spent a lot of time reading through documentation, and these are the things I still don't understand. My goal right now for the project I'm working is to use a .jpeg of my neighborhood, geo-reference it, and then get different "line" shapefiles with all the different bus routes and shuttles up. I have a bunch of questions in trying to accomplish this. First of all, I downloaded HyperCube and used Google Earth to get four longitude/latitude points that I could identify on my .jpeg of my neighborhood. Then used the Image to Reference Coordinates utility on HyperCube to add in this data, then resave this as a .tif. I was sort of skeptical that this could actually make it a geo-referenced TIFF file, so I called gdalinfo on it and got: /gdalinfo /Library/WebServer/Documents/TrialCampusMap.tif Warning 1: TIFFReadDirectoryCheckOrder:Invalid TIFF directory; tags are not sorted in ascending order Warning 1: TIFFFetchNormalTag:ASCII value for tag "GeoASCIIParams" does not end in null byte Driver: GTiff/GeoTIFF Size is 1439, 1804 Coordinate System is: GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.2572235630016, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0], UNIT["degree",0.0174532925199433], AUTHORITY["EPSG","4326"]] GeoTransform = -87.60760613250471, 1.981903295209896e-05, -7.648849138569716e-08 41.80965128643957, 3.093930015634964e-07, -1.475797871914549e-05 Metadata: AREA_OR_POINT=Point TIFFTAG_XRESOLUTION=72 TIFFTAG_YRESOLUTION=72 TIFFTAG_RESOLUTIONUNIT=2 (pixels/inch) Image Structure Metadata: INTERLEAVE=PIXEL Corner Coordinates: Upper Left ( -87.6076061, 41.8096513) ( 87d36'27.38"W, 41d48'34.74"N) Lower Left ( -87.6077441, 41.7830279) ( 87d36'27.88"W, 41d46'58.90"N) Upper Right ( -87.5790865, 41.8100965) ( 87d34'44.71"W, 41d48'36.35"N) Lower Right ( -87.5792245, 41.7834731) ( 87d34'45.21"W, 41d47'0.50"N) Center ( -87.5934153, 41.7965622) ( 87d35'36.30"W, 41d47'47.62"N) Band 1 Block=1439x1 Type=Byte, ColorInterp=Red Band 2 Block=1439x1 Type=Byte, ColorInterp=Green Band 3 Block=1439x1 Type=Byte, ColorInterp=Blue First of all -- what are the differences between the two different sets of coordinates in parentheses for "upper left/ lower left.....etc". Next, is this actually a GeoTiff? And moreover, what do I do with it now? I tried displaying it as LAYER NAME "campusmap" TYPE RASTER STATUS ON DATA "TrialCampusMap.tif" CLASSITEM "[pixel]" with a GeoTiff OUTPUTFORMAT and also with different types of files as IMAGETYPE. But each time, the image came out as horrible quality, and oddly tilted (though it might be tilted so that the latitude line is the horizontal axis?). Also, I wasn't sure what to use for the EXTENT, and used the numbers -87.60 41.75 -87.57 41.81 which seemed to display the whole map, but this was only after some trial and error with the upperleft/lowerleft, etc. data. How can I normally find the EXTENT? Second of all - I want to start adding some Vector layers, but the problem is that no shapefiles or anything exist for the data I want to add. I googled about a bit, but didn't find any good advice on how to make your own Vector data from personal knowledge. Can anybody point me in the right direction on this? Thank you very much, Rebecca -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at pobox.com Fri Jul 17 14:23:05 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Fri, 17 Jul 2009 17:23:05 -0400 Subject: [mapserver-users] Geo-Referencing questions In-Reply-To: References: Message-ID: <4A60EBB9.8080600@pobox.com> Rebecca Maurer wrote: > I was sort of skeptical that this could actually make it a > geo-referenced TIFF file, so I called gdalinfo on it and got: ... > Corner Coordinates: > Upper Left ( -87.6076061, 41.8096513) ( 87d36'27.38"W, 41d48'34.74"N) > Lower Left ( -87.6077441, 41.7830279) ( 87d36'27.88"W, 41d46'58.90"N) > Upper Right ( -87.5790865, 41.8100965) ( 87d34'44.71"W, 41d48'36.35"N) > Lower Right ( -87.5792245, 41.7834731) ( 87d34'45.21"W, 41d47'0.50"N) > Center ( -87.5934153, 41.7965622) ( 87d35'36.30"W, 41d47'47.62"N) ... > First of all -- what are the differences between the two different sets > of coordinates in parentheses for "upper left/ lower left.....etc". Rebecca, The first set is reported in decimal degrees. The second set is the same values described in degrees, minutes and seconds with hemisphere codes (W=west vs. using a negative sign for instance). The values all look plausible. > Next, is this actually a GeoTiff? It appears to be a valid geotiff though if the details of this were particularly important to you it might be better to inspect a listgeo report instead of a gdalinfo report. > And moreover, what do I do with it > now? I tried displaying it as > > LAYER > NAME "campusmap" > TYPE RASTER > STATUS ON > DATA "TrialCampusMap.tif" > CLASSITEM "[pixel]" I have no idea why you are using CLASSITEM. Normally RGB images would be used directly with no classes or classitem defined in the raster layer. > with a GeoTiff OUTPUTFORMAT and also with different types of files as > IMAGETYPE. But each time, the image came out as horrible quality, I would encourage you to use an output format like PNG24 or JPEG to avoid significant color degredation. PNG or GIF will generally be inappropriate choice for RGB imagery. > and > oddly tilted (though it might be tilted so that the latitude line is the > horizontal axis?). The photo is apparently not oriented north up, so MapServer is rectifying it on the fly. Based on the geotransform it seems the angle of rotation should be modest - perhaps a few degrees? > Also, I wasn't sure what to use for the EXTENT, and > used the numbers -87.60 41.75 -87.57 41.81 which seemed to display the > whole map, but this was only after some trial and error with the > upperleft/lowerleft, etc. data. How can I normally find the EXTENT? Normally you could find this by looking at the corner coordinates in the gdalinfo report. > Second of all - I want to start adding some Vector layers, but the > problem is that no shapefiles or anything exist for the data I want to > add. I googled about a bit, but didn't find any good advice on how to > make your own Vector data from personal knowledge. Can anybody point me > in the right direction on this? My suggestion would be to draw them by hand over the photo image you have using software like QGIS for instance. Ensure that whatever software you use understands rotated geotiff files - this is not universal. If you want predefined local data you might want to discuss data sources with your campus engineering office, or your local city/municiple GIS people. Good luck, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From michalis at u.washington.edu Fri Jul 17 15:00:46 2009 From: michalis at u.washington.edu (Michalis Avraam) Date: Fri, 17 Jul 2009 15:00:46 -0700 Subject: [mapserver-users] Error running ./configure on a Linux machine Message-ID: <829a3c190907171500ica72bcek8cafed4cc720d5ff@mail.gmail.com> Hello all. I have tried to compile MapServer 5.4.1 for the last few hours to no avail. I cannot get past the ./configure command for some reason. Any input will be greatly appreciated. Basically, my problem is that ./configure refuses to recognize some of the commands I give it for some reason (for example, --with-agg or --with-png). It also refuses to find files on the system when I specify paths. For example, /usr/sbin/httpd or /usr/bin/xml2-config. I have made sure that the files are there, installed correctly, running just fine and are accessible by the user running ./configure. Any ideas what might be the problem? The following information may be useful. Thank you in advance, Michalis Environment: Fedora Core 11 x86 Intel Core2Duo 2GB Ram Configure script run: ./configure --enable-debug \ --with-freetype=/usr \ --with-zlib=/lib \ --with-png=/usr/lib \ --with-jpeg \ --with-libiconv=/usr \ --with-gd \ --with-agg=/usr/lib \ --with-proj=/usr \ --with-threads \ --with-geos=/usr/bin/geos-config \ --with-ogr=/usr/bin/gdal-config \ --with-gdal=/usr/bin/gdal-config \ --with-tiff \ --with-postgis=/usr/bin/pg_config \ --with-wcs \ --with-wfsclient \ --with-wmsclient \ --with-sos \ --with-curl-config=/usr/bin/curl-config \ --with-xml2-config=/usr/bin/xml2-config \ --with-httpd=/usr/sbin/httpd \ --with-warnings \ --with-php=/usr/include/php \ Configure Report returned: MapServer is now configured for -------------- Compiler Info ------------- C compiler: gcc -g -O2 -fPIC -Wall C++ compiler: g++ -g -O2 -fPIC -Wall Debug: -g -DNEED_NONBLOCKING_STDERR Generic NINT: -------------- Renderer Settings --------- zlib support: -DUSE_ZLIB png support: palette rgba png support: jpeg support: -DUSE_JPEG iconv support: -DUSE_ICONV AGG support: AGG Freetype support: Ming(flash) support: PDFLib support: -------------- Support Libraries --------- Proj.4 support: Libxml2 support: FriBidi support: Curl support: FastCGI support: Threading support: GEOS support: -------------- Data Format Drivers ------- native tiff support: -DUSE_TIFF PostGIS support: EPPL7 support: -DUSE_EPPL ArcSDE support: OGR support: GDAL support: Oracle Spatial support: -------------- OGC Services -------------- WMS Server: WMS Client: WFS Server: WFS Client: WCS Server: SOS Server: -------------- MapScript ----------------- PHP MapScript: no Error Messages from configure: ./myconfigure.sh: line 8: --with-gd: command not found ./myconfigure.sh: line 23: --with-httpd=/usr/sbin/httpd: No such file or directory ./myconfigure.sh: line 25: --with-php=/usr/include/php: No such file or directory From ml at lingner.eu Fri Jul 17 15:06:07 2009 From: ml at lingner.eu (Lars Lingner) Date: Sat, 18 Jul 2009 00:06:07 +0200 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60D1F2.9060207@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> Message-ID: <4A60F5CF.9020406@lingner.eu> Andy Colson schrieb: [...] >> >>> The help says layer.sizeUnits "Sets the unit of CLASS object SIZE", does >>> that include label font size? >> >> it sets the unit of the object size, not the size itself. The font size >> is controlled by the SIZE parameter (LABEL object) >> > > Then why did the labels font size change? I'm not sure about this. If I'm changing sizeunits from meters to kilometers, my style looks realy awkward but my labels are stay the same. > > Here is my entire mapfile, the annotate_pin layer is at the bottom: > > MAP > NAME bremer > SIZE 800 800 > UNITS feet > SHAPEPATH '/pub/maps/bremerIA' > FONTSET "/pub/www/fonts/fonts.txt" > > # full extent > EXTENT 5166680.718750 3687027.837500 5306080.031250 3802972.662500 > # testing > #EXTENT 5191357.283967 3726454.400032 5205566.339522 3738272.725606 > > PROJECTION > "init=epsg:3417" > END > [...] > WEB > IMAGEPATH '/tmp/' > IMAGEURL '/tmp/' > METADATA > 'wms_title' 'bremer' > 'wms_onlineresource' > 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' > 'wms_srs' 'EPSG:3417' > END > END > > [...] > LAYER > NAME annotate_pin > TYPE line > STATUS on > # if I comment the SIZEUNITS out it only changes the label size > SIZEUNITS feet > CLASS > NAME "HIGHLIGHT" > STYLE > COLOR 0 255 0 > OUTLINECOLOR 0 255 0 > WIDTH 3 > END > LABEL > TYPE truetype > FONT "Vera" > SIZE 10 > COLOR 0 0 0 > BACKGROUNDCOLOR 255 255 255 > ANGLE follow > POSITION auto > PARTIALS false > MINDISTANCE 95000 > END > END > END > END > > The mapfile looks fine. I'm unsing MINDISTANCE the same way for controlling road labels. One other thing you can try is to play with BUFFER for the labels. Which version of MapServer are you using? I know along with 5.4 there where some enhancements for labeling. One last thought: Do you have this problem just with the layer "annotate_pin"? Does the labeling of other layers work as you expect? lars From andy at squeakycode.net Fri Jul 17 18:05:03 2009 From: andy at squeakycode.net (andy) Date: Fri, 17 Jul 2009 20:05:03 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A60F5CF.9020406@lingner.eu> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> Message-ID: <4A611FBF.9040401@squeakycode.net> Lars Lingner wrote: > Andy Colson schrieb: > [...] >>>> The help says layer.sizeUnits "Sets the unit of CLASS object SIZE", does >>>> that include label font size? >>> it sets the unit of the object size, not the size itself. The font size >>> is controlled by the SIZE parameter (LABEL object) >>> >> Then why did the labels font size change? > > I'm not sure about this. If I'm changing sizeunits from meters to > kilometers, my style looks realy awkward but my labels are stay the same. > > >> Here is my entire mapfile, the annotate_pin layer is at the bottom: >> >> MAP >> NAME bremer >> SIZE 800 800 >> UNITS feet >> SHAPEPATH '/pub/maps/bremerIA' >> FONTSET "/pub/www/fonts/fonts.txt" >> >> # full extent >> EXTENT 5166680.718750 3687027.837500 5306080.031250 3802972.662500 >> # testing >> #EXTENT 5191357.283967 3726454.400032 5205566.339522 3738272.725606 >> >> PROJECTION >> "init=epsg:3417" >> END >> > [...] >> WEB >> IMAGEPATH '/tmp/' >> IMAGEURL '/tmp/' >> METADATA >> 'wms_title' 'bremer' >> 'wms_onlineresource' >> 'http://my.host.com/cgi-bin/mapserv?map=wms.map&' >> 'wms_srs' 'EPSG:3417' >> END >> END >> >> > > [...] > >> LAYER >> NAME annotate_pin >> TYPE line >> STATUS on >> # if I comment the SIZEUNITS out it only changes the label size >> SIZEUNITS feet >> CLASS >> NAME "HIGHLIGHT" >> STYLE >> COLOR 0 255 0 >> OUTLINECOLOR 0 255 0 >> WIDTH 3 >> END >> LABEL >> TYPE truetype >> FONT "Vera" >> SIZE 10 >> COLOR 0 0 0 >> BACKGROUNDCOLOR 255 255 255 >> ANGLE follow >> POSITION auto >> PARTIALS false >> MINDISTANCE 95000 >> END >> END >> END >> END >> >> > > > The mapfile looks fine. I'm unsing MINDISTANCE the same way for > controlling road labels. > > One other thing you can try is to play with BUFFER for the labels. > > Which version of MapServer are you using? I know along with 5.4 there > where some enhancements for labeling. > > One last thought: Do you have this problem just with the layer > "annotate_pin"? Does the labeling of other layers work as you expect? > > lars I'm using 5.4.1, perl mapscript, via OpenLayers vai WMS. (Jeez, I hope that conveys meaning, because it could really easily be complete gibberish :-) ) > One last thought: Do you have this problem just with the layer > "annotate_pin"? Does the labeling of other layers work as you expect? Hum... good question. I'll try it Monday when I get back to work. Thanks for the help on this. -Andy From andy at squeakycode.net Fri Jul 17 18:07:49 2009 From: andy at squeakycode.net (andy) Date: Fri, 17 Jul 2009 20:07:49 -0500 Subject: [mapserver-users] Error running ./configure on a Linux machine In-Reply-To: <829a3c190907171500ica72bcek8cafed4cc720d5ff@mail.gmail.com> References: <829a3c190907171500ica72bcek8cafed4cc720d5ff@mail.gmail.com> Message-ID: <4A612065.9050403@squeakycode.net> Michalis Avraam wrote: > Hello all. > > I have tried to compile MapServer 5.4.1 for the last few hours to no > avail. I cannot get past the ./configure command for some reason. Any > input will be greatly appreciated. > > Basically, my problem is that ./configure refuses to recognize some of > the commands I give it for some reason (for example, --with-agg or > --with-png). It also refuses to find files on the system when I > specify paths. For example, /usr/sbin/httpd or /usr/bin/xml2-config. I > have made sure that the files are there, installed correctly, running > just fine and are accessible by the user running ./configure. > > Any ideas what might be the problem? The following information may be useful. > > Thank you in advance, > > Michalis > > Environment: > Fedora Core 11 x86 > Intel Core2Duo > 2GB Ram > > Configure script run: > ./configure --enable-debug \ > --with-freetype=/usr \ > --with-zlib=/lib \ > --with-png=/usr/lib \ > --with-jpeg \ > --with-libiconv=/usr \ > --with-gd \ > --with-agg=/usr/lib \ > --with-proj=/usr \ > --with-threads \ > --with-geos=/usr/bin/geos-config \ > --with-ogr=/usr/bin/gdal-config \ > --with-gdal=/usr/bin/gdal-config \ > --with-tiff \ > --with-postgis=/usr/bin/pg_config \ > --with-wcs \ > --with-wfsclient \ > --with-wmsclient \ > --with-sos \ > --with-curl-config=/usr/bin/curl-config \ > --with-xml2-config=/usr/bin/xml2-config \ > --with-httpd=/usr/sbin/httpd \ > --with-warnings \ > --with-php=/usr/include/php \ > > Configure Report returned: > MapServer is now configured for > > -------------- Compiler Info ------------- > C compiler: gcc -g -O2 -fPIC -Wall > C++ compiler: g++ -g -O2 -fPIC -Wall > Debug: -g -DNEED_NONBLOCKING_STDERR > Generic NINT: > > -------------- Renderer Settings --------- > zlib support: -DUSE_ZLIB > png support: > palette rgba png support: > jpeg support: -DUSE_JPEG > iconv support: -DUSE_ICONV > AGG support: > AGG Freetype support: > Ming(flash) support: > PDFLib support: > > -------------- Support Libraries --------- > Proj.4 support: > Libxml2 support: > FriBidi support: > Curl support: > FastCGI support: > Threading support: > GEOS support: > > -------------- Data Format Drivers ------- > native tiff support: -DUSE_TIFF > PostGIS support: > EPPL7 support: -DUSE_EPPL > ArcSDE support: > OGR support: > GDAL support: > Oracle Spatial support: > > -------------- OGC Services -------------- > WMS Server: > WMS Client: > WFS Server: > WFS Client: > WCS Server: > SOS Server: > > -------------- MapScript ----------------- > PHP MapScript: no > > Error Messages from configure: > ./myconfigure.sh: line 8: --with-gd: command not found > ./myconfigure.sh: line 23: --with-httpd=/usr/sbin/httpd: No such file > or directory > ./myconfigure.sh: line 25: --with-php=/usr/include/php: No such file > or directory > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users Did you by chance edit myconfigure.sh in windows? Leave around some carriage returns or something? Got extra spaces/tabs after the \ ? like: --with-libiconv=/usr \{tab} -Andy From trondmm-mapserver at crusaders.no Sat Jul 18 05:16:20 2009 From: trondmm-mapserver at crusaders.no (Trond Michelsen) Date: Sat, 18 Jul 2009 14:16:20 +0200 Subject: [mapserver-users] Problems with non-square pixels In-Reply-To: <612169113.17101247815642993.JavaMail.root@srsofaioi13477.ktso.ch> References: <4A5F617C.5157.008F.0@dnr.state.mn.us> <612169113.17101247815642993.JavaMail.root@srsofaioi13477.ktso.ch> Message-ID: <20090718121620.GD17154@crusaders.no> On Fri, Jul 17, 2009 at 09:27:22AM +0200, Pfeiffer Michael wrote: > So is it possible to send a float width and height to mapserver No. The WMS standard states that WIDTH and HEIGHT are integer values. -- Trond Michelsen From haerta at yahoo.com Sun Jul 19 08:06:51 2009 From: haerta at yahoo.com (=?iso-8859-1?Q?Michael_H=E4rtel?=) Date: Sun, 19 Jul 2009 08:06:51 -0700 (PDT) Subject: [mapserver-users] (no subject) Message-ID: <469099.37946.qm@web50805.mail.re2.yahoo.com> http://gnoelaw.com/systems.html From haerta at yahoo.com Sun Jul 19 12:43:25 2009 From: haerta at yahoo.com (=?iso-8859-1?Q?Michael_H=E4rtel?=) Date: Sun, 19 Jul 2009 12:43:25 -0700 (PDT) Subject: [mapserver-users] (no subject) Message-ID: <270833.45558.qm@web50801.mail.re2.yahoo.com> http://docs.google.com/view?docid=ddhrh4rr_50cq7wmgkb From kreshna_iceheart at yahoo.com Sun Jul 19 23:23:07 2009 From: kreshna_iceheart at yahoo.com (kreshna_iceheart at yahoo.com) Date: Sun, 19 Jul 2009 23:23:07 -0700 (PDT) Subject: [mapserver-users] Spatial operations with PHP MapScript? (plus, intersecting raster and polygon?) Message-ID: <866143.8424.qm@web110612.mail.gq1.yahoo.com> Is it possible to do spatial operations with PHP MapScript? Currently, if I want to do intersection between two shapes, I have to write the following postgis queries in my map file: ? ? DATA 'the_geom from ( select h.gid, intersection(k.the_geom, h.the_geom) as the_geom FROM test.jawabali_konservasi k INNER JOIN test.jawabali_hutanlindung h ON (k.the_geom && h.the_geom AND intersects(k.the_geom, h.the_geom)) ) as foo using unique gid using srid=-1' Is it possible to do such thing on the fly with MapScript? And if spatial operations are possible with MapScript, is it possible to intersect a particular color range of a raster (which is defined in mapfile as CLASS) with polygons? Many thanks, -Kresh From jmckenna at gatewaygeomatics.com Mon Jul 20 05:11:06 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 20 Jul 2009 09:11:06 -0300 Subject: [mapserver-users] Spatial operations with PHP MapScript? (plus, intersecting raster and polygon?) In-Reply-To: <866143.8424.qm@web110612.mail.gq1.yahoo.com> References: <866143.8424.qm@web110612.mail.gq1.yahoo.com> Message-ID: <4A645EDA.8050302@gatewaygeomatics.com> kreshna_iceheart at yahoo.com wrote: > Is it possible to do spatial operations with PHP MapScript? Give a good search of the PHPMapScript documentation. For example, I would start by searching for "intersect" on http://www.mapserver.org/mapscript/php/index.html#php-mapscript (I believe the spatial operations are handled through the GEOS library by MapServer) That should at least help you with your first question. -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From paul_everton at hotmail.com Mon Jul 20 06:18:02 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Mon, 20 Jul 2009 13:18:02 +0000 Subject: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver In-Reply-To: <4A6083E7.1050004@gatewaygeomatics.com> References: <4457.145.50.39.11.1247829724.squirrel@webmail.hostingdiscounter.nl> <32091.145.50.39.11.1247837343.squirrel@webmail.hostingdiscounter.nl> <4A6083E7.1050004@gatewaygeomatics.com> Message-ID: Thanks for your response Jeff, Ive read the document you suggested (http://www.mapserver.org/ogc/wms_server.html ) however i am still experiencing the same problem. As the document suggests i have set a projection and then added the folowing to WEB section of my mapfile METADATA "wms_title" "UK1" "wcs_onlineresource" http://127.0.0.1/cgi-bin/mapserv?map=wms.map& "wms_srs" "EPSG:32119 EPSG:4326" END *Note 'wcs_onlinesresource' as my layer is a Raster then wihtin the layer i have olny added "wms_title" "UK1" wihtin METADATA. However i still get the error message "msWMSLoadGetMapParams(): WMS Server Error message " i have also looked throught the error documentation however i cannot find anything. Any help appreciatted thanks > Date: Fri, 17 Jul 2009 11:00:07 -0300 > From: jmckenna at gatewaygeomatics.com > To: mapserver-users at lists.osgeo.org > Subject: Re: [mapserver-users] Changing to Layers.WMS from Layers.Mapserver - Error 'msWMSLoadGetMapParams(): WMS ' > > Paul Curran wrote: > > Ive implemented your changes but im still getting the > > msWMSLoadGetMapParams(): WMS Server Error message repeatedly thorughout > > the open layers map window. > > > > My map file now looks like this (i have hihglighted your changes in > > bold), do you think i have put them in correclty? > > > > Paul, > > If you are trying to serve your mapfile through WMS then you should > follow this document: http://www.mapserver.org/ogc/wms_server.html > > Also, you should read the following page on MapServer projection use: > http://www.mapserver.org/mapfile/projection.html > > -jeff > > > -- > Jeff McKenna > FOSS4G Consulting and Training Services > http://www.gatewaygeomatics.com/ > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users _________________________________________________________________ With Windows Live, you can organise, edit, and share your photos. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From kreshna_iceheart at yahoo.com Mon Jul 20 06:37:53 2009 From: kreshna_iceheart at yahoo.com (kreshna_iceheart at yahoo.com) Date: Mon, 20 Jul 2009 06:37:53 -0700 (PDT) Subject: [mapserver-users] Spatial operations with PHP MapScript? (plus, intersecting raster and polygon?) In-Reply-To: <4A645EDA.8050302@gatewaygeomatics.com> Message-ID: <222883.49419.qm@web110614.mail.gq1.yahoo.com> Thanks, Jeff. I'll tinker around with intersection function. Roppola, it seems putting the raster mesh in the database (BLOB data type?) is not feasible in this situation. I wonder if anyone has ever succeeded in intersecting polygon and raster before. From andy at squeakycode.net Mon Jul 20 08:47:52 2009 From: andy at squeakycode.net (andy) Date: Mon, 20 Jul 2009 10:47:52 -0500 Subject: [mapserver-users] Error running ./configure on a Linux machine In-Reply-To: <829a3c190907200832y1ad78605hc8419e78e98d8ca7@mail.gmail.com> References: <829a3c190907171500ica72bcek8cafed4cc720d5ff@mail.gmail.com> <4A612065.9050403@squeakycode.net> <829a3c190907200832y1ad78605hc8419e78e98d8ca7@mail.gmail.com> Message-ID: <4A6491A8.4050106@squeakycode.net> Michalis Avraam wrote: > Andy, > > It was edited on Linux and I have tried to make sure it had no white > space after the \ > > Michalis > > > > On Fri, Jul 17, 2009 at 6:07 PM, andy > wrote: > > Michalis Avraam wrote: > > Hello all. > > I have tried to compile MapServer 5.4.1 for the last few hours > to no > avail. I cannot get past the ./configure command for some > reason. Any > input will be greatly appreciated. > > Basically, my problem is that ./configure refuses to recognize > some of > the commands I give it for some reason (for example, --with-agg or > --with-png). It also refuses to find files on the system when I > specify paths. For example, /usr/sbin/httpd or > /usr/bin/xml2-config. I > have made sure that the files are there, installed correctly, > running > just fine and are accessible by the user running ./configure. > > Any ideas what might be the problem? The following information > may be useful. > > Thank you in advance, > > Michalis > > Environment: > Fedora Core 11 x86 > Intel Core2Duo > 2GB Ram > > Configure script run: > ./configure --enable-debug \ > --with-freetype=/usr \ > --with-zlib=/lib \ > --with-png=/usr/lib \ > --with-jpeg \ > --with-libiconv=/usr \ > --with-gd \ > --with-agg=/usr/lib \ > --with-proj=/usr \ > --with-threads \ > --with-geos=/usr/bin/geos-config \ > --with-ogr=/usr/bin/gdal-config \ > --with-gdal=/usr/bin/gdal-config \ > --with-tiff \ > --with-postgis=/usr/bin/pg_config \ > --with-wcs \ > --with-wfsclient \ > --with-wmsclient \ > --with-sos \ > --with-curl-config=/usr/bin/curl-config \ > --with-xml2-config=/usr/bin/xml2-config \ > --with-httpd=/usr/sbin/httpd \ > --with-warnings \ > --with-php=/usr/include/php \ > > Configure Report returned: > MapServer is now configured for > > -------------- Compiler Info ------------- > C compiler: gcc -g -O2 -fPIC -Wall > C++ compiler: g++ -g -O2 -fPIC -Wall > Debug: -g -DNEED_NONBLOCKING_STDERR > Generic NINT: > > -------------- Renderer Settings --------- > zlib support: -DUSE_ZLIB > png support: > palette rgba png support: > jpeg support: -DUSE_JPEG > iconv support: -DUSE_ICONV > AGG support: > AGG Freetype support: > Ming(flash) support: > PDFLib support: > > -------------- Support Libraries --------- > Proj.4 support: > Libxml2 support: > FriBidi support: > Curl support: > FastCGI support: > Threading support: > GEOS support: > > -------------- Data Format Drivers ------- > native tiff support: -DUSE_TIFF > PostGIS support: > EPPL7 support: -DUSE_EPPL > ArcSDE support: > OGR support: > GDAL support: > Oracle Spatial support: > > -------------- OGC Services -------------- > WMS Server: > WMS Client: > WFS Server: > WFS Client: > WCS Server: > SOS Server: > > -------------- MapScript ----------------- > PHP MapScript: no > > Error Messages from configure: > ./myconfigure.sh: line 8: --with-gd: command not found > ./myconfigure.sh: line 23: --with-httpd=/usr/sbin/httpd: No > such file > or directory > ./myconfigure.sh: line 25: --with-php=/usr/include/php: No such > file > or directory > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > Did you by chance edit myconfigure.sh in windows? Leave around some > carriage returns or something? Got extra spaces/tabs after the \ ? > > like: > --with-libiconv=/usr \{tab} > > > -Andy > > And so it works or it does not? Assuming it does not: if you make it all on one line, does it work? -Andy From Michelle.Douville at gov.bc.ca Mon Jul 20 09:30:26 2009 From: Michelle.Douville at gov.bc.ca (Douville, Michelle R ILMB:EX) Date: Mon, 20 Jul 2009 09:30:26 -0700 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. Message-ID: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> Hello List, I am currently using Mapserver 5.2 on Windows Server 2003. () We have just observed, that when we publish a shapefile that has two features.. With FID = 0 and FID =1, it only displays the feature with FID = 1.. (for other Shapefiles it is all features greater than 0 only) For some reason it seems to skip the feature if FID = 0 Has anyone else come across this before? Is there a work around? (Other than editing the Shapefile), Many thanks, Michelle ########## # Purpose: Mapserver Shapefile Repository Service # Author: Michelle Douville # Date: 20090217 # ######### MAP EXTENT 200000 200000 1900000 1900000 SIZE 100 100 #default image size UNITS meters SYMBOLSET "e:\sw_nt\mapfiles\symbols.sym" FONTSET "e:\sw_nt\mapfiles\fonts.lst" SHAPEPATH "E:\inetpub\wwwroot\imf\upload" DEBUG 5 CONFIG "MS_ERRORFILE" "test.log" IMAGETYPE png IMAGECOLOR 0 0 0 OUTPUTFORMAT NAME aggpng24 DRIVER AGG/PNG MIMETYPE "image/png" IMAGEMODE RGBA EXTENSION "png" END WEB METADATA WMS_TITLE "User uploaded data" WMS_ABSTRACT "Temporary service based on user uploaded data." WMS_ONLINERESOURCE "http://server/mapserver/mapserv.exe?service=wms&map=E:/inetpub/wwwroot/ imf/upload/shp32973.map&" wms_srs "EPSG:3785 EPSG:102190 EPSG:26907 EPSG:26707 EPSG:32607 EPSG:3005 EPSG:42102 EPSG:4269 EPSG:4326 EPSG:26708 EPSG:26709 EPSG:26710 EPSG:26711 EPSG:26712 EPSG:26908 EPSG:26909 EPSG:26910 EPSG:26911 EPSG:26912 EPSG:32608 EPSG:32609 EPSG:32610 EPSG:32611 EPSG:32612 EPSG:54004" wfs_srs "EPSG:3785 EPSG:102190 EPSG:26907 EPSG:26707 EPSG:32607 EPSG:3005 EPSG:42102 EPSG:4269 EPSG:4326 EPSG:26708 EPSG:26709 EPSG:26710 EPSG:26711 EPSG:26712 EPSG:26908 EPSG:26909 EPSG:26910 EPSG:26911 EPSG:26912 EPSG:32608 EPSG:32609 EPSG:32610 EPSG:32611 EPSG:32612 EPSG:54004" wfs_maxfeatures "0" wms_accessconstraints " " wms_fees "None" END IMAGEPATH "E:/server/wwwroot/imf/pdf/" IMAGEURL "http://server/imf/pdf/" END PROJECTION "init=epsg:3005" END LAYER NAME "shp32973" DATA shp32973 TYPE POLYGON LABELITEM "IMF_ID" CLASS NAME "IMF_ID" STYLE OUTLINECOLOR 0 0 0 END #end style LABEL COLOR 255 0 0 FONT arial TYPE truetype SIZE 7 POSITION cc PARTIALS FALSE BUFFER 1 #BACKGROUNDCOLOR 254 254 254 OUTLINECOLOR 254 254 254 FORCE true END # end label END #end class STATUS ON PROJECTION "init=EPSG:3005" END METADATA "wms_title" "test" ## REQUIRED "wfs_title" "test" ## REQUIRED "gml_featureid" "IMF_ID" ## REQUIRED "ows_include_items" "all" ## Optional (serves all attributes for layer) "gml_geometries" "shape" "gml_geom_type" "polygon" "gml_exclude_items" "GEOMETRY,OBJECTID" END #metadata DUMP TRUE TEMPLATE "foo.html" #MINSCALEDENOM 0 #MAXSCALEDENOM 1500000 END #end layer END -------------- next part -------------- An HTML attachment was scrubbed... URL: From jmckenna at gatewaygeomatics.com Mon Jul 20 09:58:00 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 20 Jul 2009 13:58:00 -0300 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> Message-ID: <4A64A218.9090809@gatewaygeomatics.com> Douville, Michelle R ILMB:EX wrote: > Hello List, > > I am currently using Mapserver 5.2 on Windows Server 2003. > > () > > We have just observed, that when we publish a shapefile that has two > features.. > > With FID = 0 and FID =1, it only displays the feature with FID = 1.. > (for other Shapefiles it is all features greater than 0 only) > > For some reason it seems to skip the feature if FID = 0 > > Has anyone else come across this before? > > Is there a work around? (Other than editing the Shapefile), > > Many thanks, > Hello Michelle, I have never seen your issue before. Test your mapfile with a shp2img command - does your problem still occur (in the resulting map image)? Or are you saying that this only occurs when you consume your mapfile through a WMS client? -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From mrdouville at shaw.ca Mon Jul 20 10:31:04 2009 From: mrdouville at shaw.ca (Michelle Douville) Date: Mon, 20 Jul 2009 10:31:04 -0700 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. Message-ID: Hello List, ? I am currently using Mapserver 5.2 on Windows Server 2003. () ? We have just observed,? that when we publish a shapefile that has two features.. With FID = 0 and FID =1, it only displays the feature with FID = 1.. (for other Shapefiles it is all features greater than 0 only) ? For some reason it seems to skip the feature if FID = 0 Has anyone else come across this before? ? Is there a work around? (Other than editing the Shapefile), ? Many thanks, Michelle ? ? ########## # Purpose: Mapserver Shapefile Repository Service # Author:? Michelle Douville # Date:??? 20090217 # ######### ? MAP ? EXTENT 200000 200000 1900000 1900000 ? SIZE 100 100 #default image size ? UNITS meters ? SYMBOLSET "e:\sw_nt\mapfiles\symbols.sym" ? FONTSET "e:\sw_nt\mapfiles\fonts.lst" ? SHAPEPATH "E:\inetpub\wwwroot\imf\upload" ? ?DEBUG 5 ?CONFIG? "MS_ERRORFILE" "test.log" ? ? IMAGETYPE png ? IMAGECOLOR 0 0 0 ? ? OUTPUTFORMAT ??? NAME aggpng24 ??? DRIVER AGG/PNG ??? MIMETYPE "image/png" ??? IMAGEMODE RGBA ??? EXTENSION "png" ? END ? ? WEB ? METADATA ??? WMS_TITLE "User uploaded data"??? WMS_ABSTRACT "Temporary service based on user uploaded data." ??? WMS_ONLINERESOURCE "http://server/mapserver/mapserv.exe?service=wms&map=E:/inetpub/wwwroot/imf/upload/shp32973.map&" ??? wms_srs "EPSG:3785 EPSG:102190 EPSG:26907 EPSG:26707 EPSG:32607 EPSG:3005 EPSG:42102 EPSG:4269 EPSG:4326 EPSG:26708 EPSG:26709 EPSG:26710 EPSG:26711 EPSG:26712 EPSG:26908 EPSG:26909 EPSG:26910 EPSG:26911 EPSG:26912 EPSG:32608 EPSG:32609 EPSG:32610 EPSG:32611 EPSG:32612 EPSG:54004" ??? wfs_srs "EPSG:3785 EPSG:102190 EPSG:26907 EPSG:26707 EPSG:32607 EPSG:3005 EPSG:42102 EPSG:4269 EPSG:4326 EPSG:26708 EPSG:26709 EPSG:26710 EPSG:26711 EPSG:26712 EPSG:26908 EPSG:26909 EPSG:26910 EPSG:26911 EPSG:26912 EPSG:32608 EPSG:32609 EPSG:32610 EPSG:32611 EPSG:32612 EPSG:54004" ??? wfs_maxfeatures "0" ??? wms_accessconstraints " " ??? wms_fees "None" ? END ? ? IMAGEPATH "E:/server/wwwroot/imf/pdf/" ? IMAGEURL "http://server/imf/pdf/" ? END ? PROJECTION ? "init=epsg:3005" END ? ??? ? LAYER ??? NAME "shp32973" ??? DATA shp32973 ??? TYPE POLYGON ??? ? ??? LABELITEM "IMF_ID" ??????? CLASS ????????? NAME "IMF_ID" ????????? STYLE ??????????? OUTLINECOLOR 0 0 0 ????????? END #end style ????????? LABEL ??????????? COLOR 255 0 0 ??????????? FONT arial ??????????? TYPE truetype ??????????? SIZE 7 ??????????? POSITION cc ??????????? PARTIALS FALSE ??????????? BUFFER 1 ??????????? #BACKGROUNDCOLOR 254 254 254 ??????????? OUTLINECOLOR 254 254 254 ??????????? FORCE true????? ?????????? END # end label ??? END #end class ??? ??? ??? STATUS ON ??? PROJECTION ????? "init=EPSG:3005" ??? END ??? ????? ??? METADATA ????? "wms_title"??? "test" ## REQUIRED ???? "wfs_title"??? "test" ## REQUIRED ???? "gml_featureid" "IMF_ID" ## REQUIRED ???? "ows_include_items" "all"? ## Optional (serves all attributes for layer) ???? "gml_geometries" "shape" ???? "gml_geom_type" "polygon" ???? "gml_exclude_items" "GEOMETRY,OBJECTID" ????????? ??? END #metadata ??? ??? DUMP TRUE ??? TEMPLATE "foo.html" ??? #MINSCALEDENOM 0 ??? #MAXSCALEDENOM 1500000 ? END #end layer ? ? ? END ? -------------- next part -------------- An HTML attachment was scrubbed... URL: From mrdouville at shaw.ca Mon Jul 20 10:35:48 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Mon, 20 Jul 2009 10:35:48 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <4A64A218.9090809@gatewaygeomatics.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> Message-ID: <1248111348949-3290374.post@n2.nabble.com> Hi Jeff, thanks for the quick reply.. I haven't tried the shp2img.. My tests are through WMS only.. Jeff McKenna wrote: > > Douville, Michelle R ILMB:EX wrote: >> Hello List, >> >> I am currently using Mapserver 5.2 on Windows Server 2003. >> >> () >> >> We have just observed, that when we publish a shapefile that has two >> features.. >> >> With FID = 0 and FID =1, it only displays the feature with FID = 1.. >> (for other Shapefiles it is all features greater than 0 only) >> >> For some reason it seems to skip the feature if FID = 0 >> >> Has anyone else come across this before? >> >> Is there a work around? (Other than editing the Shapefile), >> >> Many thanks, >> > > Hello Michelle, > > I have never seen your issue before. Test your mapfile with a shp2img > command - does your problem still occur (in the resulting map image)? > Or are you saying that this only occurs when you consume your mapfile > through a WMS client? > > -jeff > > > > -- > Jeff McKenna > FOSS4G Consulting and Training Services > http://www.gatewaygeomatics.com/ > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3290374.html Sent from the Mapserver - User mailing list archive at Nabble.com. From mrdouville at shaw.ca Mon Jul 20 11:23:10 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Mon, 20 Jul 2009 11:23:10 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1248111348949-3290374.post@n2.nabble.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> Message-ID: <1248114190840-3290653.post@n2.nabble.com> I was able to create a png from MAPSERVER 4.10 / SHP2IMG.. and it does show both features.. (see image .. http://n2.nabble.com/file/n3290653/test.png When I attempt to run MAPSERVER 5.2 / SHP2IMG .. I get this.. http://n2.nabble.com/file/n3290653/Capture.jpg Perhaps it is my compiled version.. thanks, Michelle -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3290653.html Sent from the Mapserver - User mailing list archive at Nabble.com. From David.Fawcett at state.mn.us Mon Jul 20 11:33:05 2009 From: David.Fawcett at state.mn.us (Fawcett, David) Date: Mon, 20 Jul 2009 13:33:05 -0500 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1248114190840-3290653.post@n2.nabble.com> Message-ID: <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> What do you get when you run ogrinfo against the shapefile? David. -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Michelle Douvil Sent: Monday, July 20, 2009 1:23 PM To: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] Shapefile with first FID = 0 not showing.. I was able to create a png from MAPSERVER 4.10 / SHP2IMG.. and it does show both features.. (see image .. http://n2.nabble.com/file/n3290653/test.png When I attempt to run MAPSERVER 5.2 / SHP2IMG .. I get this.. http://n2.nabble.com/file/n3290653/Capture.jpg Perhaps it is my compiled version.. thanks, Michelle -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289 974p3290653.html Sent from the Mapserver - User mailing list archive at Nabble.com. _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From mrdouville at shaw.ca Mon Jul 20 12:04:36 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Mon, 20 Jul 2009 12:04:36 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> Message-ID: <1248116676077-3290900.post@n2.nabble.com> Results of OGRINFO.. E:\apps_data\mapserverutils>ogrinfo -so E:\inetpub\wwwroot\imf\upload INFO: Open of `E:\inetpub\wwwroot\imf\upload' using driver `ESRI Shapefile' successful. 1: shp32973 (Polygon) E:\apps_data\mapserverutils>ogrinfo -summary E:\inetpub\wwwroot\imf\upload\shp32 973.shp shp32973 INFO: Open of `E:\inetpub\wwwroot\imf\upload\shp32973.shp' using driver `ESRI Shapefile' successful. Layer name: shp32973 Geometry: Polygon Feature Count: 2 Extent: (827805.053191, 1185370.191489) - (1117390.585106, 1512564.234043) Layer SRS WKT: PROJCS["Albers Conical Equal Area", GEOGCS["GCS_North_American_1983", DATUM["North_American_Datum_1983", SPHEROID["GRS_1980",6378137.0,298.257222101]], PRIMEM["Greenwich",0.0], UNIT["Degree",0.0174532925199433]], PROJECTION["Albers_Conic_Equal_Area"], PARAMETER["False_Easting",1000000.0], PARAMETER["False_Northing",0.0], PARAMETER["longitude_of_center",-126.0], PARAMETER["Standard_Parallel_1",50.0], PARAMETER["Standard_Parallel_2",58.5], PARAMETER["latitude_of_center",45.0], UNIT["Meter",1.0]] IMF_ID: Integer (10.0) E:\apps_data\mapserverutils>ogrinfo -ro E:\inetpub\wwwroot\imf\upload\shp32973.s hp shp32973 -q Layer name: shp32973 OGRFeature(shp32973):0 IMF_ID (Integer) = 0 POLYGON ((827805.053 1512564.234,1029010.585 1512564.234,1029010.585 1379054.0 21,827805.053 1379054.021,827805.053 1512564.234)) OGRFeature(shp32973):1 IMF_ID (Integer) = 1 POLYGON ((918065.479 1330162.957,1117390.585 1330162.957,1117390.585 1185370.1 91,918065.479 1185370.191,918065.479 1330162.957)) -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3290900.html Sent from the Mapserver - User mailing list archive at Nabble.com. From mrdouville at shaw.ca Mon Jul 20 15:06:06 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Mon, 20 Jul 2009 15:06:06 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1248116676077-3290900.post@n2.nabble.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> <1248116676077-3290900.post@n2.nabble.com> Message-ID: <1248127566461-3292077.post@n2.nabble.com> Just did a test and this wasn't an issue with our version of Mapserver 4.10.. The feature with FID = 0 did display via WMS using mapserver 4.10 (same mapfile, same shapefile). -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3292077.html Sent from the Mapserver - User mailing list archive at Nabble.com. From jmckenna at gatewaygeomatics.com Mon Jul 20 15:11:17 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Mon, 20 Jul 2009 19:11:17 -0300 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1248127566461-3292077.post@n2.nabble.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> <1248116676077-3290900.post@n2.nabble.com> <1248127566461-3292077.post@n2.nabble.com> Message-ID: <4A64EB85.5060009@gatewaygeomatics.com> Michelle Douvil wrote: > Just did a test and this wasn't an issue with our version of Mapserver 4.10.. > The feature with FID = 0 did display via WMS using mapserver 4.10 (same > mapfile, same shapefile). I would download the latest MS4W[1] (with MapServer 5.4.1) and try a shp2img with your mapfile. If that correctly displays the 2 features then you know it is not a MapServer version issue. [1] www.maptools.org/ms4w -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From mrdouville at shaw.ca Mon Jul 20 15:34:56 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Mon, 20 Jul 2009 15:34:56 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <4A64EB85.5060009@gatewaygeomatics.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> <1248116676077-3290900.post@n2.nabble.com> <1248127566461-3292077.post@n2.nabble.com> <4A64EB85.5060009@gatewaygeomatics.com> Message-ID: <1248129296203-3292192.post@n2.nabble.com> Thanks Jeff.. I download the Stable setup.exe Installer for MS4W. Which installed the ms4w-2.3.1-setup.exe 142 KB (contains MapServer 5.2.1). And it worked properly.. Both polygon features were displayed. I am not sure what could be the issue, but I believe it may be related to our compiled version MapServer version 5.2.0 Regards, Michelle -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3292192.html Sent from the Mapserver - User mailing list archive at Nabble.com. From adrian_gh.popa at romtelecom.ro Tue Jul 21 01:32:25 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 21 Jul 2009 11:32:25 +0300 Subject: [mapserver-users] Performance in regular expressions or analternative way to select a list of features In-Reply-To: <4A604CE0.3090704@romtelecom.ro> References: <4A5C2277.80204@romtelecom.ro> <4A5C5216.5157.008F.0@dnr.state.mn.us> <4A5D740D.10605@romtelecom.ro> <4A604CE0.3090704@romtelecom.ro> Message-ID: <4A657D19.9050105@romtelecom.ro> Just for reference: I tried to select about 130 items using a regular expression in the form of EXPRESSION (/^ITEM1|ITEM2|ITEM3|...|ITEM130$/) and rendering took about 4.5-5 seconds. I tried to select the exact same 130 items using "IN" syntax: EXPRESSION ("[myfield]" IN "ITEM1,ITEM2,ITEM3,...,ITEM130") and the query took about 8.5-9 seconds. The tests were run several times in the same conditions - so the relative results should be relevant. So - performance favors regular expressions :) Adrian Popa wrote: > Here's how I "fixed" this issue. I ended up regenerating the shapefile > and dbf and adding a separate column with the grouping I desired. Now, > my map file selects from that column, and the syntax is much simpler > (by one or two orders of magnitude). I am happy with the results, > however, I didn't get the chance to try out all the other methods > because of lack of time. > > Thanks again, > Adrian > > Adrian Popa wrote: >> Hello Steve, >> >> I haven't tried out the simplified regex so I don't know if it will >> be faster. I will try to test it as part of a speed test of the >> various methods... >> >> I'm not sure what you mean by writing a temporary set of geometries. >> Do you mean adding an index to my data so that I can select it by a >> different (grouping) field instead? Unfortunately I can't do that >> because the same item can be part of 10-20 groups, so there would not >> be an easy way to group items apart from duplicating them in the >> shapefile/dbf. I'm not sure if there's a problem if the same feature >> appears 12 times in the same shapefile. >> >> In the end data reorganizing might be the fastest method available. >> Problem is some items will belong to groups dinamically, so I will >> have to implement a selection mechanism based on item id... >> >> Regards, >> Adrian >> >> Steve Lime wrote: >>> Have you tried a simplified version of your regex? I think you can do: >>> >>> EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ >>> >>> You might also consider writing a temporary set of geometries if a user will continually display from >>> that set. In that case your overhead would be in managing the set of features which would be higher >>> the first time but then very fast to render. Your dynamic portion of the mapfile would reference the >>> temporary data. >>> >>> Steve >>> >>> >>>>>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian Popa >>>>>> >>> wrote: >>> >>>> Hello everyone, >>>> >>>> Here's my problem: I'm trying to highlight segments from a line layer by >>>> using an expression in a specific class. This portion of the mapfile is >>>> dynamically generated and when it is done, it is sent to mapserver for >>>> rendering. >>>> My problem is that I have to select between 10 - 400 features at a time >>>> and I noticed when I have a lot of features there is a severe >>>> performance degradation in mapserver (takes a lot of time to render or >>>> even times out). >>>> Right now, my expression is built using regular expressions: something like: >>>> *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* >>>> This works ok, but as I said has a performance penalty when you reach >>>> ~400 items. My data is selected from a shapefile layer which has about >>>> 5500 items. >>>> >>>> Since I wouldn't be using the regular expressions at full capacity (I'm >>>> matching the full name), I might rewrite the expression using something >>>> like: >>>> *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR >>>> ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* >>>> >>>> From the documentation I see that: >>>> /Regular expression with MapServer work similarly to string comparison, >>>> but allow more complex operation. They are slower than pure string >>>> comparisons, but might be still faster than logical expression. As with >>>> the string comparison use regular expressions, a FILTERITEM or a >>>> CLASSITEM has to defined, respectively. >>>> >>>> /I would like to know if there is an efficient way of selecting a list >>>> of elements from a layer, or what are your recommendations. >>>> >>>> Also - have there been significant changes in performance for this issue >>>> from mapserver 4.10 (I am now migrating to mapserver 5.4)? >>>> >>>> Thanks, >>>> Adrian >>>> >>> >>> >>> >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- --- Adrian Popa NOC Division Network Engineer Divizia Centrul National de Operare Retea Departament Transport IP & Metro Compartiment IP Core & Backbone Phone: +40 21 400 3099 -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Tue Jul 21 01:59:58 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 21 Jul 2009 11:59:58 +0300 Subject: [mapserver-users] Problems when using complex expressions Message-ID: <4A65838E.6050404@romtelecom.ro> Hello everyone, I'm trying to filter items by using a regular expression and a string/number comparison. Here's what works, and what doesnt: EXPRESSION (/MYREGEXP/i) -> doesn't work (doesn't match anything) EXPRESSION /MYREGEXP/i -> works EXPRESSION "[myColumn]" ==1 -> doesn't work (loadClass(): Unknown identifier. Parsing error near (=)) EXPRESSION ("[myColumn]" ==1) -> doesn't work (doesn't match anything) EXPRESSION ("[myColumn]" eq "1") -> works EXPRESSION (/MYREGEXP/i) && ("[myColumn]" eq "1") -> doesn't work (doesn't match anything) EXPRESSION /MYREGEXP/i && ("[myColumn]" eq "1") -> doesn't work (loadClass(): Unknown identifier. Parsing error near (&)) EXPRESSION ((/MYREGEXP/i) && ("[myColumn]" eq "1")) -> doesn't work (doesn't match anything) I have checked my data and it should match - most likely, my expression is wrong. Any suggestions? What is the correct syntax for mixing regular expressions with other values? Thanks, Adrian From andreas.albarello at territoriumonline.com Tue Jul 21 02:21:09 2009 From: andreas.albarello at territoriumonline.com (Andreas Albarello) Date: Tue, 21 Jul 2009 11:21:09 +0200 Subject: [mapserver-users] Problems when using complex expressions In-Reply-To: <4A65838E.6050404@romtelecom.ro> References: <4A65838E.6050404@romtelecom.ro> Message-ID: <4A658885.4050101@territoriumonline.com> Adrian Popa wrote: > EXPRESSION (/MYREGEXP/i) -> doesn't work (doesn't match anything) > EXPRESSION /MYREGEXP/i -> works > EXPRESSION "[myColumn]" ==1 -> doesn't work (loadClass(): Unknown > identifier. Parsing error near (=)) > EXPRESSION ("[myColumn]" ==1) -> doesn't work (doesn't match anything) > EXPRESSION ("[myColumn]" eq "1") -> works > > EXPRESSION (/MYREGEXP/i) && ("[myColumn]" eq "1") -> doesn't work > (doesn't match anything) > EXPRESSION /MYREGEXP/i && ("[myColumn]" eq "1") -> doesn't work > (loadClass(): Unknown identifier. Parsing error near (&)) > EXPRESSION ((/MYREGEXP/i) && ("[myColumn]" eq "1")) -> doesn't work > (doesn't match anything) > > I have checked my data and it should match - most likely, my expression > is wrong. Any suggestions? What is the correct syntax for mixing regular > expressions with other values? Adrian, have a look at this: http://mapserver.org/mapfile/expressions.html As far as mixing regular and other expressions goes, this is the correct way to do it: EXPRESSION (("[myColumn]" =~ /MYREGEXP/i) && ("[myColumn]" eq "1")) Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi Str. 12 I 39100 Bolzano/Bozen Phone: +39 0471 068611 Fax: +39 0471 068619 email: andreas.albarello at territoriumonline.com web: http://www.territoriumonline.com -------------------------------------------------------------------- From adrian_gh.popa at romtelecom.ro Tue Jul 21 03:35:12 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 21 Jul 2009 13:35:12 +0300 Subject: [mapserver-users] Problems when using complex expressions In-Reply-To: <4A658885.4050101@territoriumonline.com> References: <4A65838E.6050404@romtelecom.ro> <4A658885.4050101@territoriumonline.com> Message-ID: <4A6599E0.20409@romtelecom.ro> Thanks, Andreas, I've tried your solution (and already looked over the manual) but it still doesn't match anything... Also - EXPRESSION ("[myColumn]" =~ /MYREGEXP/i) doesn't match anything and EXPRESSION "[myColumn]" =~ /MYREGEXP/i complains of a syntax error. myColumn is the exact same thing as what I use in the layer's CLASSITEM definition. I am puzzled... I think I'm using the EXPRESSION syntax the wrong way, but I'm not sure what I'm doing wrong. Regards, Adrian Andreas Albarello wrote: > Adrian Popa wrote: >> EXPRESSION (/MYREGEXP/i) -> doesn't work (doesn't match anything) >> EXPRESSION /MYREGEXP/i -> works >> EXPRESSION "[myColumn]" ==1 -> doesn't work (loadClass(): Unknown >> identifier. Parsing error near (=)) >> EXPRESSION ("[myColumn]" ==1) -> doesn't work (doesn't match anything) >> EXPRESSION ("[myColumn]" eq "1") -> works >> >> EXPRESSION (/MYREGEXP/i) && ("[myColumn]" eq "1") -> doesn't work >> (doesn't match anything) >> EXPRESSION /MYREGEXP/i && ("[myColumn]" eq "1") -> doesn't work >> (loadClass(): Unknown identifier. Parsing error near (&)) >> EXPRESSION ((/MYREGEXP/i) && ("[myColumn]" eq "1")) -> doesn't work >> (doesn't match anything) >> >> I have checked my data and it should match - most likely, my >> expression is wrong. Any suggestions? What is the correct syntax for >> mixing regular expressions with other values? > > Adrian, > > have a look at this: http://mapserver.org/mapfile/expressions.html > > As far as mixing regular and other expressions goes, this is the > correct way to do it: > > EXPRESSION (("[myColumn]" =~ /MYREGEXP/i) && ("[myColumn]" eq "1")) > > Best regards, From adrian_gh.popa at romtelecom.ro Tue Jul 21 05:19:21 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Tue, 21 Jul 2009 15:19:21 +0300 Subject: [mapserver-users] Problems when using complex expressions In-Reply-To: <4A6599E0.20409@romtelecom.ro> References: <4A65838E.6050404@romtelecom.ro> <4A658885.4050101@territoriumonline.com> <4A6599E0.20409@romtelecom.ro> Message-ID: <4A65B249.7020906@romtelecom.ro> I managed to find a workaround for my problem: I used a FILTER statement in the layer definition and an EXPRESSION in my classes: LAYER ... FILTERITEM "myColumn1" FILTER /MYREGEXP/i CLASS NAME "Test" EXPRESSION ( "[myColumn2]" eq "1" ) .... END END This configuration seems to work - I will test it some more... If anywone has an idea why the previous examples didn't work - I'd be happy to hear it out... Regards, Adrian Adrian Popa wrote: > Thanks, Andreas, > > I've tried your solution (and already looked over the manual) but it > still doesn't match anything... > > Also - EXPRESSION ("[myColumn]" =~ /MYREGEXP/i) doesn't match anything > and EXPRESSION "[myColumn]" =~ /MYREGEXP/i complains of a syntax error. > > myColumn is the exact same thing as what I use in the layer's > CLASSITEM definition. > > I am puzzled... I think I'm using the EXPRESSION syntax the wrong way, > but I'm not sure what I'm doing wrong. > > Regards, > Adrian > > Andreas Albarello wrote: >> Adrian Popa wrote: >>> EXPRESSION (/MYREGEXP/i) -> doesn't work (doesn't match anything) >>> EXPRESSION /MYREGEXP/i -> works >>> EXPRESSION "[myColumn]" ==1 -> doesn't work (loadClass(): Unknown >>> identifier. Parsing error near (=)) >>> EXPRESSION ("[myColumn]" ==1) -> doesn't work (doesn't match anything) >>> EXPRESSION ("[myColumn]" eq "1") -> works >>> >>> EXPRESSION (/MYREGEXP/i) && ("[myColumn]" eq "1") -> doesn't work >>> (doesn't match anything) >>> EXPRESSION /MYREGEXP/i && ("[myColumn]" eq "1") -> doesn't work >>> (loadClass(): Unknown identifier. Parsing error near (&)) >>> EXPRESSION ((/MYREGEXP/i) && ("[myColumn]" eq "1")) -> doesn't work >>> (doesn't match anything) >>> >>> I have checked my data and it should match - most likely, my >>> expression is wrong. Any suggestions? What is the correct syntax for >>> mixing regular expressions with other values? >> >> Adrian, >> >> have a look at this: http://mapserver.org/mapfile/expressions.html >> >> As far as mixing regular and other expressions goes, this is the >> correct way to do it: >> >> EXPRESSION (("[myColumn]" =~ /MYREGEXP/i) && ("[myColumn]" eq "1")) >> >> Best regards, > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From andreas.albarello at territoriumonline.com Tue Jul 21 06:02:21 2009 From: andreas.albarello at territoriumonline.com (Andreas Albarello) Date: Tue, 21 Jul 2009 15:02:21 +0200 Subject: [mapserver-users] Problems when using complex expressions In-Reply-To: <4A6599E0.20409@romtelecom.ro> References: <4A65838E.6050404@romtelecom.ro> Message-ID: <4A65BC5D.70409@territoriumonline.com> Adrian Popa wrote: > Thanks, Andreas, > > I've tried your solution (and already looked over the manual) but it > still doesn't match anything... > > Also - EXPRESSION ("[myColumn]" =~ /MYREGEXP/i) doesn't match anything > and EXPRESSION "[myColumn]" =~ /MYREGEXP/i complains of a syntax error. Adrian, brackets are always required around expressions like that, so that explains why the second example you posted doesn't work. The first one, however, should. I'll admit, though, that I've never used it with the /i (case-insensitive, I guess) at the end. Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi Str. 12 I 39100 Bolzano/Bozen Phone: +39 0471 068611 Fax: +39 0471 068619 email: andreas.albarello at territoriumonline.com web: http://www.territoriumonline.com -------------------------------------------------------------------- From Steve.Lime at dnr.state.mn.us Tue Jul 21 10:35:09 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 21 Jul 2009 12:35:09 -0500 Subject: [mapserver-users] FOSS4G Abstracts announced + Early Bird registration looming Message-ID: <4A65B5FD.5157.008F.0@dnr.state.mn.us> = FOSS4G Abstracts announced + Early Bird registration looming = Sydney, Australia. 20 July 2009. http://2009.foss4g.org == Abstracts Announced == A comprehensive list of presentations has been announced for the international Free and Open Source Software for Geospatial conference, in Sydney, Australia, 20-23 October 2009. Abstracts presented by the world's best Developers, Policy Makers, Sponsors and Geospatial Professionals include the latest geospatial applications, standards, government programs, business processes and case studies. Topics include mobile platforms, location based applications, crowd sourcing, cloud computing, development, spatial standards, integration of cross-agency data, Spatial Data Infrastructures, Sensor Webs, Web Processing Services, Integration of Open Source and Proprietary Software and more. For the full list of quality abstracts, view: http://2009.foss4g.org/presentations/ Community participation in the abstract selection was impressive, with over 150 community members selecting 85 general track abstracts from the 183 submitted and a further 12 academic abstracts selected by 52 academic peers. == Early Bird Registration == After getting inspired from the breadth of abstracts, be sure to register for the FOSS4G conference. Early Bird registration closes in just over two weeks, on 7 August, 2009. http://2009.foss4g.org/registration/ == Upcoming milestones == * 7 Aug 2009, __Early bird registration deadline__ * 14 Sep 2009, __Completed program available__ * 20 Oct 2009, FOSS4G Workshop * 21-23 Oct 2009, FOSS4G Presentations and Tutorials * 24 Oct 2009, FOSS4G Code Sprint == Media Sponsors == * Position Magazine: http://www.positionmag.com.au/ * Asian Surveying and Mapping Newsletter: http://www.asmmag.com * Geoconnexions Magazine: http://www.geoconnexion.com/ * Directions Magazine: http://directionsmag.com/ * GIS Development: http://gisdevelopment.net/ * Baliz Media: http://www.BALIZ-MEDIA.com/ ------ For more information or to keep informed from the FOSS4G Organising Committee, join our email list or twitter feed at: http://2009.foss4g.org/contacts/ or contact: Cameron Shorter, Chair of the FOSS4G Organising Committee and Geospatial Systems Architect at LISAsoft tel +61-2-8570-5050 c a m e r o n . s h o r t e r @ l i s a s o f t . c o m From Steve.Lime at dnr.state.mn.us Tue Jul 21 10:52:09 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 21 Jul 2009 12:52:09 -0500 Subject: [mapserver-users] Performance in regular expressions or analternativeway to select a list of features In-Reply-To: <4A657D19.9050105@romtelecom.ro> References: <4A5C2277.80204@romtelecom.ro> <4A5C5216.5157.008F.0@dnr.state.mn.us> <4A5D740D.10605@romtelecom.ro> <4A604CE0.3090704@romtelecom.ro><4A604CE0.3090704@romtelecom.ro> <4A657D19.9050105@romtelecom.ro> Message-ID: <4A65B9F9.5157.008F.0@dnr.state.mn.us> Thanks for the report, not unexpected I think... Steve >>> On 7/21/2009 at 3:32 AM, in message <4A657D19.9050105 at romtelecom.ro>, Adrian Popa wrote: > Just for reference: > > I tried to select about 130 items using a regular expression in the form > of EXPRESSION (/^ITEM1|ITEM2|ITEM3|...|ITEM130$/) and rendering took > about 4.5-5 seconds. > > I tried to select the exact same 130 items using "IN" syntax: EXPRESSION > ("[myfield]" IN "ITEM1,ITEM2,ITEM3,...,ITEM130") and the query took > about 8.5-9 seconds. > > The tests were run several times in the same conditions - so the > relative results should be relevant. > > So - performance favors regular expressions :) > > > > Adrian Popa wrote: >> Here's how I "fixed" this issue. I ended up regenerating the shapefile >> and dbf and adding a separate column with the grouping I desired. Now, >> my map file selects from that column, and the syntax is much simpler >> (by one or two orders of magnitude). I am happy with the results, >> however, I didn't get the chance to try out all the other methods >> because of lack of time. >> >> Thanks again, >> Adrian >> >> Adrian Popa wrote: >>> Hello Steve, >>> >>> I haven't tried out the simplified regex so I don't know if it will >>> be faster. I will try to test it as part of a speed test of the >>> various methods... >>> >>> I'm not sure what you mean by writing a temporary set of geometries. >>> Do you mean adding an index to my data so that I can select it by a >>> different (grouping) field instead? Unfortunately I can't do that >>> because the same item can be part of 10-20 groups, so there would not >>> be an easy way to group items apart from duplicating them in the >>> shapefile/dbf. I'm not sure if there's a problem if the same feature >>> appears 12 times in the same shapefile. >>> >>> In the end data reorganizing might be the fastest method available. >>> Problem is some items will belong to groups dinamically, so I will >>> have to implement a selection mechanism based on item id... >>> >>> Regards, >>> Adrian >>> >>> Steve Lime wrote: >>>> Have you tried a simplified version of your regex? I think you can do: >>>> >>>> EXPRESSION /^ITEM1|ITEM2|ITEM3|ITEM4$/ >>>> >>>> You might also consider writing a temporary set of geometries if a user will > continually display from >>>> that set. In that case your overhead would be in managing the set of > features which would be higher >>>> the first time but then very fast to render. Your dynamic portion of the > mapfile would reference the >>>> temporary data. >>>> >>>> Steve >>>> >>>> >>>>>>> On 7/14/2009 at 1:15 AM, in message <4A5C2277.80204 at romtelecom.ro>, Adrian > Popa >>>>>>> >>>> wrote: >>>> >>>>> Hello everyone, >>>>> >>>>> Here's my problem: I'm trying to highlight segments from a line layer by >>>>> using an expression in a specific class. This portion of the mapfile is >>>>> dynamically generated and when it is done, it is sent to mapserver for >>>>> rendering. >>>>> My problem is that I have to select between 10 - 400 features at a time >>>>> and I noticed when I have a lot of features there is a severe >>>>> performance degradation in mapserver (takes a lot of time to render or >>>>> even times out). >>>>> Right now, my expression is built using regular expressions: something like: >>>>> *EXPRESSION /^ITEM1$|^ITEM2$|^ITEM3$|^ITEM4$/* >>>>> This works ok, but as I said has a performance penalty when you reach >>>>> ~400 items. My data is selected from a shapefile layer which has about >>>>> 5500 items. >>>>> >>>>> Since I wouldn't be using the regular expressions at full capacity (I'm >>>>> matching the full name), I might rewrite the expression using something >>>>> like: >>>>> *EXPRESSION ( ([NAME]=="ITEM1") OR ([NAME]=="ITEM2") OR >>>>> ([NAME]=="ITEM3") OR ([NAME]=="ITEM4") )* >>>>> >>>>> From the documentation I see that: >>>>> /Regular expression with MapServer work similarly to string comparison, >>>>> but allow more complex operation. They are slower than pure string >>>>> comparisons, but might be still faster than logical expression. As with >>>>> the string comparison use regular expressions, a FILTERITEM or a >>>>> CLASSITEM has to defined, respectively. >>>>> >>>>> /I would like to know if there is an efficient way of selecting a list >>>>> of elements from a layer, or what are your recommendations. >>>>> >>>>> Also - have there been significant changes in performance for this issue >>>>> from mapserver 4.10 (I am now migrating to mapserver 5.4)? >>>>> >>>>> Thanks, >>>>> Adrian >>>>> >>>> >>>> >>>> >>> >>> ------------------------------------------------------------------------ >>> >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >> >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > -- > --- > Adrian Popa > NOC Division > Network Engineer > Divizia Centrul National de Operare Retea > Departament Transport IP & Metro > Compartiment IP Core & Backbone > Phone: +40 21 400 3099 From paul_everton at hotmail.com Wed Jul 22 00:55:18 2009 From: paul_everton at hotmail.com (Paul Curran) Date: Wed, 22 Jul 2009 07:55:18 +0000 Subject: [mapserver-users] Openayers - Map zoomed in to much Message-ID: Hi, I am having trouble viewing my map correctly via open layers, the map is zoomed in very close I cannot zoom out anymore. I have tried different zoom extents however it is the same. Can anyone tell me where I am going wrong is it the epsg code? If I enter a different epsg code I just see the background colour of my map file. Andy help greatly appreciated My map and openlayers files are below Thanks MAP NAME UK1 PROJECTION "init=epsg:4326" END SIZE 1600 1200 IMAGECOLOR 153 204 255 IMAGETYPE JPEG SHAPEPATH "http://localhost/openlayers/data/" EXTENT -8883850.321101 -310000.000000 15483850.321101 12710000.000000 UNITS METERS WEB TEMPLATE "http://localhost/openlayers/examples/test.html" LOG "\ms4w\tmp\ms_tmp\log.txt" IMAGEPATH "\ms4w\tmp\ms_tmp\" IMAGEURL "/ms_tmp/" METADATA 'wms_title' "wms demo" 'wcs_onlineresource' "http://127.0.0.1./cgi-bin/mapserv?map=/ms4w/apps/openlayers-2.5/data/uk1.map&" 'wms_srs' "epsg:4326 epsg:4269" END END LAYER NAME "UK" METADATA 'wms_title' "wms_demo" END STATUS DEFAULT TYPE raster TILEINDEX "map" TILEITEM "Location" PROJECTION "init=epsg:4326" END CLASS STYLE COLOR 0 0 0 END LABEL COLOR 0 0 0 SIZE SMALL END END END END MAPPING TEST
_________________________________________________________________ Share your memories online with anyone you want. http://clk.atdmt.com/UKM/go/134665338/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From c.declercq at alkante.com Wed Jul 22 01:35:13 2009 From: c.declercq at alkante.com (Charlotte Declercq) Date: Wed, 22 Jul 2009 10:35:13 +0200 Subject: [mapserver-users] Problem getting WFS results after zoom + queryByRect / PHPMapscript Message-ID: <4A66CF41.7020804@alkante.com> Hello, Here is the thing : I am adding the WFS in my map => that creates a first gml temporary file (temp1.tmp.gml). Then I am doing a zoom => creates second temporary gml file for the WFS (temp2.tmp.gml). After, when I want to do a queryByRect, I am getting the right shapeindexes but $oShape = $oLayer->getShape(0, shapeindex) doesn't return any shape because it reads the wrong GML (temp2.tmp.gml) and should read the temp1.tmp.gml that contains all the values for the gml. If a do a second queryByRect with the full extent of the map, it is ok, I get my results because the layer does point again the right GML (temp1.tmp.gml). Any ideas, advices for avoiding query the map a second time? -- Charlotte DECLERCQ ALKANTE SAS Ing?nieur R&D SIG 1, rue du Ch?ne Morand 35 510 Cesson-S?vign? Bur: + 33 (0) 2 99 22 25 70 fax : + 33 (0) 2 99 32 12 76 From andy at squeakycode.net Wed Jul 22 06:47:39 2009 From: andy at squeakycode.net (Andy Colson) Date: Wed, 22 Jul 2009 08:47:39 -0500 Subject: [mapserver-users] Openayers - Map zoomed in to much In-Reply-To: References: Message-ID: <4A67187B.50206@squeakycode.net> Paul Curran wrote: > Hi, > I am having trouble viewing my map correctly via open layers, the map is > zoomed in very close I cannot zoom out anymore. > I have tried different zoom extents however it is the same. Can anyone > tell me where I am going wrong is it the epsg code? If I enter a > different epsg code I just see the background colour of my map file. > Andy help greatly appreciated > My map and openlayers files are below > Thanks > > > MAP > > NAME UK1 > PROJECTION > "init=epsg:4326" > END > SIZE 1600 1200 > IMAGECOLOR 153 204 255 > IMAGETYPE JPEG > SHAPEPATH "http://localhost/openlayers/data/" > EXTENT -8883850.321101 -310000.000000 15483850.321101 12710000.000000 > UNITS METERS > > > WEB > TEMPLATE "http://localhost/openlayers/examples/test.html" > LOG "\ms4w\tmp\ms_tmp\log.txt" > IMAGEPATH "\ms4w\tmp\ms_tmp\" > IMAGEURL "/ms_tmp/" > METADATA > 'wms_title' "wms demo" > 'wcs_onlineresource' > "http://127.0.0.1./cgi-bin/mapserv?map=/ms4w/apps/openlayers-2.5/data/uk1.map&" > 'wms_srs' "epsg:4326 epsg:4269" > END > END > LAYER > > NAME "UK" > METADATA > 'wms_title' "wms_demo" > END > STATUS DEFAULT > TYPE raster > TILEINDEX "map" > TILEITEM "Location" > PROJECTION > "init=epsg:4326" > END > CLASS > STYLE > COLOR 0 0 0 > END > LABEL > COLOR 0 0 0 > SIZE SMALL > END > > END > > END > END > > > MAPPING TEST > > > > > >
> > > In the javascript, I set the zoom between 17 (all the way out) and 5 (zoomed in), you have zoom set to 1 so that would be way way in. Also, in the constructer add numZoomLevels, like: map = new OpenLayers.Map('map', { maxExtent: bounds, numZoomLevels: 10 }); That'll give you 10 levels to hit the + / - to zoom in/out. -Andy From bfraser at geoanalytic.com Wed Jul 22 06:53:39 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Wed, 22 Jul 2009 07:53:39 -0600 Subject: [mapserver-users] Openayers - Map zoomed in to much In-Reply-To: References: Message-ID: <4A6719E3.2040504@geoanalytic.com> Paul, The PROJECTION, EXTENT, and UNITS objects in the map file are closely related. If the PROJECTION is geographic (as yours is), you need to set the UNITS to DD and the EXTENT to something in that coordinate system, eg: PROJECTION # a spherical coordinate system "init=epsg:4326" END UNITS DD # Decimal Degrees EXTENT -11 50 2 60 # UK extent in degrees and in your Javascript: var bounds = new OpenLayers.Bounds(-11,50, 2, 60); Best Regards, Brent Fraser Paul Curran wrote: > Hi, > I am having trouble viewing my map correctly via open layers, the map is > zoomed in very close I cannot zoom out anymore. > I have tried different zoom extents however it is the same. Can anyone > tell me where I am going wrong is it the epsg code? If I enter a > different epsg code I just see the background colour of my map file. > Andy help greatly appreciated > My map and openlayers files are below > Thanks > > > MAP > > NAME UK1 > PROJECTION > "init=epsg:4326" > END > SIZE 1600 1200 > IMAGECOLOR 153 204 255 > IMAGETYPE JPEG > SHAPEPATH "http://localhost/openlayers/data/" > EXTENT -8883850.321101 -310000.000000 15483850.321101 12710000.000000 > UNITS METERS > > > WEB > TEMPLATE "http://localhost/openlayers/examples/test.html" > LOG "\ms4w\tmp\ms_tmp\log.txt" > IMAGEPATH "\ms4w\tmp\ms_tmp\" > IMAGEURL "/ms_tmp/" > METADATA > 'wms_title' "wms demo" > 'wcs_onlineresource' > "http://127.0.0.1./cgi-bin/mapserv?map=/ms4w/apps/openlayers-2.5/data/uk1.map&" > 'wms_srs' "epsg:4326 epsg:4269" > END > END > LAYER > > NAME "UK" > METADATA > 'wms_title' "wms_demo" > END > STATUS DEFAULT > TYPE raster > TILEINDEX "map" > TILEITEM "Location" > PROJECTION > "init=epsg:4326" > END > CLASS > STYLE > COLOR 0 0 0 > END > LABEL > COLOR 0 0 0 > SIZE SMALL > END > > END > > END > END > > > MAPPING TEST > > > > > >
> > > > ------------------------------------------------------------------------ > Share your memories online with anyone you want. Learn more. > > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From pauljame at gmail.com Wed Jul 22 07:49:37 2009 From: pauljame at gmail.com (Paul james) Date: Wed, 22 Jul 2009 11:49:37 -0300 Subject: [mapserver-users] [OffTopic]Convert Postgis table to MSSQL 2008 ... Message-ID: <33fad6880907220749g39aac04fv51ff23066b05a018@mail.gmail.com> Hello guys... How can I convert a Postgis table to MS SQL 2008? Paul -------------- next part -------------- An HTML attachment was scrubbed... URL: From pramsey at cleverelephant.ca Wed Jul 22 08:09:24 2009 From: pramsey at cleverelephant.ca (Paul Ramsey) Date: Wed, 22 Jul 2009 08:09:24 -0700 Subject: [mapserver-users] [OffTopic]Convert Postgis table to MSSQL 2008 ... In-Reply-To: <33fad6880907220749g39aac04fv51ff23066b05a018@mail.gmail.com> References: <33fad6880907220749g39aac04fv51ff23066b05a018@mail.gmail.com> Message-ID: <30fe546d0907220809i130488e7j54da81734198abd5@mail.gmail.com> I'd tell you, but then I'd have to kill you. (Check ogr2ogr.) On Wed, Jul 22, 2009 at 7:49 AM, Paul james wrote: > Hello guys... > How can I convert a Postgis table to MS SQL 2008? > > Paul > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > From paul_pag00 at hotmail.com Wed Jul 22 09:12:13 2009 From: paul_pag00 at hotmail.com (Paul Alarcon) Date: Wed, 22 Jul 2009 09:12:13 -0700 (PDT) Subject: [mapserver-users] doubts wms Message-ID: <1248279133597-3304257.post@n2.nabble.com> Hello everyone, i have a dout in the wms in mapserver 5.4 I made a test with a wms service in a local network and that works fine but when i load the wms in gvsig or arcgis i dont have my default extension , layer are displayed too far how i could fix this ? Thanks a lot PD : Here is my metadata for the web and layers web METADATA "LAYER_ENCODING" "UTF-8" "wms_title" "CAPAS DE CONCOPE" "wms_onlineresource" "http://192.168.5.17/cgi-bin/wmserv?map=nacional.map&" "wms_srs" "EPSG:32717" END # Metadata Layer "wms_title" "Intervencion" "wms_srs" "EPSG:32717" my projection is PROJECTION "init=epsg:32717" END -- View this message in context: http://n2.nabble.com/doubts-wms-tp3304257p3304257.html Sent from the Mapserver - User mailing list archive at Nabble.com. From marco.salvatori at witech.it Wed Jul 22 10:06:31 2009 From: marco.salvatori at witech.it (Marco Salvatori) Date: Wed, 22 Jul 2009 10:06:31 -0700 (PDT) Subject: [mapserver-users] problem on java mapscript queryByPoint Message-ID: <1248282391886-3304559.post@n2.nabble.com> Hello, I'm using java mapscript I'm confused with queryByPoint function in layerObj class. I want to query a raster layer (Arc/Info Binary Grid) from specific coordinates to check if a point is covered by the layer. The code is the follow: pointObj centerPoint = new pointObj(centerX, centerY, 0); layerObj layer = map.getLayerByName(layerName); int resQuery = layer.queryByPoint(map, centerPoint, mapscript.MS_SINGLE, 180.0); ..... calling queryByPoint with mode mapscript.MS_SINGLE is the same as I call the function with mapscript.MS_MULTIPLE. My expectation is to have only one result, but I get many resuts. I tested the same function using python mapscript and it works correctly. The question is why this does not work in Java? Thanks Marco -- View this message in context: http://n2.nabble.com/problem-on-java-mapscript-queryByPoint-tp3304559p3304559.html Sent from the Mapserver - User mailing list archive at Nabble.com. From evemar at paranacidade.org.br Wed Jul 22 12:30:55 2009 From: evemar at paranacidade.org.br (Evemar Wernick) Date: Wed, 22 Jul 2009 16:30:55 -0300 Subject: [mapserver-users] WMS client sample Message-ID: <4A6768EF.80209@paranacidade.org.br> Hi all, I'm trying to show a WMS layer in Mapserver (5.4.1). I've tried to use lots of samples from the Internet, but without success. It woks fine with some local data (shapefiles), so it's not a Mapserver/Apache problem (I'm using MS4W). I also have tested the connection url in ArcGis, and was ok. When I try to get WMS layer, it just show a blank rectangle... Does anyone could help or send me some working sample (html and .map)? Below is my last tried. Thanks, Evemar **** index.html (start)**** Mapserver WMS

Formul?rio de inicializa??o


MapFile:
**** index.html (end)**** **** web_template.html (start)**** Mapserver

Executando consultas



Legenda
Scalebar
Aproximar Mover Afastar
**** web_template.html (end)**** **** wms_test2.map (start)**** MAP NAME TEST STATUS ON SIZE 900 500 EXTENT -180 -90 180 90 UNITS DD IMAGETYPE PNG24 OUTPUTFORMAT NAME png24 DRIVER "GDAL/PNG" MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" END SHAPEPATH "/shp/" # FONTSET "/tmp/font/fontset" # projection # "init=EPSG:4326" # end SCALEBAR STATUS EMBED UNITS KILOMETERS INTERVALS 3 TRANSPARENT TRUE OUTLINECOLOR 0 0 0 END #End of SCALEBAR WEB TEMPLATE web_template.html MAXSCALE 125992916 # IMAGEPATH "/tmp/" # IMAGEURL "/tmp/" IMAGEPATH "/ms4w/tmp/ms_tmp/" IMAGEURL "/ms_tmp/" LOG "/tmp/mapserver.log" END #End of WEB layer name "da" type raster offsite 0 0 0 status DEFAULT connectiontype wms connection "http://wms.jpl.nasa.gov/wms.cgi?" metadata "wms_title" "global" "wms_srs" "EPSG:4326" "wms_name" "global_mosaic" "wms_style" "visual" "wms_server_version" "1.1.1" "wms_format" "image/jpeg" "wms_force_separate_request" "1" end projection "init=EPSG:4326" end end LAYER NAME "prov_bound" # province TYPE RASTER STATUS default CONNECTION "http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?" CONNECTIONTYPE WMS METADATA "wms_srs" "EPSG:42304" "wms_name" "prov_bound" "wms_server_version" "1.1.1" "wms_format" "image/gif" END END END #End of MAP **** wms_test2.map (end)**** **** MapServer WMS support check **** C:\ms4w\Apache\cgi-bin>mapserv -v MapServer version 5.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICO NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUP PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE From jmckenna at gatewaygeomatics.com Wed Jul 22 12:47:57 2009 From: jmckenna at gatewaygeomatics.com (Jeff McKenna) Date: Wed, 22 Jul 2009 16:47:57 -0300 Subject: [mapserver-users] WMS client sample In-Reply-To: <4A6768EF.80209@paranacidade.org.br> References: <4A6768EF.80209@paranacidade.org.br> Message-ID: <4A676CED.6010508@gatewaygeomatics.com> Evemar Wernick wrote: > Hi all, > > I'm trying to show a WMS layer in Mapserver (5.4.1). I've tried to use > lots of samples from the Internet, but without success. > It woks fine with some local data (shapefiles), so it's not a > Mapserver/Apache problem (I'm using MS4W). I also have tested the > connection url in ArcGis, and was ok. > When I try to get WMS layer, it just show a blank rectangle... > Does anyone could help or send me some working sample (html and .map)? Hello, My guess is that you're running into projection problems. Here are some quick notes: - make sure your MAP level EXTENTS match the projection defined at the MAP level - if you don't have a projection object at MAP level then add one (think of this as output projection) - make sure your WMS layer contains a projection object, in order to tell MapServer what the requested image's projection is - the EPSG code is the code that you requested from the WMS server Hope that helps. -jeff -- Jeff McKenna FOSS4G Consulting and Training Services http://www.gatewaygeomatics.com/ From aeskreis at gmail.com Wed Jul 22 15:10:17 2009 From: aeskreis at gmail.com (Adam Eskreis) Date: Wed, 22 Jul 2009 18:10:17 -0400 Subject: [mapserver-users] Symbol Image Quality Message-ID: Hello all, I am creating a symbol layer which uses images as the symbols. The images themselves are fairly high quality, however, when mapserver renders the images, they are losing a significant amount of that quality. I am using 24 bit pngs but they don't seem to get the job done. What are the other rendering alternatives that could get a better output? -Adam -------------- next part -------------- An HTML attachment was scrubbed... URL: From SansonR at asurequality.com Wed Jul 22 15:28:15 2009 From: SansonR at asurequality.com (Robert Sanson) Date: Thu, 23 Jul 2009 10:28:15 +1200 Subject: [mapserver-users] Symbol Image Quality In-Reply-To: References: Message-ID: <4A683B3F.379F.0037.0@asurequality.com> Hi Adam What pixel dimensions are your image symbols? If they are not already scaled to an appropriate size for display on a map, Mapserver has to downsample them to fit in with the overall image dimensions of your map (eg. 512x512), within which your sumbols might only occupy a very small size - say 16x16 pixels. That is likely the issue here. You need to have symbols that are clear at these sizes. Regards, Robert Sanson >>> Adam Eskreis 23/07/2009 10:10 a.m. >>> Hello all, I am creating a symbol layer which uses images as the symbols. The images themselves are fairly high quality, however, when mapserver renders the images, they are losing a significant amount of that quality. I am using 24 bit pngs but they don't seem to get the job done. What are the other rendering alternatives that could get a better output? -Adam Click here ( https://www.mailcontrol.com/sr/wQw0zmjPoHdJTZGyOCrrhg== ) to report this email as spam. ------------------------------------------------------------------ The contents of this email are confidential to AsureQuality. If you have received this communication in error please notify the sender immediately and delete the message and any attachments. The opinions expressed in this email are not necessarily those of AsureQuality. This message has been scanned for known viruses before delivery. AsureQuality supports the Unsolicited Electronic Messages Act 2007. If you do not wish to receive similar communications in future, please notify the sender of this message. ------------------------------------------------------------------ This message has been scanned for malware by SurfControl plc. www.surfcontrol.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at dnr.state.mn.us Wed Jul 22 20:55:58 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Wed, 22 Jul 2009 22:55:58 -0500 Subject: [mapserver-users] Symbol Image Quality Message-ID: <4A6798FE0200008F000265DD@co5.dnr.state.mn.us> Kinda need more info: - which version of MapServer - format of symbols (8-bit, 24-bit-, 32-bit) - which driver (GD vs AGG) - what output format parameters etc... It's safe to say there's a mismatch but with what who knows without more information. Steve >>> Adam Eskreis 07/22/09 5:18 PM >>> Hello all, I am creating a symbol layer which uses images as the symbols. The images themselves are fairly high quality, however, when mapserver renders the images, they are losing a significant amount of that quality. I am using 24 bit pngs but they don't seem to get the job done. What are the other rendering alternatives that could get a better output? -Adam From daniel.degasperi at r3-gis.com Thu Jul 23 00:41:25 2009 From: daniel.degasperi at r3-gis.com (Daniel Degasperi) Date: Thu, 23 Jul 2009 09:41:25 +0200 Subject: [mapserver-users] Querymap Message-ID: <4A681425.1010203@r3-gis.com> Hello MapServer Users, I've been using the Querymap-Feature of MapServer. As I understand the objects are highlighted by changing the color. It would be very nice to have the possibility to define other style-properties like SIZE, OUTLINECOLOR, etc. Is this possible? Best regards Daniel Degasperi -- Daniel Degasperi Software Developer daniel.degasperi at r3-gis.com --------------------------- R3 GIS Srl Via Johann Kravogl 2 I-39010 Merano - Sinigo (BZ) Tel. +39 0473 494949 Fax. +39 0473 069902 Web http://www.r3-gis.com ----------------------------- From bicphuongonline at yahoo.com Thu Jul 23 05:21:46 2009 From: bicphuongonline at yahoo.com (Mr. Bic Phuong) Date: Thu, 23 Jul 2009 05:21:46 -0700 (PDT) Subject: [mapserver-users] msConvertWideStringToUTF8(): General error message. Encoding not supported by libiconv (UTF-16LE) Message-ID: <523072.24105.qm@web35101.mail.mud.yahoo.com> I hope someone can solve this problem, our project is delayed by this error. the GetFeatureInfo function is failed: msConvertWideStringToUTF8(): General error message. Encoding not supported by libiconv (UTF-16LE) this error accured when I'm setting up a webgis on the second Red Hat Enterprise Linux (RHEL) 5.3, on the first RHEL 5.3, GetFeatureInfo is working perfect. Some other info:(the same for both 2 server) - Database server: oracle 10g - ArcSDE 9.2 - Mapserver 5.4.1 - Libiconv 1.13 - Database encoding: AL32UTF16 Please help me ! -------------- next part -------------- An HTML attachment was scrubbed... URL: From evemar at paranacidade.org.br Thu Jul 23 05:47:28 2009 From: evemar at paranacidade.org.br (Evemar Wernick) Date: Thu, 23 Jul 2009 09:47:28 -0300 Subject: [mapserver-users] WMS client sample References: 4A6768EF.80209@paranacidade.org.br Message-ID: <4A685BE0.7050005@paranacidade.org.br> Evemar Wernick wrote: >/ Hi all, />/ />/ I'm trying to show a WMS layer in Mapserver (5.4.1). I've tried to use />/ lots of samples from the Internet, but without success. />/ It woks fine with some local data (shapefiles), so it's not a />/ Mapserver/Apache problem (I'm using MS4W). I also have tested the />/ connection url in ArcGis, and was ok. />/ When I try to get WMS layer, it just show a blank rectangle... />/ Does anyone could help or send me some working sample (html and .map)? / Jeff McKenna wrote: >> Hello, >> >> My guess is that you're running into projection problems. Here are some >> quick notes: >> >> - make sure your MAP level EXTENTS match the projection defined at the >> MAP level >> - if you don't have a projection object at MAP level then add one >> (think of this as output projection) >> - make sure your WMS layer contains a projection object, in order to >> tell MapServer what the requested image's projection is >> - the EPSG code is the code that you requested from the WMS server >> >> Hope that helps. >> >> -jeff >> >> >> -- >> Jeff McKenna >> FOSS4G Consulting and Training Services >> http://www.gatewaygeomatics.com/ Hi Jeff, Thanks for your help. I already tried to change projections/extents. Even following the original samples available on the Internet, it didn't work... I don't know what is wrong... So, I think it would be better if someone who have a working code could send it to me... If it still not work, could be my mapserver. Regards, Evemar -------------- next part -------------- An HTML attachment was scrubbed... URL: From dmorissette at mapgears.com Thu Jul 23 05:48:10 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Thu, 23 Jul 2009 08:48:10 -0400 Subject: [mapserver-users] msConvertWideStringToUTF8(): General error message. Encoding not supported by libiconv (UTF-16LE) In-Reply-To: <523072.24105.qm@web35101.mail.mud.yahoo.com> References: <523072.24105.qm@web35101.mail.mud.yahoo.com> Message-ID: <4A685C0A.1070504@mapgears.com> Mr. Bic Phuong wrote: > I hope someone can solve this problem, our project is delayed by this error. > the GetFeatureInfo function is failed: > > msConvertWideStringToUTF8(): General error message. Encoding not supported > by libiconv (UTF-16LE) > This error message is telling you that the libiconv library, which is used by MapServer for encoding conversions, does not support UTF-16LE on that server. You need to find out which libiconv your Mapserver was compiled with and then make sure that copy of libiconv has support for the UTF-16LE encoding. You can list the encodings supported by libiconv on a given system using "iconv -l"... make sure UTF-16LE is there. > > this error accured when I'm setting up a webgis on the second Red Hat > Enterprise Linux (RHEL) 5.3, on the first RHEL 5.3, GetFeatureInfo is > working perfect. > Look for a difference between the two servers related to libiconv. Daniel -- Daniel Morissette http://www.mapgears.com/ From dmorissette at mapgears.com Thu Jul 23 06:01:22 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Thu, 23 Jul 2009 09:01:22 -0400 Subject: [mapserver-users] msConvertWideStringToUTF8(): General error message. Encoding not supported by libiconv (UTF-16LE) In-Reply-To: <4A685C0A.1070504@mapgears.com> References: <523072.24105.qm@web35101.mail.mud.yahoo.com> <4A685C0A.1070504@mapgears.com> Message-ID: <4A685F22.7060803@mapgears.com> Daniel Morissette wrote: >> >> this error accured when I'm setting up a webgis on the second Red Hat >> Enterprise Linux (RHEL) 5.3, on the first RHEL 5.3, GetFeatureInfo is >> working perfect. >> > > Look for a difference between the two servers related to libiconv. > A few more notes: - On some systems, there may not be an separate libiconv library installed, but instead the iconv*() functions are provided by glibc. I don't know if that's the case with RHEL 5.3 or not. - If you downloaded a mapserv binary that was compiled on another system then it may be compiled with a different libiconv than the one you have on your server, and in this case the info returned by "iconv -l" may not be a good indication of the encodings supported by your copy of MapServer. Daniel -- Daniel Morissette http://www.mapgears.com/ From andy at squeakycode.net Thu Jul 23 08:17:42 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 23 Jul 2009 10:17:42 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A611FBF.9040401@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> Message-ID: <4A687F16.3070001@squeakycode.net> > Lars Lingner wrote: >> One last thought: Do you have this problem just with the layer >> "annotate_pin"? Does the labeling of other layers work as you expect? > > Hum... good question. I'll try it Monday when I get back to work. > Thanks for the help on this. > > -Andy > Ok, took longer than I thought to get back to this, but I've tried it with the roads layer and still cannot adjust the distance between labels. here is a screen shot: http://maps.camavision.com/map2.png I've changed MINDISTANCE from 9 to 900000, and the image stays the same... the labels don't move. If I set the layer.sizeunits to feet, then the font size scales with the image as I zoom in and out... I assume the font size is being set to 7 feet instead of 7 pixels? (I have label.size = 7). But still, the mindistance seems to make no difference. Also, some of the labels are being messed up, in the screen shot you can see it. And the road didnt get draw right either. hum... it occurs to me... I dont know how many different lines were used to draw 110th st. If they used multiple lines, would I get a label for each line? Casper seemed to get one label. -Andy From cnieman at dmsolutions.ca Thu Jul 23 08:24:27 2009 From: cnieman at dmsolutions.ca (Christy Nieman) Date: Thu, 23 Jul 2009 11:24:27 -0400 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A687F16.3070001@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> Message-ID: <4A6880AB.802@dmsolutions.ca> Hi, (I don't remember if this has been asked yet or not, but...) does your OpenLayers application use tiles? Is it possible the duplicate labels are actually on separate tiles? If so, you can try setting OpenLayers to single tile mode to see if this is indeed the problem. Then you can try defining PROCESSING 'LABEL_NO_CLIP=1' for the layer. Christy Andy Colson wrote: >> Lars Lingner wrote: >>> One last thought: Do you have this problem just with the layer >>> "annotate_pin"? Does the labeling of other layers work as you expect? >> >> Hum... good question. I'll try it Monday when I get back to work. >> Thanks for the help on this. >> >> -Andy >> > > Ok, took longer than I thought to get back to this, but I've tried it > with the roads layer and still cannot adjust the distance between labels. > > here is a screen shot: > > http://maps.camavision.com/map2.png > > I've changed MINDISTANCE from 9 to 900000, and the image stays the > same... the labels don't move. > > If I set the layer.sizeunits to feet, then the font size scales with > the image as I zoom in and out... I assume the font size is being set > to 7 feet instead of 7 pixels? (I have label.size = 7). But still, > the mindistance seems to make no difference. > > Also, some of the labels are being messed up, in the screen shot you > can see it. And the road didnt get draw right either. > > hum... it occurs to me... I dont know how many different lines were > used to draw 110th st. If they used multiple lines, would I get a > label for each line? Casper seemed to get one label. > > -Andy > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From dmorissette at mapgears.com Thu Jul 23 08:39:33 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Thu, 23 Jul 2009 11:39:33 -0400 Subject: [mapserver-users] msConvertWideStringToUTF8(): General error message. Encoding not supported by libiconv (UTF-16LE) In-Reply-To: <892527.90336.qm@web35105.mail.mud.yahoo.com> References: <892527.90336.qm@web35105.mail.mud.yahoo.com> Message-ID: <4A688435.4040604@mapgears.com> (Taking this back to the mapserver-users list... ) Your problem is very likely related to the use of multiple iconv copies on your system... that LD_PRELOAD doesn't smell good. Do you absolutely need to do that? Why not use the iconv that comes with glibc? You wrote that "iconv -l" lists UTF-16LE ... but are you sure that it is reporting the info for the same version of iconv that your mapserv binary is using? The only advice I can provide is make sure you *compile* your MapServer with the same copy of iconv that you run with, and that this copy of iconv does include UTF-16LE support. Daniel Mr. Bic Phuong wrote: > Dear Daniel, > > Thanks for your reply, > > 1. To prevent iconv() in glibc 2.5 I have set this line: > > export LD_PRELOAD=/usr/local/lib/preloadable_libiconv.so > > in /root/.bash_profile and > > SetEnv LD_PRELOAD /usr/local/lib/preloadable_libiconv.so > > in /etc/httpd/conf/httpd.conf > > and reboot the server but this didn't solve the problem > > 2. I found that UTF-16LE is listed in the result of the command "iconv -l" > > 3. I manual configure and make the file mapserv for first RHEL 5.3. Then > I manual configure and make the file mapserv for second RHEL 5.3. I do > not copy pre-compiled mapserv. > > I hope you can help me to solve this problem Daniel ! > > --- On *Thu, 7/23/09, Daniel Morissette //* wrote: > > > From: Daniel Morissette > Subject: Re: [mapserver-users] msConvertWideStringToUTF8(): General > error message. Encoding not supported by libiconv (UTF-16LE) > To: mapserver-users at lists.osgeo.org > Date: Thursday, July 23, 2009, 7:48 PM > > Mr. Bic Phuong wrote: > > I hope someone can solve this problem, our project is delayed by > this error. > > the GetFeatureInfo function is failed: > > > > msConvertWideStringToUTF8(): General error message. Encoding not > supported > > by libiconv (UTF-16LE) > > > > This error message is telling you that the libiconv library, which > is used by MapServer for encoding conversions, does not support > UTF-16LE on that server. > > You need to find out which libiconv your Mapserver was compiled with > and then make sure that copy of libiconv has support for the > UTF-16LE encoding. You can list the encodings supported by libiconv > on a given system using "iconv -l"... make sure UTF-16LE is there. > > > > > > this error accured when I'm setting up a webgis on the second Red Hat > > Enterprise Linux (RHEL) 5.3, on the first RHEL 5.3, GetFeatureInfo is > > working perfect. > > > > Look for a difference between the two servers related to libiconv. > > Daniel > -- Daniel Morissette > http://www.mapgears.com/ > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- Daniel Morissette http://www.mapgears.com/ _______________________________________________ mapserver-dev mailing list mapserver-dev at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-dev From andy at squeakycode.net Thu Jul 23 08:57:39 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 23 Jul 2009 10:57:39 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A6880AB.802@dmsolutions.ca> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> <4A6880AB.802@dmsolutions.ca> Message-ID: <4A688873.4060007@squeakycode.net> > Andy Colson wrote: >>> Lars Lingner wrote: >>>> One last thought: Do you have this problem just with the layer >>>> "annotate_pin"? Does the labeling of other layers work as you expect? >>> >>> Hum... good question. I'll try it Monday when I get back to work. >>> Thanks for the help on this. >>> >>> -Andy >>> >> >> Ok, took longer than I thought to get back to this, but I've tried it >> with the roads layer and still cannot adjust the distance between labels. >> >> here is a screen shot: >> >> http://maps.camavision.com/map2.png >> >> I've changed MINDISTANCE from 9 to 900000, and the image stays the >> same... the labels don't move. >> >> If I set the layer.sizeunits to feet, then the font size scales with >> the image as I zoom in and out... I assume the font size is being set >> to 7 feet instead of 7 pixels? (I have label.size = 7). But still, >> the mindistance seems to make no difference. >> >> Also, some of the labels are being messed up, in the screen shot you >> can see it. And the road didnt get draw right either. >> >> hum... it occurs to me... I dont know how many different lines were >> used to draw 110th st. If they used multiple lines, would I get a >> label for each line? Casper seemed to get one label. >> >> -Andy >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users Christy Nieman wrote: > Hi, > > (I don't remember if this has been asked yet or not, but...) does your > OpenLayers application use tiles? Is it possible the duplicate labels > are actually on separate tiles? If so, you can try setting OpenLayers > to single tile mode to see if this is indeed the problem. Then you can > try defining PROCESSING 'LABEL_NO_CLIP=1' for the layer. > > Christy > Ok, that makes a difference. Which makes sense if you think about it. Thanks for the pointer. However... http://maps.camavision.com/map3.png some of the labels came out ok, and some didnt. I removed all the lables from all other classes and if I change the font color, they all change, but they never get the backgroud. This happens regardless of the LABEL_NO_CLIP=1 setting. -Andy From andy at squeakycode.net Thu Jul 23 09:00:54 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 23 Jul 2009 11:00:54 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A6880AB.802@dmsolutions.ca> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> <4A6880AB.802@dmsolutions.ca> Message-ID: <4A688936.1090208@squeakycode.net> Christy Nieman wrote: > Hi, > > (I don't remember if this has been asked yet or not, but...) does your > OpenLayers application use tiles? Is it possible the duplicate labels > are actually on separate tiles? If so, you can try setting OpenLayers > to single tile mode to see if this is indeed the problem. Then you can > try defining PROCESSING 'LABEL_NO_CLIP=1' for the layer. > > Christy > > Andy Colson wrote: >>> Lars Lingner wrote: >>>> One last thought: Do you have this problem just with the layer >>>> "annotate_pin"? Does the labeling of other layers work as you expect? >>> >>> Hum... good question. I'll try it Monday when I get back to work. >>> Thanks for the help on this. >>> >>> -Andy >>> >> >> Ok, took longer than I thought to get back to this, but I've tried it >> with the roads layer and still cannot adjust the distance between labels. >> >> here is a screen shot: >> >> http://maps.camavision.com/map2.png >> >> I've changed MINDISTANCE from 9 to 900000, and the image stays the >> same... the labels don't move. >> >> If I set the layer.sizeunits to feet, then the font size scales with >> the image as I zoom in and out... I assume the font size is being set >> to 7 feet instead of 7 pixels? (I have label.size = 7). But still, >> the mindistance seems to make no difference. >> >> Also, some of the labels are being messed up, in the screen shot you >> can see it. And the road didnt get draw right either. >> >> hum... it occurs to me... I dont know how many different lines were >> used to draw 110th st. If they used multiple lines, would I get a >> label for each line? Casper seemed to get one label. >> >> -Andy >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users Also, note, however, it does not fix my original problem, my annotate_pin layer still has dup labels. (yes, I added the PROCESSING 'LABEL_NO_CLIP=1' to the layer). I even tryed setting OpenLayers to single tiled mode, and it still dups the labels. So looks like when I'm adding Features it gets drawn different than line layers? -Andy From Steve.Lime at dnr.state.mn.us Thu Jul 23 09:16:16 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 23 Jul 2009 11:16:16 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A688873.4060007@squeakycode.net> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> <4A6880AB.802@dmsolutions.ca><4A6880AB.802@dmsolutions.ca> <4A688873.4060007@squeakycode.net> Message-ID: <4A684680.5157.008F.0@dnr.state.mn.us> Would help if you could put together a test case for us to try. Without being familiar with your data it's hard to know what is right or wrong in the images. The label parameter MINDISTANCE is always given in pixels. In current versions it works of the centers of labels although that will change in the next release so that label size is taken into account. Anyway, MINDISTANCE is considered when two labels are from the same layer, same class and have the same exact value. Would be interesting to see your data and mapfile... Steve >>> On 7/23/2009 at 10:57 AM, in message <4A688873.4060007 at squeakycode.net>, Andy Colson wrote: >> Andy Colson wrote: >>>> Lars Lingner wrote: >>>>> One last thought: Do you have this problem just with the layer >>>>> "annotate_pin"? Does the labeling of other layers work as you expect? >>>> >>>> Hum... good question. I'll try it Monday when I get back to work. >>>> Thanks for the help on this. >>>> >>>> -Andy >>>> >>> >>> Ok, took longer than I thought to get back to this, but I've tried it >>> with the roads layer and still cannot adjust the distance between labels. >>> >>> here is a screen shot: >>> >>> http://maps.camavision.com/map2.png >>> >>> I've changed MINDISTANCE from 9 to 900000, and the image stays the >>> same... the labels don't move. >>> >>> If I set the layer.sizeunits to feet, then the font size scales with >>> the image as I zoom in and out... I assume the font size is being set >>> to 7 feet instead of 7 pixels? (I have label.size = 7). But still, >>> the mindistance seems to make no difference. >>> >>> Also, some of the labels are being messed up, in the screen shot you >>> can see it. And the road didnt get draw right either. >>> >>> hum... it occurs to me... I dont know how many different lines were >>> used to draw 110th st. If they used multiple lines, would I get a >>> label for each line? Casper seemed to get one label. >>> >>> -Andy >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > Christy Nieman wrote: > > Hi, > > > > (I don't remember if this has been asked yet or not, but...) does your > > OpenLayers application use tiles? Is it possible the duplicate labels > > are actually on separate tiles? If so, you can try setting OpenLayers > > to single tile mode to see if this is indeed the problem. Then you can > > try defining PROCESSING 'LABEL_NO_CLIP=1' for the layer. > > > > Christy > > > > > Ok, that makes a difference. Which makes sense if you think about it. > Thanks for the pointer. However... > > http://maps.camavision.com/map3.png > > some of the labels came out ok, and some didnt. I removed all the > lables from all other classes and if I change the font color, they all > change, but they never get the backgroud. > > This happens regardless of the LABEL_NO_CLIP=1 setting. > > -Andy > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From andy at squeakycode.net Thu Jul 23 09:34:40 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 23 Jul 2009 11:34:40 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A684680.5157.008F.0@dnr.state.mn.us> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> <4A6880AB.802@dmsolutions.ca><4A6880AB.802@dmsolutions.ca> <4A688873.4060007@squeakycode.net> <4A684680.5157.008F.0@dnr.state.mn.us> Message-ID: <4A689120.7070908@squeakycode.net> Steve Lime wrote: > Would help if you could put together a test case for us to try. Without being familiar with your > data it's hard to know what is right or wrong in the images. The label parameter MINDISTANCE > is always given in pixels. In current versions it works of the centers of labels although that will > change in the next release so that label size is taken into account. > > Anyway, MINDISTANCE is considered when two labels are from the same layer, same class and > have the same exact value. Would be interesting to see your data and mapfile... > > Steve > I can. What would be best for you? I can put the wms server on the outside so you can query it. Or I can send shapefiles and the mapfile. (I dont have permission to give everything to everybody, but I'd bet a select few would be ok. So I'd rater not post a download to the mailing list, but would give it to a select few.) Also, I think there are two problems: 1) some labels dont get background 2) my perl script adds features to a layer and that layer is drawn different than line layers. 1) I can get you stuff pretty easy, but 2) might be more difficult. Let me play around with it a little and see if I can make a mapfile with the features in it and see if shp2img will draw it. Thank you very much for the help, -Andy From andy at squeakycode.net Thu Jul 23 11:33:10 2009 From: andy at squeakycode.net (Andy Colson) Date: Thu, 23 Jul 2009 13:33:10 -0500 Subject: [mapserver-users] duplicate labels In-Reply-To: <4A684680.5157.008F.0@dnr.state.mn.us> References: <4A60C2D9.6090609@squeakycode.net> <4A60C90F.60601@lingner.eu> <4A60CB6B.1050504@squeakycode.net> <4A60D03C.1090509@lingner.eu> <4A60D1F2.9060207@squeakycode.net> <4A60F5CF.9020406@lingner.eu> <4A611FBF.9040401@squeakycode.net> <4A687F16.3070001@squeakycode.net> <4A6880AB.802@dmsolutions.ca><4A6880AB.802@dmsolutions.ca> <4A688873.4060007@squeakycode.net> <4A684680.5157.008F.0@dnr.state.mn.us> Message-ID: <4A68ACE6.4050509@squeakycode.net> Steve Lime wrote: > Would help if you could put together a test case for us to try. Without being familiar with your > data it's hard to know what is right or wrong in the images. The label parameter MINDISTANCE > is always given in pixels. In current versions it works of the centers of labels although that will > change in the next release so that label size is taken into account. > > Anyway, MINDISTANCE is considered when two labels are from the same layer, same class and > have the same exact value. Would be interesting to see your data and mapfile... > > Steve > Ok, after some playing I have a simple test that show's the label background problem. The dup label problem on a line layer (road names) is not a problem, the LABEL_NO_CLIP=1 fixes my problem (or using OpenLayers singleTile). The dup label problem on my annotate-pin layer is a problem. The layer seems to ignore LABEL_NO_CLIP=1. If I set OpenLayers to use singleTile then it displays correctly. I have a mapfile with the features defined inside (so no perl script is needed). shp2img displays it correctly because, I assume, it draws as one tile. I also noticed, when drawn as one tile, all the lines (roads n stuff) draw correctly, but in OpenLayers with mult-tiles, it get's messed up. One Tile: http://maps.camavision.com/map4.png Muiti-Tile: http://maps.camavision.com/map3.png I have a shape file, and a mapfile if anyone wants it, I'd prefer to send you the link privately though. -Andy From jbw2003 at earthlink.net Thu Jul 23 12:32:31 2009 From: jbw2003 at earthlink.net (jim white) Date: Thu, 23 Jul 2009 15:32:31 -0400 Subject: [mapserver-users] problem reading log/debug Message-ID: <4A68BACF.5030503@earthlink.net> I am having a problem seeing the log/debug output. In order to see the log out I have to restart the Apache server. On shutdown it outputs the log files. Besides having to restart the server I would prefer to monitor the logs in real time with tail -f logfile. I am running Mapserver version 5.4.1. My map file has this in the map section. CONFIG "MS_ERRORFILE" "stderr" DEBUG 5 Jim -- James (Jim) B. White tel: (919)-380-9615 homepage: http://jimserver.net/ From Jukka.Rahkonen at mmmtike.fi Thu Jul 23 15:09:46 2009 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Fri, 24 Jul 2009 01:09:46 +0300 Subject: [mapserver-users] problem reading log/debug References: <4A68BACF.5030503@earthlink.net> Message-ID: Hi, Change "stderr" to some filename and debug info will be written directly into that. -Jukka Rahkonen- -----Alkuper?inen viesti----- L?hett?j?: mapserver-users-bounces at lists.osgeo.org puolesta: jim white L?hetetty: to 23.7.2009 22:32 Vastaanottaja: mapserver-users at lists.osgeo.org Aihe: [mapserver-users] problem reading log/debug I am having a problem seeing the log/debug output. In order to see the log out I have to restart the Apache server. On shutdown it outputs the log files. Besides having to restart the server I would prefer to monitor the logs in real time with tail -f logfile. I am running Mapserver version 5.4.1. My map file has this in the map section. CONFIG "MS_ERRORFILE" "stderr" DEBUG 5 Jim -- James (Jim) B. White tel: (919)-380-9615 homepage: http://jimserver.net/ _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From jbw2003 at earthlink.net Thu Jul 23 15:23:22 2009 From: jbw2003 at earthlink.net (jim white) Date: Thu, 23 Jul 2009 18:23:22 -0400 Subject: [mapserver-users] problem reading log/debug In-Reply-To: References: <4A68BACF.5030503@earthlink.net> Message-ID: <4A68E2DA.9000304@earthlink.net> I can use a file instead of stderr and have the same problem - restart apache to see the logs. Jim Rahkonen Jukka wrote: > Hi, > > Change "stderr" to some filename and debug info will be written directly into that. > > -Jukka Rahkonen- > > > -----Alkuper?inen viesti----- > L?hett?j?: mapserver-users-bounces at lists.osgeo.org puolesta: jim white > L?hetetty: to 23.7.2009 22:32 > Vastaanottaja: mapserver-users at lists.osgeo.org > Aihe: [mapserver-users] problem reading log/debug > > I am having a problem seeing the log/debug output. In order to see the > log out I have to restart the Apache server. On shutdown it outputs the > log files. Besides having to restart the server I would prefer to > monitor the logs in real time with tail -f logfile. I am running > Mapserver version 5.4.1. My map file has this in the map section. > > CONFIG "MS_ERRORFILE" "stderr" > DEBUG 5 > > Jim > > -- James (Jim) B. White tel: (919)-380-9615 homepage: http://jimserver.net/ From dmorissette at mapgears.com Thu Jul 23 18:43:23 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Thu, 23 Jul 2009 21:43:23 -0400 Subject: [mapserver-users] problem reading log/debug In-Reply-To: <4A68E2DA.9000304@earthlink.net> References: <4A68BACF.5030503@earthlink.net> <4A68E2DA.9000304@earthlink.net> Message-ID: <4A6911BB.3030708@mapgears.com> jim white wrote: > I can use a file instead of stderr and have the same problem - restart > apache to see the logs. > Um... the only reason I can think of for this to happen would be if your mapserv processes hang and never close/flush the log output. Actually, are you using the mapserv CGI or MapScript? On which OS is this happening? If you built from source, you could possibly work around the problem by adding a fflush() call in msDebug() after the msIO_vfprintf() line. That could keep you going but would not solve the key issue which seems to be that your processes possibly hang or something like that. We'd need more info to help with that. Index: mapdebug.c =================================================================== --- mapdebug.c (revision 9170) +++ mapdebug.c (working copy) @@ -360,6 +360,7 @@ va_start(args, pszFormat); msIO_vfprintf(debuginfo->fp, pszFormat, args); + fflush(debuginfo->fp); va_end(args); } #ifdef _WIN32 -- Daniel Morissette http://www.mapgears.com/ From ml at lingner.eu Thu Jul 23 23:09:18 2009 From: ml at lingner.eu (Lars Lingner) Date: Fri, 24 Jul 2009 08:09:18 +0200 Subject: [mapserver-users] problem reading log/debug In-Reply-To: <4A68BACF.5030503@earthlink.net> References: <4A68BACF.5030503@earthlink.net> Message-ID: <4A69500E.9040301@lingner.eu> jim white schrieb: > I am having a problem seeing the log/debug output. In order to see the > log out I have to restart the Apache server. On shutdown it outputs the > log files. Besides having to restart the server I would prefer to > monitor the logs in real time with tail -f logfile. I am running > Mapserver version 5.4.1. My map file has this in the map section. > > CONFIG "MS_ERRORFILE" "stderr" > DEBUG 5 > Just a note, no solution: I have an installation of MapServer (a week old svn version) with fastcgi and lighttpd. There are 6 processes available. The logging isn't reliable, if I "tail -f" the log file, I don't see the messages in real time. The idle timeout is set to 20. I didn't try the restart of lighttpd. I assume that this behavior depends on my lighttpd config (and not in MapServer), but I did not put time in it to find the cause. Not sure if this helps at all, I just wanted to say something ;) Lars From gju at galigeo.com Fri Jul 24 00:58:26 2009 From: gju at galigeo.com (Galigeo) Date: Fri, 24 Jul 2009 00:58:26 -0700 (PDT) Subject: [mapserver-users] loadOutputFormat(): error AGG/PNG driver isn't configured. In-Reply-To: <9ab9b8cf0902260237h73d8200eqebd0b0f512101c4f@mail.gmail.com> References: <9ab9b8cf0902260237h73d8200eqebd0b0f512101c4f@mail.gmail.com> Message-ID: <1248422306630-3314438.post@n2.nabble.com> Hi kapilmanoj I do have actually the same problem (exept I use Ubuntu 8.04). I had to compile mapscript by myself since I use Java and Java mapscript is not pre-packaged by Ubuntu. Maybe I missed a dependency during the compilation ? Anyway, if anyone has a solution to this problem, I'd be glad to know it! Cheers, Ganael kapilmanoj wrote: > > Dear users, > > I am using mapserver 5.0.3 on fedora 9. i have been trying out the > examples > given in the mapserver 5.x tutorial. i am receiving the following error > message when attempting to use AGG Output format. i have installed AGG-2.5 > through yum install command in fedora 9.... > > error message: *loadOutputFormat(): General error message. OUTPUTFORMAT > clause references driver AGG/PNG, but this driver isn't configured. > * > > This my mapfile for your kind attention > MAP > NAME Gods own country > EXTENT 201621.496941 -294488.285333 1425518.020722 498254.511514 > # > LAEA > #EXTENT -97.5 41.619778 -82.122902 49.38562 # Geographic > SIZE 400 300 > IMAGECOLOR 255 255 255 > SHAPEPATH "/var/www/html/ms4w/aapa/tutorial/data" > SYMBOLSET "/var/www/html/ms4w/aapa/tutorial/symbols/symbols35.sym" > FONTSET "/var/www/html/ms4w/aapa/tutorial/fonts/fonts.list" > > IMAGETYPE PNG24 > > OUTPUTFORMAT > NAME png > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE PC256 > EXTENSION "png" > END > OUTPUTFORMAT > NAME png24 > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE RGBA > EXTENSION "png" > END > OUTPUTFORMAT > NAME jpeg > DRIVER "GD/JPEG" > FORMATOPTION "QUALITY=75" > MIMETYPE "image/jpeg" > IMAGEMODE RGB > EXTENSION "jpg" > END > OUTPUTFORMAT > NAME GTiff > DRIVER "GDAL/GTiff" > MIMETYPE "image/tiff" > IMAGEMODE RGB > EXTENSION "tif" > END > > OUTPUTFORMAT > NAME AGG > DRIVER "AGG/PNG" > IMAGEMODE RGB > END > OUTPUTFORMAT > NAME AGGA > DRIVER "AGG/PNG" > IMAGEMODE RGBA > END > OUTPUTFORMAT > NAME AGGJ > DRIVER "AGG/JPEG" > IMAGEMODE RGB > END > > WEB > IMAGEPATH '/tmp/ms_tmp/' > IMAGEURL '/ms_tmp/' > END > > PROJECTION > "init=epsg:2163" > END > LAYER > NAME districts > DATA parl_04 > STATUS OFF > TYPE POLYGON > > PROJECTION > "init=epsg:4326" > END > > CLASSITEM "NAME" > > CLASS > EXPRESSION 'party' > STYLE > SYMBOL 0 > COLOR 232 232 232 > END > END > END > . > . > . > . > > LAYER > NAME districts > DATA parl_04 > STATUS OFF > TYPE ANNOTATION > > PROJECTION > "init=epsg:4326" > END > > CLASSITEM "NAME" > LABELITEM "WINNER" > CLASS > EXPRESSION 'party' > STYLE > COLOR -1 -1 -1 > END > LABEL > COLOR 255 255 255 > TYPE TRUETYPE > FONT arial-bold > SIZE 12 > ANTIALIAS TRUE > POSITION CL > PARTIALS FALSE > MINDISTANCE 300 > BUFFER 4 > END # end of label > END # end of class > END # States label layer ends here > # End of LAYER DEFINITIONS ------------------------------- > > END # end of map file > > > > can anyone please help me out ..... > suggestion will be appreciated.. > > Thanks > kapilmanoj > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- View this message in context: http://n2.nabble.com/loadOutputFormat%28%29%3A-error-AGG-PNG-driver-isn%27t-configured.-tp2388899p3314438.html Sent from the Mapserver - User mailing list archive at Nabble.com. From thomas.bonfort at camptocamp.com Fri Jul 24 01:07:40 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Fri, 24 Jul 2009 10:07:40 +0200 Subject: [mapserver-users] loadOutputFormat(): error AGG/PNG driver isn't configured. In-Reply-To: <1248422306630-3314438.post@n2.nabble.com> References: <9ab9b8cf0902260237h73d8200eqebd0b0f512101c4f@mail.gmail.com> <1248422306630-3314438.post@n2.nabble.com> Message-ID: <2922382e0907240107s63b03614m2baf99c7609c6087@mail.gmail.com> what's the output of mapserv -v it should include the AGG key somewhere for agg to be supported. regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Fri, Jul 24, 2009 at 09:58, Galigeo wrote: > > Hi kapilmanoj > > I do have actually the same problem (exept I use Ubuntu 8.04). I had to > compile mapscript by myself since I use Java and Java mapscript is not > pre-packaged by Ubuntu. Maybe I missed a dependency during the compilation ? > > Anyway, if anyone has a solution to this problem, I'd be glad to know it! > > Cheers, > Ganael > > > kapilmanoj wrote: >> >> Dear users, >> >> I am using mapserver 5.0.3 on fedora 9. i have been trying out the >> examples >> given in the mapserver 5.x tutorial. i am receiving the following error >> message when attempting to use AGG Output format. i have installed AGG-2.5 >> through yum install command in fedora 9.... >> >> error message: ? *loadOutputFormat(): General error message. OUTPUTFORMAT >> clause references driver AGG/PNG, but this driver isn't configured. >> * >> >> This my mapfile for your kind attention >> MAP >> ? NAME ? ? ? ? ? Gods own country >> ? EXTENT ? ? ? ? 201621.496941 -294488.285333 1425518.020722 498254.511514 >> # >> LAEA >> ? #EXTENT ? ? ? ? -97.5 41.619778 -82.122902 49.38562 # Geographic >> ? SIZE ? ? ? ? ? 400 300 >> ? IMAGECOLOR ? ? 255 255 255 >> ? SHAPEPATH ? ? ?"/var/www/html/ms4w/aapa/tutorial/data" >> ? SYMBOLSET ? ? ?"/var/www/html/ms4w/aapa/tutorial/symbols/symbols35.sym" >> ? FONTSET ? ? ? ?"/var/www/html/ms4w/aapa/tutorial/fonts/fonts.list" >> >> ? IMAGETYPE PNG24 >> >> ? OUTPUTFORMAT >> ? ? NAME png >> ? ? DRIVER "GD/PNG" >> ? ? MIMETYPE "image/png" >> ? ? IMAGEMODE PC256 >> ? ? EXTENSION "png" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME png24 >> ? ? DRIVER "GD/PNG" >> ? ? MIMETYPE "image/png" >> ? ? IMAGEMODE RGBA >> ? ? EXTENSION "png" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME jpeg >> ? ? DRIVER "GD/JPEG" >> ? ? FORMATOPTION "QUALITY=75" >> ? ? MIMETYPE "image/jpeg" >> ? ? IMAGEMODE RGB >> ? ? EXTENSION "jpg" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME GTiff >> ? ? DRIVER "GDAL/GTiff" >> ? ? MIMETYPE "image/tiff" >> ? ? IMAGEMODE RGB >> ? ? EXTENSION "tif" >> ? END >> >> ? OUTPUTFORMAT >> ? ? NAME AGG >> ? ? DRIVER "AGG/PNG" >> ? ? IMAGEMODE RGB >> ? END >> ? OUTPUTFORMAT >> ? ? NAME AGGA >> ? ? DRIVER "AGG/PNG" >> ? ? IMAGEMODE RGBA >> ? END >> ? OUTPUTFORMAT >> ? ? NAME AGGJ >> ? ? DRIVER "AGG/JPEG" >> ? ? IMAGEMODE RGB >> ? END >> >> ? ?WEB >> ? ? IMAGEPATH '/tmp/ms_tmp/' >> ? ? IMAGEURL ?'/ms_tmp/' >> ? END >> >> ? PROJECTION >> ? ? ? ?"init=epsg:2163" >> ? END >> ? LAYER >> ? ? NAME ? ? ? ? districts >> ? ? DATA ? ? ? ? parl_04 >> ? ? STATUS ? ? ? OFF >> ? ? TYPE ? ? ? ? POLYGON >> >> ? ? PROJECTION >> ? ? ? "init=epsg:4326" >> ? ? END >> >> ? ? ?CLASSITEM ? ?"NAME" >> >> ? ? ? CLASS >> ? ? ? EXPRESSION 'party' >> ? ? ? STYLE >> ? ? ? ? SYMBOL ? ? 0 >> ? ? ? ? COLOR ? ? ?232 232 232 >> ? ? ? END >> ? ? END >> ? END >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> >> ? LAYER >> ? ? NAME ? ? ? ? districts >> ? ? DATA ? ? ? ? parl_04 >> ? ? STATUS ? ? ? OFF >> ? ? TYPE ? ? ? ? ANNOTATION >> >> ? ? PROJECTION >> ? ? ? "init=epsg:4326" >> ? ? END >> >> ? ? CLASSITEM ? ?"NAME" >> ? ? LABELITEM ? ?"WINNER" >> ? ? CLASS >> ? ? ? EXPRESSION 'party' >> ? ? ? STYLE >> ? ? ? ? COLOR ? ? ?-1 -1 -1 >> ? ? ? END >> ? ? ? LABEL >> ? ? ? ? COLOR ? ?255 255 255 >> ? ? ? ? TYPE ? ? TRUETYPE >> ? ? ? ? FONT ? ? arial-bold >> ? ? ? ? SIZE ? ? 12 >> ? ? ? ? ANTIALIAS ? ?TRUE >> ? ? ? ? POSITION ? ? CL >> ? ? ? ? PARTIALS ? ? FALSE >> ? ? ? ? MINDISTANCE ?300 >> ? ? ? ? BUFFER ? ? ? 4 >> ? ? ? END # end of label >> ? ? END # end of class >> ? END # States label layer ends here >> ? # End of LAYER DEFINITIONS ------------------------------- >> >> END # end of map file >> >> >> >> can anyone please help me out ..... >> suggestion will be appreciated.. >> >> Thanks >> kapilmanoj >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > > -- > View this message in context: http://n2.nabble.com/loadOutputFormat%28%29%3A-error-AGG-PNG-driver-isn%27t-configured.-tp2388899p3314438.html > Sent from the Mapserver - User mailing list archive at Nabble.com. > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From gju at galigeo.com Fri Jul 24 01:22:32 2009 From: gju at galigeo.com (=?iso-8859-1?Q?Gana=EBl_Jatteau?=) Date: Fri, 24 Jul 2009 10:22:32 +0200 Subject: [mapserver-users] loadOutputFormat(): error AGG/PNG driver isn't configured. In-Reply-To: <2922382e0907240107s63b03614m2baf99c7609c6087@mail.gmail.com> Message-ID: <00a801ca0c37$e4bbadc0$a301a8c0@avantias.local> Hi Thomas, Thanks for your answer. The info I get with mapserver -v is: MapServer version 5.0.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE It doesn't say anything about AGG, however it has PNG (which I believe use the same driver). Cheers, Ganael -----Message d'origine----- De?: Thomas Bonfort [mailto:thomas.bonfort at camptocamp.com] Envoy??: vendredi 24 juillet 2009 10:08 ??: Galigeo Cc?: mapserver-users at lists.osgeo.org Objet?: Re: [mapserver-users] loadOutputFormat(): error AGG/PNG driver isn't configured. what's the output of mapserv -v it should include the AGG key somewhere for agg to be supported. regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Fri, Jul 24, 2009 at 09:58, Galigeo wrote: > > Hi kapilmanoj > > I do have actually the same problem (exept I use Ubuntu 8.04). I had to > compile mapscript by myself since I use Java and Java mapscript is not > pre-packaged by Ubuntu. Maybe I missed a dependency during the compilation ? > > Anyway, if anyone has a solution to this problem, I'd be glad to know it! > > Cheers, > Ganael > > > kapilmanoj wrote: >> >> Dear users, >> >> I am using mapserver 5.0.3 on fedora 9. i have been trying out the >> examples >> given in the mapserver 5.x tutorial. i am receiving the following error >> message when attempting to use AGG Output format. i have installed AGG-2.5 >> through yum install command in fedora 9.... >> >> error message: ? *loadOutputFormat(): General error message. OUTPUTFORMAT >> clause references driver AGG/PNG, but this driver isn't configured. >> * >> >> This my mapfile for your kind attention >> MAP >> ? NAME ? ? ? ? ? Gods own country >> ? EXTENT ? ? ? ? 201621.496941 -294488.285333 1425518.020722 498254.511514 >> # >> LAEA >> ? #EXTENT ? ? ? ? -97.5 41.619778 -82.122902 49.38562 # Geographic >> ? SIZE ? ? ? ? ? 400 300 >> ? IMAGECOLOR ? ? 255 255 255 >> ? SHAPEPATH ? ? ?"/var/www/html/ms4w/aapa/tutorial/data" >> ? SYMBOLSET ? ? ?"/var/www/html/ms4w/aapa/tutorial/symbols/symbols35.sym" >> ? FONTSET ? ? ? ?"/var/www/html/ms4w/aapa/tutorial/fonts/fonts.list" >> >> ? IMAGETYPE PNG24 >> >> ? OUTPUTFORMAT >> ? ? NAME png >> ? ? DRIVER "GD/PNG" >> ? ? MIMETYPE "image/png" >> ? ? IMAGEMODE PC256 >> ? ? EXTENSION "png" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME png24 >> ? ? DRIVER "GD/PNG" >> ? ? MIMETYPE "image/png" >> ? ? IMAGEMODE RGBA >> ? ? EXTENSION "png" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME jpeg >> ? ? DRIVER "GD/JPEG" >> ? ? FORMATOPTION "QUALITY=75" >> ? ? MIMETYPE "image/jpeg" >> ? ? IMAGEMODE RGB >> ? ? EXTENSION "jpg" >> ? END >> ? OUTPUTFORMAT >> ? ? NAME GTiff >> ? ? DRIVER "GDAL/GTiff" >> ? ? MIMETYPE "image/tiff" >> ? ? IMAGEMODE RGB >> ? ? EXTENSION "tif" >> ? END >> >> ? OUTPUTFORMAT >> ? ? NAME AGG >> ? ? DRIVER "AGG/PNG" >> ? ? IMAGEMODE RGB >> ? END >> ? OUTPUTFORMAT >> ? ? NAME AGGA >> ? ? DRIVER "AGG/PNG" >> ? ? IMAGEMODE RGBA >> ? END >> ? OUTPUTFORMAT >> ? ? NAME AGGJ >> ? ? DRIVER "AGG/JPEG" >> ? ? IMAGEMODE RGB >> ? END >> >> ? ?WEB >> ? ? IMAGEPATH '/tmp/ms_tmp/' >> ? ? IMAGEURL ?'/ms_tmp/' >> ? END >> >> ? PROJECTION >> ? ? ? ?"init=epsg:2163" >> ? END >> ? LAYER >> ? ? NAME ? ? ? ? districts >> ? ? DATA ? ? ? ? parl_04 >> ? ? STATUS ? ? ? OFF >> ? ? TYPE ? ? ? ? POLYGON >> >> ? ? PROJECTION >> ? ? ? "init=epsg:4326" >> ? ? END >> >> ? ? ?CLASSITEM ? ?"NAME" >> >> ? ? ? CLASS >> ? ? ? EXPRESSION 'party' >> ? ? ? STYLE >> ? ? ? ? SYMBOL ? ? 0 >> ? ? ? ? COLOR ? ? ?232 232 232 >> ? ? ? END >> ? ? END >> ? END >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> ? ? ? ? ? ?. >> >> ? LAYER >> ? ? NAME ? ? ? ? districts >> ? ? DATA ? ? ? ? parl_04 >> ? ? STATUS ? ? ? OFF >> ? ? TYPE ? ? ? ? ANNOTATION >> >> ? ? PROJECTION >> ? ? ? "init=epsg:4326" >> ? ? END >> >> ? ? CLASSITEM ? ?"NAME" >> ? ? LABELITEM ? ?"WINNER" >> ? ? CLASS >> ? ? ? EXPRESSION 'party' >> ? ? ? STYLE >> ? ? ? ? COLOR ? ? ?-1 -1 -1 >> ? ? ? END >> ? ? ? LABEL >> ? ? ? ? COLOR ? ?255 255 255 >> ? ? ? ? TYPE ? ? TRUETYPE >> ? ? ? ? FONT ? ? arial-bold >> ? ? ? ? SIZE ? ? 12 >> ? ? ? ? ANTIALIAS ? ?TRUE >> ? ? ? ? POSITION ? ? CL >> ? ? ? ? PARTIALS ? ? FALSE >> ? ? ? ? MINDISTANCE ?300 >> ? ? ? ? BUFFER ? ? ? 4 >> ? ? ? END # end of label >> ? ? END # end of class >> ? END # States label layer ends here >> ? # End of LAYER DEFINITIONS ------------------------------- >> >> END # end of map file >> >> >> >> can anyone please help me out ..... >> suggestion will be appreciated.. >> >> Thanks >> kapilmanoj >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > > -- > View this message in context: http://n2.nabble.com/loadOutputFormat%28%29%3A-error-AGG-PNG-driver-isn%27t- configured.-tp2388899p3314438.html > Sent from the Mapserver - User mailing list archive at Nabble.com. > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From Jukka.Rahkonen at mmmtike.fi Fri Jul 24 01:30:36 2009 From: Jukka.Rahkonen at mmmtike.fi (Rahkonen Jukka) Date: Fri, 24 Jul 2009 11:30:36 +0300 Subject: [mapserver-users] loadOutputFormat(): error AGG/PNG driver isn'tconfigured. In-Reply-To: <00a801ca0c37$e4bbadc0$a301a8c0@avantias.local> References: <2922382e0907240107s63b03614m2baf99c7609c6087@mail.gmail.com> <00a801ca0c37$e4bbadc0$a301a8c0@avantias.local> Message-ID: Hi, If it does not say it supports AGG then it does not. Without AGG pngs are created with GD renderer. Mapserver -v output will look like this when AGG is included. MapServer version 5.2.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICO NV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUP PORTS=THREADS SUPPORTS=GEOS SUPPORTS=RGBA_PNG INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE -Jukka Rahkonen- > Gana?l Jatteau wrote > > Hi Thomas, > > Thanks for your answer. The info I get with mapserver -v is: > > MapServer version 5.0.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG > OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE > SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER > SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=THREADS > SUPPORTS=GEOS INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL > INPUT=SHAPEFILE > > It doesn't say anything about AGG, however it has PNG (which > I believe use the same driver). > > Cheers, > Ganael > > -----Message d'origine----- > De?: Thomas Bonfort [mailto:thomas.bonfort at camptocamp.com] > Envoy??: vendredi 24 juillet 2009 10:08 > ??: Galigeo > Cc?: mapserver-users at lists.osgeo.org > Objet?: Re: [mapserver-users] loadOutputFormat(): error > AGG/PNG driver isn't configured. > > what's the output of > > mapserv -v > > it should include the AGG key somewhere for agg to be supported. > > regards, > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Fri, Jul 24, 2009 at 09:58, Galigeo wrote: > > > > Hi kapilmanoj > > > > I do have actually the same problem (exept I use Ubuntu > 8.04). I had > > to compile mapscript by myself since I use Java and Java > mapscript is > > not pre-packaged by Ubuntu. Maybe I missed a dependency during the > > compilation > ? > > > > Anyway, if anyone has a solution to this problem, I'd be > glad to know it! > > > > Cheers, > > Ganael > > > > > > kapilmanoj wrote: > >> > >> Dear users, > >> > >> I am using mapserver 5.0.3 on fedora 9. i have been trying out the > >> examples given in the mapserver 5.x tutorial. i am receiving the > >> following error message when attempting to use AGG Output > format. i > >> have installed > AGG-2.5 > >> through yum install command in fedora 9.... > >> > >> error message: ? *loadOutputFormat(): General error message. > >> OUTPUTFORMAT clause references driver AGG/PNG, but this > driver isn't configured. > >> * > >> > >> This my mapfile for your kind attention MAP > >> ? NAME ? ? ? ? ? Gods own country > >> ? EXTENT ? ? ? ? 201621.496941 -294488.285333 1425518.020722 > 498254.511514 > >> # > >> LAEA > >> ? #EXTENT ? ? ? ? -97.5 41.619778 -82.122902 49.38562 # Geographic > >> ? SIZE ? ? ? ? ? 400 300 > >> ? IMAGECOLOR ? ? 255 255 255 > >> ? SHAPEPATH ? ? ?"/var/www/html/ms4w/aapa/tutorial/data" > >> ? SYMBOLSET ? ? ? "/var/www/html/ms4w/aapa/tutorial/symbols/symbols35.sym" > >> ? FONTSET ? ? ? ? "/var/www/html/ms4w/aapa/tutorial/fonts/fonts.list" > >> > >> ? IMAGETYPE PNG24 > >> > >> ? OUTPUTFORMAT > >> ? ? NAME png > >> ? ? DRIVER "GD/PNG" > >> ? ? MIMETYPE "image/png" > >> ? ? IMAGEMODE PC256 > >> ? ? EXTENSION "png" > >> ? END > >> ? OUTPUTFORMAT > >> ? ? NAME png24 > >> ? ? DRIVER "GD/PNG" > >> ? ? MIMETYPE "image/png" > >> ? ? IMAGEMODE RGBA > >> ? ? EXTENSION "png" > >> ? END > >> ? OUTPUTFORMAT > >> ? ? NAME jpeg > >> ? ? DRIVER "GD/JPEG" > >> ? ? FORMATOPTION "QUALITY=75" > >> ? ? MIMETYPE "image/jpeg" > >> ? ? IMAGEMODE RGB > >> ? ? EXTENSION "jpg" > >> ? END > >> ? OUTPUTFORMAT > >> ? ? NAME GTiff > >> ? ? DRIVER "GDAL/GTiff" > >> ? ? MIMETYPE "image/tiff" > >> ? ? IMAGEMODE RGB > >> ? ? EXTENSION "tif" > >> ? END > >> > >> ? OUTPUTFORMAT > >> ? ? NAME AGG > >> ? ? DRIVER "AGG/PNG" > >> ? ? IMAGEMODE RGB > >> ? END > >> ? OUTPUTFORMAT > >> ? ? NAME AGGA > >> ? ? DRIVER "AGG/PNG" > >> ? ? IMAGEMODE RGBA > >> ? END > >> ? OUTPUTFORMAT > >> ? ? NAME AGGJ > >> ? ? DRIVER "AGG/JPEG" > >> ? ? IMAGEMODE RGB > >> ? END > >> > >> ? ?WEB > >> ? ? IMAGEPATH '/tmp/ms_tmp/' > >> ? ? IMAGEURL ?'/ms_tmp/' > >> ? END > >> > >> ? PROJECTION > >> ? ? ? ?"init=epsg:2163" > >> ? END > >> ? LAYER > >> ? ? NAME ? ? ? ? districts > >> ? ? DATA ? ? ? ? parl_04 > >> ? ? STATUS ? ? ? OFF > >> ? ? TYPE ? ? ? ? POLYGON > >> > >> ? ? PROJECTION > >> ? ? ? "init=epsg:4326" > >> ? ? END > >> > >> ? ? ?CLASSITEM ? ?"NAME" > >> > >> ? ? ? CLASS > >> ? ? ? EXPRESSION 'party' > >> ? ? ? STYLE > >> ? ? ? ? SYMBOL ? ? 0 > >> ? ? ? ? COLOR ? ? ?232 232 232 > >> ? ? ? END > >> ? ? END > >> ? END > >> ? ? ? ? ? ?. > >> ? ? ? ? ? ?. > >> ? ? ? ? ? ?. > >> ? ? ? ? ? ?. > >> > >> ? LAYER > >> ? ? NAME ? ? ? ? districts > >> ? ? DATA ? ? ? ? parl_04 > >> ? ? STATUS ? ? ? OFF > >> ? ? TYPE ? ? ? ? ANNOTATION > >> > >> ? ? PROJECTION > >> ? ? ? "init=epsg:4326" > >> ? ? END > >> > >> ? ? CLASSITEM ? ?"NAME" > >> ? ? LABELITEM ? ?"WINNER" > >> ? ? CLASS > >> ? ? ? EXPRESSION 'party' > >> ? ? ? STYLE > >> ? ? ? ? COLOR ? ? ?-1 -1 -1 > >> ? ? ? END > >> ? ? ? LABEL > >> ? ? ? ? COLOR ? ?255 255 255 > >> ? ? ? ? TYPE ? ? TRUETYPE > >> ? ? ? ? FONT ? ? arial-bold > >> ? ? ? ? SIZE ? ? 12 > >> ? ? ? ? ANTIALIAS ? ?TRUE > >> ? ? ? ? POSITION ? ? CL > >> ? ? ? ? PARTIALS ? ? FALSE > >> ? ? ? ? MINDISTANCE ?300 > >> ? ? ? ? BUFFER ? ? ? 4 > >> ? ? ? END # end of label > >> ? ? END # end of class > >> ? END # States label layer ends here > >> ? # End of LAYER DEFINITIONS ------------------------------- > >> > >> END # end of map file > >> > >> > >> > >> can anyone please help me out ..... > >> suggestion will be appreciated.. > >> > >> Thanks > >> kapilmanoj > >> > >> _______________________________________________ > >> mapserver-users mailing list > >> mapserver-users at lists.osgeo.org > >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > >> > >> > > > > -- > > View this message in context: > http://n2.nabble.com/loadOutputFormat%28%29%3A-error-AGG-PNG-d river-isn%27t- > configured.-tp2388899p3314438.html > > Sent from the Mapserver - User mailing list archive at Nabble.com. > > _______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From m.spring at gmx.de Fri Jul 24 05:03:30 2009 From: m.spring at gmx.de (Markus Spring) Date: Fri, 24 Jul 2009 14:03:30 +0200 Subject: [mapserver-users] how to retrieve 2 records at the same point with getfeatureinfo Message-ID: <4A69A312.9070701@thinkpad> Hi list, I have a shapefile with 2 points at the same location. Displaying the shape and selecting this point in gvSIG shows two records. However a getfeatureinfo request always retrieves only one record. I have the following settings in the mapfile WMS_FEATURE_INFO_MIME_TYPE "text/html" WMS_INCLUDE_ITEMS "all" OWS_INCLUDE_ITEMS "all" The problem remains the same if I change the mime type in request and mapfile to text/plain. Is this a feature of ogc wms, is this a bug or do I have to set a special parameter ? Markus From adube at mapgears.com Fri Jul 24 05:14:37 2009 From: adube at mapgears.com (Alexandre Dube) Date: Fri, 24 Jul 2009 08:14:37 -0400 Subject: [mapserver-users] how to retrieve 2 records at the same point with getfeatureinfo In-Reply-To: <4A69A312.9070701@thinkpad> References: <4A69A312.9070701@thinkpad> Message-ID: <4A69A5AD.4020106@mapgears.com> Hi, Have you tried the FEATURE_COUNT (1) property in your request ? Regards, Alexandre (1) http://webhelp.esri.com/arcims/9.2/general/mergedProjects/wms_connect/wms_connector/get_featureinfo.htm Markus Spring wrote: > Hi list, > > I have a shapefile with 2 points at the same location. Displaying the > shape and selecting this point in gvSIG shows two records. > > However a getfeatureinfo request always retrieves only one record. I > have the following settings in the mapfile > > WMS_FEATURE_INFO_MIME_TYPE "text/html" > WMS_INCLUDE_ITEMS "all" > OWS_INCLUDE_ITEMS "all" > > The problem remains the same if I change the mime type in request and > mapfile to text/plain. Is this a feature of ogc wms, is this a bug or > do I have to set a special parameter ? > > Markus > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- Alexandre Dub? Mapgears www.mapgears.com From m.spring at gmx.de Fri Jul 24 05:27:55 2009 From: m.spring at gmx.de (Markus Spring) Date: Fri, 24 Jul 2009 14:27:55 +0200 Subject: [mapserver-users] how to retrieve 2 records at the same point with getfeatureinfo In-Reply-To: <4A69A5AD.4020106@mapgears.com> References: <4A69A312.9070701@thinkpad> <4A69A5AD.4020106@mapgears.com> Message-ID: <4A69A8CB.3040203@thinkpad> Alexandre Dube schrieb: > Have you tried the FEATURE_COUNT (1) property in your request ? Thank you very much - that solved indeed my problem. Great! Markus From dmorissette at mapgears.com Fri Jul 24 06:10:13 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Fri, 24 Jul 2009 09:10:13 -0400 Subject: [mapserver-users] MapServer 5.4.2 released (also 5.2.3 and 4.10.5) Message-ID: <4A69B2B5.3000602@mapgears.com> The MapServer team is pleased to announce the release of MapServer version 5.4.2. No new functionality has been added. This is a maintenance release that fixes a few issues found in 5.4.1, including a new fix for security vulnerability CVE-2009-0840 (ticket #2943) which was not completely resolved in the previous releases. The full 5.4.2 change log can be found at: http://trac.osgeo.org/mapserver/browser/tags/rel-5-4-2/mapserver/HISTORY.TXT The source code is available at: http://mapserver.org/download.html Binary distributions linked from the same download page will follow shortly. Windows users can now download MS4W 3.0 beta5 which contains this release. We encourage all users of pre-5.4 releases to upgrade to 5.4 as soon as possible. However, for the convenience of those who cannot upgrade right away, we have backported the security fixes and produced release packages for 5.2.3 and 4.10.5 that are available in source form on the same download page listed above. Daniel From pramsey at opengeo.org Fri Jul 24 11:15:03 2009 From: pramsey at opengeo.org (Paul Ramsey) Date: Fri, 24 Jul 2009 11:15:03 -0700 Subject: [mapserver-users] PostGIS 1.4.0 Released Message-ID: <30fe546d0907241115r9f47b77u214146ca562524b2@mail.gmail.com> July 24, 2009 The PostGIS development team has, after a long period of meditation and soul searching, released version 1.4.0 of the spatial data extension for PostgreSQL. http://postgis.refractions.net/download/postgis-1.4.0.tar.gz This new version of PostGIS includes substantial performance enhancements, more detailed reference documentation, new output formats (GeoJSON) and an improved internal testing system. PostGIS 1.4 also supports the recent PostgreSQL 8.4 release. Thanks to everyone who helped by testing during the release candidate process! Your PostGIS Team -- Detailed PostGIS 1.4 Release Notes -- - As of the 1.4 release series, the public API of PostGIS will not change during minor releases. - Compatibility - The versions below are the *minimum* requirements for PostGIS 1.4 - PostgreSQL 8.2 and higher on all platforms - GEOS 3.0 and higher only - PROJ4 4.5 and higher only - New Features - ST_Union() uses high-speed cascaded union when compiled against GEOS 3.1+ (Paul Ramsey) - ST_ContainsProperly() requires GEOS 3.1+ - ST_Intersects(), ST_Contains(), ST_Within() use high-speed cached prepared geometry against GEOS 3.1+ (Paul Ramsey) - Vastly improved documentation and reference manual (Regina Obe & Kevin Neufeld) - Figures and diagram examples in the reference manual (Kevin Neufeld) - ST_IsValidReason() returns readable explanations for validity failures (Paul Ramsey) - ST_GeoHash() returns a geohash.org signature for geometries (Paul Ramsey) - GTK+ multi-platform GUI for shape file loading (Paul Ramsey) - ST_LineCrossingDirection() returns crossing directions (Paul Ramsey) - ST_LocateBetweenElevations() returns sub-string based on Z-ordinate. (Paul Ramsey) - Geometry parser returns explicit error message about location of syntax errors (Mark Cave-Ayland) - ST_AsGeoJSON() return JSON formatted - Populate_Geometry_Columns() -- automatically add records to geometry_columns for TABLES and VIEWS (Kevin Neufeld) - ST_MinimumBoundingCircle() -- returns the smallest circle polygon that can encompass a geometry (Bruce Rindahl) - Enhancements - Core geometry system moved into independent library, liblwgeom. (Mark Cave-Ayland) - New build system uses PostgreSQL "pgxs" build bootstrapper. (Mark Cave-Ayland) - Debugging framework formalized and simplified. (Mark Cave-Ayland) - All build-time #defines generated at configure time and placed in headers for easier cross-platform support (Mark Cave-Ayland) - Logging framework formalized and simplified (Mark Cave-Ayland) - Expanded and more stable support for CIRCULARSTRING, COMPOUNDCURVE and CURVEPOLYGON, better parsing, wider support in functions (Mark Leslie & Mark Cave-Ayland) - Improved support for OpenSolaris builds (Paul Ramsey) - Improved support for MSVC builds (Mateusz Loskot) - Updated KML support (Olivier Courtin) - Unit testing framework for liblwgeom (Paul Ramsey) - New testing framework to comprehensively exercise every PostGIS function (Regine Obe) - Performance improvements to all geometry aggregate functions (Paul Ramsey) - Support for the upcoming PostgreSQL 8.4 (Mark Cave-Ayland, Talha Bin Rizwan) - Shp2pgsql and pgsql2shp re-worked to depend on the common parsing/unparsing code in liblwgeom (Mark Cave-Ayland) - Use of PDF DbLatex to build PDF docs and preliminary instructions for build (Jean David Techer) - Automated User documentation build (PDF and HTML) and Developer Doxygen Documentation (Kevin Neufeld) - Automated build of document images using ImageMagick from WKT geometry text files (Kevin Neufeld) - More attractive CSS for HTML documentation (Dane Springmeyer) - Bug fixes - http://trac.osgeo.org/postgis/query?status=closed&milestone=postgis+1.4.0&order=priority From jbw2003 at earthlink.net Fri Jul 24 11:31:56 2009 From: jbw2003 at earthlink.net (jim white) Date: Fri, 24 Jul 2009 14:31:56 -0400 Subject: [mapserver-users] problem reading log/debug Message-ID: <4A69FE1C.2060903@earthlink.net> Daniel, Great - the fflush worked. The OS is Debian Etch 64. I am using php/mapscript. Perhaps you recall that I had a similar problem with the same server with PHP/mapscript and calling flush caused a segmentation fault to show in the apache error logs. Perhaps there is something similar I could experiment with that would flush mapscript output? Jim jim white wrote: > > I can use a file instead of stderr and have the same problem - restart > > apache to see the logs. > > > Um... the only reason I can think of for this to happen would be if your mapserv processes hang and never close/flush the log output. Actually, are you using the mapserv CGI or MapScript? On which OS is this happening? If you built from source, you could possibly work around the problem by adding a fflush() call in msDebug() after the msIO_vfprintf() line. That could keep you going but would not solve the key issue which seems to be that your processes possibly hang or something like that. We'd need more info to help with that. Index: mapdebug.c =================================================================== --- mapdebug.c (revision 9170) +++ mapdebug.c (working copy) @@ -360,6 +360,7 @@ va_start(args, pszFormat); msIO_vfprintf(debuginfo->fp, pszFormat, args); + fflush(debuginfo->fp); va_end(args); } #ifdef _WIN32 -- James (Jim) B. White tel: (919)-380-9615 homepage: http://jimserver.net/ From mark_brooks at ncsu.edu Fri Jul 24 13:01:51 2009 From: mark_brooks at ncsu.edu (Mark Brooks) Date: Fri, 24 Jul 2009 16:01:51 -0400 Subject: [mapserver-users] distance between line and a given point using mapscript Message-ID: <4A6A132F.3090207@ncsu.edu> I'm trying to create several new line objects and then find the lines that are within x miles of a given point. (i.e., how far away a given point is from the track of a hurricane or the path of a ship). I'm having some difficulties and I hope someone can help. How do I query a layer with one or more line features to find all features with X miles of a given point? Here is how I'm approaching the problem in PHP: // Test array of points. This is used to make a line. $points[0]['lat'] = 35.5; $points[0]['lon'] = -78.8; $points[1]['lat'] = 36.5; $points[1]['lon'] = -79.8; $points[2]['lat'] = 37.5; $points[2]['lon'] = -80.1; // make new map object. $map = ms_newMapObj('mapdata/mymap.map'); // Create new line $my_line = ms_newLineObj(); // Loop through points, and add to the line while (list(,$coordinate)=each($points)){ // Create new point object $my_point = ms_newpointObj(); $my_point->setXY($coordinate['lon'],$coordinate['lat']); // Add point to line object $my_line->add($my_point); } // Now create a new shape $my_shape = ms_newShapeObj(MS_SHAPE_LINE); $my_shape->add($my_line); // create new layer $my_layer = ms_newLayerObj($map); // set some fields for this new layer //$my_layer->set("units","miles"); // does not seem to work as expected // Create new class and add TEMPLATE. This is required for queries on the layer to work? $my_class = ms_newClassObj($my_layer); $my_class->set("template",'/home/www/html/query_template.html'); // Add feature to the layer $my_layer->addFeature($my_shape); // Draw map. Query doesn't work if I don't do this now. $map->draw(); // Make a new point object that will be our ref point // to check how far away the line is from this point. $my_point = ms_newpointObj(); $my_point->setXY(-82,36); // lon, lat // Run a point query on the line object layer; layer must have a class with a LAYER TEMPLATE value // The third argument is the buffer tolerance. Default unit is pixels? Must figure out how to make miles or km. if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ $my_result = $my_layer->getResult(0); // Get the result $my_layer = $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // Get the shape } From Steve.Lime at dnr.state.mn.us Fri Jul 24 20:26:09 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Fri, 24 Jul 2009 22:26:09 -0500 Subject: [mapserver-users] Querymap Message-ID: <4A6A35010200008F00026805@co5.dnr.state.mn.us> Hi Daniel: Sadly, no. It's primarily because there's only one querymap for potentially all the layers so symbolization could become quite complex as different layers are processed. A better solution is to store a selection style with each layer. Depending on your application you might be able to work around this limitation using dynamic expressions. For example: # selected feature layer LAYER NAME 'selected' ... LABELITEM 'keyfield' CLASS EXPRESSION '%keyvalue%' ...styles to draw the feature in a selected manner... METADATA keyvalue_validation_pattern 'some regex to make sure the keyvalue is of the proper form' END END END Then if using the CGI you could call MapServer with a primary key from the selected feature, e.g.: /cgi-bin/mapserv?map=...&layer=selected&keyvalue=1234 If your app knows stuff about the selected feature (either as part of a template presentation or perhaps the query was done via ajax) then this works nicely. Steve >>> Daniel Degasperi 07/23/09 3:42 AM >>> Hello MapServer Users, I've been using the Querymap-Feature of MapServer. As I understand the objects are highlighted by changing the color. It would be very nice to have the possibility to define other style-properties like SIZE, OUTLINECOLOR, etc. Is this possible? Best regards Daniel Degasperi -- Daniel Degasperi Software Developer daniel.degasperi at r3-gis.com --------------------------- R3 GIS Srl Via Johann Kravogl 2 I-39010 Merano - Sinigo (BZ) Tel. +39 0473 494949 Fax. +39 0473 069902 Web http://www.r3-gis.com ----------------------------- _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at dnr.state.mn.us Sat Jul 25 07:36:57 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Sat, 25 Jul 2009 09:36:57 -0500 Subject: [mapserver-users] distance between line and a given point usingmapscript Message-ID: <4A6AD23A0200008F0002680A@co5.dnr.state.mn.us> > How do I query a layer with one or more line features to find all > features with X miles of a given point? Your line layer should like so: LAYER NAME 'lines' TYPE LINE ...other junk... TEMPLATE 'dummy' # to be queryable TOLERANCEUNITS MILES TOLERANCE X END Then in mapscript you'd do a $my_layer->queryByPoint($my_point, MS_MULTIPLE, -1); The buffer parameter is used to override a layer tolerance so setting to -1 tells the method to ignore it. If you do use it then it's given in the units of the layer being searched (before any projection). Does that help? Steve >>> Mark Brooks 07/24/09 3:26 PM >>> I'm trying to create several new line objects and then find the lines that are within x miles of a given point. (i.e., how far away a given point is from the track of a hurricane or the path of a ship). I'm having some difficulties and I hope someone can help. How do I query a layer with one or more line features to find all features with X miles of a given point? Here is how I'm approaching the problem in PHP: // Test array of points. This is used to make a line. $points[0]['lat'] = 35.5; $points[0]['lon'] = -78.8; $points[1]['lat'] = 36.5; $points[1]['lon'] = -79.8; $points[2]['lat'] = 37.5; $points[2]['lon'] = -80.1; // make new map object. $map = ms_newMapObj('mapdata/mymap.map'); // Create new line $my_line = ms_newLineObj(); // Loop through points, and add to the line while (list(,$coordinate)=each($points)){ // Create new point object $my_point = ms_newpointObj(); $my_point->setXY($coordinate['lon'],$coordinate['lat']); // Add point to line object $my_line->add($my_point); } // Now create a new shape $my_shape = ms_newShapeObj(MS_SHAPE_LINE); $my_shape->add($my_line); // create new layer $my_layer = ms_newLayerObj($map); // set some fields for this new layer //$my_layer->set("units","miles"); // does not seem to work as expected // Create new class and add TEMPLATE. This is required for queries on the layer to work? $my_class = ms_newClassObj($my_layer); $my_class->set("template",'/home/www/html/query_template.html'); // Add feature to the layer $my_layer->addFeature($my_shape); // Draw map. Query doesn't work if I don't do this now. $map->draw(); // Make a new point object that will be our ref point // to check how far away the line is from this point. $my_point = ms_newpointObj(); $my_point->setXY(-82,36); // lon, lat // Run a point query on the line object layer; layer must have a class with a LAYER TEMPLATE value // The third argument is the buffer tolerance. Default unit is pixels? Must figure out how to make miles or km. if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ $my_result = $my_layer->getResult(0); // Get the result $my_layer = $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // Get the shape } _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Steve.Lime at dnr.state.mn.us Sat Jul 25 07:42:01 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Sat, 25 Jul 2009 09:42:01 -0500 Subject: [mapserver-users] distance between line and a given point usingmapscript Message-ID: <4A6AD3690200008F0002680F@co5.dnr.state.mn.us> Oh, wanted to also note that there are some distance methods associated with points in mapscript so that you could avoid the query methods altogether. They are (for a point): - distanceToSegment(a, b); # where a and b are pointObj's - distanceToShape(a); # where a is a shapeObj These are planar distances, no great circle computations. Steve >>> Mark Brooks 07/24/09 3:26 PM >>> I'm trying to create several new line objects and then find the lines that are within x miles of a given point. (i.e., how far away a given point is from the track of a hurricane or the path of a ship). I'm having some difficulties and I hope someone can help. How do I query a layer with one or more line features to find all features with X miles of a given point? Here is how I'm approaching the problem in PHP: // Test array of points. This is used to make a line. $points[0]['lat'] = 35.5; $points[0]['lon'] = -78.8; $points[1]['lat'] = 36.5; $points[1]['lon'] = -79.8; $points[2]['lat'] = 37.5; $points[2]['lon'] = -80.1; // make new map object. $map = ms_newMapObj('mapdata/mymap.map'); // Create new line $my_line = ms_newLineObj(); // Loop through points, and add to the line while (list(,$coordinate)=each($points)){ // Create new point object $my_point = ms_newpointObj(); $my_point->setXY($coordinate['lon'],$coordinate['lat']); // Add point to line object $my_line->add($my_point); } // Now create a new shape $my_shape = ms_newShapeObj(MS_SHAPE_LINE); $my_shape->add($my_line); // create new layer $my_layer = ms_newLayerObj($map); // set some fields for this new layer //$my_layer->set("units","miles"); // does not seem to work as expected // Create new class and add TEMPLATE. This is required for queries on the layer to work? $my_class = ms_newClassObj($my_layer); $my_class->set("template",'/home/www/html/query_template.html'); // Add feature to the layer $my_layer->addFeature($my_shape); // Draw map. Query doesn't work if I don't do this now. $map->draw(); // Make a new point object that will be our ref point // to check how far away the line is from this point. $my_point = ms_newpointObj(); $my_point->setXY(-82,36); // lon, lat // Run a point query on the line object layer; layer must have a class with a LAYER TEMPLATE value // The third argument is the buffer tolerance. Default unit is pixels? Must figure out how to make miles or km. if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ $my_result = $my_layer->getResult(0); // Get the result $my_layer = $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // Get the shape } _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From adrian_gh.popa at romtelecom.ro Mon Jul 27 02:37:03 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Mon, 27 Jul 2009 12:37:03 +0300 Subject: [mapserver-users] Applying a hatch over a line layer Message-ID: <4A6D753F.30009@romtelecom.ro> Hello, I'm trying to apply a hatch over a line segment, but it doesn't seem to work. My symbol definition is: SYMBOL NAME 'hatch' TYPE HATCH END My layer definition is: LAYER TYPE LINE ... CLASS NAME "Test" EXPRESSION ( "[flag]" eq "1") STYLE SYMBOL 'hatch' ANGLE 45 SIZE 3 #spacing between lines WIDTH 4 #width of each line color "#000000" END style color "#fff94d" width 2 antialias true end END END The behavior is the following: mapserver draws the lines using the second style (a yellowish color), but doesn't draw a hatch over my line. I've tried with the hatch symbol after the style definition, but it still doesn't work. The hatch worked for POLYGON layers just fine. Is there any way I can use it for LINE data? Thanks, Adrian P.S. I'm using mapserver 5.4.1 From thomas.bonfort at camptocamp.com Mon Jul 27 04:11:53 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Mon, 27 Jul 2009 13:11:53 +0200 Subject: [mapserver-users] Applying a hatch over a line layer In-Reply-To: <4A6D753F.30009@romtelecom.ro> References: <4A6D753F.30009@romtelecom.ro> Message-ID: <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> hi, hatches only apply to polygon layers. what you are probably looking for is the PATTERN keyword: symbol type simple pattern 2 2 end name "dashes" end regards, thomas www.camptocamp.com +33 4 79 26 57 97 On Mon, Jul 27, 2009 at 11:37, Adrian Popa wrote: > Hello, > > I'm trying to apply a hatch over a line segment, but it doesn't seem to > work. > My symbol definition is: > > SYMBOL ? ? ? ? ? ? ?NAME 'hatch' > ? ?TYPE HATCH ?END > My layer definition is: > LAYER > ? TYPE LINE > ? ... > ? CLASS > ? ? ?NAME "Test" > ? ? ?EXPRESSION ( "[flag]" eq "1") > ? ? ?STYLE ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? SYMBOL 'hatch' > ? ? ? ? ? ANGLE 45 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? SIZE 3 #spacing between > lines > ? ? ? ? ? WIDTH 4 #width of each line ? ? ? ? ? color "#000000" > ? ? ? END ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? style > ? ? ? ? color "#fff94d" ? ? ? ? ? ? ? ? ? ? ? width 2 > ? ? ? ? antialias true ? ? ? ? ? ? ? ? ? ? ? end > ? END > END > > The behavior is the following: mapserver draws the lines using the second > style (a yellowish color), but doesn't draw a hatch over my line. > > I've tried with the hatch symbol after the style definition, but it still > doesn't work. ?The hatch worked for POLYGON layers just fine. > > Is there any way I can use it for LINE data? > > Thanks, > Adrian > > P.S. I'm using mapserver 5.4.1 > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From adrian_gh.popa at romtelecom.ro Mon Jul 27 04:44:31 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Mon, 27 Jul 2009 14:44:31 +0300 Subject: [mapserver-users] Applying a hatch over a line layer In-Reply-To: <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> References: <4A6D753F.30009@romtelecom.ro> <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> Message-ID: <4A6D931F.9030003@romtelecom.ro> Hello Thomas, Thank you for your reply. I tried your solution and it draws a dashed line paralel to my feature (on each side because the symbol is thicker). This is nice, but I was wondering if it's possible to draw the lines at an angle relative to my feature, thus created the "hatch" effect. If this is not possible with a simple symbol - would it be possible with a graphical symbol (picture)? And if yes, should I expect a high performance penalty? Thanks again, Adrian Thomas Bonfort wrote: > hi, > > hatches only apply to polygon layers. > > what you are probably looking for is the PATTERN keyword: > > symbol > type simple > pattern 2 2 end > name "dashes" > end > > > regards, > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Mon, Jul 27, 2009 at 11:37, Adrian Popa wrote: > >> Hello, >> >> I'm trying to apply a hatch over a line segment, but it doesn't seem to >> work. >> My symbol definition is: >> >> SYMBOL NAME 'hatch' >> TYPE HATCH END >> My layer definition is: >> LAYER >> TYPE LINE >> ... >> CLASS >> NAME "Test" >> EXPRESSION ( "[flag]" eq "1") >> STYLE SYMBOL 'hatch' >> ANGLE 45 SIZE 3 #spacing between >> lines >> WIDTH 4 #width of each line color "#000000" >> END style >> color "#fff94d" width 2 >> antialias true end >> END >> END >> >> The behavior is the following: mapserver draws the lines using the second >> style (a yellowish color), but doesn't draw a hatch over my line. >> >> I've tried with the hatch symbol after the style definition, but it still >> doesn't work. The hatch worked for POLYGON layers just fine. >> >> Is there any way I can use it for LINE data? >> >> Thanks, >> Adrian >> >> P.S. I'm using mapserver 5.4.1 >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From adrian_gh.popa at romtelecom.ro Mon Jul 27 04:47:00 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Mon, 27 Jul 2009 14:47:00 +0300 Subject: [mapserver-users] Applying a hatch over a line layer In-Reply-To: <4A6D931F.9030003@romtelecom.ro> References: <4A6D753F.30009@romtelecom.ro> <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> <4A6D931F.9030003@romtelecom.ro> Message-ID: <4A6D93B4.7080103@romtelecom.ro> ...Or, to be more clear, I would like to give my lines a "striped" look - I don't know if there's an easier way to do it than using a symbol... Thanks. Adrian Popa wrote: > Hello Thomas, > > Thank you for your reply. I tried your solution and it draws a dashed > line paralel to my feature (on each side because the symbol is > thicker). This is nice, but I was wondering if it's possible to draw > the lines at an angle relative to my feature, thus created the "hatch" > effect. > > If this is not possible with a simple symbol - would it be possible > with a graphical symbol (picture)? And if yes, should I expect a high > performance penalty? > > Thanks again, > Adrian > > Thomas Bonfort wrote: >> hi, >> >> hatches only apply to polygon layers. >> >> what you are probably looking for is the PATTERN keyword: >> >> symbol >> type simple >> pattern 2 2 end >> name "dashes" >> end >> >> >> regards, >> thomas >> >> www.camptocamp.com >> +33 4 79 26 57 97 >> >> >> >> On Mon, Jul 27, 2009 at 11:37, Adrian Popa wrote: >> >>> Hello, >>> >>> I'm trying to apply a hatch over a line segment, but it doesn't seem to >>> work. >>> My symbol definition is: >>> >>> SYMBOL NAME 'hatch' >>> TYPE HATCH END >>> My layer definition is: >>> LAYER >>> TYPE LINE >>> ... >>> CLASS >>> NAME "Test" >>> EXPRESSION ( "[flag]" eq "1") >>> STYLE SYMBOL 'hatch' >>> ANGLE 45 SIZE 3 #spacing between >>> lines >>> WIDTH 4 #width of each line color "#000000" >>> END style >>> color "#fff94d" width 2 >>> antialias true end >>> END >>> END >>> >>> The behavior is the following: mapserver draws the lines using the second >>> style (a yellowish color), but doesn't draw a hatch over my line. >>> >>> I've tried with the hatch symbol after the style definition, but it still >>> doesn't work. The hatch worked for POLYGON layers just fine. >>> >>> Is there any way I can use it for LINE data? >>> >>> Thanks, >>> Adrian >>> >>> P.S. I'm using mapserver 5.4.1 >>> >>> >>> _______________________________________________ >>> mapserver-users mailing list >>> mapserver-users at lists.osgeo.org >>> http://lists.osgeo.org/mailman/listinfo/mapserver-users >>> >>> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.bonfort at camptocamp.com Mon Jul 27 05:00:59 2009 From: thomas.bonfort at camptocamp.com (Thomas Bonfort) Date: Mon, 27 Jul 2009 14:00:59 +0200 Subject: [mapserver-users] Applying a hatch over a line layer In-Reply-To: <4A6D93B4.7080103@romtelecom.ro> References: <4A6D753F.30009@romtelecom.ro> <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> <4A6D931F.9030003@romtelecom.ro> <4A6D93B4.7080103@romtelecom.ro> Message-ID: <2922382e0907270500v3d75ba3ana25f260d286bfb25@mail.gmail.com> yes, you can definitely do that with an image symbol, although that won't be very flexible if you want to change the width. another solution would be with a vector symbol. in both cases, you'll have to add a negative GAP to your symbol definition. cheers, thomas www.camptocamp.com +33 4 79 26 57 97 On Mon, Jul 27, 2009 at 13:47, Adrian Popa wrote: > ...Or, to be more clear, I would like to give my lines a "striped" look -? I > don't know if there's an easier way to do it than using a symbol... > > Thanks. > > > Adrian Popa wrote: > > Hello Thomas, > > Thank you for your reply. I tried your solution and it draws a dashed line > paralel to my feature (on each side because the symbol is thicker). This is > nice, but I was wondering if it's possible to draw the lines at an angle > relative to my feature, thus created the "hatch" effect. > > If this is not possible with a simple symbol - would it be possible with a > graphical symbol (picture)? And if yes, should I expect a high performance > penalty? > > Thanks again, > Adrian > > Thomas Bonfort wrote: > > hi, > > hatches only apply to polygon layers. > > what you are probably looking for is the PATTERN keyword: > > symbol > type simple > pattern 2 2 end > name "dashes" > end > > > regards, > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Mon, Jul 27, 2009 at 11:37, Adrian Popa > wrote: > > > Hello, > > I'm trying to apply a hatch over a line segment, but it doesn't seem to > work. > My symbol definition is: > > SYMBOL ? ? ? ? ? ? ?NAME 'hatch' > ? ?TYPE HATCH ?END > My layer definition is: > LAYER > ? TYPE LINE > ? ... > ? CLASS > ? ? ?NAME "Test" > ? ? ?EXPRESSION ( "[flag]" eq "1") > ? ? ?STYLE ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? SYMBOL 'hatch' > ? ? ? ? ? ANGLE 45 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? SIZE 3 #spacing between > lines > ? ? ? ? ? WIDTH 4 #width of each line ? ? ? ? ? color "#000000" > ? ? ? END ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? style > ? ? ? ? color "#fff94d" ? ? ? ? ? ? ? ? ? ? ? width 2 > ? ? ? ? antialias true ? ? ? ? ? ? ? ? ? ? ? end > ? END > END > > The behavior is the following: mapserver draws the lines using the second > style (a yellowish color), but doesn't draw a hatch over my line. > > I've tried with the hatch symbol after the style definition, but it still > doesn't work. ?The hatch worked for POLYGON layers just fine. > > Is there any way I can use it for LINE data? > > Thanks, > Adrian > > P.S. I'm using mapserver 5.4.1 > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > > > From adrian_gh.popa at romtelecom.ro Mon Jul 27 05:57:37 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Mon, 27 Jul 2009 15:57:37 +0300 Subject: [mapserver-users] Applying a hatch over a line layer In-Reply-To: <2922382e0907270500v3d75ba3ana25f260d286bfb25@mail.gmail.com> References: <4A6D753F.30009@romtelecom.ro> <2922382e0907270411i1a999d6emb3ea48c7dec4f2e5@mail.gmail.com> <4A6D931F.9030003@romtelecom.ro> <4A6D93B4.7080103@romtelecom.ro> <2922382e0907270500v3d75ba3ana25f260d286bfb25@mail.gmail.com> Message-ID: <4A6DA441.50903@romtelecom.ro> Hello Thomas, Thank you for your reply. I tried first with an image, but the output didn't look so hot, so I created my own symbol by following this guide: http://umn.mapserver.ch/MapServer/en/sym_vector.htm It still doesn't look very nice, but I will tune it from here. Thanks again, Adrian Thomas Bonfort wrote: > yes, you can definitely do that with an image symbol, although that > won't be very flexible if you want to change the width. > > another solution would be with a vector symbol. > > in both cases, you'll have to add a negative GAP to your symbol definition. > > cheers, > > thomas > > www.camptocamp.com > +33 4 79 26 57 97 > > > > On Mon, Jul 27, 2009 at 13:47, Adrian Popa wrote: > >> ...Or, to be more clear, I would like to give my lines a "striped" look - I >> don't know if there's an easier way to do it than using a symbol... >> >> Thanks. >> >> >> Adrian Popa wrote: >> >> Hello Thomas, >> >> Thank you for your reply. I tried your solution and it draws a dashed line >> paralel to my feature (on each side because the symbol is thicker). This is >> nice, but I was wondering if it's possible to draw the lines at an angle >> relative to my feature, thus created the "hatch" effect. >> >> If this is not possible with a simple symbol - would it be possible with a >> graphical symbol (picture)? And if yes, should I expect a high performance >> penalty? >> >> Thanks again, >> Adrian >> >> Thomas Bonfort wrote: >> >> hi, >> >> hatches only apply to polygon layers. >> >> what you are probably looking for is the PATTERN keyword: >> >> symbol >> type simple >> pattern 2 2 end >> name "dashes" >> end >> >> >> regards, >> thomas >> >> www.camptocamp.com >> +33 4 79 26 57 97 >> >> >> >> On Mon, Jul 27, 2009 at 11:37, Adrian Popa >> wrote: >> >> >> Hello, >> >> I'm trying to apply a hatch over a line segment, but it doesn't seem to >> work. >> My symbol definition is: >> >> SYMBOL NAME 'hatch' >> TYPE HATCH END >> My layer definition is: >> LAYER >> TYPE LINE >> ... >> CLASS >> NAME "Test" >> EXPRESSION ( "[flag]" eq "1") >> STYLE SYMBOL 'hatch' >> ANGLE 45 SIZE 3 #spacing between >> lines >> WIDTH 4 #width of each line color "#000000" >> END style >> color "#fff94d" width 2 >> antialias true end >> END >> END >> >> The behavior is the following: mapserver draws the lines using the second >> style (a yellowish color), but doesn't draw a hatch over my line. >> >> I've tried with the hatch symbol after the style definition, but it still >> doesn't work. The hatch worked for POLYGON layers just fine. >> >> Is there any way I can use it for LINE data? >> >> Thanks, >> Adrian >> >> P.S. I'm using mapserver 5.4.1 >> >> >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> >> >> >> >> >> >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mark_brooks at ncsu.edu Mon Jul 27 07:49:06 2009 From: mark_brooks at ncsu.edu (Mark Brooks) Date: Mon, 27 Jul 2009 10:49:06 -0400 Subject: [mapserver-users] distance between line and a given point usingmapscript In-Reply-To: <4A6AD23A0200008F0002680A@co5.dnr.state.mn.us> References: <4A6AD23A0200008F0002680A@co5.dnr.state.mn.us> Message-ID: <4A6DBE62.8050205@ncsu.edu> Steve, This is a huge help. The only thing I had not figured out was the 'toleranceunits' and 'tolerance' fields. I appreciate your help! I intend to add many, possible hundreds, lines to a layer. Then query it with a given reference point. How do I get the number of results and then loop through each one? Best Regards, Mark Steve Lime wrote: >> How do I query a layer with one or more line features to find all >> features with X miles of a given point? > > Your line layer should like so: > > LAYER > NAME 'lines' > TYPE LINE > ...other junk... > TEMPLATE 'dummy' # to be queryable > TOLERANCEUNITS MILES > TOLERANCE X > END > > Then in mapscript you'd do a > > $my_layer->queryByPoint($my_point, MS_MULTIPLE, -1); > > The buffer parameter is used to override a layer tolerance so setting to -1 tells > the method to ignore it. If you do use it then it's given in the units of the layer > being searched (before any projection). > > Does that help? > > Steve > >>>> Mark Brooks 07/24/09 3:26 PM >>> > I'm trying to create several new line objects and then find the lines > that are within x miles of a given point. (i.e., how far away a given > point is from the track of a hurricane or the path of a ship). I'm > having some difficulties and I hope someone can help. > > How do I query a layer with one or more line features to find all > features with X miles of a given point? > > Here is how I'm approaching the problem in PHP: > > // Test array of points. This is used to make a line. > $points[0]['lat'] = 35.5; > $points[0]['lon'] = -78.8; > $points[1]['lat'] = 36.5; > $points[1]['lon'] = -79.8; > $points[2]['lat'] = 37.5; > $points[2]['lon'] = -80.1; > > // make new map object. > $map = ms_newMapObj('mapdata/mymap.map'); > > // Create new line > $my_line = ms_newLineObj(); > > // Loop through points, and add to the line > while (list(,$coordinate)=each($points)){ > > // Create new point object > $my_point = ms_newpointObj(); > $my_point->setXY($coordinate['lon'],$coordinate['lat']); > > // Add point to line object > $my_line->add($my_point); > } > > // Now create a new shape > $my_shape = ms_newShapeObj(MS_SHAPE_LINE); > $my_shape->add($my_line); > > // create new layer > $my_layer = ms_newLayerObj($map); > > // set some fields for this new layer > //$my_layer->set("units","miles"); // does not seem to work as expected > > // Create new class and add TEMPLATE. This is required for queries on > the layer to work? > $my_class = ms_newClassObj($my_layer); > $my_class->set("template",'/home/www/html/query_template.html'); > > // Add feature to the layer > $my_layer->addFeature($my_shape); > > // Draw map. Query doesn't work if I don't do this now. > $map->draw(); > > // Make a new point object that will be our ref point > // to check how far away the line is from this point. > $my_point = ms_newpointObj(); > $my_point->setXY(-82,36); // lon, lat > > // Run a point query on the line object layer; layer must have a class > with a LAYER TEMPLATE value > // The third argument is the buffer tolerance. Default unit is pixels? > Must figure out how to make miles or km. > if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ > > $my_result = $my_layer->getResult(0); // Get the result > $my_layer = > $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // > Get the shape > > } > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- Mark Brooks State Climate Office of North Carolina Box 7236, NC State University Raleigh, NC 27695-7236 Phone: 919.515.1446 Fax: 919.515.1441 From Steve.Lime at dnr.state.mn.us Mon Jul 27 20:54:26 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Mon, 27 Jul 2009 22:54:26 -0500 Subject: [mapserver-users] distance between line and a given point usingmapscript Message-ID: <4A6E30220200008F000269B5@co5.dnr.state.mn.us> There are lots of samples that show you how to loop through a set of search results. There's a getNumResults() method for layer objects and then a getResult() method to retrieve each one individually. Steve >>> Mark Brooks 07/27/09 9:50 AM >>> Steve, This is a huge help. The only thing I had not figured out was the 'toleranceunits' and 'tolerance' fields. I appreciate your help! I intend to add many, possible hundreds, lines to a layer. Then query it with a given reference point. How do I get the number of results and then loop through each one? Best Regards, Mark Steve Lime wrote: >> How do I query a layer with one or more line features to find all >> features with X miles of a given point? > > Your line layer should like so: > > LAYER > NAME 'lines' > TYPE LINE > ...other junk... > TEMPLATE 'dummy' # to be queryable > TOLERANCEUNITS MILES > TOLERANCE X > END > > Then in mapscript you'd do a > > $my_layer->queryByPoint($my_point, MS_MULTIPLE, -1); > > The buffer parameter is used to override a layer tolerance so setting to -1 tells > the method to ignore it. If you do use it then it's given in the units of the layer > being searched (before any projection). > > Does that help? > > Steve > >>>> Mark Brooks 07/24/09 3:26 PM >>> > I'm trying to create several new line objects and then find the lines > that are within x miles of a given point. (i.e., how far away a given > point is from the track of a hurricane or the path of a ship). I'm > having some difficulties and I hope someone can help. > > How do I query a layer with one or more line features to find all > features with X miles of a given point? > > Here is how I'm approaching the problem in PHP: > > // Test array of points. This is used to make a line. > $points[0]['lat'] = 35.5; > $points[0]['lon'] = -78.8; > $points[1]['lat'] = 36.5; > $points[1]['lon'] = -79.8; > $points[2]['lat'] = 37.5; > $points[2]['lon'] = -80.1; > > // make new map object. > $map = ms_newMapObj('mapdata/mymap.map'); > > // Create new line > $my_line = ms_newLineObj(); > > // Loop through points, and add to the line > while (list(,$coordinate)=each($points)){ > > // Create new point object > $my_point = ms_newpointObj(); > $my_point->setXY($coordinate['lon'],$coordinate['lat']); > > // Add point to line object > $my_line->add($my_point); > } > > // Now create a new shape > $my_shape = ms_newShapeObj(MS_SHAPE_LINE); > $my_shape->add($my_line); > > // create new layer > $my_layer = ms_newLayerObj($map); > > // set some fields for this new layer > //$my_layer->set("units","miles"); // does not seem to work as expected > > // Create new class and add TEMPLATE. This is required for queries on > the layer to work? > $my_class = ms_newClassObj($my_layer); > $my_class->set("template",'/home/www/html/query_template.html'); > > // Add feature to the layer > $my_layer->addFeature($my_shape); > > // Draw map. Query doesn't work if I don't do this now. > $map->draw(); > > // Make a new point object that will be our ref point > // to check how far away the line is from this point. > $my_point = ms_newpointObj(); > $my_point->setXY(-82,36); // lon, lat > > // Run a point query on the line object layer; layer must have a class > with a LAYER TEMPLATE value > // The third argument is the buffer tolerance. Default unit is pixels? > Must figure out how to make miles or km. > if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ > > $my_result = $my_layer->getResult(0); // Get the result > $my_layer = > $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // > Get the shape > > } > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- Mark Brooks State Climate Office of North Carolina Box 7236, NC State University Raleigh, NC 27695-7236 Phone: 919.515.1446 Fax: 919.515.1441 From mark_brooks at ncsu.edu Tue Jul 28 05:49:05 2009 From: mark_brooks at ncsu.edu (Mark Brooks) Date: Tue, 28 Jul 2009 08:49:05 -0400 (EDT) Subject: [mapserver-users] distance between line and a given point usingmapscript In-Reply-To: <4A6E30220200008F000269B5@co5.dnr.state.mn.us> References: <4A6E30220200008F000269B5@co5.dnr.state.mn.us> Message-ID: <3903.74.167.248.129.1248785345.squirrel@webmail.ncsu.edu> I got the looping through each result. However, all distances are calculated to -1, which I know can't be right. In debugging, I'm also echo'ing the shape index for each result, but it's always the same. Am I constructing the layer correctly? // create array of points from database query results. for ($i=0; $row=mysql_fetch_assoc($result); $i++){ $points[$row['snum']][$i]['lat'] = $row['lat']; $points[$row['snum']][$i]['lon'] = $row['lon']; } // End loop through points // create map object $map = ms_newMapObj('wms.map'); // create new layer for hurricane tracks. $my_layer = ms_newLayerObj($map); // set some fields for this new layer $my_layer->set("toleranceunits","miles"); $my_layer->set("tolerance","20"); // Create new class and add TEMPLATE. $my_class = ms_newClassObj($my_layer); $my_class->set("template",'query_template.html'); // Loop through points, create line for each storm, and add track points to new line object. while (list($snum,$coordinates)=each($points)){ // Create new line object $my_line = ms_newLineObj(); // Loop through each point coordinate for this snum while (list($num,$coordinate)=each($coordinates)){ // Create new point object $my_point = ms_newpointObj(); $my_point->setXY($coordinate['lon'],$coordinate['lat']); // Add point to line object $my_line->add($my_point); } // done adding this storm's points to the line object // Now create a new shape object $my_shape = ms_newShapeObj(MS_SHAPE_LINE); $my_shape->add($my_line); // Add feature to the layer $my_layer->addFeature($my_shape); } // end creating and adding points to line objects and line objects to the layer. // Draw map. $map->draw(); // Make a new point object that will be our reference point. $my_ref_point = ms_newpointObj(); $my_ref_point->setXY(-78.7,35.4); // user-entered coordinates of where we are querying from. // Run a point query on the line object layer. if (@$my_layer->queryByPoint($my_point,MS_MULTIPLE,-1)==MS_SUCCESS){ // Loop through results. $num_results = $my_layer->getNumResults(); echo "# results = $num_results\n\n"; // Loop through each result for ($num=0; $num<$num_results; $num++){ echo "result # $num:\n"; // Get this result $my_result = $my_layer->getResult($num); //$my_shape = $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // Get the shape echo "shapeindex = ".$my_result->shapeindex."\n"; $my_shape = $my_layer->getFeature($my_result->shapeindex); // Get the feature echo "distanceToShape = ".$my_ref_point->distanceToShape($my_shape)."\n\n"; // calculate distance from ref point to feature } } On Mon, July 27, 2009 11:54 pm, Steve Lime wrote: > There are lots of samples that show you how to loop through a set of > search > results. There's a getNumResults() method for layer objects and then a > getResult() > method to retrieve each one individually. > > Steve > >>>> Mark Brooks 07/27/09 9:50 AM >>> > Steve, > > This is a huge help. The only thing I had not figured out was the > 'toleranceunits' and 'tolerance' fields. I appreciate your help! > > I intend to add many, possible hundreds, lines to a layer. Then query > it with a given reference point. How do I get the number of results and > then loop through each one? > > Best Regards, > Mark > > > Steve Lime wrote: >>> How do I query a layer with one or more line features to find all >>> features with X miles of a given point? >> >> Your line layer should like so: >> >> LAYER >> NAME 'lines' >> TYPE LINE >> ...other junk... >> TEMPLATE 'dummy' # to be queryable >> TOLERANCEUNITS MILES >> TOLERANCE X >> END >> >> Then in mapscript you'd do a >> >> $my_layer->queryByPoint($my_point, MS_MULTIPLE, -1); >> >> The buffer parameter is used to override a layer tolerance so setting to >> -1 tells >> the method to ignore it. If you do use it then it's given in the units >> of the layer >> being searched (before any projection). >> >> Does that help? >> >> Steve >> >>>>> Mark Brooks 07/24/09 3:26 PM >>> >> I'm trying to create several new line objects and then find the lines >> that are within x miles of a given point. (i.e., how far away a given >> point is from the track of a hurricane or the path of a ship). I'm >> having some difficulties and I hope someone can help. >> >> How do I query a layer with one or more line features to find all >> features with X miles of a given point? >> >> Here is how I'm approaching the problem in PHP: >> >> // Test array of points. This is used to make a line. >> $points[0]['lat'] = 35.5; >> $points[0]['lon'] = -78.8; >> $points[1]['lat'] = 36.5; >> $points[1]['lon'] = -79.8; >> $points[2]['lat'] = 37.5; >> $points[2]['lon'] = -80.1; >> >> // make new map object. >> $map = ms_newMapObj('mapdata/mymap.map'); >> >> // Create new line >> $my_line = ms_newLineObj(); >> >> // Loop through points, and add to the line >> while (list(,$coordinate)=each($points)){ >> >> // Create new point object >> $my_point = ms_newpointObj(); >> $my_point->setXY($coordinate['lon'],$coordinate['lat']); >> >> // Add point to line object >> $my_line->add($my_point); >> } >> >> // Now create a new shape >> $my_shape = ms_newShapeObj(MS_SHAPE_LINE); >> $my_shape->add($my_line); >> >> // create new layer >> $my_layer = ms_newLayerObj($map); >> >> // set some fields for this new layer >> //$my_layer->set("units","miles"); // does not seem to work as expected >> >> // Create new class and add TEMPLATE. This is required for queries on >> the layer to work? >> $my_class = ms_newClassObj($my_layer); >> $my_class->set("template",'/home/www/html/query_template.html'); >> >> // Add feature to the layer >> $my_layer->addFeature($my_shape); >> >> // Draw map. Query doesn't work if I don't do this now. >> $map->draw(); >> >> // Make a new point object that will be our ref point >> // to check how far away the line is from this point. >> $my_point = ms_newpointObj(); >> $my_point->setXY(-82,36); // lon, lat >> >> // Run a point query on the line object layer; layer must have a class >> with a LAYER TEMPLATE value >> // The third argument is the buffer tolerance. Default unit is pixels? >> Must figure out how to make miles or km. >> if ($my_layer->queryByPoint($my_point,MS_SINGLE,1)==MS_SUCCESS){ >> >> $my_result = $my_layer->getResult(0); // Get the result >> $my_layer = >> $my_layer->getShape($my_result->tileindex,$my_result->shapeindex); // >> Get the shape >> >> } >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users From Tim.Nolte at ipcswirelessinc.com Tue Jul 28 06:15:34 2009 From: Tim.Nolte at ipcswirelessinc.com (Nolte, Tim) Date: Tue, 28 Jul 2009 09:15:34 -0400 Subject: [mapserver-users] MapInfo Vertical Mapper/PlanetEV Data and MapServer In-Reply-To: <3903.74.167.248.129.1248785345.squirrel@webmail.ncsu.edu> References: <4A6E30220200008F000269B5@co5.dnr.state.mn.us> <3903.74.167.248.129.1248785345.squirrel@webmail.ncsu.edu> Message-ID: Does anyone have any experience with preparing MapInfo Vertical Mapper/PlanetEV data for use with MapServer? I'm looking for some tips and ways to streamline my process, as well as improve the performance of my final MapServer maps. ---- Timothy J Nolte - tnolte at ilpcs.com Network Planning Engineer iPCS Wireless, Inc. 4717 Broadmoor Ave, Suite G Kentwood, MI 49512 Office: 616-656-5163 PCS: 616-706-2438 Fax: 616-554-6484 Web: www.ipcswirelessinc.com From rashadkm at gmail.com Tue Jul 28 07:33:58 2009 From: rashadkm at gmail.com (Mohammed Rashad) Date: Tue, 28 Jul 2009 20:03:58 +0530 Subject: [mapserver-users] Python Message-ID: <50c7e3a0907280733h423ab27ap3a3a9e204f377f83@mail.gmail.com> Why python mapscript is not used as php mapscript?? What are problems using python mapscript?? If i am using python mapscript can i develop an webgis interface which can perform faster than interfaces built on php-mapscripts such as cartoweb,ka-map etc... Can i get more speed with python mapscript apps.. Is there any benefit in moving from php to python?? anybody please help Any suggestion are always welcomed.. Thanks in advance -- Regards, Mohammed Rashad K.M http://keralainfo.web4all.in/ +919605476742 -------------- next part -------------- An HTML attachment was scrubbed... URL: From coffee at uni-bonn.de Tue Jul 28 07:50:39 2009 From: coffee at uni-bonn.de (CoFIS Web) Date: Tue, 28 Jul 2009 16:50:39 +0200 Subject: [mapserver-users] Legend: Calling one of two layers shows both legend entries Message-ID: <4A6F103F.3010205@uni-bonn.de> Dear all, I am using a mapfile with two layers. When using Geomoose 2 as client and turning the first of these layers on from the legend, the respective signature will appear in the legend at its respective location (as expected), but also the legend location of the second layer. I tried using STATUS ON / OFF at layer level - but no success. How can I change this? I added two screenshots for clarification. Mapbook snippets are below. When calling the legend via URL in my browser, there is no such problem: http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01&layer=LAYER-02 shows both legend signatures http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01 shows only the signature of LAYER-01 Any hints on that? Thanks, Nils -- Center for Development Research Department of Ecology and Resource Management Walter-Flex-Strasse 3 53113 Bonn (Germany) Tel.: +49 (0) 228 - 73-1793 FAX: +49 (0) 228 - 73-1889 E-Mail: coffee at uni-bonn.de Web: http://www.cofis.info/atlas http://www.coffee.uni-bonn.de From mitchelljj98 at gmail.com Tue Jul 28 09:11:13 2009 From: mitchelljj98 at gmail.com (John Mitchell) Date: Tue, 28 Jul 2009 12:11:13 -0400 Subject: [mapserver-users] Can google earth skin format be converted by GDAL to be used within MapServer? Message-ID: Hi, Can google earth skin format be converted by GDAL to be used within MapServer? Thanks, John J. Mitchell -------------- next part -------------- An HTML attachment was scrubbed... URL: From bthoen at gisnet.com Tue Jul 28 09:47:27 2009 From: bthoen at gisnet.com (Bill Thoen) Date: Tue, 28 Jul 2009 10:47:27 -0600 Subject: [mapserver-users] Mapserver Security Message-ID: <4A6F2B9F.8060405@gisnet.com> I have some questions about securing a MapServer WMS. From the googlits I've gathered it seems that the easy way is to use Basic Authentication if you have Apache. I do have that on my Linux-based server, so I sealed off the directory in which I have my mapfile and web template. And so far so good. If a browser attempts to access that directory it is challenged to produce a valid username/password. However, in my CGI directory, I have a wrapper set up for this directory that looks something like this: MS_MAPFILE=/var/www/html/theDir/theFile.map export MS_MAPFILE QUERY_STRING="map=${MS_MAPFILE}&zoomdir=0&zoomsize=2&layer=counties&layer=states&... /var/www/cgi-bin/mapserv It works fine, but I don't know why it works because it accesses the mapfile in /theDir/, and /theDir is supposed to be password protected now by Apache. To make sure that I didn't already have a valid user in my browser, I shut it down and then tried again. When I ran that wrapper it picked up its info from the mapfile and then happily drew the map using the web template file that's also in that "protected" directory. It's as if there was no security at all! But if I steer my browser to that directory and try to access the mapfile directly, I get challenged to produce a password before I can access any file in that directory. I also just discovered another issue that should have been obvious but I didn't realize the implications until now. That is, if someone just tries a getCapabilities and gets a list of what's on my server, then they can view those layers via calls to getMap regardless of whether my map file is in a protected directory or not. But I thought they had to read the map file for getCapabilities to work, and yet on my system, the map files in protected directories seem to be just as friendly to strangers as the mapfiles in my public directories. So can anybody explain what I need to do to secure a Mapserver WMS site or can you point me to a "HOW TO" document that explains things? Also, are there any other possible security surprises that I probably don't know about? I'd like to get these information leaks plugged up. Thanks in advance, - Bill Thoen From andy at squeakycode.net Tue Jul 28 09:54:55 2009 From: andy at squeakycode.net (Andy Colson) Date: Tue, 28 Jul 2009 11:54:55 -0500 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6F2B9F.8060405@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> Message-ID: <4A6F2D5F.3030702@squeakycode.net> Bill Thoen wrote: > I have some questions about securing a MapServer WMS. From the googlits > I've gathered it seems that the easy way is to use Basic Authentication > if you have Apache. I do have that on my Linux-based server, so I sealed > off the directory in which I have my mapfile and web template. And so > far so good. If a browser attempts to access that directory it is > challenged to produce a valid username/password. > > However, in my CGI directory, I have a wrapper set up for this directory > that looks something like this: > > MS_MAPFILE=/var/www/html/theDir/theFile.map > export MS_MAPFILE > QUERY_STRING="map=${MS_MAPFILE}&zoomdir=0&zoomsize=2&layer=counties&layer=states&... > > /var/www/cgi-bin/mapserv > > It works fine, but I don't know why it works because it accesses the > mapfile in /theDir/, and /theDir is supposed to be password protected > now by Apache. To make sure that I didn't already have a valid user in > my browser, I shut it down and then tried again. When I ran that wrapper > it picked up its info from the mapfile and then happily drew the map > using the web template file that's also in that "protected" directory. > It's as if there was no security at all! > > But if I steer my browser to that directory and try to access the > mapfile directly, I get challenged to produce a password before I can > access any file in that directory. > > I also just discovered another issue that should have been obvious but > I didn't realize the implications until now. That is, if someone just > tries a getCapabilities and gets a list of what's on my server, then > they can view those layers via calls to getMap regardless of whether my > map file is in a protected directory or not. But I thought they had to > read the map file for getCapabilities to work, and yet on my system, the > map files in protected directories seem to be just as friendly to > strangers as the mapfiles in my public directories. > > So can anybody explain what I need to do to secure a Mapserver WMS site > or can you point me to a "HOW TO" document that explains things? Also, > are there any other possible security surprises that I probably don't > know about? I'd like to get these information leaks plugged up. > > Thanks in advance, > - Bill Thoen > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users Without reading/answering all your questions: apache security protects apache paths, so /xyz is protected because you put access rights on /xyz. you didnt put access rights on /cgi-bin, so /cgi-bin is not protected. A cgi program (mapserv in this case) does not know anything about apache security, so it can access any path it wants. Apache also has no control over cgi programs, so it cannot stop mapserv from acccessiinng (sp?) any path it wants. -Andy From aboudreault at mapgears.com Tue Jul 28 10:04:03 2009 From: aboudreault at mapgears.com (Alan Boudreault) Date: Tue, 28 Jul 2009 13:04:03 -0400 Subject: [mapserver-users] Python In-Reply-To: <50c7e3a0907280733h423ab27ap3a3a9e204f377f83@mail.gmail.com> References: <50c7e3a0907280733h423ab27ap3a3a9e204f377f83@mail.gmail.com> Message-ID: <200907281304.04056.aboudreault@mapgears.com> Hi Mohammed, See comments below... On July 28, 2009 10:33:58 am Mohammed Rashad wrote: > Why python mapscript is not used as php mapscript?? PHP is just a lot more popular/easier than python for dynamic websites. I think this is the only reason. > What are problems using python mapscript?? There is no problem... > If i am using python mapscript can i develop an webgis interface which can > perform faster than interfaces built on php-mapscripts such as > cartoweb,ka-map etc... There is a no significant performance gain between the two languages. > Can i get more speed with python mapscript apps.. I don't understand your question...... if the performance of your application would be very important, you wouldn't choice a mapscript binding. > > Is there any benefit in moving from php to python?? Of course... the use of python itself. ;) > > anybody please help > Any suggestion are always welcomed.. > > Thanks in advance Alan -- Alan Boudreault Mapgears http://www.mapgears.com From gregor at hostgis.com Tue Jul 28 10:47:21 2009 From: gregor at hostgis.com (Gregor at HostGIS) Date: Tue, 28 Jul 2009 10:47:21 -0700 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6F2B9F.8060405@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> Message-ID: <4A6F39A9.2030005@hostgis.com> > MS_MAPFILE=/var/www/html/theDir/theFile.map > export MS_MAPFILE > QUERY_STRING="map=${MS_MAPFILE}&zoomdir=0&zoomsize=2&layer=counties&layer=states&... > /var/www/cgi-bin/mapserv > it accesses the > mapfile in /theDir/, and /theDir is supposed to be password protected > now by Apache. Correct. But the browser is not calling /theDir/ as an URL. The browser is calling /cgi-bin/wrapper.cgi Therefore, Apache will only apply security for /cgi-bin/ to the request. After the request has been approved (since cgi-bin is not protected) Apache pays no attention at all to what the program DOES, including accessing file paths. > But if I steer my browser to that directory and try to access the > mapfile directly, I get challenged to produce a password before I can > access any file in that directory. Exactly right. Apache matches the URL or directory that the BROWSER requested, and in this case the browser was in fact trying to access /theDir/ > So can anybody explain what I need to do to secure a Mapserver WMS site > or can you point me to a "HOW TO" document that explains things? Sure. Remove MapServer from cgi-bin and place it somewhere where it will not be directly accessible from the web -- for example /usr/local/bin/mapserv. Modify your wrapper.cgi to use the new path to mapserv Then password-protect the directory which contains wrapper.cgi The result will be that one can only access MapServer through wrapper.cgi, and that wrapper.cgi will be password protected. If you're the only one using MapServer and only to serve "protected" layers, this should be just what you need. > are there any other possible security surprises that I probably don't > know about? I'd like to get these information leaks plugged up. As far as MapServer bugs, nope. This one isn't even an Apache bug; it's the way Apache works and is documented to work, just misunderstood. But following the above (password-protect cgi-bin and move mapserv out of it) will get past this surprise. -- HostGIS, Open Source solutions for the global GIS community Greg Allensworth - SysAdmin, Programmer, GIS Person, Security Network+ Server+ A+ Security+ From Steve.Lime at dnr.state.mn.us Tue Jul 28 10:57:25 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 28 Jul 2009 12:57:25 -0500 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6F2B9F.8060405@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> Message-ID: <4A6EF5B5.5157.008F.0@dnr.state.mn.us> Others may have different ideas but it seems to me you'll need to secure the wms binary rather than a directory. (I wouldn't store mapfiles and templates in a web accessible location anyway.) There are probably many ways to do this. One idea might be to have separate WMS binaries, one for password-protected stuff and another for public stuff, call 'em wms1 and wms2. Latest versions of MapServer allow you to set an env variable called MS_MAPFILE_PATTERN. This is used as a regex test against the requested mapfile and can help restrict what can be loaded. It's not fool proof but is a good start. You could set that variable conditionally based on what binary (wms1 or wms2) is requested (see mod_setenvif). You'd apply password protection against the wms1 in this case. You can go further and not allow full path mapfiles at all. (see MS_MAP_NO_PATH in this document: http://trac.osgeo.org/mapserver/wiki/EnvironmentVariables). In this case you'd set: SetEnv MS_MAP_NO_PATH 1 SetEnv WMS1_MAPFILE 'some path' SetEnv WMS2_MAPFILE 'some other path' and users could only use WMS1_MAPFILE or WMS2_MAPFILE in WMS calls (or CGI calls for that matter). You might even be able to secure one wms binary based on the mapfile requested. That is, any URL request with WMS1_MAPFILE requires basic authentication. Steve >>> On 7/28/2009 at 11:47 AM, in message <4A6F2B9F.8060405 at gisnet.com>, Bill Thoen wrote: > I have some questions about securing a MapServer WMS. From the googlits > I've gathered it seems that the easy way is to use Basic Authentication > if you have Apache. I do have that on my Linux-based server, so I sealed > off the directory in which I have my mapfile and web template. And so > far so good. If a browser attempts to access that directory it is > challenged to produce a valid username/password. > > However, in my CGI directory, I have a wrapper set up for this directory > that looks something like this: > > MS_MAPFILE=/var/www/html/theDir/theFile.map > export MS_MAPFILE > QUERY_STRING="map=${MS_MAPFILE}&zoomdir=0&zoomsize=2&layer=counties&layer=states& > ... > /var/www/cgi-bin/mapserv > > It works fine, but I don't know why it works because it accesses the > mapfile in /theDir/, and /theDir is supposed to be password protected > now by Apache. To make sure that I didn't already have a valid user in > my browser, I shut it down and then tried again. When I ran that wrapper > it picked up its info from the mapfile and then happily drew the map > using the web template file that's also in that "protected" directory. > It's as if there was no security at all! > > But if I steer my browser to that directory and try to access the > mapfile directly, I get challenged to produce a password before I can > access any file in that directory. > > I also just discovered another issue that should have been obvious but > I didn't realize the implications until now. That is, if someone just > tries a getCapabilities and gets a list of what's on my server, then > they can view those layers via calls to getMap regardless of whether my > map file is in a protected directory or not. But I thought they had to > read the map file for getCapabilities to work, and yet on my system, the > map files in protected directories seem to be just as friendly to > strangers as the mapfiles in my public directories. > > So can anybody explain what I need to do to secure a Mapserver WMS site > or can you point me to a "HOW TO" document that explains things? Also, > are there any other possible security surprises that I probably don't > know about? I'd like to get these information leaks plugged up. > > Thanks in advance, > - Bill Thoen > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From gregor at hostgis.com Tue Jul 28 11:15:47 2009 From: gregor at hostgis.com (Gregor at HostGIS) Date: Tue, 28 Jul 2009 11:15:47 -0700 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6EF5B5.5157.008F.0@dnr.state.mn.us> References: <4A6F2B9F.8060405@gisnet.com> <4A6EF5B5.5157.008F.0@dnr.state.mn.us> Message-ID: <4A6F4053.6030408@hostgis.com> > Latest versions of MapServer allow you to set an env variable called > MS_MAPFILE_PATTERN Holy cow! > SetEnv MS_MAP_NO_PATH 1 > SetEnv WMS1_MAPFILE 'some path' > SetEnv WMS2_MAPFILE 'some other path' Wow! Wow! Super cool. I hadn't even heard of these. Thanks for the tip! -- HostGIS, Open Source solutions for the global GIS community Greg Allensworth - SysAdmin, Programmer, GIS Person, Security Network+ Server+ A+ Security+ From Steve.Lime at dnr.state.mn.us Tue Jul 28 11:25:26 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Tue, 28 Jul 2009 13:25:26 -0500 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6F4053.6030408@hostgis.com> References: <4A6F2B9F.8060405@gisnet.com> <4A6EF5B5.5157.008F.0@dnr.state.mn.us> <4A6F4053.6030408@hostgis.com> Message-ID: <4A6EFC46.5157.008F.0@dnr.state.mn.us> Problem with MS_MAPFILE_PATTERN is that if using it for the path part of a mapfile you could use back references to get elsewhere. I imagine it's possible to craft a regex that wouldn't allow '..' but it's not trivial (examples welcome!). Not allowing path'd mapfiles at all is more restrictive and is certainly a goal of mine now when setting apps up. I should add that we are very interested in security improvements so please let us know if you run into issues or have ideas! Steve >>> On 7/28/2009 at 1:15 PM, in message <4A6F4053.6030408 at hostgis.com>, Gregor at HostGIS wrote: >> Latest versions of MapServer allow you to set an env variable called >> MS_MAPFILE_PATTERN > > Holy cow! > > >> SetEnv MS_MAP_NO_PATH 1 >> SetEnv WMS1_MAPFILE 'some path' >> SetEnv WMS2_MAPFILE 'some other path' > > Wow! Wow! > > Super cool. I hadn't even heard of these. Thanks for the tip! From aboudreault at mapgears.com Tue Jul 28 11:27:18 2009 From: aboudreault at mapgears.com (Alan Boudreault) Date: Tue, 28 Jul 2009 14:27:18 -0400 Subject: [mapserver-users] Python In-Reply-To: <50c7e3a0907281114m91893c4r3fe46c75df037c71@mail.gmail.com> References: <50c7e3a0907280733h423ab27ap3a3a9e204f377f83@mail.gmail.com> <200907281304.04056.aboudreault@mapgears.com> <50c7e3a0907281114m91893c4r3fe46c75df037c71@mail.gmail.com> Message-ID: <200907281427.18182.aboudreault@mapgears.com> What about OpenLayers ? On July 28, 2009 02:14:41 pm Mohammed Rashad wrote: > On Tue, Jul 28, 2009 at 10:34 PM, Alan Boudreault > > wrote: > > Hi Mohammed, > > > > See comments below... > > > > On July 28, 2009 10:33:58 am Mohammed Rashad wrote: > > > Why python mapscript is not used as php mapscript?? > > > > PHP is just a lot more popular/easier than python for dynamic websites. I > > think this is the only reason. > > > > > What are problems using python mapscript?? > > > > There is no problem... > > > > > If i am using python mapscript can i develop an webgis interface which > > > > can > > > > > perform faster than interfaces built on php-mapscripts such as > > > cartoweb,ka-map etc... > > > > There is a no significant performance gain between the two languages. > > > > > Can i get more speed with python mapscript apps.. > > > > I don't understand your question...... if the performance of your > > application > > would be very important, you wouldn't choice a mapscript binding. > > I need a webgis interface which is used in areas with low bandwidth such as > 30kb/s browsing speed. so webgis interface should display maps easily. I > used cartoweb in my last project > http://keralainfo.web4all.in/ . But it takes a lot time to open website. > I also tried KaMap. That's why i thought of changing to python mapscript. > Both of these uses php mapscript. Changing to python will help me??? > I googled python vs php and got positive response for python. I search and > found no webgis interface built on python. So i decided to develop one > application. > I want to know that python mapscript interface can reduce the problems > relating to speed which is low in other interfaces... > > If all these cant solve my problem , then using mapserver in CGI mode will > help????? > > > Thanks in advance > > > > Is there any benefit in moving from php to python?? > > > > Of course... the use of python itself. ;) > > > > > anybody please help > > > Any suggestion are always welcomed.. > > > > > > Thanks in advance > > > > Alan > > > > -- > > Alan Boudreault > > Mapgears > > http://www.mapgears.com -- Alan Boudreault Mapgears http://www.mapgears.com From andy at squeakycode.net Tue Jul 28 12:39:07 2009 From: andy at squeakycode.net (Andy Colson) Date: Tue, 28 Jul 2009 14:39:07 -0500 Subject: [mapserver-users] pretty maps Message-ID: <4A6F53DB.5080703@squeakycode.net> Hi All, I am a programmer, and not an artist or a mapper. (I cant even draw good stick figures.) So my question is, how do ya'll make pretty maps? Is there a tool you use? Are there standards/common colors/symbols that should be used? (I assume watter should be blue... and red-green dotted lines to show alien landing sites :-) ) Also, are there people/company's around that we could hire to make my maps look pretty? (I'm think of sending them my mapfile and shapefies, and they'd send me a mapfile back, and it wouldn't be too expensive) I don't have permission to spend money on this yet, but I can see it coming down the road. I'd like to know what my options are. Thanks, -Andy From David.Fawcett at state.mn.us Tue Jul 28 13:21:55 2009 From: David.Fawcett at state.mn.us (Fawcett, David) Date: Tue, 28 Jul 2009 15:21:55 -0500 Subject: [mapserver-users] pretty maps In-Reply-To: <4A6F53DB.5080703@squeakycode.net> Message-ID: <6246727221874A4FB8D3F9BBC37D9BD5056DA6F9@s-sp22.pca.state.mn.us> For thematic maps, Color Brewer is a lot of help. http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer_intro.html -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Andy Colson Sent: Tuesday, July 28, 2009 2:39 PM To: mapser all users Subject: [mapserver-users] pretty maps Hi All, I am a programmer, and not an artist or a mapper. (I cant even draw good stick figures.) So my question is, how do ya'll make pretty maps? Is there a tool you use? Are there standards/common colors/symbols that should be used? (I assume watter should be blue... and red-green dotted lines to show alien landing sites :-) ) Also, are there people/company's around that we could hire to make my maps look pretty? (I'm think of sending them my mapfile and shapefies, and they'd send me a mapfile back, and it wouldn't be too expensive) I don't have permission to spend money on this yet, but I can see it coming down the road. I'd like to know what my options are. Thanks, -Andy _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users From Bob.Basques at ci.stpaul.mn.us Tue Jul 28 14:00:59 2009 From: Bob.Basques at ci.stpaul.mn.us (Bob Basques) Date: Tue, 28 Jul 2009 16:00:59 -0500 Subject: [mapserver-users] pretty maps In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5056DA6F9@s-sp22.pca.state.mn.us> References: <4A6F53DB.5080703@squeakycode.net> <6246727221874A4FB8D3F9BBC37D9BD5056DA6F9@s-sp22.pca.state.mn.us> Message-ID: <4A6F20BB.163B.00A8.0@ci.stpaul.mn.us> I use this color tool as well: http://www.colorsontheweb.com/colorwizard.asp#wizard ( http://www.colorsontheweb.com/colorwizard.asp#wizard ) bobb >>> "Fawcett, David" wrote: For thematic maps, Color Brewer is a lot of help. http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer_intro.html -----Original Message----- From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Andy Colson Sent: Tuesday, July 28, 2009 2:39 PM To: mapser all users Subject: [mapserver-users] pretty maps Hi All, I am a programmer, and not an artist or a mapper. (I cant even draw good stick figures.) So my question is, how do ya'll make pretty maps? Is there a tool you use? Are there standards/common colors/symbols that should be used? (I assume watter should be blue... and red-green dotted lines to show alien landing sites :-) ) Also, are there people/company's around that we could hire to make my maps look pretty? (I'm think of sending them my mapfile and shapefies, and they'd send me a mapfile back, and it wouldn't be too expensive) I don't have permission to spend money on this yet, but I can see it coming down the road. I'd like to know what my options are. Thanks, -Andy _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list mapserver-users at lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From bfraser at geoanalytic.com Tue Jul 28 18:29:53 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Tue, 28 Jul 2009 19:29:53 -0600 (Mountain Daylight Time) Subject: [mapserver-users] Legend: Calling one of two layers shows both legend entries In-Reply-To: <4A6F103F.3010205@uni-bonn.de> References: <4A6F103F.3010205@uni-bonn.de> Message-ID: <.208.110.47.155.1248830993.squirrel@208.110.47.155> Nils, Sounds like a GeoMoose problem; you might try asking their email list. I seem to recall a similar problem with GeoMoose 1.6.1; try using underscores (_) instead of a dash (-) in the layer name. Best Regards, Brent Fraser > Dear all, > I am using a mapfile with two layers. > > When using Geomoose 2 as client and turning the first of these layers on > from the legend, the respective signature will appear in the legend at > its respective location (as expected), but also the legend location of > the second layer. > > I tried using STATUS ON / OFF at layer level - but no success. How can I > change this? I added two screenshots for clarification. Mapbook snippets > are below. > > When calling the legend via URL in my browser, there is no such problem: > http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01&layer=LAYER-02 > shows both legend signatures > > http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01 > shows only the signature of LAYER-01 > > Any hints on that? > > Thanks, > Nils > -- > Center for Development Research > Department of Ecology and Resource Management > > Walter-Flex-Strasse 3 > 53113 Bonn (Germany) > > Tel.: +49 (0) 228 - 73-1793 > FAX: +49 (0) 228 - 73-1889 > > E-Mail: coffee at uni-bonn.de > > Web: http://www.cofis.info/atlas > http://www.coffee.uni-bonn.de > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From bthoen at gisnet.com Wed Jul 29 03:41:29 2009 From: bthoen at gisnet.com (Bill Thoen) Date: Wed, 29 Jul 2009 04:41:29 -0600 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6F2B9F.8060405@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> Message-ID: <4A702759.6030306@gisnet.com> Thanks for the help, everyone. Good advice, as usual, and I think I've got it sorted out now. From youness.elmedraoui at somei.fr Wed Jul 29 03:55:40 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Wed, 29 Jul 2009 12:55:40 +0200 Subject: [mapserver-users] OGR Message-ID: An HTML attachment was scrubbed... URL: From snaperski at gmail.com Wed Jul 29 04:38:36 2009 From: snaperski at gmail.com (Raivo Alla) Date: Wed, 29 Jul 2009 14:38:36 +0300 Subject: [mapserver-users] label positioning Message-ID: <49dc012b0907290438p76ee12c0sc761985ad3f31b49@mail.gmail.com> Hello, I am labeling streets (again) and have two questions. I would be enormously thankful If anyone could help me. 1) First, if I set labels of the street line features to ANGLE FOLLOW, the output is sometimes weird as it is seen here: http://picasaweb.google.com/snaperski/Ort#5363839637825485026 : Aleksander Pushkin's street is positioned weirdly on the top. Then, if I change to ANGLE AUTO, then that label is positioned better: http://picasaweb.google.com/snaperski/Ort#5363839638912023874 I am aware that in case of ANGLE FOLLOW the label is placed different from ANGLE AUTO, but that concrete street (Aleksander Pushkin) contains only one line segment, so it should'nt be different. The label section in the mapfile: LABEL TYPE truetype FONT "arial" COLOR 240 240 240 OUTLINECOLOR 52 52 52 SIZE 9 priority 3 ENCODING UTF-8 force false MINDISTANCE 200 MINFEATURESIZE 15 ANGLE follow POSITION cc BUFFER 2 END 2) Another question arouses from previous screenshots (ie http://picasaweb.google.com/snaperski/Ort#5363839637825485026) and is an encoding problem. Namely, I could'nt display correctly symbol "?" - that one appears crippled on the screen. My system uses mapserver 5.4.1 and libiconv package version 1.13.1. Data to be displayed uses shapefile. I already tried to edit those street label values in the shapefile to make sure that input character "?" is from UTF-8 charset. I tried to change encoding to ISO-8859-1 also (in the mapfile), but nothing. So, I would appreciate a little help here ;) Best wishes, Raivo Alla From coffee at uni-bonn.de Wed Jul 29 04:48:46 2009 From: coffee at uni-bonn.de (CoFIS Web) Date: Wed, 29 Jul 2009 13:48:46 +0200 Subject: [mapserver-users] Legend: Calling one of two layers shows both legend entries In-Reply-To: <.208.110.47.155.1248830993.squirrel@208.110.47.155> References: <4A6F103F.3010205@uni-bonn.de> <.208.110.47.155.1248830993.squirrel@208.110.47.155> Message-ID: <4A70371E.4020605@uni-bonn.de> Dear Brent, thanks a lot. Replacing the dashes with underscores helped. I'll post that to the Geomoose list as well. Nils Brent Fraser schrieb: > Nils, > > Sounds like a GeoMoose problem; you might try asking their email list. > > I seem to recall a similar problem with GeoMoose 1.6.1; try using > underscores (_) instead of a dash (-) in the layer name. > > Best Regards, > Brent Fraser > > >> Dear all, >> I am using a mapfile with two layers. >> >> When using Geomoose 2 as client and turning the first of these layers on >> from the legend, the respective signature will appear in the legend at >> its respective location (as expected), but also the legend location of >> the second layer. >> >> I tried using STATUS ON / OFF at layer level - but no success. How can I >> change this? I added two screenshots for clarification. Mapbook snippets >> are below. >> >> When calling the legend via URL in my browser, there is no such problem: >> http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01&layer=LAYER-02 >> shows both legend signatures >> >> http://host/cgi-bin/mapserv?map=/srv/coffeeshop/map/conservation.map&mode=legend&layer=LAYER-01 >> shows only the signature of LAYER-01 >> >> Any hints on that? >> >> Thanks, >> Nils >> -- >> Center for Development Research >> Department of Ecology and Resource Management >> >> Walter-Flex-Strasse 3 >> 53113 Bonn (Germany) >> >> Tel.: +49 (0) 228 - 73-1793 >> FAX: +49 (0) 228 - 73-1889 >> >> E-Mail: coffee at uni-bonn.de >> >> Web: http://www.cofis.info/atlas >> http://www.coffee.uni-bonn.de >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- Center for Development Research Department of Ecology and Resource Management Walter-Flex-Strasse 3 53113 Bonn (Germany) Tel.: +49 (0) 228 - 73-1793 FAX: +49 (0) 228 - 73-1889 E-Mail: coffee at uni-bonn.de Web: http://www.cofis.info/atlas http://www.coffee.uni-bonn.de From szekerest at gmail.com Wed Jul 29 05:03:59 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Wed, 29 Jul 2009 14:03:59 +0200 Subject: [mapserver-users] OGR In-Reply-To: References: Message-ID: You can use the OGR C# bindings (add reference to ogr_csharp.dll). You can download binary packages for various MSVC versions from this location: http://vbkto.dyndns.org:1280/sdk/ Best regards, Tamas 2009/7/29 YOUNESS ELMEDRAOUI > Hi, > > can we develop with OGR in .net? use a classes of OGR? add a layer, create > a features, ...? > > tnks, > > Youness ELMEDRAOUI > Les informations figurant sur cet e-mail ont un caract?re strictement > confidentiel et sont exclusivement adress?es au destinataire mentionn? > ci-dessus.Tout usage, reproduction ou divulgation de cet e-mail est > strictement interdit si vous n'en ?tes pas le destinataire.Dans ce cas, > veuillez nous en avertir imm?diatement par la m?me voie et d?truire > l'original. Merci > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From youness.elmedraoui at somei.fr Wed Jul 29 06:49:30 2009 From: youness.elmedraoui at somei.fr (YOUNESS ELMEDRAOUI) Date: Wed, 29 Jul 2009 15:49:30 +0200 Subject: =?ISO-8859-1?Q?R=E9f=2E_=3A_Re=3A_[mapserver-users]_OGR?= In-Reply-To: References: , Message-ID: An HTML attachment was scrubbed... URL: From bthoen at gisnet.com Wed Jul 29 08:13:28 2009 From: bthoen at gisnet.com (Bill Thoen) Date: Wed, 29 Jul 2009 09:13:28 -0600 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A6EF5B5.5157.008F.0@dnr.state.mn.us> References: <4A6F2B9F.8060405@gisnet.com> <4A6EF5B5.5157.008F.0@dnr.state.mn.us> Message-ID: <4A706718.7010901@gisnet.com> Steve Lime wrote: > Others may have different ideas but it seems to me you'll need to secure the wms binary > rather than a directory. (I wouldn't store mapfiles and templates in a web accessible location > anyway.) There are probably many ways to do this. One idea might be to have separate > WMS binaries, one for password-protected stuff and another for public stuff, call 'em > wms1 and wms2. Latest versions of MapServer allow you to set an env variable called > MS_MAPFILE_PATTERN. This is used as a regex test against the requested mapfile and can > help restrict what can be loaded. It's not fool proof but is a good start. You could .... > I thought I knew how regex worked but I guess not. Attempting to follow your advice, I'm trying to run this file from a wrapper: /var/www/mapfiles/MyMapfile.map and in /etc/httpd/conf/httpd.conf, I've set the following line: SetEnv MS_MAPFILE_PATTERN='^/var/www/mapfiles/.*$' and restarted the httpd service. But what's wrong with my regex? I'm getting this error: msEvalRegex(): Regular expression error. String (/var/www/mapfiles/MyMapfile.map) failed expression test. From godwin.liz at gmail.com Wed Jul 29 08:28:50 2009 From: godwin.liz at gmail.com (Liz Godwin) Date: Wed, 29 Jul 2009 11:28:50 -0400 Subject: [mapserver-users] SLD Enabled flag for WMS Message-ID: I saw in the WMS Server documents online, that there is a flag - "ows_sld_enabled". I have tried it, and it doesn't seem to work. It doesn't look like it should yet, but I wanted to confirm I'm not going mad. My my expectations stem from reading bug #1395which details the implementation. The history.txt file modified with the update seems to suggest it was included after the 5.4.0 beta. However the bug milestone is set for 6.0. Also, the online docs already show it - so it's not clear to me if it's actually implemented in 5.4.1. Can someone clarify if it's current functionality or if it's in the trunk waiting for 6.0? Thanks! Liz Eidsness -------------- next part -------------- An HTML attachment was scrubbed... URL: From joe.nunn at usegis.co.uk Wed Jul 29 07:57:46 2009 From: joe.nunn at usegis.co.uk (Joe Nunn) Date: Wed, 29 Jul 2009 15:57:46 +0100 Subject: [mapserver-users] MapScript querybypoint using mapObj rather than layerObj Message-ID: <000001ca105c$ef8c37a0$cea4a6e0$@nunn@usegis.co.uk> Hi I am using MapScript to perform a querybypoint and I have succeeded in querying each individual layer however this is slow and I wonder if this is possible (as the documentation suggests) by querying the mapObj and come back results from all layers within the mapfile. My current code is: $o_map = ms_newMapObj("QueryCounties.map"); $v_nl = $o_map->numlayers; $o_point = ms_newPointObj(); $o_point->setXY($v_longitude, $v_latitude); //loop through layers in mapfile for($j = 0; $j < $v_nl; $j++) { $o_query_layer = $o_map->getLayer($j); $o_query_layer->set("status",1); //select layer if point lies within layer if ((@$o_query_layer->queryByPoint($o_point, MS_MULTIPLE, -1))==MS_SUCCESS) { $o_query_layer->open(); //gets the first result from each query $o_result = $o_query_layer->getResult(0); $o_shape = $o_query_layer->getShape(-1,$o_result->shapeindex); //return values from columns of shapefile $v_decade = $o_shape->values["NAME"]; And my attempt to perform queryByPoint on a mapObj is like this: $o_query = $o_map->queryByPoint($o_point, MS_MULTIPLE, -1); echo "query_results: ".$o_query; My Mapfile looks like this: MAP NAME "Counties" SHAPEPATH "C:\Data\ STATUS ON PROJECTION "init=epsg:4326" END LAYER NAME Counties1790 STATUS ON DATA "US_county_1790_region.shp" TYPE POLYGON CLASS NAME "counties" TEMPLATE "void" END END LAYER NAME Counties1810 STATUS ON DATA "US_county_1810_region.shp" TYPE POLYGON CLASS NAME "counties" TEMPLATE "void" END END ..... END Anyone know how to get this querybypoint working on a mapobj and if it will speed up the code? All the best Joe -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at gmail.com Wed Jul 29 10:50:20 2009 From: szekerest at gmail.com (Tamas Szekeres) Date: Wed, 29 Jul 2009 19:50:20 +0200 Subject: =?ISO-8859-1?B?UmU6IFLpZi4gOiBSZTogW21hcHNlcnZlci11c2Vyc10gT0dS?= In-Reply-To: References: Message-ID: 2009/7/29 YOUNESS ELMEDRAOUI > Thanls, > > but the link is not work. > It works just fine for me. Maybe your firewall doesn't permit accessing an outbound connection with TCP 1280. Best regards, Tamas -------------- next part -------------- An HTML attachment was scrubbed... URL: From yassefa at dmsolutions.ca Wed Jul 29 13:51:54 2009 From: yassefa at dmsolutions.ca (Yewondwossen Assefa) Date: Wed, 29 Jul 2009 16:51:54 -0400 Subject: [mapserver-users] SLD Enabled flag for WMS In-Reply-To: References: Message-ID: <4A70B66A.6000901@dmsolutions.ca> Liz Godwin wrote: > I saw in the WMS Server documents online, that there is a flag - > "ows_sld_enabled". I have tried it, and it doesn't seem to work. It > doesn't look like it should yet, but I wanted to confirm I'm not going mad. > > My my expectations stem from reading bug #1395 > which details the > implementation. > > The history.txt file modified with the update seems to suggest it was > included after the 5.4.0 beta. However the bug milestone is set for > 6.0. Also, the online docs already show it - so it's not clear to me if > it's actually implemented in 5.4.1. > > Can someone clarify if it's current functionality or if it's in the > trunk waiting for 6.0? > Hi Liz, It is only available in the trunk that would be released as 5.6 (or 6.0) sometime this fall The 5.4 branch was created just after the 5.4.0 betas (before actually the 5.4.0 release), and that would explain the history file entries. I will check for the docs and update it accrdingly. regards, > Thanks! > > Liz Eidsness > > > ------------------------------------------------------------------------ > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From alex.lagache at gmail.com Wed Jul 29 14:43:48 2009 From: alex.lagache at gmail.com (Alexandre Lagache) Date: Wed, 29 Jul 2009 17:43:48 -0400 Subject: [mapserver-users] PHPMapScript 5.4.0 > 5.4.1&2 queryByPoint ms_multiple weird results Message-ID: <76a916120907291443m371e02c6rac7395b5b051f508@mail.gmail.com> Hi all, I apologize if the question has already been asked, I looked the july archive and couldn't find it. When performing a : queryByPoint($click,MS_MULTIPLE, -1)==MS_SUCCESS) On PHPMapscript 5.4.0, getNumResults() returns the correct number of results. On 5.4.1 and 5.4.2 getNumResults() returns a single result. Has anything changed ? Does anyone know why it's doing this ? MapServer Version MapServer version 5.4.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=GEOS INPUT=EPPL7 INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE PHP MapScript Version ($Revision: 8814 $ $Date: 2009-03-19 14:18:36 -0800 (Thu, 19 Mar 2009) $) Thanks for any help ! Alex mapsgeek.com biketrip.org From adrian_gh.popa at romtelecom.ro Wed Jul 29 22:42:04 2009 From: adrian_gh.popa at romtelecom.ro (Adrian Popa) Date: Thu, 30 Jul 2009 08:42:04 +0300 Subject: [mapserver-users] Mapserver Security In-Reply-To: <4A706718.7010901@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> <4A6EF5B5.5157.008F.0@dnr.state.mn.us> <4A706718.7010901@gisnet.com> Message-ID: <4A7132AC.7060409@romtelecom.ro> Hello Bill. Try escaping the forward slashes... Although they are not a special character, usually regexes are called between forward slashes /REGEX/, so it could mess things up. Try: SetEnv MS_MAPFILE_PATTERN='^\/var\/www\/mapfiles\/.*$' Also, $ after .* is irrelevant... :) Good luck, Adrian Bill Thoen wrote: > Steve Lime wrote: >> Others may have different ideas but it seems to me you'll need to >> secure the wms binary rather than a directory. (I wouldn't store >> mapfiles and templates in a web accessible location >> anyway.) There are probably many ways to do this. One idea might be >> to have separate >> WMS binaries, one for password-protected stuff and another for public >> stuff, call 'em wms1 and wms2. Latest versions of MapServer allow you >> to set an env variable called >> MS_MAPFILE_PATTERN. This is used as a regex test against the >> requested mapfile and can >> help restrict what can be loaded. It's not fool proof but is a good >> start. You could .... >> > > I thought I knew how regex worked but I guess not. Attempting to > follow your advice, I'm trying to run this file from a wrapper: > /var/www/mapfiles/MyMapfile.map > > and in /etc/httpd/conf/httpd.conf, I've set the following line: > SetEnv MS_MAPFILE_PATTERN='^/var/www/mapfiles/.*$' > and restarted the httpd service. > > But what's wrong with my regex? I'm getting this error: > msEvalRegex(): Regular expression error. String > (/var/www/mapfiles/MyMapfile.map) failed expression test. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > From Antti.Roppola at daff.gov.au Thu Jul 30 00:12:50 2009 From: Antti.Roppola at daff.gov.au (Roppola, Antti - BRS) Date: Thu, 30 Jul 2009 17:12:50 +1000 Subject: [mapserver-users] Mapserver Security [SEC=UNCLASSIFIED] In-Reply-To: <4A6F2B9F.8060405@gisnet.com> References: <4A6F2B9F.8060405@gisnet.com> Message-ID: <61C2DEA055980B418D063F8646FCAEFC09E40F76@ACT001CL03EX03.agdaff.gov.au> Hi Bill, That's because it's not Apache reading the content in the directory. Apache is running the CGI and the CGI is accessing the directory directly. The CGI is already "behind" the access policy layer. As the CGI is usually running as the Apache user, it has the same access level as the Apache user (i.e. everything that any Apache process can see). It's not *that* great a problem as you can only interact with content using methods supported by the Mapserver CGI. For example, "draw". Mapserver is unlikely to have any methods that will enable wholesale, unaltered transfer of raw content, using mapserver to access most files is unlikely to elicit a useful response. Some ideas: - Wrap your CGI and use _established_ tools to test/assert canoncial paths on inputs * Within the CGI wrapper i.e. Might Perl's bless/taint be applicable? * using server level tools like mnodern equivalents to "mod_security"? * Home brew regexp style security tools are probably always faulty - Your CGI wrapper could use sudo to contain different contexts to different roles/permissions - Put sensitive data into a database (like PostGIS) and use RDBMS roles/permssions (with login details kept out of the map file!) - Use security frameworks like SELinux or AppArmor to assert contexts (example below) The last option makes it easy to restrict particular CGIs to particular paths and is probably easiest to manage. Say put a sensitive map ito a separate VirtualHost with its own CGI and use SELinux or AppArmor to restrict each VirtualHost to its own content. In a single host system, you could keep two CGIs and place a context policy on the generic mapserv.exe that keeps it out of "theDir". Here's a sample snippet from an AppArmor context that could be applied: 1) Allow that conext to execute object as in a specified location ("bin/*.sh", think "mapserv.exe") 2) Those executables are only allowed to read .jar files (think "path/*.map") from another specified location /data/some/app { ... /data/some/app/bin/*.sh rix, /data/some/app/common/**.jar r, ... By no means a "ready rolled" solution, but rather some avenues to explore. Cheers, Antti -----Original Message----- It works fine, but I don't know why it works because it accesses the mapfile in /theDir/, and /theDir is supposed to be password protected now by Apache. To make sure that I didn't already have a valid user in my browser, I shut it down and then tried again. When I ran that wrapper it picked up its info from the mapfile and then happily drew the map using the web template file that's also in that "protected" directory. It's as if there was no security at all! ------ IMPORTANT - This message has been issued by The Department of Agriculture, Fisheries and Forestry (DAFF). The information transmitted is for the use of the intended recipient only and may contain sensitive and/or legally privileged material. It is your responsibility to check any attachments for viruses and defects before opening or sending them on. Any reproduction, publication, communication, re-transmission, disclosure, dissemination or other use of the information contained in this e-mail by persons or entities other than the intended recipient is prohibited. The taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error please notify the sender and delete all copies of this transmission together with any attachments. If you have received this e-mail as part of a valid mailing list and no longer want to receive a message such as this one advise the sender by return e-mail accordingly. Only e-mail correspondence which includes this footer, has been authorised by DAFF ------ From coffee at uni-bonn.de Thu Jul 30 02:45:56 2009 From: coffee at uni-bonn.de (CoFIS Web) Date: Thu, 30 Jul 2009 11:45:56 +0200 Subject: [mapserver-users] Intervalls for EXPRESSION in CLASS object Message-ID: <4A716BD4.9060602@uni-bonn.de> Hello, I have a shape file with isohyets and want to draw only certain values at different map scales. The larger the scale, the more detail I want. Currently I use CLASS EXPRESSION ( ([value] = 250) OR ([value] = 500) OR ([value] = 750)...) MAXSCALEDENOM 1000000 MINSCALEDENOM 500000 .. END CLASS EXPRESSION ( ([value] = 100) OR ([value] = 200) OR ([value] = 300) ...) MAXSCALEDENOM 500000 MINSCALEDENOM 250000 .. END which becomes a pretty long list in large scale class definitions, since I got precipitation values up to 3000mm intervals. Can I do something like EXPRESSION ( ([value] = 'all values in 100 intervals') Thanks, Nils -- Center for Development Research Department of Ecology and Resource Management Walter-Flex-Strasse 3 53113 Bonn (Germany) Tel.: +49 (0) 228 - 73-1793 FAX: +49 (0) 228 - 73-1889 E-Mail: coffee at uni-bonn.de Web: http://www.cofis.info/atlas http://www.coffee.uni-bonn.de From andreas.albarello at territoriumonline.com Thu Jul 30 03:01:22 2009 From: andreas.albarello at territoriumonline.com (Andreas Albarello) Date: Thu, 30 Jul 2009 12:01:22 +0200 Subject: [mapserver-users] Intervalls for EXPRESSION in CLASS object In-Reply-To: <4A716BD4.9060602@uni-bonn.de> References: <4A716BD4.9060602@uni-bonn.de> Message-ID: <4A716F72.1040709@territoriumonline.com> On 30.07.2009 11:45, CoFIS Web wrote: > > Can I do something like > > EXPRESSION ( ([value] = 'all values in 100 intervals') Nils, you might want to try something like this using the modulo operator: EXPRESSION ( ([value] % 100) = 0 ) Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi Str. 12 I 39100 Bolzano/Bozen Phone: +39 0471 068611 Fax: +39 0471 068619 email: andreas.albarello at territoriumonline.com web: http://www.territoriumonline.com -------------------------------------------------------------------- From cnieman at dmsolutions.ca Thu Jul 30 05:36:32 2009 From: cnieman at dmsolutions.ca (Christy Nieman) Date: Thu, 30 Jul 2009 08:36:32 -0400 Subject: [mapserver-users] label SIZE parameter Message-ID: <4A7193D0.1040605@dmsolutions.ca> Good morning, I was just playing around with the sizes of some labels, and, after checking the mapfile documentation, I'm a little confused with the results I've seen. In the documentation it says that SIZE takes an integer for truetype fonts, but I was able to specify "SIZE 5.5" which did not give the same result as "SIZE 5" (which is what I would have expected) or "SIZE 6" with MapServer 5.4.2. Is this an error in the documentation? Thanks, Christy From JC at sodiplan.be Thu Jul 30 07:38:24 2009 From: JC at sodiplan.be (Julien Collaer) Date: Thu, 30 Jul 2009 16:38:24 +0200 Subject: [mapserver-users] Impossible to draw SDO Geometries from Oracle when SDO_GTYPE is 2007 and the interpretation is 2 (connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Message-ID: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> Hello list, I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a layer from an Oracle Spatial database (SDO geometries). Everything is working fine except for some geometries : multipolygons with interpretation 2 (vertex connected by arcs). Here is an example of such geometry : MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,1003,2,21,1003,2),MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196,83936.989422804,89883,83933,89886.989422804,83929.010577196,89883,83933,89879.010577196,83345,89445.010577196,83348.989422804,89449,83345,89452.989422804,83341.010577196,89449,83345,89445.010577196,82793,89490.010577196,82796.989422804,89494,82793,89497.989422804,82789.010577196,89494,82793,89490.010577196)) The layer is rendered but no feature are displayed. The geomtries are correct (verified with the Oracle MapViewer). If someone knows a solution for this case it will be very useful... Thanks in advance, Julien Collaer -------------- next part -------------- An HTML attachment was scrubbed... URL: From schatterjee at addisontx.gov Thu Jul 30 07:57:51 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Thu, 30 Jul 2009 09:57:51 -0500 Subject: [mapserver-users] How to enter the projected coordinates in Postgis Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D002797773@sc-exchange.addisongov.org> Hi, I have created 2 tables in postGIS and POSTGreSQL - in one, I am storing the GPS coordinates which are in the form of say lat= 32.4 and longitude = 72.45 ( which are in degrees) with SRID 2276 And in another I am capturing the user defined points from a projected map in mapserver. So here the points are having the projected coordinates like 2479589 7037631. The projection of the map has epsg=2276 Now I want to find the distance between the GPS points and the user defined point. For that I require the projected coordinates for both. So how can I store the projected coordinates of the GPS points in the table? Is there any function for that? Any help will be great! Thanks Suman ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* -------------- next part -------------- An HTML attachment was scrubbed... URL: From bthoen at gisnet.com Thu Jul 30 08:13:08 2009 From: bthoen at gisnet.com (Bill Thoen) Date: Thu, 30 Jul 2009 09:13:08 -0600 Subject: [mapserver-users] Mapserver Security [SEC=UNCLASSIFIED] In-Reply-To: <61C2DEA055980B418D063F8646FCAEFC09E40F76@ACT001CL03EX03.agdaff.gov.au> References: <4A6F2B9F.8060405@gisnet.com> <61C2DEA055980B418D063F8646FCAEFC09E40F76@ACT001CL03EX03.agdaff.gov.au> Message-ID: <4A71B884.9010108@gisnet.com> Roppola, Antti - BRS wrote: > That's because it's not Apache reading the content in the directory. > Apache is running the CGI and the CGI is accessing the directory > directly. The CGI is already "behind" the access policy layer. > > As the CGI is usually running as the Apache user, it has the same access > level as the Apache user (i.e. everything that any Apache process can > see). > I think I've got this now, but for a newbie to CGI, this is a subtlety that's easy to miss. I was so focused on preventing unauthorized browser access (because I kept seeing MapServer in a browser context only) that I completely forgot that there's plenty of other vectors into the data to consider. And in this case, even protecting the WMS image of the data is important. It would be bad news if an attacker could get to the raw data, but it would be just as bad if they got a look at maps made from it, too. I like the idea of virtual hosts; I think I'll look more into that. - Bill Thoen From Steve.Lime at dnr.state.mn.us Thu Jul 30 08:22:27 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 30 Jul 2009 10:22:27 -0500 Subject: [mapserver-users] Impossible to draw SDO Geometries from Oraclewhen SDO_GTYPE is 2007 and the interpretation is 2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) In-Reply-To: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> References: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> Message-ID: <4A717464.5157.008F.0@dnr.state.mn.us> Does it matter if you're using GD vs. AGG? They have slightly different transformation routines... Could you post a picture of how it's supposed to look? Steve >>> On 7/30/2009 at 9:38 AM, in message <38FFFA96BE9C224893B3559563614BEA12CC45 at begemsrv01.sodiplan-begem.local>, "Julien Collaer" wrote: > Hello list, > > I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a > layer from an Oracle Spatial database (SDO geometries). > Everything is working fine except for some geometries : multipolygons with > interpretation 2 (vertex connected by arcs). > > Here is an example of such geometry : > MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,100 > 3,2,21,1003,2),MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196,83936.989422804 > ,89883,83933,89886.989422804,83929.010577196,89883,83933,89879.010577196,8334 > 5,89445.010577196,83348.989422804,89449,83345,89452.989422804,83341.010577196 > ,89449,83345,89445.010577196,82793,89490.010577196,82796.989422804,89494,8279 > 3,89497.989422804,82789.010577196,89494,82793,89490.010577196)) > The layer is rendered but no feature are displayed. > > The geomtries are correct (verified with the Oracle MapViewer). > > If someone knows a solution for this case it will be very useful... > > Thanks in advance, > > Julien Collaer From JC at sodiplan.be Thu Jul 30 08:37:57 2009 From: JC at sodiplan.be (Julien Collaer) Date: Thu, 30 Jul 2009 17:37:57 +0200 Subject: =?iso-8859-1?Q?RE=A0=3A_=5Bmapserver-users=5D_Impossible_to_draw_SDO_Geom?= =?iso-8859-1?Q?etries_fromOraclewhen_SDO=5FGTYPE_is_2007_and_the_interpre?= =?iso-8859-1?Q?tation_is2=28connectivity_by_arcs_=3A_SDO=5FELEM=5FINF?= =?iso-8859-1?Q?O=281=2C_1003=2C_2=2C_=5B=2E=2E=2E=5D=29_=29?= References: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> <4A716E79.163B.00A8.0@ci.stpaul.mn.us> Message-ID: <38FFFA96BE9C224893B3559563614BEA12CC46@begemsrv01.sodiplan-begem.local> Hello Bob, thanks for your fast response. These geometries are generated by Oracle : SDO_Buffer function on multipoints geometries. When i look to the SDO_GEOM example,there are three geometries (polygons) composed of five points with the first point being the same of the last one : MDSYS.SDO_GEOMETRY(2007,26273,null, MDSYS.SDO_ELEM_INFO_ARRAY( 1,1003,2, 11,1003,2, 21,1003,2), MDSYS.SDO_ORDINATE_ARRAY( --Geom 1 : 83933, 89879.010577196, 83936.989422804, 89883, 83933, 89886.989422804, 83929.010577196, 89883, 83933, 89879.010577196, --Geom 2 : 83345, 89445.010577196, 83348.989422804, 89449, 83345, 89452.989422804, 83341.010577196, 89449, 83345, 89445.010577196, --Geom 3 : 82793, 89490.010577196, 82796.989422804, 89494, 82793, 89497.989422804, 82789.010577196, 89494, 82793, 89490.010577196 )) So i suppose that the problem must be something else. Other thing : If i change manually (but, of course, it's not a solution for the production version) the interpretation of the vertex from 2 to 1 (arcs to lines) Mapserver is able to draw the rectangles. Thanks, Julien Collaer -------- Message d'origine-------- De: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Date: jeu. 30/07/2009 16:57 ?: Julien Collaer Objet : Re: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is 2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Julien, Looking at the SDO description in the Oracle MAN for . . . ----------- 1003 or 2003 2 Polygon made up of a connected sequence of circular arcs that closes on itself. The end point of the last arc is the same as the start point of the first arc. Each circular arc is described using three coordinates: the start point of the arc, any point on the arc, and the end point of the arc. The coordinates for a point designating the end of one arc and the start of the next arc are not repeated. For example, five coordinates are used to describe a polygon made up of two connected circular arcs. Points 1, 2, and 3 define the first arc, and points 3, 4, and 5 define the second arc. The coordinates for points 1 and 5 must be the same (tolerance is not considered), and point 3 is not repeated. ----------- It looks like the first and last points need to be the same and your record shows different points for the first and last entries. You may have one extra point on the end as well (I think), or maybe you are just missing the last point on the end . . . bobb + >>> "Julien Collaer" wrote: Hello list, I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a layer from an Oracle Spatial database (SDO geometries). Everything is working fine except for some geometries : multipolygons with interpretation 2 (vertex connected by arcs). Here is an example of such geometry : MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,1003,2,21,1003,2), MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196, 83936.989422804,89883, 83933,89886.989422804, 83929.010577196,89883, 83933,89879.010577196, 83345,89445.010577196, 83348.989422804,89449, 83345,89452.989422804, 83341.010577196,89449, 83345,89445.010577196, 82793,89490.010577196, 82796.989422804,89494, 82793,89497.989422804, 82789.010577196,89494, 82793,89490.010577196)) The layer is rendered but no feature are displayed. The geomtries are correct (verified with the Oracle MapViewer). If someone knows a solution for this case it will be very useful... Thanks in advance, Julien Collaer -------------- next part -------------- An HTML attachment was scrubbed... URL: From JC at sodiplan.be Thu Jul 30 08:57:17 2009 From: JC at sodiplan.be (Julien Collaer) Date: Thu, 30 Jul 2009 17:57:17 +0200 Subject: =?iso-8859-1?Q?RE=A0=3A_=5Bmapserver-users=5D_Impossible_to_draw_SDO_Geom?= =?iso-8859-1?Q?etries_fromOraclewhen_SDO=5FGTYPE_is_2007_and_the_interpre?= =?iso-8859-1?Q?tation_is2=28connectivity_by_arcs_=3A_SDO=5FELEM=5FINF?= =?iso-8859-1?Q?O=281=2C_1003=2C_2=2C_=5B=2E=2E=2E=5D=29_=29?= References: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> <4A717464.5157.008F.0@dnr.state.mn.us> Message-ID: <38FFFA96BE9C224893B3559563614BEA12CC47@begemsrv01.sodiplan-begem.local> Hello Steve, I'm currently using AGG driver. OUTPUTFORMAT NAME jpeg DRIVER "AGG/JPEG" MIMETYPE "image/jpeg" IMAGEMODE RGB EXTENSION "jpg" FORMATOPTION "QUALITY=80" TRANSPARENT TRUE END I've just tested with GD and there is no change... the problem is still there. I've put an attachment to this email : the png image from Oracle Mapviewer : the difference is that with Mapserver only the non circular geometries are drawed (These geometries are of interpretation 1 (vertex joined by lines and not arcs)). Thanks, Julien Collaer -------- Message d'origine-------- De: Steve Lime [mailto:Steve.Lime at dnr.state.mn.us] Date: jeu. 30/07/2009 17:22 ?: mapserver-users at lists.osgeo.org; Julien Collaer Objet : Re: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Does it matter if you're using GD vs. AGG? They have slightly different transformation routines... Could you post a picture of how it's supposed to look? Steve >>> On 7/30/2009 at 9:38 AM, in message <38FFFA96BE9C224893B3559563614BEA12CC45 at begemsrv01.sodiplan-begem.local>, "Julien Collaer" wrote: > Hello list, > > I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a > layer from an Oracle Spatial database (SDO geometries). > Everything is working fine except for some geometries : multipolygons with > interpretation 2 (vertex connected by arcs). > > Here is an example of such geometry : > MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,100 > 3,2,21,1003,2),MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196,83936.989422804 > ,89883,83933,89886.989422804,83929.010577196,89883,83933,89879.010577196,8334 > 5,89445.010577196,83348.989422804,89449,83345,89452.989422804,83341.010577196 > ,89449,83345,89445.010577196,82793,89490.010577196,82796.989422804,89494,8279 > 3,89497.989422804,82789.010577196,89494,82793,89490.010577196)) > The layer is rendered but no feature are displayed. > > The geomtries are correct (verified with the Oracle MapViewer). > > If someone knows a solution for this case it will be very useful... > > Thanks in advance, > > Julien Collaer -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: oracle_mapviewer.png Type: image/png Size: 6590 bytes Desc: oracle_mapviewer.png URL: From nkjoep at gmail.com Thu Jul 30 09:49:30 2009 From: nkjoep at gmail.com (=?ISO-8859-15?Q?Andrea_Dess=EC?=) Date: Thu, 30 Jul 2009 18:49:30 +0200 Subject: [mapserver-users] SLD with Mapserver 5.4.2 Message-ID: <4A71CF1A.9070004@gmail.com> Hi, i've started using Mapserver few days ago and i cannot apply SLD styles. i'm using MapServer version 5.4.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS SUPPORTS=GEOS INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE under Ubuntu 9.04. I want to user mapserver as WMS Server and the apply SLD styles on the fly... the common query is: http://localhost/cgi-bin/wms?SERVICE=WMS& VERSION=1.1.1& REQUEST=GetMap& BBOX=-74.012362,40.752314,-73.948216,40.791051& SRS=EPSG:4326& WIDTH=500& HEIGHT=500& LAYERS=myground,myroads& FORMAT=image/gif& TRANSPARENT=TRUE& SLD=http://localhost/mysld.xml But sld is not applying. The question is: there are specific parameters for using SLD in mapfile? I'm feeling a bit confused about this. Thank You, -- Andrea From shanksje at yahoo.com Thu Jul 30 10:25:45 2009 From: shanksje at yahoo.com (Jennifer Shanks) Date: Thu, 30 Jul 2009 10:25:45 -0700 (PDT) Subject: [mapserver-users] label character spacing and curves Message-ID: <379300.45451.qm@web83408.mail.sp1.yahoo.com> Hello, I'm having trouble with labels that follow a curve. When the curves are tight, the letters are too close together and appear in a jumble. I'm using a true type font arial. I'd like to space the characters but don't see an option for that. What have others done to solve this problem? Are there suggestions for other true type fonts that have a wider spacing? Any other ideas? Thanks, Jennifer From woodbri at swoodbridge.com Thu Jul 30 10:56:55 2009 From: woodbri at swoodbridge.com (Stephen Woodbridge) Date: Thu, 30 Jul 2009 13:56:55 -0400 Subject: [mapserver-users] label character spacing and curves In-Reply-To: <379300.45451.qm@web83408.mail.sp1.yahoo.com> References: <379300.45451.qm@web83408.mail.sp1.yahoo.com> Message-ID: <4A71DEE7.3020001@swoodbridge.com> Jennifer Shanks wrote: > Hello, > > I'm having trouble with labels that follow a curve. When the curves > are tight, the letters are too close together and appear in a > jumble. I'm using a true type font arial. I'd like to space the > characters but don't see an option for that. What have others done > to solve this problem? Are there suggestions for other true type > fonts that have a wider spacing? Any other ideas? Hi Jennifer, Unfortunately, I'm unaware of any current way to work around this problem, but Thomas would be the expert on this. There are couple of issues in dealing with this problem in the code but they have not been implemented mostly because they would have an impact on performance and require time/effort of a developer. Hi Thomas, I'm not sure if you have thought about this at all, but here are a few ideas: 1) check that the bbox of the character being placed against the prior character and increase the space between the character if they collide. 2) on segments that double back on themselves, like bowties, you might need to perform the above check on all prior characters, taking more time, to avoid these type of collisions. These checks might be dynamically enabled/disabled doing a quick scan of the part of the line segment that is being labeled and checking the angle between segments and maybe the length of the segments to see if there may be a need to do additional checking. From Steve.Lime at dnr.state.mn.us Thu Jul 30 12:04:33 2009 From: Steve.Lime at dnr.state.mn.us (Steve Lime) Date: Thu, 30 Jul 2009 14:04:33 -0500 Subject: [mapserver-users] label SIZE parameter In-Reply-To: <4A7193D0.1040605@dmsolutions.ca> References: <4A7193D0.1040605@dmsolutions.ca> Message-ID: <4A71A871.5157.008F.0@dnr.state.mn.us> Yup, a documentation error. Doubles have been supported for label size, and style size/width since 5.2 I believe. If you would, please file a documentation ticket in trac. trac.osgeo.org/mapserver Steve >>> On 7/30/2009 at 7:36 AM, in message <4A7193D0.1040605 at dmsolutions.ca>, Christy Nieman wrote: > Good morning, > > I was just playing around with the sizes of some labels, and, after > checking the mapfile documentation, I'm a little confused with the > results I've seen. In the documentation it says that SIZE takes an > integer for truetype fonts, but I was able to specify "SIZE 5.5" which > did not give the same result as "SIZE 5" (which is what I would have > expected) or "SIZE 6" with MapServer 5.4.2. Is this an error in the > documentation? > > Thanks, > Christy > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users From mschulz at webgis.de Thu Jul 30 12:27:28 2009 From: mschulz at webgis.de (Michael Schulz) Date: Thu, 30 Jul 2009 21:27:28 +0200 Subject: [mapserver-users] SLD with Mapserver 5.4.2 In-Reply-To: <4A71CF1A.9070004@gmail.com> References: <4A71CF1A.9070004@gmail.com> Message-ID: Hi Andrea, to use SLD you won't need very special mapfile configuration. You should pay attention to setting the imgpath parameter of the web section correctly, i.e. accessible and writable by mapserver-cgi, since the sld's are stored there temporarily while/after downloading them from the specified URL. I am not aware of any other special configuration, but very helpful are the debugging outputs, that you can enable with the keyword DEBUG "on" at map or layer level. I find it most convenient to specify an errorfile path via CONFIG "MS_ERRORFILE" "/ms4w/tmp/ms_error.txt" at map level. Be sure to set the SLD's NamedLayer Name tag value exactly the same as your mapfile's layer name you want to style. Cheers, Michael 2009/7/30 Andrea Dess? : > Hi, > > i've started using Mapserver few days ago and i cannot apply SLD styles. > > i'm using ?MapServer version 5.4.2 > OUTPUT=GIF OUTPUT=PNG > OUTPUT=JPEG OUTPUT=WBMP > OUTPUT=SVG > SUPPORTS=PROJ > SUPPORTS=AGG > SUPPORTS=FREETYPE > SUPPORTS=ICONV > SUPPORTS=WMS_SERVER > SUPPORTS=WMS_CLIENT > SUPPORTS=WFS_SERVER > SUPPORTS=WFS_CLIENT > SUPPORTS=WCS_SERVER > SUPPORTS=FASTCGI > SUPPORTS=THREADS > SUPPORTS=GEOS > INPUT=EPPL7 > INPUT=POSTGIS > INPUT=OGR > INPUT=GDAL > INPUT=SHAPEFILE > > under Ubuntu 9.04. > > I want to user mapserver as WMS Server and the apply SLD styles on the > fly... the common query is: > http://localhost/cgi-bin/wms?SERVICE=WMS& > VERSION=1.1.1& > REQUEST=GetMap& > BBOX=-74.012362,40.752314,-73.948216,40.791051& > SRS=EPSG:4326& > WIDTH=500& > HEIGHT=500& > LAYERS=myground,myroads& > FORMAT=image/gif& > TRANSPARENT=TRUE& > SLD=http://localhost/mysld.xml > > But sld is not applying. > > The question is: there are specific parameters for using SLD in mapfile? > I'm feeling a bit confused about this. > > Thank You, > -- > Andrea > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Aufwind durch Wissen! Qualifizierte Open Source Schulungen bei der http://www.foss-akademie.de/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------------------------------------- Michael Schulz mschulz at webgis.de in medias res Gesellschaft f?r Informationstechnologie mbH +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ Schwimmbadstra?e 2 D-79100 Freiburg i. Br. Tel: +49 (0)761 705798-102 Tel: +49 (0)761 705798-0 Fax: +49 (0)761 705798-09 +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ http://www.webgis.de / http://www.zopecms.de -------------------------------------------------------------- Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg From temiz at deprem.gov.tr Thu Jul 30 23:47:20 2009 From: temiz at deprem.gov.tr (Ahmet Temiz) Date: Fri, 31 Jul 2009 09:47:20 +0300 Subject: [mapserver-users] confused with regular expression Message-ID: <20090731064126.M5152@deprem.gov.tr> hello I am confused with regular expression. EXPRESSION ('[lkod]' =~ /andezit | bazalt/' ) I just want to choose "andezit | bazalt" containing records. But I got nothing. can you tell what the correct expression is ? regards -- Open WebMail Project (http://openwebmail.org) -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. From mschulz at webgis.de Fri Jul 31 00:30:28 2009 From: mschulz at webgis.de (Michael Schulz) Date: Fri, 31 Jul 2009 09:30:28 +0200 Subject: [mapserver-users] confused with regular expression In-Reply-To: <20090731064126.M5152@deprem.gov.tr> References: <20090731064126.M5152@deprem.gov.tr> Message-ID: Hi, maybe try removing the last quotation mark after the regex. Also, I think the spaces are taken into account in your regex, so you should try remove them and see if it works. I think sth. like EXPRESSION ('[lkod]' =~ /andezit|bazalt/ ) could work. If the field "lkod" only contains the rock names and nothing else you could try the logical expression form: EXPRESSION ('[lkod]' == 'andezit' OR '[lkod]' == 'bazalt') Cheers, Michael 2009/7/31 Ahmet Temiz : > hello > > I am confused with regular expression. > > EXPRESSION ('[lkod]' ?=~ /andezit | bazalt/' ) > > I just want to choose "andezit | bazalt" containing records. > > But I got nothing. > > can you tell what the correct expression is ? > > regards > > -- > Open WebMail Project (http://openwebmail.org) > > > -- > This message has been scanned for viruses and > dangerous content by MailScanner, and is > believed to be clean. > > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Aufwind durch Wissen! Qualifizierte Open Source Schulungen bei der http://www.foss-akademie.de/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------------------------------------- Michael Schulz mschulz at webgis.de in medias res Gesellschaft f?r Informationstechnologie mbH +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ Schwimmbadstra?e 2 D-79100 Freiburg i. Br. Tel: +49 (0)761 705798-102 Tel: +49 (0)761 705798-0 Fax: +49 (0)761 705798-09 +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ http://www.webgis.de / http://www.zopecms.de -------------------------------------------------------------- Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg From nkjoep at gmail.com Fri Jul 31 01:45:29 2009 From: nkjoep at gmail.com (=?UTF-8?Q?Andrea_Dess=C3=AC?=) Date: Fri, 31 Jul 2009 10:45:29 +0200 Subject: [mapserver-users] SLD with Mapserver 5.4.2 In-Reply-To: References: <4A71CF1A.9070004@gmail.com> Message-ID: <52632d9e0907310145r2fe77b56nfb6a307e7ad87a70@mail.gmail.com> Hi Michael, Thank you for your answer :) Now SLD is working i had a mistake with names references. I have just another question: how is possible to "add" a style using SLD without overriding the whole server style? I explain what i want to do: I have a map served by MapServer, so a mapfile with layers and styles. I want to add a style with "new" characteristics (could be outline or overriding just the color of the text). Thanks, Andrea 2009/7/30 Michael Schulz > Hi Andrea, > > to use SLD you won't need very special mapfile configuration. You > should pay attention to setting the imgpath parameter of the web > section correctly, i.e. accessible and writable by mapserver-cgi, > since the sld's are stored there temporarily while/after downloading > them from the specified URL. I am not aware of any other special > configuration, but very helpful are the debugging outputs, that you > can enable with the keyword DEBUG "on" at map or layer level. I find > it most convenient to specify an errorfile path via CONFIG > "MS_ERRORFILE" "/ms4w/tmp/ms_error.txt" at map level. > > Be sure to set the SLD's NamedLayer Name tag value exactly the same as > your mapfile's layer name you want to style. > > Cheers, Michael > > > 2009/7/30 Andrea Dess? : > > Hi, > > > > i've started using Mapserver few days ago and i cannot apply SLD styles. > > > > i'm using MapServer version 5.4.2 > > OUTPUT=GIF OUTPUT=PNG > > OUTPUT=JPEG OUTPUT=WBMP > > OUTPUT=SVG > > SUPPORTS=PROJ > > SUPPORTS=AGG > > SUPPORTS=FREETYPE > > SUPPORTS=ICONV > > SUPPORTS=WMS_SERVER > > SUPPORTS=WMS_CLIENT > > SUPPORTS=WFS_SERVER > > SUPPORTS=WFS_CLIENT > > SUPPORTS=WCS_SERVER > > SUPPORTS=FASTCGI > > SUPPORTS=THREADS > > SUPPORTS=GEOS > > INPUT=EPPL7 > > INPUT=POSTGIS > > INPUT=OGR > > INPUT=GDAL > > INPUT=SHAPEFILE > > > > under Ubuntu 9.04. > > > > I want to user mapserver as WMS Server and the apply SLD styles on the > > fly... the common query is: > > http://localhost/cgi-bin/wms?SERVICE=WMS& > > VERSION=1.1.1& > > REQUEST=GetMap& > > BBOX=-74.012362,40.752314,-73.948216,40.791051& > > SRS=EPSG:4326& > > WIDTH=500& > > HEIGHT=500& > > LAYERS=myground,myroads& > > FORMAT=image/gif& > > TRANSPARENT=TRUE& > > SLD=http://localhost/mysld.xml > > > > But sld is not applying. > > > > The question is: there are specific parameters for using SLD in mapfile? > > I'm feeling a bit confused about this. > > > > Thank You, > > -- > > Andrea > > > > _______________________________________________ > > mapserver-users mailing list > > mapserver-users at lists.osgeo.org > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > > > > > -- > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > Aufwind durch Wissen! > > Qualifizierte Open Source Schulungen bei der > http://www.foss-akademie.de/ > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > ----------------------------------------------------------- > Michael Schulz > mschulz at webgis.de > > in medias res > Gesellschaft f?r Informationstechnologie mbH > > +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ > > Schwimmbadstra?e 2 > D-79100 Freiburg i. Br. > > Tel: +49 (0)761 705798-102 > Tel: +49 (0)761 705798-0 > Fax: +49 (0)761 705798-09 > > +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ > > http://www.webgis.de / http://www.zopecms.de > -------------------------------------------------------------- > Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck > Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg > _______________________________________________ > mapserver-users mailing list > mapserver-users at lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/mapserver-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From pvoudouris at gaiocorp.com Fri Jul 31 01:49:54 2009 From: pvoudouris at gaiocorp.com (Pano Voudouris) Date: Fri, 31 Jul 2009 11:49:54 +0300 Subject: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) In-Reply-To: <38FFFA96BE9C224893B3559563614BEA12CC46@begemsrv01.sodiplan-begem.local> References: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> <4A716E79.163B.00A8.0@ci.stpaul.mn.us> <38FFFA96BE9C224893B3559563614BEA12CC46@begemsrv01.sodiplan-begem.local> Message-ID: <001401ca11bb$e2c9c130$a85d4390$@com> Julien, I know you said you verified the geometries by Mapviewer but have you tried the sdo_validate layer routine? Just to be sure... Example from the manual: -- Is a layer valid? (First, create the result table.) CREATE TABLE val_results (sdo_rowid ROWID, result varchar2(1000)); -- (Next statement must be on one command line.) CALL SDO_GEOM.VALIDATE_LAYER_WITH_CONTEXT('COLA_MARKETS','SHAPE','VAL_RESULTS'); Call completed. SQL> SELECT * from val_results; SDO_ROWID ------------------ RESULT ---------------------------------------------------------------------------- ---- Rows Processed <12> AAABXNAABAAAK+YAAC 13349 [Element <1>] [Ring <1>][Edge <1>][Edge <3>] Cheers, Pano From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Julien Collaer Sent: 30 July 2009 18:38 To: Bob Basques; mapserver-users at lists.osgeo.org Subject: RE : [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Hello Bob, thanks for your fast response. These geometries are generated by Oracle : SDO_Buffer function on multipoints geometries. When i look to the SDO_GEOM example,there are three geometries (polygons) composed of five points with the first point being the same of the last one : MDSYS.SDO_GEOMETRY(2007,26273,null, MDSYS.SDO_ELEM_INFO_ARRAY( 1,1003,2, 11,1003,2, 21,1003,2), MDSYS.SDO_ORDINATE_ARRAY( --Geom 1 : 83933, 89879.010577196, 83936.989422804, 89883, 83933, 89886.989422804, 83929.010577196, 89883, 83933, 89879.010577196, --Geom 2 : 83345, 89445.010577196, 83348.989422804, 89449, 83345, 89452.989422804, 83341.010577196, 89449, 83345, 89445.010577196, --Geom 3 : 82793, 89490.010577196, 82796.989422804, 89494, 82793, 89497.989422804, 82789.010577196, 89494, 82793, 89490.010577196 )) So i suppose that the problem must be something else. Other thing : If i change manually (but, of course, it's not a solution for the production version) the interpretation of the vertex from 2 to 1 (arcs to lines) Mapserver is able to draw the rectangles. Thanks, Julien Collaer -------- Message d'origine-------- De: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Date: jeu. 30/07/2009 16:57 ?: Julien Collaer Objet : Re: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is 2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Julien, Looking at the SDO description in the Oracle MAN for . . . ----------- 1003 or 2003 2 Polygon made up of a connected sequence of circular arcs that closes on itself. The end point of the last arc is the same as the start point of the first arc. Each circular arc is described using three coordinates: the start point of the arc, any point on the arc, and the end point of the arc. The coordinates for a point designating the end of one arc and the start of the next arc are not repeated. For example, five coordinates are used to describe a polygon made up of two connected circular arcs. Points 1, 2, and 3 define the first arc, and points 3, 4, and 5 define the second arc. The coordinates for points 1 and 5 must be the same (tolerance is not considered), and point 3 is not repeated. ----------- It looks like the first and last points need to be the same and your record shows different points for the first and last entries. You may have one extra point on the end as well (I think), or maybe you are just missing the last point on the end . . . bobb + >>> "Julien Collaer" wrote: Hello list, I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a layer from an Oracle Spatial database (SDO geometries). Everything is working fine except for some geometries : multipolygons with interpretation 2 (vertex connected by arcs). Here is an example of such geometry : MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,100 3,2,21,1003,2), MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196, 83936.989422804,89883, 83933,89886.989422804, 83929.010577196,89883, 83933,89879.010577196, 83345,89445.010577196, 83348.989422804,89449, 83345,89452.989422804, 83341.010577196,89449, 83345,89445.010577196, 82793,89490.010577196, 82796.989422804,89494, 82793,89497.989422804, 82789.010577196,89494, 82793,89490.010577196)) The layer is rendered but no feature are displayed. The geomtries are correct (verified with the Oracle MapViewer). If someone knows a solution for this case it will be very useful... Thanks in advance, Julien Collaer -------------- next part -------------- An HTML attachment was scrubbed... URL: From tschobber at gmx.at Fri Jul 31 04:04:29 2009 From: tschobber at gmx.at (=?iso-8859-1?Q?=22tschobber_tsch=F6bbi=22?=) Date: Fri, 31 Jul 2009 13:04:29 +0200 Subject: [mapserver-users] Bad image quality with PHP Mapscript Message-ID: <20090731110429.66180@gmx.net> Dear user list, I have a simple question: What could be the reason (in my case) why the image output of PHP Mapscript generated files are much worse than with the mapserv binary file? Both use the same mapfile with 3 layers - each for one zoomlevel. The PHP Mapscript file reads the mapfile and writes the data to the browser without saving it - that's all ... I tried to enhance the quality by using the function "outputformat", but nothing changed. Unfortunately I'm not able to show you the Code because I'm on holiday at the moment and I have no access to the files. I hope you can help me on this issue. Thanks, Martin -- Neu: GMX Doppel-FLAT mit Internet-Flatrate + Telefon-Flatrate f?r nur 19,99 Euro/mtl.!* http://portal.gmx.net/de/go/dsl02 From mschulz at webgis.de Fri Jul 31 04:13:38 2009 From: mschulz at webgis.de (Michael Schulz) Date: Fri, 31 Jul 2009 13:13:38 +0200 Subject: [mapserver-users] SLD with Mapserver 5.4.2 In-Reply-To: <52632d9e0907310145r2fe77b56nfb6a307e7ad87a70@mail.gmail.com> References: <4A71CF1A.9070004@gmail.com> <52632d9e0907310145r2fe77b56nfb6a307e7ad87a70@mail.gmail.com> Message-ID: Hi Andrea, mapserver uses sld in "library" mode, meaning that if for a certain layer of the mapfile an sld symbolization is provided it takes precedence over the mapfile symbolization. If for another layer no sld id provided, then the mapfile symbolization is used. Thus, As far as I know you can only "replace" the symbolization of a complete layer and not add styling in a sense of taking the labelling definitions from the mapfile and the fill-color from the sld for one layer. It may nevertheless be that some definitions regarding symbolization are mixed, e.g. the transparency settings of a layer is kept when applying an sld (at least this was the case for older versions). When you really want to add something to the symbolization, a possible approach would be to use the getstyle request to obtain mapserver's sld-representation of the current layer styling, then you could add or modify that and sent it back modified for a getmap request. Cheers, Michael 2009/7/31 Andrea Dess? : > Hi Michael, > > Thank you for your answer :) > > Now SLD is working i had a mistake with names references. > > I have just another question: how is possible to "add" a style > using SLD without overriding the whole server style? > > I explain what i want to do: I have a map served by MapServer, so a > mapfile with layers and styles. I want to add a style with "new" > characteristics (could be outline or overriding just the color of the text). > > Thanks, > Andrea > > > > 2009/7/30 Michael Schulz >> >> Hi Andrea, >> >> to use SLD you won't need very special mapfile configuration. You >> should pay attention to setting the imgpath parameter of the web >> section correctly, i.e. accessible and writable by mapserver-cgi, >> since the sld's are stored there temporarily while/after downloading >> them from the specified URL. I am not aware of any other special >> configuration, but very helpful are the debugging outputs, that you >> can enable with the keyword DEBUG "on" at map or layer level. I find >> it most convenient to specify an errorfile path via CONFIG >> "MS_ERRORFILE" "/ms4w/tmp/ms_error.txt" at map level. >> >> Be sure to set the SLD's NamedLayer Name tag value exactly the same as >> your mapfile's layer name you want to style. >> >> Cheers, Michael >> >> >> 2009/7/30 Andrea Dess? : >> > Hi, >> > >> > i've started using Mapserver few days ago and i cannot apply SLD styles. >> > >> > i'm using ?MapServer version 5.4.2 >> > OUTPUT=GIF OUTPUT=PNG >> > OUTPUT=JPEG OUTPUT=WBMP >> > OUTPUT=SVG >> > SUPPORTS=PROJ >> > SUPPORTS=AGG >> > SUPPORTS=FREETYPE >> > SUPPORTS=ICONV >> > SUPPORTS=WMS_SERVER >> > SUPPORTS=WMS_CLIENT >> > SUPPORTS=WFS_SERVER >> > SUPPORTS=WFS_CLIENT >> > SUPPORTS=WCS_SERVER >> > SUPPORTS=FASTCGI >> > SUPPORTS=THREADS >> > SUPPORTS=GEOS >> > INPUT=EPPL7 >> > INPUT=POSTGIS >> > INPUT=OGR >> > INPUT=GDAL >> > INPUT=SHAPEFILE >> > >> > under Ubuntu 9.04. >> > >> > I want to user mapserver as WMS Server and the apply SLD styles on the >> > fly... the common query is: >> > http://localhost/cgi-bin/wms?SERVICE=WMS& >> > VERSION=1.1.1& >> > REQUEST=GetMap& >> > BBOX=-74.012362,40.752314,-73.948216,40.791051& >> > SRS=EPSG:4326& >> > WIDTH=500& >> > HEIGHT=500& >> > LAYERS=myground,myroads& >> > FORMAT=image/gif& >> > TRANSPARENT=TRUE& >> > SLD=http://localhost/mysld.xml >> > >> > But sld is not applying. >> > >> > The question is: there are specific parameters for using SLD in mapfile? >> > I'm feeling a bit confused about this. >> > >> > Thank You, >> > -- >> > Andrea >> > >> > _______________________________________________ >> > mapserver-users mailing list >> > mapserver-users at lists.osgeo.org >> > http://lists.osgeo.org/mailman/listinfo/mapserver-users >> > >> >> >> >> -- >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> Aufwind durch Wissen! >> >> Qualifizierte Open Source Schulungen bei der >> http://www.foss-akademie.de/ >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> >> ----------------------------------------------------------- >> Michael Schulz >> mschulz at webgis.de >> >> in medias res >> Gesellschaft f?r Informationstechnologie mbH >> >> +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ >> >> Schwimmbadstra?e 2 >> D-79100 ?Freiburg i. Br. >> >> Tel: ?+49 (0)761 705798-102 >> Tel: ?+49 (0)761 705798-0 >> Fax: +49 (0)761 705798-09 >> >> +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ >> >> http://www.webgis.de / http://www.zopecms.de >> -------------------------------------------------------------- >> Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck >> Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg >> _______________________________________________ >> mapserver-users mailing list >> mapserver-users at lists.osgeo.org >> http://lists.osgeo.org/mailman/listinfo/mapserver-users > > -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Aufwind durch Wissen! Qualifizierte Open Source Schulungen bei der http://www.foss-akademie.de/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------------------------------------- Michael Schulz mschulz at webgis.de in medias res Gesellschaft f?r Informationstechnologie mbH +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ Schwimmbadstra?e 2 D-79100 Freiburg i. Br. Tel: +49 (0)761 705798-102 Tel: +49 (0)761 705798-0 Fax: +49 (0)761 705798-09 +++ Bitte beachten Sie unsere neue Adresse und Durchwahl +++ http://www.webgis.de / http://www.zopecms.de -------------------------------------------------------------- Gesch?ftsf?hrer: Stefan Giese, Dr. Christof Lindenbeck Eingetragen im Handelsregister HRB 5930 beim Amtsgericht Freiburg From dmorissette at mapgears.com Fri Jul 31 05:12:01 2009 From: dmorissette at mapgears.com (Daniel Morissette) Date: Fri, 31 Jul 2009 08:12:01 -0400 Subject: [mapserver-users] Bad image quality with PHP Mapscript In-Reply-To: <20090731110429.66180@gmx.net> References: <20090731110429.66180@gmx.net> Message-ID: <4A72DF91.8010002@mapgears.com> tschobber tsch?bbi wrote: > > I have a simple question: What could be the reason (in my case) why the image output of PHP Mapscript generated files are much worse than with the mapserv binary file? > I guess it would help if you were more explicit on what you mean by "much worse"... is it a color problem, font rendering problem, antialias vs no-antialias problem, ??? Perhaps post two sample maps for us to see and maybe someone will have an idea? My first suggestions would be: 1- For your tests, make sure the CGI and the PHP versions both use the default output format and don't try to change it (via URL or scripting). 2- Did you compile and/or install multiple versions/copies of MapServer on your server? Make sure both the CGI and your PHP use the exact same version from the same build of MapServer. Different compile options could explain a difference in rendering quality. Daniel -- Daniel Morissette http://www.mapgears.com/ From JC at sodiplan.be Fri Jul 31 05:14:32 2009 From: JC at sodiplan.be (Julien Collaer) Date: Fri, 31 Jul 2009 14:14:32 +0200 Subject: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) In-Reply-To: <001401ca11bb$e2c9c130$a85d4390$@com> References: <38FFFA96BE9C224893B3559563614BEA12CC45@begemsrv01.sodiplan-begem.local> <4A716E79.163B.00A8.0@ci.stpaul.mn.us> <38FFFA96BE9C224893B3559563614BEA12CC46@begemsrv01.sodiplan-begem.local> <001401ca11bb$e2c9c130$a85d4390$@com> Message-ID: <38FFFA96BE9C224893B3559563614BEA481D84@begemsrv01.sodiplan-begem.local> Hello Pano, Thanks for the idea, it wasn't done yet ! I've just executed the validate_layer_with_context verification Oracle function and my geometries are ok (the result table is empty for the circular / problematics geometries). But some of the others geometries (correctly rendered by Mapserver) are presenting some errors (only some 13367 - vertex in wrong order)... Thanks, Julien Collaer De : Pano Voudouris [mailto:pvoudouris at gaiocorp.com] Envoy? : vendredi 31 juillet 2009 10:50 ? : Julien Collaer; mapserver-users at lists.osgeo.org Objet : RE: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Julien, I know you said you verified the geometries by Mapviewer but have you tried the sdo_validate layer routine? Just to be sure... Example from the manual: -- Is a layer valid? (First, create the result table.) CREATE TABLE val_results (sdo_rowid ROWID, result varchar2(1000)); -- (Next statement must be on one command line.) CALL SDO_GEOM.VALIDATE_LAYER_WITH_CONTEXT('COLA_MARKETS','SHAPE','VAL_RESULTS'); Call completed. SQL> SELECT * from val_results; SDO_ROWID ------------------ RESULT -------------------------------------------------------------------------------- Rows Processed <12> AAABXNAABAAAK+YAAC 13349 [Element <1>] [Ring <1>][Edge <1>][Edge <3>] Cheers, Pano From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Julien Collaer Sent: 30 July 2009 18:38 To: Bob Basques; mapserver-users at lists.osgeo.org Subject: RE : [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Hello Bob, thanks for your fast response. These geometries are generated by Oracle : SDO_Buffer function on multipoints geometries. When i look to the SDO_GEOM example,there are three geometries (polygons) composed of five points with the first point being the same of the last one : MDSYS.SDO_GEOMETRY(2007,26273,null, MDSYS.SDO_ELEM_INFO_ARRAY( 1,1003,2, 11,1003,2, 21,1003,2), MDSYS.SDO_ORDINATE_ARRAY( --Geom 1 : 83933, 89879.010577196, 83936.989422804, 89883, 83933, 89886.989422804, 83929.010577196, 89883, 83933, 89879.010577196, --Geom 2 : 83345, 89445.010577196, 83348.989422804, 89449, 83345, 89452.989422804, 83341.010577196, 89449, 83345, 89445.010577196, --Geom 3 : 82793, 89490.010577196, 82796.989422804, 89494, 82793, 89497.989422804, 82789.010577196, 89494, 82793, 89490.010577196 )) So i suppose that the problem must be something else. Other thing : If i change manually (but, of course, it's not a solution for the production version) the interpretation of the vertex from 2 to 1 (arcs to lines) Mapserver is able to draw the rectangles. Thanks, Julien Collaer -------- Message d'origine-------- De: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Date: jeu. 30/07/2009 16:57 ?: Julien Collaer Objet : Re: [mapserver-users] Impossible to draw SDO Geometries fromOraclewhen SDO_GTYPE is 2007 and the interpretation is 2(connectivity by arcs : SDO_ELEM_INFO(1, 1003, 2, [...]) ) Julien, Looking at the SDO description in the Oracle MAN for . . . ----------- 1003 or 2003 2 Polygon made up of a connected sequence of circular arcs that closes on itself. The end point of the last arc is the same as the start point of the first arc. Each circular arc is described using three coordinates: the start point of the arc, any point on the arc, and the end point of the arc. The coordinates for a point designating the end of one arc and the start of the next arc are not repeated. For example, five coordinates are used to describe a polygon made up of two connected circular arcs. Points 1, 2, and 3 define the first arc, and points 3, 4, and 5 define the second arc. The coordinates for points 1 and 5 must be the same (tolerance is not considered), and point 3 is not repeated. ----------- It looks like the first and last points need to be the same and your record shows different points for the first and last entries. You may have one extra point on the end as well (I think), or maybe you are just missing the last point on the end . . . bobb + >>> "Julien Collaer" wrote: Hello list, I'm using Mapserver CGI 5.0.2 (and i'v tried with the 5.4.x too) to render a layer from an Oracle Spatial database (SDO geometries). Everything is working fine except for some geometries : multipolygons with interpretation 2 (vertex connected by arcs). Here is an example of such geometry : MDSYS.SDO_GEOMETRY(2007,26273,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,2,11,1003,2,21,1003,2), MDSYS.SDO_ORDINATE_ARRAY(83933,89879.010577196, 83936.989422804,89883, 83933,89886.989422804, 83929.010577196,89883, 83933,89879.010577196, 83345,89445.010577196, 83348.989422804,89449, 83345,89452.989422804, 83341.010577196,89449, 83345,89445.010577196, 82793,89490.010577196, 82796.989422804,89494, 82793,89497.989422804, 82789.010577196,89494, 82793,89490.010577196)) The layer is rendered but no feature are displayed. The geomtries are correct (verified with the Oracle MapViewer). If someone knows a solution for this case it will be very useful... Thanks in advance, Julien Collaer -------------- next part -------------- An HTML attachment was scrubbed... URL: From nkjoep at gmail.com Fri Jul 31 08:16:42 2009 From: nkjoep at gmail.com (=?ISO-8859-1?Q?Andrea_Dess=EC?=) Date: Fri, 31 Jul 2009 17:16:42 +0200 Subject: [mapserver-users] SLD with Mapserver 5.4.2 In-Reply-To: References: <4A71CF1A.9070004@gmail.com> <52632d9e0907310145r2fe77b56nfb6a307e7ad87a70@mail.gmail.com> Message-ID: <4A730ADA.2080906@gmail.com> Michael Schulz ha scritto: > Hi Andrea, > > mapserver uses sld in "library" mode, meaning that if for a certain > layer of the mapfile an sld symbolization is provided it takes > precedence over the mapfile symbolization. If for another layer no sld > id provided, then the mapfile symbolization is used. Thus, As far as I > know you can only "replace" the symbolization of a complete layer and > not add styling in a sense of taking the labelling definitions from > the mapfile and the fill-color from the sld for one layer. > Yes, it's working now ;) > It may nevertheless be that some definitions regarding symbolization > are mixed, e.g. the transparency settings of a layer is kept when > applying an sld (at least this was the case for older versions). > > When you really want to add something to the symbolization, a possible > approach would be to use the getstyle request to obtain mapserver's > sld-representation of the current layer styling, then you could add or > modify that and sent it back modified for a getmap request. > Michael, using java, we get the layer's style from the request. Before doing the new request to WMS server, we tried to extract the old style and then add a new style (in the new request there are the old and the new ones) So using geotools we have: [...] StyleImpl styleImpl = new StyleImpl(); // istantiate new Style List featuresStyles = new ArrayList(); //define list of styles featuresStyles.add(featureTypeStyle); // defining style list styleImpl.setFeatureStyles(featuresStyles); // applying feature styles to the current style List st = new ArrayList(); // the new style list st.add(style); // adding the old style coming from the request st.add(styleImpl); // adding our new style // then defining the new request with layer... Layer l = new Layer(); l.setStyles(st); l.setName("nycroads"); request.addLayer(l); [...] So we are trying to: - ask getCapabilites to WMS server - retrieving the style list from the layer - retrieve the old style from the layer - create a new style for the layer - insert one old style and a new one to the layer - do a request with the elaborated layer result: not working :) is it a good approach? Thank you, Andrea -------------- next part -------------- An HTML attachment was scrubbed... URL: From greenkov at gmail.com Fri Jul 31 08:37:52 2009 From: greenkov at gmail.com (Alexander Petkov) Date: Fri, 31 Jul 2009 09:37:52 -0600 Subject: [mapserver-users] How to enter the projected coordinates in Postgis In-Reply-To: <6924A68BEE67AA46A1E95CC0EB4F98D002797773@sc-exchange.addisongov.org> References: <6924A68BEE67AA46A1E95CC0EB4F98D002797773@sc-exchange.addisongov.org> Message-ID: On Thu, Jul 30, 2009 at 8:57 AM, Suman Chatterjee wrote: > Hi, > > I have created 2 tables in postGIS and POSTGreSQL ? in one, I am storing > the GPS coordinates which are in the form of say lat= 32.4 and longitude = > 72.45 ( which are in degrees) with SRID 2276 > > And in another I am capturing the user defined points from a projected map > in mapserver. So here the points are having the projected coordinates like > 2479589 7037631. The projection of the map has epsg=2276 One of your SRID codes will need to be corrected (I suspect the 1st one). You are using coordinates in degrees, and some other units for thesame SRID? > > Now I want to find the distance between the GPS points and the user defined > point. For that I require the projected coordinates for both. > > So how can I store the projected coordinates of the GPS points in the table? > Is there any function for that? Once you get your coordinates in the same projection (you can use the postgis transform function), you can use the postgis distance function. And you wouldn't need to necessarily store the coordinates captured from the user, just build a point geometry from the numbers. Alex From MarkVolz at co.lyon.mn.us Fri Jul 31 09:06:00 2009 From: MarkVolz at co.lyon.mn.us (Mark Volz) Date: Fri, 31 Jul 2009 11:06:00 -0500 Subject: [mapserver-users] tile index question - appropriate scales Message-ID: <3D56274B4A7874468F58FADDBFD0980107A87906@llmhs02.r8nssis.local> Hello, I created a tile index for an air photo. I would like to know how to determine an appropriate scale for each tile index level. Thanks Mark Volz GIS Specialist Lyon County, MN -------------- next part -------------- An HTML attachment was scrubbed... URL: From schatterjee at addisontx.gov Fri Jul 31 10:10:03 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Fri, 31 Jul 2009 12:10:03 -0500 Subject: [mapserver-users] How to enter the projected coordinates in Postgis Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15D6@sc-exchange.addisongov.org> Hi Alex, Thank You very much for pointing out the mistake. But still I am facing some problem. My GPS is collecting data in NAD1983 which I found corresponds to SRID 4269. The extent of the Addison area is 2445459.0713 7001896.9648 2514178.5480 7070616.4415 It is in LCC NAD1983(ft) which I found to correspond with SRID 2276. I am using the Transform function like below: The coordinates with which I am testing are :lat 32.98 and long -96.83 Select ST_Transform(gpscoords,2276) from gpsdata; But it is throwing error : ERROR: transform: couldn't project point:-14 (latitude or longitude exceeded)SQL state:XX000 Any idea how to proceed? Thanks Suman -----Original Message----- From: Alexander Petkov [mailto:greenkov at gmail.com] Sent: Friday, July 31, 2009 10:38 AM To: Suman Chatterjee Cc: mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] How to enter the projected coordinates in Postgis On Thu, Jul 30, 2009 at 8:57 AM, Suman Chatterjee wrote: > Hi, > > I have created 2 tables in postGIS and POSTGreSQL - in one, I am storing > the GPS coordinates which are in the form of say lat= 32.4 and longitude = > 72.45 ( which are in degrees) with SRID 2276 > > And in another I am capturing the user defined points from a projected map > in mapserver. So here the points are having the projected coordinates like > 2479589 7037631. The projection of the map has epsg=2276 One of your SRID codes will need to be corrected (I suspect the 1st one). You are using coordinates in degrees, and some other units for thesame SRID? > > Now I want to find the distance between the GPS points and the user defined > point. For that I require the projected coordinates for both. > > So how can I store the projected coordinates of the GPS points in the table? > Is there any function for that? Once you get your coordinates in the same projection (you can use the postgis transform function), you can use the postgis distance function. And you wouldn't need to necessarily store the coordinates captured from the user, just build a point geometry from the numbers. Alex ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* From gregor at hostgis.com Fri Jul 31 10:39:17 2009 From: gregor at hostgis.com (Gregor at HostGIS) Date: Fri, 31 Jul 2009 10:39:17 -0700 Subject: [mapserver-users] How to enter the projected coordinates in Postgis In-Reply-To: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15D6@sc-exchange.addisongov.org> References: <6924A68BEE67AA46A1E95CC0EB4F98D0027A15D6@sc-exchange.addisongov.org> Message-ID: <4A732C45.80907@hostgis.com> > Select ST_Transform(gpscoords,2276) from gpsdata; > But it is throwing error : > ERROR: transform: couldn't project point:-14 (latitude or longitude > exceeded)SQL state:XX000 It means what it says: one of your points has a invalid ordinate, so it cannot be transformed. Try this to debug it. Look through them manually and find the one that has the wrong latitude or longitude then correct or delete it. SELECT astext(the_geom) from gpsdata; You can also try these, to sort the list and perhaps make the bad coordinate show up at the start or end of the list: SELECT astext(the_geom) from gpsdata order by x(the_geom); SELECT astext(the_geom) from gpsdata order by x(the_geom) DESC; SELECT astext(the_geom) from gpsdata order by y(the_geom); SELECT astext(the_geom) from gpsdata order by y(the_geom) DESC; -- HostGIS, Open Source solutions for the global GIS community Greg Allensworth - SysAdmin, Programmer, GIS Person, Security Network+ Server+ A+ Security+ From schatterjee at addisontx.gov Fri Jul 31 10:43:53 2009 From: schatterjee at addisontx.gov (Suman Chatterjee) Date: Fri, 31 Jul 2009 12:43:53 -0500 Subject: [mapserver-users] How to enter the projected coordinates in Postgis Message-ID: <6924A68BEE67AA46A1E95CC0EB4F98D002797776@sc-exchange.addisongov.org> Hi Greg, Thank You very much. I was just trying and found the fault.Actually the longitude should come first and then the latitude. I was doing otherwise and so the error. Now the transform function is working. Thanks Suman -----Original Message----- From: Gregor at HostGIS [mailto:gregor at hostgis.com] Sent: Friday, July 31, 2009 12:39 PM To: Suman Chatterjee Cc: Alexander Petkov; mapserver-users at lists.osgeo.org Subject: Re: [mapserver-users] How to enter the projected coordinates in Postgis > Select ST_Transform(gpscoords,2276) from gpsdata; > But it is throwing error : > ERROR: transform: couldn't project point:-14 (latitude or longitude > exceeded)SQL state:XX000 It means what it says: one of your points has a invalid ordinate, so it cannot be transformed. Try this to debug it. Look through them manually and find the one that has the wrong latitude or longitude then correct or delete it. SELECT astext(the_geom) from gpsdata; You can also try these, to sort the list and perhaps make the bad coordinate show up at the start or end of the list: SELECT astext(the_geom) from gpsdata order by x(the_geom); SELECT astext(the_geom) from gpsdata order by x(the_geom) DESC; SELECT astext(the_geom) from gpsdata order by y(the_geom); SELECT astext(the_geom) from gpsdata order by y(the_geom) DESC; -- HostGIS, Open Source solutions for the global GIS community Greg Allensworth - SysAdmin, Programmer, GIS Person, Security Network+ Server+ A+ Security+ ******************************************************************************************************************* This e-mail and any files or attachments transmitted with it contains Information that is confidential and privileged. This document may contain Protected Health Information (PHI) or other information that is intended only for the use of the individual(s) and entity(ies) to whom it is addressed. If you are the intended recipient, further disclosures are prohibited without proper authorization. If you are not the intended recipient, any disclosure, copying, printing, or use of this information is strictly prohibited and possibly a violation of federal or state law and regulations. If you have received this information in error, please delete it and notify Hamid Khaleghipour at 972-450-2868 immediately. Thank you. ******************************************************************************************************************* From mrdouville at shaw.ca Fri Jul 31 11:05:08 2009 From: mrdouville at shaw.ca (Michelle Douvil) Date: Fri, 31 Jul 2009 11:05:08 -0700 (PDT) Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1248129296203-3292192.post@n2.nabble.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> <1248116676077-3290900.post@n2.nabble.com> <1248127566461-3292077.post@n2.nabble.com> <4A64EB85.5060009@gatewaygeomatics.com> <1248129296203-3292192.post@n2.nabble.com> Message-ID: <1249063508516-3364179.post@n2.nabble.com> It looks like if I switch to the OGR driver for Shapefiles, my issues are resolved. Are there any drawbacks to using the OGR driver vs the Native mapserver drivers? Many thanks, Michelle -- View this message in context: http://n2.nabble.com/Shapefile-with-first-FID-%3D-0-not-showing..-tp3289974p3364179.html Sent from the Mapserver - User mailing list archive at Nabble.com. From warmerdam at pobox.com Fri Jul 31 11:37:41 2009 From: warmerdam at pobox.com (Frank Warmerdam) Date: Fri, 31 Jul 2009 14:37:41 -0400 Subject: [mapserver-users] Shapefile with first FID = 0 not showing.. In-Reply-To: <1249063508516-3364179.post@n2.nabble.com> References: <0FB1F527BFBF944991C0DBF8910F5B0A97C272@candle.idir.bcgov> <4A64A218.9090809@gatewaygeomatics.com> <1248111348949-3290374.post@n2.nabble.com> <1248114190840-3290653.post@n2.nabble.com> <6246727221874A4FB8D3F9BBC37D9BD5056DA6B6@s-sp22.pca.state.mn.us> <1248116676077-3290900.post@n2.nabble.com> <1248127566461-3292077.post@n2.nabble.com> <4A64EB85.5060009@gatewaygeomatics.com> <1248129296203-3292192.post@n2.nabble.com> <1249063508516-3364179.post@n2.nabble.com> Message-ID: <4A7339F5.6050005@pobox.com> Michelle Douvil wrote: > It looks like if I switch to the OGR driver for Shapefiles, my issues are > resolved. > Are there any drawbacks to using the OGR driver vs the Native mapserver > drivers? Michelle, The OGR driver is slower - quite a bit of extra overhead going from shape objects to OGR objects to mapserver objects. Best regards, -- ---------------------------------------+-------------------------------------- I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush | Geospatial Programmer for Rent From bfraser at geoanalytic.com Fri Jul 31 16:28:34 2009 From: bfraser at geoanalytic.com (Brent Fraser) Date: Fri, 31 Jul 2009 17:28:34 -0600 (Mountain Daylight Time) Subject: [mapserver-users] tile index question - appropriate scales In-Reply-To: <3D56274B4A7874468F58FADDBFD0980107A87906@llmhs02.r8nssis.local> References: <3D56274B4A7874468F58FADDBFD0980107A87906@llmhs02.r8nssis.local> Message-ID: <.208.110.47.155.1249082914.squirrel@208.110.47.155> Mark, Take the pixel size in meters and multiply by 4,000; that will get you close. So for a image with a pixel size of 5 meters, a good scale would be 1:20,000. Any larger than that (say 1:10,000) and you'll start to see pixel edges. Unless you meant something else?... Best Regards, Brent Fraser > Hello, > > I created a tile index for an air photo. I would like to know how to > determine an appropriate scale for each tile index level. > > Thanks > > Mark Volz > GIS Specialist > Lyon County, MN