From crystal.li at IDISIS.COM Sun Jul 1 09:05:35 2007 From: crystal.li at IDISIS.COM (Crystal Li) Date: Sun, 1 Jul 2007 10:05:35 -0600 Subject: System problems - installation Message-ID: Hi all, I am new to mapserver, still have trouble with system installation. I tried differnt versions of MapServer, it seems there are some problems with SSL. Now I installed MS4W_2.2.3, Chameleon_ms4W-2.4.1-20060906, Apache_2.2.3-Openssl_0.9.8d-WIn32, I followed the instruction until postgresql is successfully installed. then I start apache again, there is error is below: The Apache service named reported the following error: >>> httpd.exe: Syntax error on line 114 of C:/ms4w/Apache/conf/httpd.conf: Cannot load C:/ms4w/Apache/modules/mod_ssl.so into server: The operating system cannot run The Apache service named. Please help! IS SSL version not matching Mapserver version? How can I fix this problem??? not sure, tried to stop IIS and coldfusion services, still cannot start apache service. Thanks in advance! Crystal -- ========================= Crystal Li Systems Analyst Idisis, Inc. 430, 318 11th Avenue S.E. Calgary, Alberta T2G 0Y2 www.idisis.com E-mail: crystal.li at idisis.com Office: (403)670-7351 Fax: (403) 670-7359 -------------- next part -------------- An HTML attachment was scrubbed... URL: From nkdiitd2002 at GMAIL.COM Mon Jul 2 05:05:39 2007 From: nkdiitd2002 at GMAIL.COM (nishith datta) Date: Mon, 2 Jul 2007 17:35:39 +0530 Subject: help with scalebar Message-ID: hi all, I have not understood the scalebar object . I can create it in the map file but how do i display it in the web page I donot see it displayed automatically. Do i need to do something to show it up. What about the reference map . What needs to be done after we define it as an object in the map file. thanks in advance nishith -------------- next part -------------- An HTML attachment was scrubbed... URL: From cerruti.marco at GMAIL.COM Mon Jul 2 05:18:30 2007 From: cerruti.marco at GMAIL.COM (Marco Cerruti) Date: Mon, 2 Jul 2007 14:18:30 +0200 Subject: help with scalebar In-Reply-To: Message-ID: Nishith, you have to use CGI parameters in the HTML template (browse mode) to show the reference map, scalebar, legend and so on. Please take a look of the Template File Reference: http://mapserver.gis.umn.edu/docs/reference/templatereference/templatereference M 2007/7/2, nishith datta : > > hi all, > I have not understood the scalebar object . I can create it in the map > file but how do i display it in the web page > I donot see it displayed automatically. Do i need to do something to show > it up. What about the reference > map . What needs to be done after we define it as an object in the map > file. > thanks in advance > nishith > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at DNR.STATE.MN.US Mon Jul 2 08:08:13 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Mon, 2 Jul 2007 10:08:13 -0500 Subject: FOSS4G 2007 Community Program Review Message-ID: Coming to FOSS4G 2007? Help us build the FOSS4G 2007 program! http://www.foss4g2007.org/presentations/review/ We want the attendees at the Free and Open Source Software for Geospatial (FOSS4G) conference to help us build the program, by providing rankings of the abstract submissions. Go to the community ranking page at the link above, and follow the directions. Just tell us the sessions that YOU want to see, and we will build the program that fits the highest number of attendees. The ranking data will also be used to assign presentations to appropriately sized rooms. EARLY BIRD DISCOUNTS END SOON Book now to get the early bird rates: conference registration before the deadline is just $395CAD; after July 27, registration is $565CAD. The early bird really does get the worm! From jchurchill at AL.UMCES.EDU Mon Jul 2 11:40:21 2007 From: jchurchill at AL.UMCES.EDU (John B. Churchill) Date: Mon, 2 Jul 2007 14:40:21 -0400 Subject: trouble with attribute query Message-ID: Hi All, I'm having trouble executing an Attribute Query when I base the query (qitem) on the "filename" field in my shapefile. I can choose any other field and supply the appropriate qstring and everything works fine but when I use the filename field I get a "no matching records" found error. The text in the long string in the address bar of the browser IS complete and DOES match the value in the shapefile. Perhaps the text values in the shapefile field are too long for MapServer or special characters like the "." or "-" are causing a problem ? Can anyone confirm or deny either of my theories about this or point to any other possibilities ? The qstring is ... p016r032_09-09-1986_lt5_doc.img The qitem is "filename" and it is a text field. The entire query string in the address bar is ... http://localhost/cgi-bin/mapserv.exe?qlayer=landsat_4&myitem=landsat_4%2Cfilename&qstring=p016r032_09-09-1986_lt5_doc.img&map=C%3A%5Cms4w%5CApache%5Chtdocs%5Cimg_browser%5Cimg_browser.map&program=%2Fcgi-bin%2Fmapserv&mode=itemnquery&qitem=filename The error is ... msQueryByAttributes(): Search returned no results. No matching record(s) found. -- --------------------------------------------- John B. Churchill, M.S. http://alx.al.umces.edu/~jchurch/ GIS Specialist (301) 689-7109 University of Maryland Center for Environmental Science Appalachian Laboratory http://www.al.umces.edu/ Environmental Science Education http://alese.al.umces.edu/ 301 Braddock Road Frostburg, MD 21532 FAX - (301) 689-7200 From rhow at I3.COM Mon Jul 2 17:12:04 2007 From: rhow at I3.COM (Randy How) Date: Mon, 2 Jul 2007 18:12:04 -0600 Subject: Proj.4 definition for USA_Contiguous_Lambert_Conformal_Conic Message-ID: I'm trying to support a specific projection in MapServer: USA_Contiguous_Lambert_Conformal_Conic 1) Why it wouldn't be in proj/nad/epsg in the first place, I'm sure there's a good reason. 2) Now that it's added to proj/nad/epsg file, it produces a map. But the scale is calculated incorrectly. The datasets at larger scales are not displaying. What other info does mapserver need to calculate the scale correctly? Definition: PROJCS["USA_Contiguous_Lambert_Conformal_Conic", GEOGCS["GCS_North_American_1983", DATUM["D_North_American_1983",SPHEROID["GRS_1980",6378137.0,298.257222101]], PRIMEM["Greenwich",0.0], UNIT["Degree",0.0174532925199433]], PROJECTION["Lambert_Conformal_Conic"], PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0], PARAMETER["Central_Meridian",-96.0], PARAMETER["Standard_Parallel_1",33.0], PARAMETER["Standard_Parallel_2",45.0], PARAMETER["Latitude_Of_Origin",39.0], UNIT["Meter",1.0]] My Proj Definition: # USA_Contiguous_Lambert_Conformal_Conic <102004> +proj=lcc +lat_1=33.0 +lat_2=45.0 +lat_0=39.0 +lon_0=-96.0 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs <> ________________________________________________ Randy How Geospatial Applications Developer Rhow[@]i3[.]com From satsuman at GMAIL.COM Tue Jul 3 06:15:31 2007 From: satsuman at GMAIL.COM (Satish Suman) Date: Tue, 3 Jul 2007 08:15:31 -0500 Subject: Can not see the map file in "itasca_adds_dhtml.html" Message-ID: I have downloaded mapserver- demo and trying to change it with my own files. I can able to see the image in all the links other than "itasca_adds_dhtml.html". Its the last one and more advanced too. I am able to see the reference image and other things but not the map file and not able to querry as well.. Plz help me out. Regards From jmckenna at DMSOLUTIONS.CA Tue Jul 3 07:00:59 2007 From: jmckenna at DMSOLUTIONS.CA (Jeff McKenna) Date: Tue, 3 Jul 2007 10:00:59 -0400 Subject: System problems - installation In-Reply-To: <417cc46d0707010905va532c9crfaf64a60e47f91fa@mail.gmail.com> Message-ID: I believe that MS4W version contains MapServer built with curl-7.15.1 with SSL enabled...but I have never gone as far as you and tried to use the mod_ssl apache module, so you may be correct. Please let the MS4W mailing list (join at http://lists.maptools.org/mailman/listinfo/ms4w-users) know of your progress, and if you include details instructions in your email to that list I can make sure that the MS4W README is updated. jeff Crystal Li wrote: > Hi all, > > I am new to mapserver, still have trouble with system installation. > I tried differnt versions of MapServer, it seems there are some problems > with SSL. > > Now I installed MS4W_2.2.3, Chameleon_ms4W-2.4.1-20060906, > Apache_2.2.3-Openssl_0.9.8d-WIn32, I followed the instruction until > postgresql is successfully installed. then I start apache again, there > is error is > below: > > The Apache service named reported the following error: > >>> httpd.exe: Syntax error on line 114 of C:/ms4w/Apache/conf/httpd.conf: > Cannot load C:/ms4w/Apache/modules/mod_ssl.so into server: The operating > system cannot run The Apache service named. > > Please help! IS SSL version not matching Mapserver version? How can I > fix this > problem??? > > not sure, tried to stop IIS and coldfusion services, still cannot start > apache service. > > Thanks in advance! > > Crystal > > > -- > ========================= > Crystal Li > Systems Analyst > Idisis, Inc. > 430, 318 11th Avenue S.E. > Calgary, Alberta T2G 0Y2 > www.idisis.com > E-mail: crystal.li at idisis.com > Office: (403)670-7351 > Fax: (403) 670-7359 -- Jeff McKenna DM Solutions Group Inc. http://www.dmsolutions.ca From peter.loewe at GMX.DE Tue Jul 3 08:11:31 2007 From: peter.loewe at GMX.DE (=?iso-8859-1?Q?=22Peter_L=F6we=22?=) Date: Tue, 3 Jul 2007 17:11:31 +0200 Subject: Mapscript and SOS In-Reply-To: <467BE65B.2090909@dmsolutions.ca> Message-ID: Hi, the MapScript Wrappers for WxS Services indeed _do_ enable SOS requests, however, the results seem strange: A GetObservation-query like: http://localhost/swe/php_sos0.php?Request=GetObservation&service=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.31 provides only the event time. (output follow below). Here's the SOS-relevant content which is provided via PHP: --------------------------- $oLayerSensor_temp->setMetaData("sos_procedure","sputnik001"); $oLayerSensor_temp->setMetaData("sos_offering_id", "oid_1" ); $oLayerSensor_temp->setMetaData("sos_observedproperty_id", "1234" ); $oLayerSensor_temp->setMetaData("sos_describesensor_url", "139.255.165.155/swe/weatherstation.xml" ); $oLayerSensor_temp->setMetaData("sos_componenturl", "139.255.165.155/swe/component.xml" ); $oLayerSensor_temp->setMetaData("sos_observedproperty_name", "opid_name_Temperature" ); $oLayerSensor_temp->setMetaData("sos_offering_description", "OfferingDescription_Temperature" ); $oLayerSensor_temp->setMetaData("sos_offering_extent", "29.5.4, 34.5, 30.5, 35.5" ); $oLayerSensor_temp->setMetaData("sos_offering_timeextent", "1982/2007" ); --------------------------- This is the returned XML: 1982 2007 On the other hand, when the same amount of SOS-Metadata is provided through a map-file, the returned XMl is much more talkative: 2005 2006 ObservedProperty_the_gauge 107.496 -7.80619 107.496 -7.80619 107.496,-7.80619 Any suggestions how to make the Mapscript-Wrapper version more verbose ? CU Peter >There is no direct support through the scripting languages to call SOS >requests or any other OGC specific requests. >You may want to look into the MapScript Wrappers for WxS Services >(http://mapserver.gis.umn.edu/docs/howto/wxs_mapscript) if that can be >used for you purpose. > >Later, > >Peter Loewe wrote: >> Hi, >> >> does any information exist how to formulate SOS getObeservation / describeSensor >>queries when using Mapscript/PHP in the backend ? -- Dr. Peter L?we Psssst! Schon vom neuen GMX MultiMessenger geh?rt? Der kanns mit allen: http://www.gmx.net/de/go/multimessenger From Tom.Kralidis at EC.GC.CA Tue Jul 3 08:27:32 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Tue, 3 Jul 2007 11:27:32 -0400 Subject: Mapscript and SOS In-Reply-To: A<20070703151131.26320@gmx.net> Message-ID: Can you check your server logs see, exactly, what mapscript sends as the GetObservation request? ..Tom > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of "Peter L?we" > Sent: 03 July, 2007 11:12 AM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS > > Hi, > > the MapScript Wrappers for WxS Services indeed _do_ enable > SOS requests, however, the results seem strange: > > A GetObservation-query like: > > http://localhost/swe/php_sos0.php?Request=GetObservation&servi > ce=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik0 > 01&version=0.0.31 > > provides only the event time. (output follow below). > > Here's the SOS-relevant content which is provided via PHP: > --------------------------- > $oLayerSensor_temp->setMetaData("sos_procedure","sputnik001"); > $oLayerSensor_temp->setMetaData("sos_offering_id", "oid_1" ); > $oLayerSensor_temp->setMetaData("sos_observedproperty_id", "1234" ); > $oLayerSensor_temp->setMetaData("sos_describesensor_url", > "139.255.165.155/swe/weatherstation.xml" ); > $oLayerSensor_temp->setMetaData("sos_componenturl", > "139.255.165.155/swe/component.xml" ); > $oLayerSensor_temp->setMetaData("sos_observedproperty_name", > "opid_name_Temperature" ); > $oLayerSensor_temp->setMetaData("sos_offering_description", > "OfferingDescription_Temperature" ); > $oLayerSensor_temp->setMetaData("sos_offering_extent", > "29.5.4, 34.5, 30.5, 35.5" ); > $oLayerSensor_temp->setMetaData("sos_offering_timeextent", > "1982/2007" ); > --------------------------- > > This is the returned XML: > > > xmlns:gml="http://www.opengis.net/gml" > xmlns:ows="http://www.opengis.net/ows" > xmlns:swe="http://www.opengis.net/swe" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:sos="http://www.opengis.net/sos" > xmlns:om="http://www.opengis.net/om" gml:id="oid_1" > xsi:schemaLocation="http://www.opengeospatial.net/om > http://schemas.opengeospatial.net/om.xsd"> > > > xmlns:gml="http://www.opengis.net/gml">1982 > xmlns:gml="http://www.opengis.net/gml">2007 > > > > > On the other hand, when the same amount of SOS-Metadata is > provided through a map-file, the returned XMl is much more talkative: > > > xmlns:gml="http://www.opengis.net/gml" > xmlns:ows="http://www.opengis.net/ows" > xmlns:swe="http://www.opengis.net/swe" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:sos="http://www.opengis.net/sos" > xmlns:om="http://www.opengis.net/om" gml:id="gauge01" > xsi:schemaLocation="http://www.opengeospatial.net/om > http://schemas.opengeospatial.net/om.xsd"> > > > xmlns:gml="http://www.opengis.net/gml">2005 > xmlns:gml="http://www.opengis.net/gml">2006 > > > > > xlink:href="urn:ogc:def:procedure:SOSPROCEDURE_the_gauge"/> > ObservedProperty_the_gauge > > > > > > 107.496 > -7.80619 > 107.496 > -7.80619 > > > > xmlns:gml="http://www.opengis.net/gml" srsName="epsg:4326"> > xmlns:gml="http://www.opengis.net/gml">107.496,-7.80619 oordinates> > > > > > > > > > > > Any suggestions how to make the Mapscript-Wrapper version > more verbose ? > > CU > Peter > > > >There is no direct support through the scripting languages > to call SOS > >requests or any other OGC specific requests. > >You may want to look into the MapScript Wrappers for WxS Services > >(http://mapserver.gis.umn.edu/docs/howto/wxs_mapscript) if > that can be > >used for you purpose. > > > >Later, > > > >Peter Loewe wrote: > >> Hi, > >> > >> does any information exist how to formulate SOS > getObeservation / describeSensor >>queries when using > Mapscript/PHP in the backend ? > -- > Dr. Peter L?we > > > > > > > Psssst! Schon vom neuen GMX MultiMessenger geh?rt? > Der kanns mit allen: http://www.gmx.net/de/go/multimessenger > From peter.loewe at GMX.DE Tue Jul 3 08:45:43 2007 From: peter.loewe at GMX.DE (=?iso-8859-1?Q?=22Peter_L=F6we=22?=) Date: Tue, 3 Jul 2007 17:45:43 +0200 Subject: Mapscript and SOS In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277EFE@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Hello Tom: After calling up http://localhost/swe/php_sos0.php?Request=GetObservation&service=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.31 the apache access_log holds: ::1 - - [03/Jul/2007:17:36:37 +0200] "GET /swe/php_sos0.php?Request=GetObservation&service=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.31 HTTP/1.1" 200 790 and this piece of XML is returned: 1982 2007 ..Peter >Can you check your server logs see, exactly, what mapscript sends as the >GetObservation request? > >..Tom -- Dr. Peter L?we Psssst! Schon vom neuen GMX MultiMessenger geh?rt? Der kanns mit allen: http://www.gmx.net/de/go/multimessenger From Tom.Kralidis at EC.GC.CA Tue Jul 3 08:51:12 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Tue, 3 Jul 2007 11:51:12 -0400 Subject: Mapscript and SOS In-Reply-To: A<20070703154543.204580@gmx.net> Message-ID: Weird. What happens (in terms of the response) when you do a GetCapabilities via mapscript and regular SOS request? I wonder if the metadata is actually being set. ..Tom > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of "Peter L?we" > Sent: 03 July, 2007 11:46 AM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS > > Hello Tom: > > After calling up > http://localhost/swe/php_sos0.php?Request=GetObservation&servi > ce=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik0 > 01&version=0.0.31 > > the apache access_log holds: > > ::1 - - [03/Jul/2007:17:36:37 +0200] "GET > /swe/php_sos0.php?Request=GetObservation&service=SOS&offering= > oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.3 > 1 HTTP/1.1" 200 790 > > and this piece of XML is returned: > > > xmlns:gml="http://www.opengis.net/gml" > xmlns:ows="http://www.opengis.net/ows" > xmlns:swe="http://www.opengis.net/swe" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:sos="http://www.opengis.net/sos" > xmlns:om="http://www.opengis.net/om" gml:id="oid_1" > xsi:schemaLocation="http://www.opengeospatial.net/om > http://schemas.opengeospatial.net/om.xsd"> > > > xmlns:gml="http://www.opengis.net/gml">1982 > xmlns:gml="http://www.opengis.net/gml">2007 > > > > > > > ..Peter > > > >Can you check your server logs see, exactly, what mapscript > sends as the >GetObservation request? > > > >..Tom > -- > Dr. Peter L?we > > > > > > > Psssst! Schon vom neuen GMX MultiMessenger geh?rt? > Der kanns mit allen: http://www.gmx.net/de/go/multimessenger > From bfischer at HOUSTONENGINEERINGINC.COM Tue Jul 3 12:20:06 2007 From: bfischer at HOUSTONENGINEERINGINC.COM (Fischer, Brian) Date: Tue, 3 Jul 2007 14:20:06 -0500 Subject: nquery produces extra results Message-ID: MapServer Users, I received a line shapefile that I am trying to use in an nquery call to mapserver. Everytime I perform an nquery on the layer I get two extra results in my template. Has anyone ran into this issue? I think I have the mapfile defined correctly, so I believe it might be an issue with the shapefile. Does anyone know what in a shapefile would cause this to happen? It is just a shapefile of roads and it appears to be fine (no extra records) when using it in ArcView. I have done many applications using nquery in the past and never ran into this issue before. Here is the URL that makes the nquery call and produces two extra records: http://demo.openmnnd.org/cgi-bin/mapserv.exe?map=/geomoose_install/ms4w/ apps/GeoMOOSE/maps_morton/identify.map&mapxy=313517.8472682601%205202126 .4672472775&layers=SectionLines%20RoadsQuery&mode=nquery Also here is the snippet from the mapfile that is being called. MAP NAME 'all layers' SIZE 800 650 STATUS ON EXTENT 208161.327 5147824.71 300060.94 5222515.03 UNITS METERS SYMBOLSET 'symbols/basics.sym' SHAPEPATH 'geomoose_install/ms4w/apps/GeoMOOSE/maps_morton' TRANSPARENT TRUE IMAGETYPE PNG QUERYMAP STATUS ON STYLE SELECTED END WEB IMAGEPATH "/ms4w/tmp/ms_tmp/" IMAGEURL "/ms_tmp/" HEADER 'header.html' FOOTER 'footer.html' EMPTY '/geomoose/query_miss.html' END LAYER NAME 'RoadsQuery' DATA 'transportation/roads_new.shp' STATUS ON TYPE LINE MAXSCALE 300000 TOLERANCE 1 TEMPLATE 'transportation/identify_roads.html' END LAYER NAME 'SectionLines' DATA 'administrative/sections.shp' STATUS ON TYPE POLYGON TOLERANCE 0 TEMPLATE 'administrative/identify_plss.html' END END Any help or insights would be appreciated. Thanks, Brian Brian Fischer, CFM GIS Project Manager Houston Engineering, Inc. | Leave Nothing to ChanceTM 6901 East Fish Lake Road, Suite 140 Maple Grove, MN 55369 Phone: 763.493.4522 / Fax: 763.493.5572 Email: bfischer at houstonengineeringinc.com Website: www.houstonengineeringinc.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From nelson.little at TENIX.COM Tue Jul 3 18:05:32 2007 From: nelson.little at TENIX.COM (LITTLE Nelson) Date: Wed, 4 Jul 2007 11:05:32 +1000 Subject: Architectural Question Message-ID: Hello Mapserver users, I have developed a web based mapserver application using Java Mapscript & Servlets and it works well and looks great. I currently use the Rosa Applet as the map window display. My application is very similar in behaviour to the Mapserver Atlas application (AKA gmap) (online: http://www.mapsherpa.com/gmap/gmap75.phtml). Whenever the user hits 'Redraw Map' or clicks on a tool button, it causes the whole pages to be refreshed. My question is how could this be changed so that only the map window is refreshed, not the whole page? I know this is an architectural type question which is not really related to Mapserver, but if anyone would know the answer it would be the people on this list. Thanks, Nelson Disclaimer : The contents of this e-mail including any attachments are intended only for the person or entity to which this e-mail is addressed. If you are not, or believe you may not be, the intended recipient, please advise the sender immediately by return e-mail, delete this e-mail and destroy any copies. Tenix does not warrant nor guarantee that this email communication is free from errors, virus, interception or interference. -------------- next part -------------- An HTML attachment was scrubbed... URL: From silvia.petcu at DPRA.COM Tue Jul 3 18:08:19 2007 From: silvia.petcu at DPRA.COM (Silvia Petcu) Date: Tue, 3 Jul 2007 20:08:19 -0500 Subject: WMS layer-projection Message-ID: I?m using PHP MapScript (MapServer 4.9) function getWMSFeatureInfoURL (x_px,y_px,50,?GML.1?) to query few WMS layers that are in a different projection than my map. The map projection is Lambert Conformal and the WMS layers are in Geographic projection(epsg:4326). The map covers Northwest Territories in Canada and the difference between Geographic and other projections is really noticeable here. The result returned by the function is in the right projection but the coordinates X,Y seams to be off and for WMS layers that are Point type I never get a hit when I query, for Polygons is a better since I can zoom enough to get a good result. If the map is the same projection as the WMS layer the function return a correct result and I can query without problem. Is this a known issue or I?m missing something? Thank you, Silvia Petcu From silvia.petcu at DPRA.COM Tue Jul 3 19:40:41 2007 From: silvia.petcu at DPRA.COM (Silvia Petcu) Date: Tue, 3 Jul 2007 21:40:41 -0500 Subject: Oracle Spatial reproject geometries Message-ID: Hi all, I'm using an Oracle Spatial layer (polygon geometry) that is in decimal degrees (epsg: 4326), in a map that is in another projection. The layer geometries usually are rectangles with 4-5 vertices, when the map is draw the geometry is re-projected but the lines are straight lines with no curvature and the image is really ugly (some big trapezoids ? is the same image as the one generated by Spatial Advisor in Oracle if I would transform the geometry using the epsg of map). On the other hand if I get the same layer and converted in a shape file, than loaded into my map file, the image is re-projected nicely with curved lines. I cannot use shape files in my map, I?m stuck with oracle spatial and I was wandering if there is any way to get the same image for oracle spatial as I get for shape file. Thank you in advance. From Antti.Roppola at BRS.GOV.AU Tue Jul 3 22:30:00 2007 From: Antti.Roppola at BRS.GOV.AU (Roppola, Antti - BRS) Date: Wed, 4 Jul 2007 15:30:00 +1000 Subject: Mapscript 4.10.0 and 4.10.2 gives segfault with Postgres 8.2 [SEC=UNCLASSIFIED] Message-ID: Hi all, We're in the process of upgrading from 4.8.1 to 4.10.2 and we are seeing segfaults when using PostGIS layers. I've had a look through the bug tracker and source, the main difference between msPOSTGISLayerRetrievePK() between 4.8.1 and 4.10.2 appears to be the following (mappostgis.c revisions 1.66 to 1.77): * Revision 1.71 2006/05/03 22:35:41 pramsey * Added schema separation and search path awareness to the LayerRetrievePK. (towards Bug 1571) Does anyone know if this is a known issue? Is the schema patch likely to be the source of it? - I can usually get two or three maps before the application server dies completely - We're using the Java mapscript swig bindings - Postgres 8.2 with PostGIS 1.2.0 - The segfault occurs with 4.10.0 and 4.10.2 - I have not had a chance to see if the CGI version has the same problem - Reverting to 4.8.1 on the same system works fine, suggesting it's not a Postgres/PostGIS issue - Stack trace included below Thanks, Antti Roppola Stack: [0x6f395000,0x6f408000), sp=0x6f4033c4, free space=440k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) C [libc.so.6+0x68055] strncpy+0x35 C [libmapscript.so.4.10.2+0xcf5ae] msPOSTGISLayerRetrievePK+0x8e C [libmapscript.so.4.10.2+0xd0b18] C [libmapscript.so.4.10.2+0xd1694] msPOSTGISLayerWhichShapes+0xd4 C [libmapscript.so.4.10.2+0x84f2b] msLayerWhichShapes+0x5b C [libmapscript.so.4.10.2+0x91c79] msDrawVectorLayer+0x1c9 C [libmapscript.so.4.10.2+0x920da] msDrawLayer+0x8a C [libmapscript.so.4.10.2+0x934d1] msDrawMap+0x1d1 C [libmapscript.so.4.10.2+0x464e5] Java_edu_umn_gis_mapscript_mapscriptJNI_mapObj_1draw+0x35 j edu.umn.gis.mapscript.mapscriptJNI.mapObj_draw(JLedu/umn/gis/mapscript/m apObj;)J+0 j edu.umn.gis.mapscript.mapObj.draw()Ledu/umn/gis/mapscript/imageObj;+5 v ~StubRoutines::call_stub ------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 confidential 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 ------ -------------- next part -------------- An HTML attachment was scrubbed... URL: From williams at WEBSAWYER.COM Tue Jul 3 23:32:49 2007 From: williams at WEBSAWYER.COM (Doug Williams) Date: Wed, 4 Jul 2007 00:32:49 -0600 Subject: phpmapscript imagemap creation Message-ID: Rodrigo, Here is what I did to make the imagemap work using phpmapscript. This is my first go round trying to create an imagemap, so others may have more sensible methods or more extended methods, but I never did get any specific information from anyone, nor could I find any complete information about FORMATOPTIONs which would be very helpful!!. I had to feel my way through trying to piece together bits and pieces of scattered information, found luckily by google searching which turned up one interesting old message from the list from someone that also did not have it working. I never did find any response to that person that showed a working example. Anyhow, I have also not ever tried to describe this process so bear with my rambling, long-winded description. First I added a OUTPUTFORMAT to my mapfile. I already had one OUTPUTFORMAT in my mapfile to improve the quality of images generated by mapserver. Whichever OUTPUTFORMAT comes first in the map file is used when generating images, unless the script resets this, which has to be done in order to generate both the imagemap (which is not an actual image, but just some html code) and the map (which is the actual visual image that is displayed). It would be possible to use more than one mapfile rather than resetting the outputformat used, but it is not necessary. More on outputformats in a minute. Also it is necessary to define a CLASSITEM for the layer that you want to use to define your imagemap. The classitem is the attribute that is stuffed into the html and displayed when the mouse is held over map polygons (in this example, a simple one layer example). The other important connection between the map file and the script is that the image shown in the html output has to be the same dimensions as the IMAGESIZE defined in the map file. The other necessary steps take place in the php script. So hear is the mapfile stuff: OUTPUTFORMAT NAME imagemap DRIVER imagemap FORMATOPTION "MAPNAME=map_test" FORMATOPTION "TITLE='' # this gets stuffed properly, you do not need to reference anything # on the right side of the = sign # in fact, you do not need this option at all. But maybe # someday you will? MIMETYPE "text/html" # this option is also not needed! END OUTPUTFORMAT NAME jpeg DRIVER "GD/JPEG" MIMETYPE "image/jpeg" IMAGEMODE RGB EXTENSION "jpg" FORMATOPTION "QUALITY=100" END The first output format is used to generate the imagemap, the second is used to generate the actual map. The script resets the format that is used. Show you that in a second. I don't really think the mimetype statement is necessary, but I have seen it used so I include it here. I myself will actually end up using the FORMATOPTIONs for mouseover and mouseout shown in my earlier message, but I am not going to go into how I am going to take good advantage of them here because it will apparently be necessary for me to do some additional coding to get the effect I want, which I find works much better (immediate response on the web page with more inclusive attribute data detail), but is more complicated programmatically... more scripting on the server side and a script on the client side as well which is not needed with this method. I won't describe the second output format, but the first defines a reference name for the outputformat; the driver which tells mapserver what to generate in terms of output, in this case the html code defining the areas of the imagemap with the coords; the name of the generated , you use this name when declaring the usemap; and the formatoption to add a title for each defined area of the imagemap which is stuffed with the attribute data from the shapefile specified by the layer classitem (not really needed). (Don't formatoption suppress="yes", or you will not get the areas in your .) So hear is my layer definition in my map file: LAYER NAME "lakes" # this is a bad layer example because the polygons are small and so # the imagemap driver generates some bad areas. I'll process these out. # Typically one would likely be using this with maps that produce # larger features than a few worldwide lakes that are being squished to mere dots # in an image the size and way I am doing here. DATA esri/world/lakes STATUS on TYPE polygon CLASSITEM "NAME" # this is the attribute field to list in the 'title' for each area CLASS NAME "Lakes" COLOR -1 -1 -1 OUTLINECOLOR 200 200 50 END END Well, it is something like that anyway, but the important part is the CLASSITEM line, which tells the imagemap driver what information you want stuffed in the map area title. Again, the title formatoption above is not even needed, the imagemap driver just stuffs the classitem values into the title for each area. It would be much nicer if all the attributes were made available with a reference mechanism so that one would have to declare something like formatoption "TITLE=[NAME]" with a way to escape characters like quotes ... maybe that is coming in the future. The map file will also have the SIZE defined, such as: SIZE 600 300 which we will use in the script to define the width and height of the image returned to the browser. So those are the mapfile necessities. Easy enough. The php script is not so bad either. If you have created and displayed a map, then you know how to create your map object for creating the actual map: $map_path="/path/to/mapfile/directory"; $map_file="mapfile.map"; $map = ms_newMapObj($map_path.$map_file); You may want to create another map object to deal with the imagemap, though you could just use the same object. $imagemap = ms_newMapObj($map_path.$map_file); I draw the imagemap first, and the imagemap driver is set first in my map file, so draw() is using that driver. It will be necessary to change this to the jpeg outputformat before drawing the other map (or png or gif or whatever you may be doing): $htmlmap = $imagemap->draw(); $htmlmap->saveImage("/path/to/someplace/the/script/can/write/test.html", $imagemap); This will generate a text file on the server. test.html will be the: with areas and coords and titles I use the php require() command to write this into the html that I return to the browser. To change the ouputdriver use the phpmapscript command: $map->selectOutputFormat("jpeg"); and draw as before: $image=$map->draw(); $image_url=$image->saveWebImage(MS_PNG,1,1,0); I have mixed jpeg and png here ... probably not what you want, png is better for vector/line type stuff, jpeg is better for more real world type images (in my understanding). So now you have an image of your map as before, and you have the imagemap information in a file that was written to the server. I add the imagemap to the html output like this: I just plop it in right after I send the html tag. Then you need to display the image in an tag. The standard mapserver way is to place the image in a form tag, but I have not tried this as I read stuff stating that imagemaps do not work in form elements (makes sense since there is no place to associate the needed usemap). Fortunately I had already moved away from displaying my images in those elements because I wanted to be able to click on the map without sending the form automatically. Not using the form element means you will have to send the img.x and img.y coordinates that get sent automatically when using the form element by some other method, but that goes beyond the scope of this discussion. So display the image like this: usemap="#map_test" width=width; ?> height=height; ?> border=0> or however you like to code. If things turn out correctly, when you place the cursor over a polygon and leave it still for a couple of seconds, the title will appear by the cursor showing you the attribute data. View the page source to see if the looks like what you expect it to look like. Those are the basic pieces. Sorry it is not a very well laid out description. If you have any questions, feel free to ask. I am using a slightly more recent version of mapserver, but believe this has been around a while. If the mapserver folks would like, I would be willing to produce something more in line with some of the howtos. Best, Doug From umberto.nicoletti at GMAIL.COM Tue Jul 3 23:43:00 2007 From: umberto.nicoletti at GMAIL.COM (Umberto Nicoletti) Date: Wed, 4 Jul 2007 08:43:00 +0200 Subject: Mapscript 4.10.0 and 4.10.2 gives segfault with Postgres 8.2 [SEC=UNCLASSIFIED] In-Reply-To: <61C2DEA055980B418D063F8646FCAEFC02876032@ACT001CL03EX03.agdaff.gov.au> Message-ID: Open a ticket at: http://trac.osgeo.org/mapserver/ include a demo mapfile and code to reproduce the problem if you can. We'll work on it asap. Thanks, Umberto On 7/4/07, Roppola, Antti - BRS wrote: > > > Hi all, > > We're in the process of upgrading from 4.8.1 to 4.10.2 and we are seeing > segfaults > when using PostGIS layers. I've had a look through the bug tracker and > source, the main > difference between msPOSTGISLayerRetrievePK() between 4.8.1 and 4.10.2 > appears > to be the following (mappostgis.c revisions 1.66 to 1.77): > > * Revision 1.71 2006/05/03 22:35:41 pramsey > * Added schema separation and search path awareness to the LayerRetrievePK. > (towards Bug 1571) > > Does anyone know if this is a known issue? Is the schema patch likely to be > the source of it? > > - I can usually get two or three maps before the application server dies > completely > - We're using the Java mapscript swig bindings > - Postgres 8.2 with PostGIS 1.2.0 > - The segfault occurs with 4.10.0 and 4.10.2 > - I have not had a chance to see if the CGI version has the same problem > - Reverting to 4.8.1 on the same system works fine, suggesting it's not a > Postgres/PostGIS issue > - Stack trace included below > > Thanks, > > Antti Roppola > > Stack: [0x6f395000,0x6f408000), sp=0x6f4033c4, free space=440k > Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native > code) > C [libc.so.6+0x68055] strncpy+0x35 > C [libmapscript.so.4.10.2+0xcf5ae] msPOSTGISLayerRetrievePK+0x8e > C [libmapscript.so.4.10.2+0xd0b18] > C [libmapscript.so.4.10.2+0xd1694] msPOSTGISLayerWhichShapes+0xd4 > C [libmapscript.so.4.10.2+0x84f2b] msLayerWhichShapes+0x5b > C [libmapscript.so.4.10.2+0x91c79] msDrawVectorLayer+0x1c9 > C [libmapscript.so.4.10.2+0x920da] msDrawLayer+0x8a > C [libmapscript.so.4.10.2+0x934d1] msDrawMap+0x1d1 > C [libmapscript.so.4.10.2+0x464e5] > Java_edu_umn_gis_mapscript_mapscriptJNI_mapObj_1draw+0x35 > j > edu.umn.gis.mapscript.mapscriptJNI.mapObj_draw(JLedu/umn/gis/mapscript/mapObj;)J+0 > j > edu.umn.gis.mapscript.mapObj.draw()Ledu/umn/gis/mapscript/imageObj;+5 > v ~StubRoutines::call_stub > > > > ------ > 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 confidential 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 piero.cavalieri at GMAIL.COM Wed Jul 4 00:55:07 2007 From: piero.cavalieri at GMAIL.COM (Piero Cavalieri) Date: Wed, 4 Jul 2007 09:55:07 +0200 Subject: Architectural Question In-Reply-To: <200707040105.l6415WWj008860@sprint2.tenix.com> Message-ID: You could use iframe or ajax ways. I used AjaxPro with.NET and cgi Mapserver and I don't have a single page refresh (everything is updated in background: map, scalebar, legend, query results). If u use Java, I think u coluld try DWR (Direct Web Remoting). Seems to remember that JBox is more suitable to use with Ajax, but try some ways. Cheers Piero 2007/7/4, LITTLE Nelson : > > Hello Mapserver users, > > > > I have developed a web based mapserver application using Java Mapscript & > Servlets and it works well and looks great. I currently use the Rosa Applet > as the map window display. My application is very similar in behaviour to > the Mapserver Atlas application (AKA gmap) (online: > http://www.mapsherpa.com/gmap/gmap75.phtml). > > > > Whenever the user hits 'Redraw Map' or clicks on a tool button, it causes > the whole pages to be refreshed. My question is how could this be changed so > that only the map window is refreshed, not the whole page? I know this is an > architectural type question which is not really related to Mapserver, but if > anyone would know the answer it would be the people on this list. > > > > Thanks, > > Nelson > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andreas.albarello at TERRITORIUMONLINE.COM Wed Jul 4 01:41:31 2007 From: andreas.albarello at TERRITORIUMONLINE.COM (Andreas Albarello) Date: Wed, 4 Jul 2007 10:41:31 +0200 Subject: Mapscript 4.10.0 and 4.10.2 gives segfault with Postgres 8.2 [SEC=UNCLASSIFIED] In-Reply-To: <61C2DEA055980B418D063F8646FCAEFC02876032@ACT001CL03EX03.agdaff.gov.au> Message-ID: Roppola, Antti - BRS wrote: > Hi all, > > We're in the process of upgrading from 4.8.1 to 4.10.2 and we are seeing > segfaults > when using PostGIS layers. I've had a look through the bug tracker and > source, the main > difference between msPOSTGISLayerRetrievePK() between 4.8.1 and 4.10.2 > appears > to be the following (mappostgis.c revisions 1.66 to 1.77): Antti, yes, this looks indeed like a bug in msPOSTGISLayerRetrievePK to me. I've had a look at the code and I could spot line 1770 of mappostgis.c (Mapserver 4.10.1, line number might vary slightly in other versions) which doesn't really look very effective: length = (int)pos_sep + strlen(pos_sep); Casting a pointer into an int doesn't seem to make any sense here. I'd suggest you change that line to length = strlen(pos_sep); recompile and try again. Best regards, -- -------------------------------------------------------------------- Andreas Albarello Analysis & SW Development Territorium Online srl/GmbH Via Buozzi/Buozzistra?e 12 - I 39100 Bolzano/Bozen email: andreas.albarello at territoriumonline.com web: www.territoriumonline.com -------------------------------------------------------------------- From dominik.schmid at ILU.CH Wed Jul 4 03:13:31 2007 From: dominik.schmid at ILU.CH (Dominik Schmid) Date: Wed, 4 Jul 2007 05:13:31 -0500 Subject: Error: *** glibc detected *** double free or corruption (!prev) Message-ID: Hi I have run into this persistent problem and I have already spent hours upon hours without any result whatsoever. First of all my setup: - Centos 4.4 - apache 2.0.52 - php 5.1.6 - postgresql 8.1.8 - mapserver 4.0.1 (I know, I should update mapserver, but having to rebuild all the legends in our system and possibly avoid some other side effects would be a major headache and have so far kept me from doing this) - gdal 1.4.0 - postgis 1.2.1 - geos 2.2.3 - proj 4.5.0 - glibc 2.3.4-2.25 The error in the httpd error_log reads as stated in the subject. I have added some multipolygon data that I had previously obtained by converting it from a shape file using shp2pgsql. The odd part about this error is, that I use the same syntax in the map file as for a working multipolygon layer that I had imported using older versions of postgis etc. and the older data works just fine. I have reimported said working data from the original shape file and compared it to the existing data in the working table. the_geom and other relevant stuff is identical. And still the newly imported data produces this error. I have checked projection, db access privs and just about everything else that crossed my mind as playing a part to no avail. So, is this problem a known issue? What else could I try/look into? Any advice? Thanks Dominik From mdeblois at MAPLECROFT.NET Wed Jul 4 03:50:25 2007 From: mdeblois at MAPLECROFT.NET (Mark de Blois) Date: Wed, 4 Jul 2007 11:50:25 +0100 Subject: Can I cancel WMS request?! Message-ID: Hi there, I was wondering whether it is possible to cancel WMS request once they have been fired at MapServer. Could someone enlighten me on this? Thanks, Mark From rodrigomartin at LOPEZGREGORIO.COM.AR Wed Jul 4 04:47:55 2007 From: rodrigomartin at LOPEZGREGORIO.COM.AR (=?ISO-8859-1?Q?Rodrigo_Mart=EDn_L=D3PEZ_GREGORIO?=) Date: Wed, 4 Jul 2007 12:47:55 +0100 Subject: phpmapscript imagemap creation In-Reply-To: <20070704062209.M52843@websawyer.com> Message-ID: Doug. Thanks. That's great and it was very clear. I think that will be great if you put this in a how-to in mapserver site, cause as you said, there are no enough information about the imagemap creation with mapserver. Thanks again. Rodrigo On 7/4/07, Doug Williams wrote: > > Rodrigo, > > Here is what I did to make the imagemap work using phpmapscript. This is > my first go round trying > to create an imagemap, so others may have more sensible methods or more > extended methods, but I > never did get any specific information from anyone, nor could I find any > complete information about > FORMATOPTIONs which would be very helpful!!. I had to feel my way through > trying to piece > together bits and pieces of scattered information, found luckily by > google searching which turned > up one interesting old message from the list from someone that also did > not have it working. I never > did find any response to that person that showed a working > example. Anyhow, I have also not ever > tried to describe this process so bear with my rambling, long-winded > description. > > First I added a OUTPUTFORMAT to my mapfile. I already had one > OUTPUTFORMAT in my mapfile to > improve the quality of images generated by mapserver. Whichever > OUTPUTFORMAT comes first in > the map file is used when generating images, unless the script resets > this, which has to be done in > order to generate both the imagemap (which is not an actual image, but > just some html code) and > the map (which is the actual visual image that is displayed). It would be > possible to use more than > one mapfile rather than resetting the outputformat used, but it is not > necessary. More on > outputformats in a minute. Also it is necessary to define a CLASSITEM for > the layer that you want to > use to define your imagemap. The classitem is the attribute that is > stuffed into the html and > displayed when the mouse is held over map polygons (in this example, a > simple one layer example). > The other important connection between the map file and the script is that > the image shown in the > html output has to be the same dimensions as the IMAGESIZE defined in the > map file. The other > necessary steps take place in the php script. So hear is the mapfile > stuff: > > OUTPUTFORMAT > NAME imagemap > DRIVER imagemap > FORMATOPTION "MAPNAME=map_test" > FORMATOPTION "TITLE='' # this gets stuffed properly, you do not need > to reference anything > # on the right side > of the = sign > # in fact, you do > not need this option at all. But maybe > # someday you will? > MIMETYPE "text/html" # this option is also not needed! > END > > OUTPUTFORMAT > NAME jpeg > DRIVER "GD/JPEG" > MIMETYPE "image/jpeg" > IMAGEMODE RGB > EXTENSION "jpg" > FORMATOPTION "QUALITY=100" > END > > The first output format is used to generate the imagemap, the second is > used to generate the actual > map. The script resets the format that is used. Show you that in a > second. I don't really think the > mimetype statement is necessary, but I have seen it used so I include it > here. I myself will actually > end up using the FORMATOPTIONs for mouseover and mouseout shown in my > earlier message, but I > am not going to go into how I am going to take good advantage of them here > because it will > apparently be necessary for me to do some additional coding to get the > effect I want, which I find > works much better (immediate response on the web page with more inclusive > attribute data detail), > but is more complicated programmatically... more scripting on the server > side and a script on the > client side as well which is not needed with this method. I won't > describe the second output format, > but the first defines a reference name for the outputformat; the driver > which tells mapserver what to > generate in terms of output, in this case the html code defining the areas > of the imagemap with the > coords; the name of the generated , you use this name when declaring > the usemap; and the > formatoption to add a title for each defined area of the imagemap which is > stuffed with the attribute > data from the shapefile specified by the layer classitem (not really > needed). (Don't formatoption > suppress="yes", or you will not get the areas in your .) > > So hear is my layer definition in my map file: > > LAYER > NAME "lakes" # this is a bad layer example because the polygons > are small and so > # the imagemap driver generates some bad > areas. I'll process these > out. > # Typically one would likely be using > this with maps that produce > # larger features than a few worldwide > lakes that are being squished to mere > dots > # in an image the size and way I am > doing here. > DATA esri/world/lakes > STATUS on > TYPE polygon > CLASSITEM "NAME" # this is the attribute field to list in the > 'title' for each area > CLASS > NAME "Lakes" > COLOR -1 -1 -1 > OUTLINECOLOR 200 200 50 > END > END > > Well, it is something like that anyway, but the important part is the > CLASSITEM line, which tells the > imagemap driver what information you want stuffed in the map area > title. Again, the title > formatoption above is not even needed, the imagemap driver just stuffs the > classitem values into the > title for each area. It would be much nicer if all the attributes were > made available with a reference > mechanism so that one would have to declare something like formatoption > "TITLE=[NAME]" with a > way to escape characters like quotes ... maybe that is coming in the > future. > > The map file will also have the SIZE defined, such as: > SIZE 600 300 > which we will use in the script to define the width and height of the > image returned to the browser. > > So those are the mapfile necessities. Easy enough. > > The php script is not so bad either. > > If you have created and displayed a map, then you know how to create your > map object for creating > the actual map: > $map_path="/path/to/mapfile/directory"; > $map_file="mapfile.map"; > $map = ms_newMapObj($map_path.$map_file); > > You may want to create another map object to deal with the imagemap, > though you could just use > the same object. > $imagemap = ms_newMapObj($map_path.$map_file); > > I draw the imagemap first, and the imagemap driver is set first in my map > file, so draw() is using that > driver. It will be necessary to change this to the jpeg outputformat > before drawing the other map (or > png or gif or whatever you may be doing): > $htmlmap = $imagemap->draw(); > $htmlmap->saveImage("/path/to/someplace/the/script/can/write/test.html", > $imagemap); > > This will generate a text file on the server. > test.html will be the: > > with areas and coords and titles > > > I use the php require() command to write this into the html that I return > to the browser. > > To change the ouputdriver use the phpmapscript command: > $map->selectOutputFormat("jpeg"); > and draw as before: > $image=$map->draw(); > $image_url=$image->saveWebImage(MS_PNG,1,1,0); > I have mixed jpeg and png here ... probably not what you want, png is > better for vector/line type > stuff, jpeg is better for more real world type images (in my > understanding). > > So now you have an image of your map as before, and you have the imagemap > information in a file > that was written to the server. I add the imagemap to the html output > like this: > > > > I just plop it in right after I send the html tag. Then you need to > display the image in an > tag. The standard mapserver way is to place the image in a form > tag, but I have not > tried this as I read stuff stating that imagemaps do not work in form > elements > (makes sense since there is no place to associate the needed > usemap). Fortunately I had already > moved away from displaying my images in those elements because I wanted to > be able to click on > the map without sending the form automatically. Not using the form > element means you will have to > send the img.x and img.y coordinates that get sent automatically when > using the form element by > some other method, but that goes beyond the scope of this discussion. > > So display the image like this: > usemap="#map_test" width= $map->width; ?> height= echo $map->height; ?> border=0> > > or however you like to code. If things turn out correctly, when you place > the cursor over a polygon > and leave it still for a couple of seconds, the title will appear by the > cursor showing you the attribute > data. View the page source to see if the looks like what you expect > it to look like. > > Those are the basic pieces. Sorry it is not a very well laid out > description. If you have any questions, > feel free to ask. I am using a slightly more recent version of mapserver, > but believe this has been > around a while. If the mapserver folks would like, I would be willing to > produce something more in > line with some of the howtos. > > Best, > Doug > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dmorissette at MAPGEARS.COM Wed Jul 4 04:51:16 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Wed, 4 Jul 2007 07:51:16 -0400 Subject: WMS layer-projection In-Reply-To: Message-ID: This is not a known issue, but it's always possible that there might be problems in the way the query location is reprojected in a GetFeatureInfo call. Is the WMS server using MapServer as well? Have you tried setting/increasing the TOLERANCE value inside the layers on the WMS server? Daniel Silvia Petcu wrote: > I?m using PHP MapScript (MapServer 4.9) function getWMSFeatureInfoURL > (x_px,y_px,50,?GML.1?) to query few WMS layers that are in a different > projection than my map. The map projection is Lambert Conformal and the > WMS layers are in Geographic projection(epsg:4326). The map covers > Northwest Territories in Canada and the difference between Geographic and > other projections is really noticeable here. > The result returned by the function is in the right projection but the > coordinates X,Y seams to be off and for WMS layers that are Point type I > never get a hit when I query, for Polygons is a better since I can zoom enough > to get a good result. > If the map is the same projection as the WMS layer the function return a > correct result and I can query without problem. > Is this a known issue or I?m missing something? > > Thank you, > Silvia Petcu -- Daniel Morissette http://www.mapgears.com/ From rodrigomlg at GMAIL.COM Wed Jul 4 07:16:59 2007 From: rodrigomlg at GMAIL.COM (=?ISO-8859-1?Q?Rodrigo_Mart=EDn_L=D3PEZ_GREGORIO?=) Date: Wed, 4 Jul 2007 15:16:59 +0100 Subject: phpmapscript imagemap creation In-Reply-To: <20070704062209.M52843@websawyer.com> Message-ID: Doug. Thanks. That's great and it was very clear. I think that will be great if you put this in a how-to in mapserver site, cause as you said, there are no enough information about the imagemap creation with mapserver. Thanks again. On 7/4/07, Doug Williams wrote: > > Rodrigo, > > Here is what I did to make the imagemap work using phpmapscript. This is > my first go round trying > to create an imagemap, so others may have more sensible methods or more > extended methods, but I > never did get any specific information from anyone, nor could I find any > complete information about > FORMATOPTIONs which would be very helpful!!. I had to feel my way through > trying to piece > together bits and pieces of scattered information, found luckily by > google searching which turned > up one interesting old message from the list from someone that also did > not have it working. I never > did find any response to that person that showed a working > example. Anyhow, I have also not ever > tried to describe this process so bear with my rambling, long-winded > description. > > First I added a OUTPUTFORMAT to my mapfile. I already had one > OUTPUTFORMAT in my mapfile to > improve the quality of images generated by mapserver. Whichever > OUTPUTFORMAT comes first in > the map file is used when generating images, unless the script resets > this, which has to be done in > order to generate both the imagemap (which is not an actual image, but > just some html code) and > the map (which is the actual visual image that is displayed). It would be > possible to use more than > one mapfile rather than resetting the outputformat used, but it is not > necessary. More on > outputformats in a minute. Also it is necessary to define a CLASSITEM for > the layer that you want to > use to define your imagemap. The classitem is the attribute that is > stuffed into the html and > displayed when the mouse is held over map polygons (in this example, a > simple one layer example). > The other important connection between the map file and the script is that > the image shown in the > html output has to be the same dimensions as the IMAGESIZE defined in the > map file. The other > necessary steps take place in the php script. So hear is the mapfile > stuff: > > OUTPUTFORMAT > NAME imagemap > DRIVER imagemap > FORMATOPTION "MAPNAME=map_test" > FORMATOPTION "TITLE='' # this gets stuffed properly, you do not need > to reference anything > # on the right side > of the = sign > # in fact, you do > not need this option at all. But maybe > # someday you will? > MIMETYPE "text/html" # this option is also not needed! > END > > OUTPUTFORMAT > NAME jpeg > DRIVER "GD/JPEG" > MIMETYPE "image/jpeg" > IMAGEMODE RGB > EXTENSION "jpg" > FORMATOPTION "QUALITY=100" > END > > The first output format is used to generate the imagemap, the second is > used to generate the actual > map. The script resets the format that is used. Show you that in a > second. I don't really think the > mimetype statement is necessary, but I have seen it used so I include it > here. I myself will actually > end up using the FORMATOPTIONs for mouseover and mouseout shown in my > earlier message, but I > am not going to go into how I am going to take good advantage of them here > because it will > apparently be necessary for me to do some additional coding to get the > effect I want, which I find > works much better (immediate response on the web page with more inclusive > attribute data detail), > but is more complicated programmatically... more scripting on the server > side and a script on the > client side as well which is not needed with this method. I won't > describe the second output format, > but the first defines a reference name for the outputformat; the driver > which tells mapserver what to > generate in terms of output, in this case the html code defining the areas > of the imagemap with the > coords; the name of the generated , you use this name when declaring > the usemap; and the > formatoption to add a title for each defined area of the imagemap which is > stuffed with the attribute > data from the shapefile specified by the layer classitem (not really > needed). (Don't formatoption > suppress="yes", or you will not get the areas in your .) > > So hear is my layer definition in my map file: > > LAYER > NAME "lakes" # this is a bad layer example because the polygons > are small and so > # the imagemap driver generates some bad > areas. I'll process these > out. > # Typically one would likely be using > this with maps that produce > # larger features than a few worldwide > lakes that are being squished to mere > dots > # in an image the size and way I am > doing here. > DATA esri/world/lakes > STATUS on > TYPE polygon > CLASSITEM "NAME" # this is the attribute field to list in the > 'title' for each area > CLASS > NAME "Lakes" > COLOR -1 -1 -1 > OUTLINECOLOR 200 200 50 > END > END > > Well, it is something like that anyway, but the important part is the > CLASSITEM line, which tells the > imagemap driver what information you want stuffed in the map area > title. Again, the title > formatoption above is not even needed, the imagemap driver just stuffs the > classitem values into the > title for each area. It would be much nicer if all the attributes were > made available with a reference > mechanism so that one would have to declare something like formatoption > "TITLE=[NAME]" with a > way to escape characters like quotes ... maybe that is coming in the > future. > > The map file will also have the SIZE defined, such as: > SIZE 600 300 > which we will use in the script to define the width and height of the > image returned to the browser. > > So those are the mapfile necessities. Easy enough. > > The php script is not so bad either. > > If you have created and displayed a map, then you know how to create your > map object for creating > the actual map: > $map_path="/path/to/mapfile/directory"; > $map_file="mapfile.map"; > $map = ms_newMapObj($map_path.$map_file); > > You may want to create another map object to deal with the imagemap, > though you could just use > the same object. > $imagemap = ms_newMapObj($map_path.$map_file); > > I draw the imagemap first, and the imagemap driver is set first in my map > file, so draw() is using that > driver. It will be necessary to change this to the jpeg outputformat > before drawing the other map (or > png or gif or whatever you may be doing): > $htmlmap = $imagemap->draw(); > $htmlmap->saveImage("/path/to/someplace/the/script/can/write/test.html", > $imagemap); > > This will generate a text file on the server. > test.html will be the: > > with areas and coords and titles > > > I use the php require() command to write this into the html that I return > to the browser. > > To change the ouputdriver use the phpmapscript command: > $map->selectOutputFormat("jpeg"); > and draw as before: > $image=$map->draw(); > $image_url=$image->saveWebImage(MS_PNG,1,1,0); > I have mixed jpeg and png here ... probably not what you want, png is > better for vector/line type > stuff, jpeg is better for more real world type images (in my > understanding). > > So now you have an image of your map as before, and you have the imagemap > information in a file > that was written to the server. I add the imagemap to the html output > like this: > > > > I just plop it in right after I send the html tag. Then you need to > display the image in an > tag. The standard mapserver way is to place the image in a form > tag, but I have not > tried this as I read stuff stating that imagemaps do not work in form > elements > (makes sense since there is no place to associate the needed > usemap). Fortunately I had already > moved away from displaying my images in those elements because I wanted to > be able to click on > the map without sending the form automatically. Not using the form > element means you will have to > send the img.x and img.y coordinates that get sent automatically when > using the form element by > some other method, but that goes beyond the scope of this discussion. > > So display the image like this: > usemap="#map_test" width= $map->width; ?> height= echo $map->height; ?> border=0> > > or however you like to code. If things turn out correctly, when you place > the cursor over a polygon > and leave it still for a couple of seconds, the title will appear by the > cursor showing you the attribute > data. View the page source to see if the looks like what you expect > it to look like. > > Those are the basic pieces. Sorry it is not a very well laid out > description. If you have any questions, > feel free to ask. I am using a slightly more recent version of mapserver, > but believe this has been > around a while. If the mapserver folks would like, I would be willing to > produce something more in > line with some of the howtos. > > Best, > Doug > -------------- next part -------------- An HTML attachment was scrubbed... URL: From williams at WEBSAWYER.COM Wed Jul 4 07:24:20 2007 From: williams at WEBSAWYER.COM (Doug Williams) Date: Wed, 4 Jul 2007 08:24:20 -0600 Subject: phpmapscript questions Message-ID: Hi jeff, Sorry jeff. I thought I was using the list! Your message confirms my worst fear. That Steve Lime's open source mapserver is being proprietized. Sort of reminds me of Bell Labs claim to unix after thousands of people gave freely to develop it. I was wondering why it has become so hard to get decent answers to simple questions about mapserver, and why the docs are sssooooo thin. And why else would you say 'no' with a grin? Cheers, On Wed, 04 Jul 2007 09:07:01 -0400, Jeff McKenna wrote > Since you seem to want direct support for MapServer, you should know > that our company offers exactly that > > (http://www.dmsolutions.ca/premiere/index.html). At least now you > know how we stay in business :) > > Otherwise please use the email lists. > > -- > jeff > > Doug Williams wrote: > > No worries. I have just been trying to grab attribute values for shapes > > when getting the imagemap coordinates using the imagemap outputformat > > driver. I get the coordinates alright, but have failed to figure out > > the method for getting the attributes. I am guessing grabbing the > > attributes is tied together with grabbing the shape coords because, > > well, I don't know why the coords are interesting without the attributes. > > > > Unfortunately I have not been able to spend enough time yet with > > Mapserver to call myself a power user, so I seek the help of those that > > are. I'd be happy to document my findings so as to assist others that > > are interested in utilizing imagemaps with phpmapscript. > > > > The imagemap works great, I really like it. But grabbing the attributes > > has me stumped. There must be someone that knows how to properly set up > > the map file to generate the attribute data when the coords are being > > mapped. > > > > Any direction on examples or someone that might know would be greatly > > appreciated. > > > > Doug > > > > > > > > On Jul 3, 2007, at 12:02 PM, Jeff McKenna wrote: > > > >> Actually i do a lot of documentation for mapserver, but i am not a > >> developer. sorry. so the answer is no :) In fact i am a "power > >> user", that is all. i maintain ms4w, but a mapscript guy i am not. > >> > >> sorry. > >> > >> jeff > >> > >> > >> > >> Doug Williams wrote: > >>> Jeff, > >>> are you the phpmapscript guy? > > > > > > -- > Jeff McKenna > DM Solutions Group Inc. > http://www.dmsolutions.ca From williams at WEBSAWYER.COM Wed Jul 4 07:31:51 2007 From: williams at WEBSAWYER.COM (Doug Williams) Date: Wed, 4 Jul 2007 08:31:51 -0600 Subject: phpmapscript imagemap attributes Message-ID: Assefa, Again, no worries. I'm serious that taking the time to try to explain to you what I was finding did help me to understand what was going on. I do not understand how you were trying to reproduce what I was doing. I did not know the map SIZE had three components. I thought that the docs indicated that there was just a width and height to the size (in pixels). Perhaps that is why you could not reproduce my results. Best, On Wed, 04 Jul 2007 09:03:45 -0400, Yewondwossen Assefa wrote > Doug, > > Sorry for the late answer. I just tried your map file with your > data. Just using php mapscript : $map_file="c:/msapps/tmp/bug_imagemap_doug/test.map"; > $gpoMap = ms_newMapObj("$map_file"); > $img = $gpoMap->draw(); > $url = $img->saveWebImage(); > > Doug Williams wrote: > > I see now how the classitem is just cramed into the title for the > > imagemap areas. With a little jiggling out the generated imagemap > > output I think I can create what I want. > > > > And I suppose that the squishing of the shape file to fit the image size > > was the problem with the coords. Agreed? > > > > I could not reproduce this : I tried different map size (smallest > I tried is SIZE 2 2 2). I get coords that look like: coords=" 1, > 0" or coords=" 0,0" but never with empty values. Not sure if my > tests are significant. > > > Thanks for responding to my plea for help. Discussing it with you this > > way helped me to realize what was going on. > > > > The formatoptions docs available is the source code (mapimage.c). I > think that is all the docs that exists afaik. There is a desciption > of it at the begining but looking through the code, I see that some > format options are used but not described such as (SYMBOLHREF, > SCRIPT, DXF, SKIPENDTAG). It would be nice to update the > http://mapserver.gis.umn.edu/docs/howto/imagemaps at one point but I > am not familiar enough to do it. > > Later, > > > Cheers, > > Doug > > > > > > On Jun 29, 2007, at 6:17 AM, Yewondwossen Assefa wrote: > > > >> Doug, > >> > >> I am not very familiar with imagemap output but what I can certainly > >> do is test the output results and see why there is a problem with the > >> "coords" output, if you provide me a simple map and data. Note that I > >> will do the tests with Mapserver svn (to be 5.0 release). Note that I > >> did a couple of tests with tests data that I have here and the > >> "cooords" result seem to be correct. > >> > >> Later, > >> > >> Doug Williams wrote: > >>> Hi All, Jeff, Assefa, I have made a phpmapscript to generate an > >>> imagemap for my drawn map so when mousing over the map information > >>> about the shp below the mouse cursor is displayed beside the cursor. > >>> I like the way it works, > >>> http://www.wildweb.org/imagemap/ > >>> except for a couple of questions! I am using version 4.8 on linux. > >>> 1) Some of the polygon coords for the map areas begin with a comma, > >>> such as > >>> > >>> > >>> > >>> ...... > >>> > >>> Notice how the coords for the second area begin with a comma. Does > >>> that mean I have a bad shape file? Those commas seem problematic for > >>> some browsers when using the imagemap. If I delete the commas by > >>> brute force and then display the edited html file, the imagemap works > >>> properly in all the browsers I have checked, although I guess that > >>> the areas with just two coords are not good... > >>> 2) I cannot figure how to get the attribute data for the shape. The > >>> cgi version of mapserver describes using a template, but where the > >>> cgi version describes the use of templates for other tasks, I have > >>> not found them useful for phpmapscript version, nor am I using, for > >>> this script, the header and footer templates as described in the cgi > >>> version imagemap creation tutorial, as setting the OUTPUTFORMAT > >>> driver to imagemap along with the correct FORMATOPTIONs generates > >>> everything as described in the cgi version tutorial, except I am not > >>> understanding how to get the attribute data other than the shp coords. > >>> The cgi version says the the mode would need to be set to nquery. I > >>> think this means that phpmapscript does a drawQuery(). Attempting > >>> this results in: > >>> Warning: [MapServer Error]: msDrawQueryMap(): Unable to initialize > >>> image. in /.../index.php on line 184 > >>> Fatal error: Call to a member function on a non-object in > >>> /.../index.php on line 185 > >>> It does not seem necessary to use drawQuery(). draw() provides the > >>> coords as desired (w/ the question about the commas above). > >>> My belief is that I would grab the attribute data in the > >>> FORMATOPTION statement. Am I on the right track? Does this > >>> capability exist as part of the OUTPUTFORMAT imagemap driver in > >>> phpmapscript? > >>> This is my OUTPUTFORMAT to create the imagemap: > >>> OUTPUTFORMAT > >>> NAME imagemap > >>> DRIVER imagemap > >>> FORMATOPTION "MAPNAME=map_test" > >>> FORMATOPTION "POLYHREF=" > >>> FORMATOPTION "POLYMOUSEOUT=handleClick(event,'boxinfo','hide > >>> it',''); return false;" > >>> FORMATOPTION "POLYMOUSEOVER=handleClick(event,'boxinfo','show > >>> it','%NAME%'); return false;" > >>> FORMATOPTION "TITLE=" > >>> MIMETYPE "text/html" > >>> END > >>> The %NAME% was based on the sections discussing cookie variables and > >>> such, and NAME just ends up displayed without the % chars. [NAME] as > >>> shown in the cgi version doc produces [NAME] as output. I have tried > >>> escaping the ' char with \, but that results in an error. Is there a > >>> code to put in the FORMATOPTION statement to obtain attribute data? > >>> Does the layer definition matter? Here is my layer definition: > >>> LAYER > >>> NAME "lakes" > >>> DATA esri/world/lakes > >>> STATUS on > >>> PROJECTION > >>> "proj=latlong" > >>> END #projection > >>> TYPE POLYGON > >>> METADATA > >>> "DESCRIPTION" "Lakes" > >>> "RESULT_FIELDS" "NAME SURF_ELEV DEPTH" > >>> END > >>> # HEADER "lakes_header.html" > >>> # FOOTER "lakes_footer.html" > >>> TEMPLATE "" > >>> CLASS > >>> NAME "States" > >>> OUTLINECOLOR 0 0 0 > >>> END > >>> END > >>> I have tried this with a couple of different layers and like the > >>> imagemap result (aside from not understanding why some area coords > >>> begin with a comma), but without the attribute data I am not sure > >>> what to do with it! > >>> All ideas would be much appreciated, > >>> Doug > >> > >> > >> ------------------------------------------------------------------ > >> Assefa Yewondwossen > >> Software Analyst > >> > >> Email: assefa at dmsolutions.ca > >> http://www.dmsolutions.ca/ > >> > >> Phone: (613) 565-5056 (ext 14) > >> Fax: (613) 565-0925 > >> ---------------------------------------------------------------- > > > > > > -- > ---------------------------------------------------------------- > Assefa Yewondwossen > Software Analyst > > Email: assefa at dmsolutions.ca > http://www.dmsolutions.ca/ > > Phone: (613) 565-5056 (ext 14) > Fax: (613) 565-0925 > ---------------------------------------------------------------- From jmckenna at DMSOLUTIONS.CA Wed Jul 4 07:32:12 2007 From: jmckenna at DMSOLUTIONS.CA (Jeff McKenna) Date: Wed, 4 Jul 2007 10:32:12 -0400 Subject: phpmapscript questions In-Reply-To: <20070704141356.M74890@websawyer.com> Message-ID: After several emails back and forth directly I had to let you know...but I must say thanks for forwarding my direct response to the entire list. jeff Doug Williams wrote: > Hi jeff, > > Sorry jeff. I thought I was using the list! Your message confirms my worst fear. That Steve Lime's > open source mapserver is being proprietized. Sort of reminds me of Bell Labs claim to unix after > thousands of people gave freely to develop it. I was wondering why it has become so hard to get > decent answers to simple questions about mapserver, and why the docs are sssooooo thin. And why > else would you say 'no' with a grin? > > Cheers, > From jmckenna at DMSOLUTIONS.CA Wed Jul 4 07:34:36 2007 From: jmckenna at DMSOLUTIONS.CA (Jeff McKenna) Date: Wed, 4 Jul 2007 10:34:36 -0400 Subject: phpmapscript questions In-Reply-To: <20070704141356.M74890@websawyer.com> Message-ID: So "Jeff are you the phpmapscript guy?" was a question to the entire list? And that entire thread was to the entire list? Come on. jeff Doug Williams wrote: > Hi jeff, > > Sorry jeff. I thought I was using the list! Your message confirms my worst fear. That Steve Lime's > open source mapserver is being proprietized. Sort of reminds me of Bell Labs claim to unix after > thousands of people gave freely to develop it. I was wondering why it has become so hard to get > decent answers to simple questions about mapserver, and why the docs are sssooooo thin. And why > else would you say 'no' with a grin? > > Cheers, > > > On Wed, 04 Jul 2007 09:07:01 -0400, Jeff McKenna wrote >> Since you seem to want direct support for MapServer, you should know >> that our company offers exactly that >> >> (http://www.dmsolutions.ca/premiere/index.html). At least now you >> know how we stay in business :) >> >> Otherwise please use the email lists. >> >> -- >> jeff >> >> Doug Williams wrote: >>> No worries. I have just been trying to grab attribute values for shapes >>> when getting the imagemap coordinates using the imagemap outputformat >>> driver. I get the coordinates alright, but have failed to figure out >>> the method for getting the attributes. I am guessing grabbing the >>> attributes is tied together with grabbing the shape coords because, >>> well, I don't know why the coords are interesting without the attributes. >>> >>> Unfortunately I have not been able to spend enough time yet with >>> Mapserver to call myself a power user, so I seek the help of those that >>> are. I'd be happy to document my findings so as to assist others that >>> are interested in utilizing imagemaps with phpmapscript. >>> >>> The imagemap works great, I really like it. But grabbing the attributes >>> has me stumped. There must be someone that knows how to properly set up >>> the map file to generate the attribute data when the coords are being >>> mapped. >>> >>> Any direction on examples or someone that might know would be greatly >>> appreciated. >>> >>> Doug >>> >>> >>> >>> On Jul 3, 2007, at 12:02 PM, Jeff McKenna wrote: >>> >>>> Actually i do a lot of documentation for mapserver, but i am not a >>>> developer. sorry. so the answer is no :) In fact i am a "power >>>> user", that is all. i maintain ms4w, but a mapscript guy i am not. >>>> >>>> sorry. >>>> >>>> jeff >>>> >>>> >>>> >>>> Doug Williams wrote: >>>>> Jeff, >>>>> are you the phpmapscript guy? >>> From pcreso at PCRESO.COM Wed Jul 4 11:06:17 2007 From: pcreso at PCRESO.COM (Brent Wood) Date: Wed, 4 Jul 2007 11:06:17 -0700 Subject: Is there a good WMS DLL to embed a WMS client in a VB application? Message-ID: Hi all, We have a Visual Basic application in which which users manually georeference by clicking on some control points & assigning lat's/long's to each. The program then plots GPS positions on this background, & has zoom/pan controls. It is used to capture seabed observations in real time while watching a live video stream from an underwater camera. It is now running on a LAN with a mapserver WMS, and we'd like to use this as the map background provider, instead of the local image. This background is generated from multibeam bathymetry data collected in an immediately prior run over the survey site. Can anyone offer some advice as to the best way to embed such a WMS client in VB? Ideally I guess a dll with zoom/pan & local point overlay capabilities. Thanks, Brent Wood From tutey at O2.PL Wed Jul 4 11:29:05 2007 From: tutey at O2.PL (Maciej Sieczka) Date: Wed, 4 Jul 2007 20:29:05 +0200 Subject: linked tables and spatial queries In-Reply-To: <200706281850.47947.dylan.beaudette@gmail.com> Message-ID: Dylan Beaudette wrote: > I was in need of this type of functionality, and found it through two methods: > > 1. define a query template in your mapfile, and have it redirect the user to a > PHP page which can do related DB lookups and presentation. You can pass along > mapserver query results on the URL. > > 2. use something like ka-map and adjust how the query system displays the > results in the left-hand side panel. I modified the query functions such that > all searching and presentation was done via postgres+PHP. Hi, me again. Do you think this could be possible using Chameleon as well? Maciek From mtrp36 at HOTMAIL.COM Wed Jul 4 22:21:02 2007 From: mtrp36 at HOTMAIL.COM (Kurt Kuo) Date: Thu, 5 Jul 2007 05:21:02 +0000 Subject: Tips for routing with tiger file Message-ID: Dear list, Here may not be the right place to post this question. However, I understand that mapserver users come from different fields. There must be some experts who are able to give me some advices. Thanks in advance. My question is how to use tiger file for routing purpose. As my understanding, routing needs the length of every line between source and target nodes. It seems that the tiger file does not have this information. I really appreciate if someone can provide some advices, tips, or references in order to achieve this matter. Thanks again. Best, Kurt _________________________________________________________________ http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_pcmag_0507 From orkney at GMX.DE Wed Jul 4 22:31:44 2007 From: orkney at GMX.DE (Daniel Kastl) Date: Thu, 5 Jul 2007 14:31:44 +0900 Subject: Tips for routing with tiger file In-Reply-To: Message-ID: Hi Kurt, If you use Mapserver with PostgreSQL/PostGIS, this might help you: http://pgrouting.postlbs.org/ I didn't try Tiger data for routing yet, but it should be possible. Of course you need to adjust your data and create a road network topology. Daniel Kurt Kuo schrieb: > Dear list, > Here may not be the right place to post this question. However, I > understand that mapserver users come from different fields. There must > be some experts who are able to give me some advices. Thanks in advance. > My question is how to use tiger file for routing purpose. As my > understanding, routing needs the length of every line between source and > target nodes. It seems that the tiger file does not have this > information. I really appreciate if someone can provide some advices, > tips, or references in order to achieve this matter. Thanks again. > > > Best, > > Kurt > > _________________________________________________________________ > http://imagine-windowslive.com/hotmail/?locale=en-us&ocid=TXT_TAGHM_migration_HM_mini_pcmag_0507 > > From tim.bowden at WESTNET.COM.AU Wed Jul 4 22:50:31 2007 From: tim.bowden at WESTNET.COM.AU (Tim Bowden) Date: Thu, 5 Jul 2007 13:50:31 +0800 Subject: Tips for routing with tiger file In-Reply-To: Message-ID: On Thu, 2007-07-05 at 05:21 +0000, Kurt Kuo wrote: > Dear list, > Here may not be the right place to post this question. However, I understand > that mapserver users come from different fields. There must be some experts > who are able to give me some advices. Thanks in advance. > My question is how to use tiger file for routing purpose. As my > understanding, routing needs the length of every line between source and > target nodes. It seems that the tiger file does not have this information. I > really appreciate if someone can provide some advices, tips, or references > in order to achieve this matter. Thanks again. > Tiger data is not so good for routing; It does not contain any data about one way streets or intersection controls (i.e. no left turn etc). Some intersections shown on tiger data are not even an accurate reflection of what's on the ground; Things like freeway overpasses that don't physically intersect with the road being crossed appear as intersections in the tiger set. As far as I am aware, for accurate routing you will need to purchase a commercial data set. Remember that tiger was initiated for census work, and the data has limitations when you try and bend it to other uses. HTH, Tim Bowden From umberto.nicoletti at GMAIL.COM Thu Jul 5 01:25:28 2007 From: umberto.nicoletti at GMAIL.COM (Umberto Nicoletti) Date: Thu, 5 Jul 2007 10:25:28 +0200 Subject: Error: *** glibc detected *** double free or corruption (!prev) In-Reply-To: Message-ID: If you still have the 4.0.1 sources recompile them with enable debug and run shp2img under gdb. This at least will tell you where the double free is happening and then you might even be able to fix it. Umberto On 7/4/07, Dominik Schmid wrote: > Hi > > I have run into this persistent problem and I have already spent hours upon > hours without any result whatsoever. First of all my setup: > > - Centos 4.4 > - apache 2.0.52 > - php 5.1.6 > - postgresql 8.1.8 > - mapserver 4.0.1 (I know, I should update mapserver, but having to rebuild > all the legends in our system and possibly avoid some other side effects > would be a major headache and have so far kept me from doing this) > - gdal 1.4.0 > - postgis 1.2.1 > - geos 2.2.3 > - proj 4.5.0 > - glibc 2.3.4-2.25 > > The error in the httpd error_log reads as stated in the subject. > > I have added some multipolygon data that I had previously obtained by > converting it from a shape file using shp2pgsql. > > The odd part about this error is, that I use the same syntax in the map file > as for a working multipolygon layer that I had imported using older versions > of postgis etc. and the older data works just fine. > I have reimported said working data from the original shape file and > compared it to the existing data in the working table. the_geom and other > relevant stuff is identical. And still the newly imported data produces this > error. > > I have checked projection, db access privs and just about everything else > that crossed my mind as playing a part to no avail. > > So, is this problem a known issue? What else could I try/look into? Any advice? > > Thanks > Dominik > From jchurchill at AL.UMCES.EDU Thu Jul 5 05:20:03 2007 From: jchurchill at AL.UMCES.EDU (John B. Churchill) Date: Thu, 5 Jul 2007 08:20:03 -0400 Subject: trouble with attribute query Message-ID: I figured out the problem I was having. It has to do with having underscores "_" in the text field. If I replace my underscores with hyphens "-", my query works. This seems to be an odd character for Mapserver to weed out but that appears to be what is happening. +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Hi All, I'm having trouble executing an Attribute Query when I base the query (qitem) on the "filename" field in my shapefile. I can choose any other field and supply the appropriate qstring and everything works fine but when I use the filename field I get a "no matching records" found error. The text in the long string in the address bar of the browser IS complete and DOES match the value in the shapefile. Perhaps the text values in the shapefile field are too long for MapServer or special characters like the "." or "-" are causing a problem ? Can anyone confirm or deny either of my theories about this or point to any other possibilities ? The qstring is ... p016r032_09-09-1986_lt5_doc.img The qitem is "filename" and it is a text field. The entire query string in the address bar is ... http://localhost/cgi-bin/mapserv.exe?qlayer=landsat_4&myitem=landsat_4%2Cfilename&qstring=p016r032_09-09-1986_lt5_doc.img&map=C%3A%5Cms4w%5CApache%5Chtdocs%5Cimg_browser%5Cimg_browser.map&program=%2Fcgi-bin%2Fmapserv&mode=itemnquery&qitem=filename The error is ... msQueryByAttributes(): Search returned no results. No matching record(s) found. -- --------------------------------------------- John B. Churchill, M.S. http://alx.al.umces.edu/~jchurch/ GIS Specialist (301) 689-7109 University of Maryland Center for Environmental Science Appalachian Laboratory http://www.al.umces.edu/ Environmental Science Education http://alese.al.umces.edu/ 301 Braddock Road Frostburg, MD 21532 FAX - (301) 689-7200 From superbla3000 at GMX.NET Thu Jul 5 05:46:29 2007 From: superbla3000 at GMX.NET (joerg p) Date: Thu, 5 Jul 2007 14:46:29 +0200 Subject: label with mapscript Message-ID: Hello, I have this simple layer: LAYER NAME "citylabels" STATUS DEFAULT TRANSFORM FALSE TYPE ANNOTATION FEATURE POINTS 200 150 END TEXT 'Hello world. Mapserver rocks.' END CLASS LABEL TYPE BITMAP COLOR 0 0 0 END END END and would like to set the place and the text dynamically with php-mapscript. Does anybody have a simple codesnippet? best regrads Joerg From nicolas.fortin at EC.GC.CA Thu Jul 5 05:47:17 2007 From: nicolas.fortin at EC.GC.CA (Fortin,Nicolas [SteFoy]) Date: Thu, 5 Jul 2007 08:47:17 -0400 Subject: Is there a good WMS DLL to embed a WMS client in a VB application? In-Reply-To: A<504512.7681.qm@web33211.mail.mud.yahoo.com> Message-ID: Hi Brent, You can try : Carbontools from CarbonPortal : http://www.thecarbonportal.net/ MapWindow from MapWindowGIS : http://www.mapwindow.org/ I don't know if it's exactly what you want but it costs nothing to take a look. Nicolas -----Message d'origine----- De : UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] De la part de Brent Wood Envoy? : 4 juillet 2007 14:06 ? : MAPSERVER-USERS at LISTS.UMN.EDU Objet : [UMN_MAPSERVER-USERS] Is there a good WMS DLL to embed a WMS client in a VB application? Hi all, We have a Visual Basic application in which which users manually georeference by clicking on some control points & assigning lat's/long's to each. The program then plots GPS positions on this background, & has zoom/pan controls. It is used to capture seabed observations in real time while watching a live video stream from an underwater camera. It is now running on a LAN with a mapserver WMS, and we'd like to use this as the map background provider, instead of the local image. This background is generated from multibeam bathymetry data collected in an immediately prior run over the survey site. Can anyone offer some advice as to the best way to embed such a WMS client in VB? Ideally I guess a dll with zoom/pan & local point overlay capabilities. Thanks, Brent Wood From pgiannini at BYTEWISE.IT Thu Jul 5 07:16:16 2007 From: pgiannini at BYTEWISE.IT (Pietro Giannini) Date: Thu, 5 Jul 2007 16:16:16 +0200 Subject: label with mapscript In-Reply-To: <468CE825.9050301@gmx.net> Message-ID: Hi Joerg, try: $oMap = ms_newMapObj("your.map"); // obtain the layer object: $oLay = $oMap->getLayerByName("citylabels"); // obtain a shape object with the fields of a form (in this case they are named 'X' and 'Y'): $oShape = ms_shapeObjFromWkt("POINT(".$_REQUEST['X']." ".$_REQUEST['Y'].")"); // set the text property of the shape object: $oShape->set("text","ciao"); // add the shape to the layer: $oLay->addFeature($oShape); // draw the map: $oImage = $oMap->draw(); $mapImage_url = $oImage->saveWebImage(); I tried and it works well. You can create how many features you want. Hope it is useful... ciao .............................pg Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E > Hello, > > I have this simple layer: > LAYER > NAME "citylabels" > STATUS DEFAULT > TRANSFORM FALSE > TYPE ANNOTATION > FEATURE > POINTS > 200 150 > END > TEXT 'Hello world. Mapserver rocks.' > END > CLASS > LABEL > TYPE BITMAP > COLOR 0 0 0 > END > END > END > > and would like to set the place and the text dynamically with > php-mapscript. > Does anybody have a simple codesnippet? > > best regrads > Joerg > Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E From cplist at SECONDCREEK.ORG Thu Jul 5 07:38:56 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 5 Jul 2007 10:38:56 -0400 Subject: SOS disconnect Message-ID: Hi, all: I have been pouring over the SOS how to as well as scouring the listserv posts in order to take a working WFS and turn at least part of it into SOS. WFS returns a row nicely. http://sos-web.tamu.edu/sos-cgi/madis?service=wfs&request=getfeature&version =1.0.0&typename=ndbc_44029&Filter=s ensorsea_surface_temperature The SOS part of the .map is: LAYER NAME ndbc_44029_sea_surface_temperature PROJECTION "init=epsg:4269" END CONNECTIONTYPE POSTGIS CONNECTION "blah" DATA "the_geom from (select * from top_obs where platform_handle='ndbc_44029' and sensor = 'sea_surface_temperature') as foo USING UNIQUE row_id USING SRID=-1" TYPE POINT STATUS OFF METADATA "sos_procedure" "ndbc_44029" "sos_procedure_item" "m_value" "sos_offering_id" "ndbc_44029_sea_surface_temperature" "sos_observedproperty_id" "sea_surface_temperature" "sos_describesensor_url" "http://mesonet.tamu.edu/cpurvis/sos/ndbc_44029_sea_surface_temperature.xml" "sos_srs" "init=epsg:4269" END END It's not clear to me how to actually return data. Shouldn't I be able to see something if I hit this URL? http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation&ver sion=0.0.31&offering=ndbc_44029_sea_surface_temperature&format=application/c om-xml&observedProperty=sea_surface_temperature Well, I do see something, but I don't see the actual data. And it should be coming from a column called m_value. The describe sensor URL I essentially stole from a friend since his buoy is the same as the one I'm pulling from NDBC. Is there some controlling mechanism that says, hey, here is my data in MapServer land, and here is how it needs to spit out in SOS land? This same data is being serviced by another SOS flavor (not MapServer), and it returns a field like this: 2007-07-03T20:04:00Z,42.5,-70.5999984741211,0.0,289.950012207031 And that's what I want! I can see it in my WFS, but I want to SOS-ercise it. Thanks in advance, Charlton From fsimon at UNIVALI.BR Thu Jul 5 09:06:58 2007 From: fsimon at UNIVALI.BR (Fernando Simon) Date: Thu, 5 Jul 2007 13:06:58 -0300 Subject: Oracle Spatial reproject geometries In-Reply-To: Message-ID: Hi Silvia, Can you provide mor info about you layer (definition) and mapfile (projection that you used)? About the Oracle Spatial, the UMN Mapserver driver not execute any transformation for the data. Just read from database and plot in Mapserver. Are you using geodetic SRID to store your data in Oracle DB? Best regards. -------------------------------------------- Fernando Simon UMN Mapserver and Oracle Spatial developer -------------------------------------------- Citando Silvia Petcu : > Hi all, > I'm using an Oracle Spatial layer (polygon geometry) that is in > decimal degrees > (epsg: 4326), in a map that is in another projection. > The layer geometries usually are rectangles with 4-5 vertices, when > the map is > draw the geometry is re-projected but the lines are straight lines > with no > curvature and the image is really ugly (some big trapezoids ? is > the same > image as the one generated by Spatial Advisor in Oracle if I would > transform > the geometry using the epsg of map). > > On the other hand if I get the same layer and converted in a shape > file, than > loaded into my map file, the image is re-projected nicely with > curved lines. > > I cannot use shape files in my map, I?m stuck with oracle spatial > and I was > wandering if there is any way to get the same image for oracle > spatial as I get > for shape file. > > Thank you in advance. > ------------------------------------------------- Univali - Webmail - http://webmail.univali.br From pmoen at ND.GOV Thu Jul 5 09:52:16 2007 From: pmoen at ND.GOV (Paul Moen) Date: Thu, 5 Jul 2007 11:52:16 -0500 Subject: MAXIMGSIZE in mapfile In-Reply-To: <1183651618.468d172226fd5@webmail.univali.br> Message-ID: I have been looking for a way to set the max image size in the mapfile and I have found the text at the bottom in the archives, but see nothing in the documentation on whether or not this is possible. Does anyone have any information if the maximum image size can be changed by adding the MAXIMGSIZE to the mapfile rather than recompiling. I have tried to add it to my mapfile but I get an error, which could mean that I am putting it in the wrong part of the mapfile. Frank Warmerdam wrote: > > It is my humble opionion that only remote client requests (via URL) should > be checked against this, not image sizes read from .map files or those > originating from mapscript requests. If appropriate folks agree, I could > look into making this change. Ideally we would also have a MAXIMGSIZE > directive that could be included in .map files so this could be set > without recompiling mapserver - which is very hard for some folks to do. > I agree this would be a welcome change. BTW, if you create a new MAXIMGSIZE directive then don't forget that the test on MAXIMGSIZE should be applied to the WMS as well (mapwms.c). Also it should not be possible to change those maxsize values via the CGI interface. Perhaps a bug should be created for this to track everything including required updates to the docs, etc. Daniel -- ------------------------------------------------------------ Daniel Morissette morissette at dmsolutions.ca DM Solutions Group http://www.dmsolutions.ca/ ------------------------------------------------------------ From assefa at DMSOLUTIONS.CA Thu Jul 5 12:36:05 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Thu, 5 Jul 2007 15:36:05 -0400 Subject: SOS disconnect In-Reply-To: <02ce01c7bf12$37e4b340$650fa8c0@latitude> Message-ID: Charlton Purvis wrote: > Hi, all: > > I have been pouring over the SOS how to as well as scouring the listserv > posts in order to take a working WFS and turn at least part of it into SOS. > WFS returns a row nicely. > > http://sos-web.tamu.edu/sos-cgi/madis?service=wfs&request=getfeature&version > =1.0.0&typename=ndbc_44029&Filter=s > ensorsea_surface_temperature ualTo> > > The SOS part of the .map is: > > LAYER > NAME ndbc_44029_sea_surface_temperature > PROJECTION > "init=epsg:4269" > END > CONNECTIONTYPE POSTGIS > CONNECTION "blah" > DATA "the_geom from (select * from top_obs where > platform_handle='ndbc_44029' and sensor = 'sea_surface_temperature') as foo > USING UNIQUE row_id USING SRID=-1" > TYPE POINT > STATUS OFF > METADATA > "sos_procedure" "ndbc_44029" > "sos_procedure_item" "m_value" > "sos_offering_id" "ndbc_44029_sea_surface_temperature" > "sos_observedproperty_id" "sea_surface_temperature" > "sos_describesensor_url" > "http://mesonet.tamu.edu/cpurvis/sos/ndbc_44029_sea_surface_temperature.xml" > "sos_srs" "init=epsg:4269" > END > END > > It's not clear to me how to actually return data. Shouldn't I be able to > see something if I hit this URL? > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation&ver > sion=0.0.31&offering=ndbc_44029_sea_surface_temperature&format=application/c > om-xml&observedProperty=sea_surface_temperature Well, I do see something, > but I don't see the actual data. And it should be coming from a column > called m_value. > > The describe sensor URL I essentially stole from a friend since his buoy is > the same as the one I'm pulling from NDBC. > > Is there some controlling mechanism that says, hey, here is my data in > MapServer land, and here is how it needs to spit out in SOS land? This same > data is being serviced by another SOS flavor (not MapServer), and it returns > a field like this: > > > 2007-07-03T20:04:00Z,42.5,-70.5999984741211,0.0,289.950012207031 > > > And that's what I want! I can see it in my WFS, but I want to SOS-ercise > it. > You should be able to add output the attributes values (components in SOS) by adding a metadata on the layer for each attribute you want to display. Something like sos_nameofattribute_componenturl "some href" eg : "sos_COLOUR_componenturl" "http://www.ec.gc.ca/envirodat#COLOUR" The component url would be published when doing the GetCapabilities and the attribute value would be pulished for GetObservation Later, > Thanks in advance, > > Charlton > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From cplist at SECONDCREEK.ORG Thu Jul 5 14:22:35 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 5 Jul 2007 17:22:35 -0400 Subject: SOS disconnect In-Reply-To: <468D4825.6010600@dmsolutions.ca> Message-ID: Thanks, Assefa: > > Is there some controlling mechanism that says, hey, here is my data in > > MapServer land, and here is how it needs to spit out in SOS land? This > same > > data is being serviced by another SOS flavor (not MapServer), and it > returns > > a field like this: > > > > > > 2007-07-03T20:04:00Z,42.5,-70.5999984741211,0.0,289.950012207031 > > > > > > And that's what I want! I can see it in my WFS, but I want to SOS- > ercise > > it. > > > You should be able to add output the attributes values (components in > SOS) by adding a metadata on the layer for each attribute you want to > display. Something like sos_nameofattribute_componenturl "some href" > > eg : "sos_COLOUR_componenturl" "http://www.ec.gc.ca/envirodat#COLOUR" > > The component url would be published when doing the GetCapabilities > and the attribute value would be pulished for GetObservation That did the trick. "sos_m_value_alias" "wind_speed" "sos_m_value_componenturl" "http://marinemetadata.org/cf#wind_speed" "sos_m_lon_alias" "lon" "sos_m_lon_componenturl" "urn:ogc:phenomenon:longitude:wgs84" "sos_m_lat_alias" "lat" "sos_m_lat_componenturl" "urn:ogc:phenomenon:latitude:wgs84" "sos_m_z_alias" "z" "sos_m_z_componenturl" "urn:ogc:phenomenon:depth" "sos_timeitem" "m_date" "sos_offering_timeextent" "20070530T1800Z" And now I have lovely observations. I have two issues, if I haven't worn out my welcome . . . * I am pulling 10 different types of observations from this particular buoy. I have listed them all as the same offering and each LAYER has an identical GROUP -- so they all show up nicely under ndbc_44029. The problem is, when I have more than 4 or so SOS LAYERS, whether or not they are part of the same group, I all of a sudden get an empty .xml. And Apache logs show nothing. I know for a fact that there is not a problem w/ the LAYER definition because it's just a matter of cutting and pasting to change from something like a wind_speed column to wind_speed_of_gust. Is there some kind of SOS limit in a *.h somewhere? * Secondly, is there a trick to the TIME element? Here is a working request: http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation&ver sion=0.0.31&offering=ndbc_44029&format=application/com-xml&observedProperty= http://marinemetadata.org/cf%23sea_surface_temperature And it does say it recognizes a timePeriod, but when I tack on a time parameter, it bombs w/ 'msSOSGetObservation(): SOS server error. Invalid time value given for the eventTime parameter'. I dug around in the code, and it still doesn't shed any light on where the problem is occurring. The getcaps behind all of this is here: http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=getcapabilities&ve rsion=0.0.31. I do plan on writing up how I have gotten this far, so it may help someone in the long run, too. Many, many thanks. Charlton From Steve.Lime at DNR.STATE.MN.US Thu Jul 5 14:48:57 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Thu, 5 Jul 2007 16:48:57 -0500 Subject: MAXIMGSIZE in mapfile In-Reply-To: Message-ID: There is a MAXSIZE parameter in the map object already that serves this purpose if I am not mistaken. It sets the maximum number of pixels in either image dimension and defaults to 1024. Both the CGI interface and WMS validate against it. It cannot be changed via URL. It's in the mapObj reference file... Steve >>> On 7/5/2007 at 11:52 AM, in message , Paul Moen wrote: > I have been looking for a way to set the max image size in the mapfile and I > have found the text at the bottom in the archives, but see nothing in the > documentation on whether or not this is possible. Does anyone have any > information if the maximum image size can be changed by adding the > MAXIMGSIZE to the mapfile rather than recompiling. I have tried to add it > to my mapfile but I get an error, which could mean that I am putting it in > the wrong part of the mapfile. > > Frank Warmerdam wrote: >> >> It is my humble opionion that only remote client requests (via URL) should >> be checked against this, not image sizes read from .map files or those >> originating from mapscript requests. If appropriate folks agree, I could >> look into making this change. Ideally we would also have a MAXIMGSIZE >> directive that could be included in .map files so this could be set >> without recompiling mapserver - which is very hard for some folks to do. >> > > I agree this would be a welcome change. BTW, if you create a new > MAXIMGSIZE directive then don't forget that the test on MAXIMGSIZE > should be applied to the WMS as well (mapwms.c). Also it should not be > possible to change those maxsize values via the CGI interface. Perhaps > a bug should be created for this to track everything including required > updates to the docs, etc. > > Daniel From superbla3000 at GMX.NET Thu Jul 5 14:52:37 2007 From: superbla3000 at GMX.NET (joerg pfeiffer) Date: Thu, 5 Jul 2007 23:52:37 +0200 Subject: label with mapscript In-Reply-To: <29664.62.77.56.18.1183644976.squirrel@127.0.0.1> Message-ID: Hey Pietro, thanks for your help. It seems my mapscript version is not up to date, so it doesn't know the ms_shapeObjFromWkt function. But I got it working with the following code. Only problem: It only prints one label, not as many labels, as I have in the array: $LabelLayerObj = $this->map->getLayerByName($layername); $labelpointObj = ms_newPointObj(); $labelLineObj = ms_newLineObj(); for ($i = 0; $i < count($pointlist); $i++){ $labelpointObj->setXY(100+($i*2),100+($i*2)); $labelLineObj ->add($labelpointObj); $labelshp = ms_newShapeObj(MS_SHAPE_POINT); $labelshp->set("text", $pointlist[$i] ); $labelshp->add($labelLineObj); } $LabelLayerObj->addFeature($labelshp); So if I know how to print more than one label, I would be very happy! :-) cheers Joerg pgiannini at bytewise.it schrieb: > Hi Joerg, > > try: > > $oMap = ms_newMapObj("your.map"); > // obtain the layer object: > $oLay = $oMap->getLayerByName("citylabels"); > // obtain a shape object with the fields of a form (in this case they are > named 'X' and 'Y'): > $oShape = ms_shapeObjFromWkt("POINT(".$_REQUEST['X']." > ".$_REQUEST['Y'].")"); > // set the text property of the shape object: > $oShape->set("text","ciao"); > // add the shape to the layer: > $oLay->addFeature($oShape); > // draw the map: > $oImage = $oMap->draw(); > $mapImage_url = $oImage->saveWebImage(); > > I tried and it works well. > You can create how many features you want. > Hope it is useful... > > ciao > .............................pg > > > > > Pietro Giannini > Bytewise srl - Area GIS > 41?50'38.58"N 12?29'13.39"E > > > > >> Hello, >> >> I have this simple layer: >> LAYER >> NAME "citylabels" >> STATUS DEFAULT >> TRANSFORM FALSE >> TYPE ANNOTATION >> FEATURE >> POINTS >> 200 150 >> END >> TEXT 'Hello world. Mapserver rocks.' >> END >> CLASS >> LABEL >> TYPE BITMAP >> COLOR 0 0 0 >> END >> END >> END >> >> and would like to set the place and the text dynamically with >> php-mapscript. >> Does anybody have a simple codesnippet? >> >> best regrads >> Joerg >> > > > Pietro Giannini > Bytewise srl - Area GIS > 41?50'38.58"N 12?29'13.39"E > > From Steve.Lime at DNR.STATE.MN.US Thu Jul 5 15:06:46 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Thu, 5 Jul 2007 17:06:46 -0500 Subject: Architectural Question In-Reply-To: <200707040105.l6415WWj008860@sprint2.tenix.com> Message-ID: Hi Nelson: That's certainly the trend these days, change only what needs changing. For that to work you need smarter software on the client. The basic issue is that MapServer enforces square pixels and as a result it may change the requested extent to match the requested image size. You have no way to get both the new extent and the image back in the same request. Actually you do using a template to return the computed extent and the created image, e.g.: img:[img] extent:[mapext] but it's nicer to use MapServer as just an image engine. Solutions like MapBender, OpenLayers, MapBuilder, Ka-map and others manage extents on the client and send the appropriate requests for images to MapServer, a WMS server or whatever. I use dbox here and it manages the coordinates in javascript and sends requests to MapServer (mode=map) so that it doesn't have to adjust extents and it becomes easier to just modify the map itself. Here are some examples: - http://www.dnr.state.mn.us/waters/csg/index.html - http://maps.dnr.state.mn.us/waters/csg/station_mapper.html?mapxy=481573.570471947+4900561.10653818&scale=100000&id=39101001&layers=roads+bdry_munipy3+wsh_hunitpy3+sites+strm_baseln3+shdr_clrim3+lakes - http://www.dnr.state.mn.us/hunting/moose/zones2007/zone_report.html?map=/usr/local/mapserver/apps/faw/moose/moose.map&mode=itemquery&qlayer=zone_query&qstring=zone_id%3d25 - http://maps.dnr.state.mn.us/tools/dbox-dev/example/example_fullscreen.html (flaky in IE6) In all of these the maps update, not the page. Anyway, lot's of choices! Steve >>> On 7/3/2007 at 8:05 PM, in message <200707040105.l6415WWj008860 at sprint2.tenix.com>, LITTLE Nelson wrote: > Hello Mapserver users, > > > > I have developed a web based mapserver application using Java Mapscript > & Servlets and it works well and looks great. I currently use the Rosa > Applet as the map window display. My application is very similar in > behaviour to the Mapserver Atlas application (AKA gmap) (online: > http://www.mapsherpa.com/gmap/gmap75.phtml). > > > > Whenever the user hits 'Redraw Map' or clicks on a tool button, it > causes the whole pages to be refreshed. My question is how could this be > changed so that only the map window is refreshed, not the whole page? I > know this is an architectural type question which is not really related > to Mapserver, but if anyone would know the answer it would be the people > on this list. > > > > Thanks, > > Nelson > > > Disclaimer : > The contents of this e-mail including any attachments are intended only > for the person or entity to which this e-mail is addressed. If you are not, > or believe you may not be, the intended recipient, please advise the sender > immediately by return e-mail, delete this e-mail and destroy any copies. > Tenix does not warrant nor guarantee that this email communication is free > from errors, virus, interception or interference. From Steve.Lime at DNR.STATE.MN.US Thu Jul 5 15:13:38 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Thu, 5 Jul 2007 17:13:38 -0500 Subject: trouble with attribute query In-Reply-To: <468CE1F3.1000909@al.umces.edu> Message-ID: John: Would you be so kind as to file a bug on this one. That shouldn't be the case.. http://trac.osgeo.org/mapserver Thanks! Steve >>> On 7/5/2007 at 7:20 AM, in message <468CE1F3.1000909 at al.umces.edu>, "John B. Churchill" wrote: > I figured out the problem I was having. It has to do with having > underscores "_" in the text field. If I replace my underscores with > hyphens "-", my query works. This seems to be an odd character for > Mapserver to weed out but that appears to be what is happening. > > +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > Hi All, > > I'm having trouble executing an Attribute Query when I base the > query (qitem) on the "filename" field in my shapefile. I can choose any > other field and supply the appropriate qstring and everything works fine > but when I use the filename field I get a "no matching records" found error. > > The text in the long string in the address bar of the browser IS > complete and DOES match the value in the shapefile. Perhaps the text > values in the shapefile field are too long for MapServer or special > characters like the "." or "-" are causing a problem ? Can anyone > confirm or deny either of my theories about this or point to any other > possibilities ? > > The qstring is ... > p016r032_09-09-1986_lt5_doc.img > > The qitem is "filename" and it is a text field. > > The entire query string in the address bar is ... > http://localhost/cgi-bin/mapserv.exe?qlayer=landsat_4&myitem=landsat_4%2Cfilen > ame&qstring=p016r032_09-09-1986_lt5_doc.img&map=C%3A%5Cms4w%5CApache%5Chtdocs%5Ci > mg_browser%5Cimg_browser.map&program=%2Fcgi-bin%2Fmapserv&mode=itemnquery&qitem=f > ilename > > The error is ... > msQueryByAttributes(): Search returned no results. No matching record(s) > found. From umn-ms at HYDROTEC.DE Thu Jul 5 23:25:54 2007 From: umn-ms at HYDROTEC.DE (Benedikt Rothe) Date: Fri, 6 Jul 2007 08:25:54 +0200 Subject: Antwort: [UMN_MAPSERVER-USERS] Oracle Spatial reproject geometries In-Reply-To: Message-ID: Hi > On the other hand if I get the same layer and converted in a shape file, than > loaded into my map file, the image is re-projected nicely with curved lines. No hint from me. Just a counterquestion to learn: Which software do you use to convert Oracle-Spatial to shapefile? Benedikt UMN MapServer Users List schrieb am 04.07.2007 04:40:41: > Hi all, > I'm using an Oracle Spatial layer (polygon geometry) that is in > decimal degrees > (epsg: 4326), in a map that is in another projection. > The layer geometries usually are rectangles with 4-5 vertices, when > the map is > draw the geometry is re-projected but the lines are straight lines with no > curvature and the image is really ugly (some big trapezoids ? is the same > image as the one generated by Spatial Advisor in Oracle if I would transform > the geometry using the epsg of map). > > On the other hand if I get the same layer and converted in a shape file, than > loaded into my map file, the image is re-projected nicely with curved lines. > > I cannot use shape files in my map, I?m stuck with oracle spatial and I was > wandering if there is any way to get the same image for oracle > spatial as I get > for shape file. > > Thank you in advance. -------------- next part -------------- An HTML attachment was scrubbed... URL: From pgiannini at BYTEWISE.IT Fri Jul 6 00:53:52 2007 From: pgiannini at BYTEWISE.IT (Pietro Giannini) Date: Fri, 6 Jul 2007 09:53:52 +0200 Subject: [Fwd: Re: [UMN_MAPSERVER-USERS] label with mapscript] Message-ID: Ciao Joerg, Yes I'm using php_mapscript 4.10. ms_shapeObjFromWkt is more comfortable than "create a point, create a line and add the point, create a shape and add the line" I think in your code you have only a label because you add only a shape to the layer. An annotation layer in your map file is like a points layer, then add how many shapes than labels. In your code you must only move the $layer->addFeature function into the for() block: for ($i = 0; $i < count($pointlist); $i++){ $labelpointObj->setXY(100+($i*2),100+($i*2)); $labelLineObj ->add($labelpointObj); $labelshp = ms_newShapeObj(MS_SHAPE_POINT); $labelshp->set("text", $pointlist[$i] ); $labelshp->add($labelLineObj); $LabelLayerObj->addFeature($labelshp); } I hope it's working for you ciao ..............................pg -- Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E On Gio, Luglio 5, 2007 23:52, joerg pfeiffer wrote: > Hey Pietro, > > thanks for your help. It seems my mapscript version is not up to date, > so it doesn't know the ms_shapeObjFromWkt function. But I got it working > with the following code. Only problem: It only prints one label, not as > many labels, as I have in the array: > > $LabelLayerObj = $this->map->getLayerByName($layername); > $labelpointObj = ms_newPointObj(); > $labelLineObj = ms_newLineObj(); > > for ($i = 0; $i < count($pointlist); $i++){ > > $labelpointObj->setXY(100+($i*2),100+($i*2)); > $labelLineObj ->add($labelpointObj); > $labelshp = ms_newShapeObj(MS_SHAPE_POINT); > $labelshp->set("text", $pointlist[$i] ); > $labelshp->add($labelLineObj); > } > > $LabelLayerObj->addFeature($labelshp); > > So if I know how to print more than one label, I would be very happy! :-) > > cheers > Joerg > > > > > > > pgiannini at bytewise.it schrieb: >> Hi Joerg, >> >> try: >> >> $oMap = ms_newMapObj("your.map"); >> // obtain the layer object: >> $oLay = $oMap->getLayerByName("citylabels"); >> // obtain a shape object with the fields of a form (in this case they >> are >> named 'X' and 'Y'): >> $oShape = ms_shapeObjFromWkt("POINT(".$_REQUEST['X']." >> ".$_REQUEST['Y'].")"); >> // set the text property of the shape object: >> $oShape->set("text","ciao"); >> // add the shape to the layer: >> $oLay->addFeature($oShape); >> // draw the map: >> $oImage = $oMap->draw(); >> $mapImage_url = $oImage->saveWebImage(); >> >> I tried and it works well. >> You can create how many features you want. >> Hope it is useful... >> >> ciao >> .............................pg >> >> >> >> >> Pietro Giannini >> Bytewise srl - Area GIS >> 41?50'38.58"N 12?29'13.39"E >> >> >> >> >>> Hello, >>> >>> I have this simple layer: >>> LAYER >>> NAME "citylabels" >>> STATUS DEFAULT >>> TRANSFORM FALSE >>> TYPE ANNOTATION >>> FEATURE >>> POINTS >>> 200 150 >>> END >>> TEXT 'Hello world. Mapserver rocks.' >>> END >>> CLASS >>> LABEL >>> TYPE BITMAP >>> COLOR 0 0 0 >>> END >>> END >>> END >>> >>> and would like to set the place and the text dynamically with >>> php-mapscript. >>> Does anybody have a simple codesnippet? >>> >>> best regrads >>> Joerg >>> >> >> >> Pietro Giannini >> Bytewise srl - Area GIS >> 41?50'38.58"N 12?29'13.39"E >> >> > From cplist at SECONDCREEK.ORG Fri Jul 6 04:08:41 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Fri, 6 Jul 2007 07:08:41 -0400 Subject: SOS disconnect In-Reply-To: <030e01c7bf4a$9bb36960$650fa8c0@latitude> Message-ID: > I have two issues, if I haven't worn out my welcome . . . > > * I am pulling 10 different types of observations from this particular > buoy. > I have listed them all as the same offering and each LAYER has an > identical > GROUP -- so they all show up nicely under ndbc_44029. The problem is, > when > I have more than 4 or so SOS LAYERS, whether or not they are part of the > same group, I all of a sudden get an empty .xml. And Apache logs show > nothing. I know for a fact that there is not a problem w/ the LAYER > definition because it's just a matter of cutting and pasting to change > from > something like a wind_speed column to wind_speed_of_gust. Is there some > kind of SOS limit in a *.h somewhere? The GetCapabilities seems to be the only thing that fails. I can do a GetObservations just fine, but the GetCap returns an empty .xml. From Tom.Kralidis at EC.GC.CA Fri Jul 6 05:03:44 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Fri, 6 Jul 2007 08:03:44 -0400 Subject: SOS disconnect In-Reply-To: A<030e01c7bf4a$9bb36960$650fa8c0@latitude> Message-ID: > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Charlton Purvis > Sent: 05 July, 2007 5:23 PM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] SOS disconnect > > Thanks, Assefa: > > > > Is there some controlling mechanism that says, hey, here > is my data > > > in MapServer land, and here is how it needs to spit out > in SOS land? > > > This > > same > > > data is being serviced by another SOS flavor (not > MapServer), and it > > returns > > > a field like this: > > > > > > > > > 2007-07-03T20:04:00Z,42.5,-70.5999984741211,0.0,289.950012207031 > > > > > > > > > And that's what I want! I can see it in my WFS, but I > want to SOS- > > ercise > > > it. > > > > > You should be able to add output the attributes values > (components > > in > > SOS) by adding a metadata on the layer for each attribute > you want to > > display. Something like sos_nameofattribute_componenturl "some href" > > > > eg : "sos_COLOUR_componenturl" > "http://www.ec.gc.ca/envirodat#COLOUR" > > > > The component url would be published when doing the > GetCapabilities > > and the attribute value would be pulished for GetObservation > > That did the trick. > > "sos_m_value_alias" "wind_speed" > "sos_m_value_componenturl" > "http://marinemetadata.org/cf#wind_speed" > "sos_m_lon_alias" "lon" > "sos_m_lon_componenturl" "urn:ogc:phenomenon:longitude:wgs84" > "sos_m_lat_alias" "lat" > "sos_m_lat_componenturl" "urn:ogc:phenomenon:latitude:wgs84" > "sos_m_z_alias" "z" > "sos_m_z_componenturl" "urn:ogc:phenomenon:depth" > "sos_timeitem" "m_date" > "sos_offering_timeextent" "20070530T1800Z" > > And now I have lovely observations. > > I have two issues, if I haven't worn out my welcome . . . > > * I am pulling 10 different types of observations from this > particular buoy. > I have listed them all as the same offering and each LAYER > has an identical GROUP -- so they all show up nicely under > ndbc_44029. The problem is, when I have more than 4 or so > SOS LAYERS, whether or not they are part of the same group, I > all of a sudden get an empty .xml. And Apache logs show > nothing. I know for a fact that there is not a problem w/ > the LAYER definition because it's just a matter of cutting > and pasting to change from something like a wind_speed column > to wind_speed_of_gust. Is there some kind of SOS limit in a > *.h somewhere? > > * Secondly, is there a trick to the TIME element? Here is a working > request: > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetO bservation&ver > sion=0.0.31&offering=ndbc_44029&format=application/com-xml&obs ervedProperty= > http://marinemetadata.org/cf%23sea_surface_temperature > N.B. are you intentionally setting observedproperty to a URL in the mapfile? Note that it can also be a plain old string, etc. :) > And it does say it recognizes a timePeriod, but when I tack > on a time parameter, it bombs w/ 'msSOSGetObservation(): SOS > server error. Invalid time value given for the eventTime > parameter'. I dug around in the code, and it still doesn't > shed any light on where the problem is occurring. > When I try: http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation &version=0.0.31&offering=ndbc_44029&format=application/com-xml&observedP roperty=http://marinemetadata.org/cf%23sea_surface_temperature&eventTime =2007-062007-07 It seems to work; mind you there looks to be only one record. How are you passing the time query? > The getcaps behind all of this is here: > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=getc apabilities&ve > rsion=0.0.31. > > I do plan on writing up how I have gotten this far, so it may > help someone in the long run, too. > > Many, many thanks. > > Charlton > From Tom.Kralidis at EC.GC.CA Fri Jul 6 05:07:58 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Fri, 6 Jul 2007 08:07:58 -0400 Subject: SOS disconnect In-Reply-To: A<035501c7bfbe$039004d0$650fa8c0@latitude> Message-ID: > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Charlton Purvis > Sent: 06 July, 2007 7:09 AM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] SOS disconnect > > > I have two issues, if I haven't worn out my welcome . . . > > > > * I am pulling 10 different types of observations from this > particular > > buoy. > > I have listed them all as the same offering and each LAYER has an > > identical GROUP -- so they all show up nicely under > ndbc_44029. The > > problem is, when I have more than 4 or so SOS LAYERS, > whether or not > > they are part of the same group, I all of a sudden get an > empty .xml. > > And Apache logs show nothing. I know for a fact that there > is not a > > problem w/ the LAYER definition because it's just a matter > of cutting > > and pasting to change from something like a wind_speed column to > > wind_speed_of_gust. Is there some kind of SOS limit in a *.h > > somewhere? > > The GetCapabilities seems to be the only thing that fails. I > can do a GetObservations just fine, but the GetCap returns an > empty .xml. > If I try: http://sos-web.tamu.edu/sos-cgi/madis?service=SOS&request=GetCapabilitie s&version=0.0.31 This works for me. From cplist at SECONDCREEK.ORG Fri Jul 6 05:20:29 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Fri, 6 Jul 2007 08:20:29 -0400 Subject: SOS disconnect In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F1F@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Hi, Tom and Assefa: > N.B. are you intentionally setting observedproperty to a URL in the > mapfile? Note that it can also be a plain old string, etc. :) Yes, that's intentional. It's not the most readable thing, I agree, but that's the way this particular booger needs to be done. > When I try: > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation > &version=0.0.31&offering=ndbc_44029&format=application/com-xml&observedP > roperty=http://marinemetadata.org/cf%23sea_surface_temperature&eventTime > =2007-06 osition>2007-07 > > It seems to work; mind you there looks to be only one record. How are > you passing the time query? Oh. Interesting. One record is correct. This particular table only holds the latest obs for a given sensor / platform combo. I was originally trying to pass &time=yyyymmddThhmiZ and that caused it to be unhappy. But Example2 from http://mapserver.gis.umn.edu/docs/howto/sos_server passes a time param, so maybe I'm doing something wrong, or should I stick w/ the syntax you described above? Assefa, MapServer version 4.10.2. > > The getcaps behind all of this is here: > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=getc > apabilities&ve > > rsion=0.0.31. Tom, you're right, the GetCaps works fine, but that's because I took out a layer that seemed to set the GetCaps over the edge. I'll put together a barebones .map and pass around that will hopefully be able to reproduce the problem. Many thanks, fellas! Charlton From Tom.Kralidis at EC.GC.CA Fri Jul 6 05:31:56 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Fri, 6 Jul 2007 08:31:56 -0400 Subject: SOS disconnect In-Reply-To: <035c01c7bfc8$0b608db0$650fa8c0@latitude> Message-ID: > -----Original Message----- > From: Charlton Purvis [mailto:cplist at secondcreek.org] > Sent: 06 July, 2007 8:20 AM > To: Kralidis,Tom [Burlington]; MAPSERVER-USERS at LISTS.UMN.EDU; > 'Yewondwossen Assefa' > Subject: RE: [UMN_MAPSERVER-USERS] SOS disconnect > > Hi, Tom and Assefa: > > > N.B. are you intentionally setting observedproperty to a URL in the > > mapfile? Note that it can also be a plain old string, etc. :) > > Yes, that's intentional. It's not the most readable thing, I > agree, but that's the way this particular booger needs to be done. > > > When I try: > > > > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservati > > on > > > &version=0.0.31&offering=ndbc_44029&format=application/com-xml&observe > > dP > > > roperty=http://marinemetadata.org/cf%23sea_surface_temperature&eventTi > > me > > > =2007-06 > dP > > osition>2007-07 > > > > It seems to work; mind you there looks to be only one > record. How are > > you passing the time query? > > Oh. Interesting. One record is correct. This particular > table only holds the latest obs for a given sensor / platform > combo. I was originally trying to pass &time=yyyymmddThhmiZ > and that caused it to be unhappy. But Example2 from > http://mapserver.gis.umn.edu/docs/howto/sos_server passes a > time param, so maybe I'm doing something wrong, or should I > stick w/ the syntax you described above? > Thanks for pointing this out, Charlton; eventtime is the supported parameter for passing temporal. I've changed this on the howto page. > Assefa, MapServer version 4.10.2. > > > > The getcaps behind all of this is here: > > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=getc > > apabilities&ve > > > rsion=0.0.31. > > Tom, you're right, the GetCaps works fine, but that's because > I took out a layer that seemed to set the GetCaps over the > edge. I'll put together a barebones .map and pass around > that will hopefully be able to reproduce the problem. > This would be great! > Many thanks, fellas! > > Charlton > > > From topografia.oliva at CV.GVA.ES Fri Jul 6 05:34:03 2007 From: topografia.oliva at CV.GVA.ES (Lara Perez) Date: Fri, 6 Jul 2007 07:34:03 -0500 Subject: GIF don't display Message-ID: Hello, everybody. I have a little problem I had my mapserver 4.4. running under apache 1.3 and i'd actualizated to apache 2.2 and mapser 4.10. I'd made the necesaries changes, but when the html page opens, the images (*.map) are not shown. If I make a pan it works, but I don't see the images. I can navigate fine, but I can't see the maps. I?ve attached the files. Any idea? Thanks in advance -------------- next part -------------- A non-text attachment was scrubbed... Name: Planeamiento.map Type: application/octet-stream Size: 5488 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From cplist at SECONDCREEK.ORG Fri Jul 6 05:43:59 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Fri, 6 Jul 2007 08:43:59 -0400 Subject: SOS disconnect In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F22@ecburexch1.ontario.int.ec.gc.ca> Message-ID: > > edge. I'll put together a barebones .map and pass around > > that will hopefully be able to reproduce the problem. How's this for interesting . . . The problem persists, but for the purposes of this little .tar.Z I dumped the table to a shapefile. And here is what happens: Doing a GetCapabilities on everything like normal (shapefile where it should be), http://your.box.here/cgi-bin/mapserv?map=/I/love/mapserver/m.map&request=get capabilities&service=sos returns an empty XML just like I promised. Now do one of two things: * remove ANY layer, and you should get back a nice XML doc (this is in keeping w/ what I reported earlier, i.e. this # of layers has sent mapserver over the edge). * or leave all the layers and simply remove the shapefile goodies. The getcaps works fine! Strange. I was surprised that it hit the data source at all for a getcaps. Oddly, something gets a little foobared when doing a getobs against this test dataset, and I'm not sure why. But I'm not really concerned, since it was able to return nice getobs from my real db no matter how many layers I had and whether or not the getcaps failed. Thanks for the help, guys. Charlton -------------- next part -------------- A non-text attachment was scrubbed... Name: sos_test.tar.Z Type: application/x-compress Size: 1687 bytes Desc: not available URL: From cplist at SECONDCREEK.ORG Fri Jul 6 06:02:48 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Fri, 6 Jul 2007 09:02:48 -0400 Subject: SOS disconnect In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F1F@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Tom, I'm becoming a pest, but I'm thiiiiiiiiis close to wrapping this up. > When I try: > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation > &version=0.0.31&offering=ndbc_44029&format=application/com-xml&observedP > roperty=http://marinemetadata.org/cf%23sea_surface_temperature&eventTime > =2007-06 osition>2007-07 What is odd is that if I throw in a timePeriod that I *know* shouldn't return a hit, it is returning something. e.g. http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation&ver sion=0.0.31&offering=ndbc_44029&format=application/com-xml&observedProperty= http://marinemetadata.org/cf%23sea_surface_temperature&eventTime=1990-01-011990- 02-01 My data is from 2007. From rodrigomlg at GMAIL.COM Fri Jul 6 06:19:25 2007 From: rodrigomlg at GMAIL.COM (=?ISO-8859-1?Q?Rodrigo_Mart=EDn_L=D3PEZ_GREGORIO?=) Date: Fri, 6 Jul 2007 14:19:25 +0100 Subject: GIF don't display In-Reply-To: Message-ID: Hi Lara. The first thing I noticed is that the action of your form is wrong. Your form action looks like: action="http://cgi-bin/mapserv.exe" and it would look like: action="/cgi-bin/mapserv.exe" Also in the "map" and "imgext" parameters the values seems to be wrong (but I think this will seem ok when you access the php file through Apache): If you still have problems ask me again. (Of course in spanish would be much easier ;) ) Rodrigo. On 7/6/07, Lara Perez wrote: > > Hello, everybody. > > I have a little problem > I had my mapserver 4.4. running under apache 1.3 and i'd actualizated to > apache 2.2 and mapser 4.10. I'd made the necesaries changes, but when the > html page opens, the images (*.map) are not shown. If I make a pan it > works, > but I don't see the images. I can navigate fine, but I can't see the > maps. > I?ve attached the files. Any idea? > Thanks in advance > > ------------------------------ > ------------------------------ > Acercar > Centrar > Alejar > > *Escala: *[scale] Nucleos Urbanos: Elige una zona Kiko Sectores 6 y 19 > Terranova Poblado Mar?timo Canyades Aig?es Blanques Rabdells Oliva Nova y > San Fernando Jovades Sectores 3 y 16 Casco Urbano Sector 15 Sector 2 > ------------------------------ > Modo: Navegaci?n Consulta > ------------------------------ > > Volver > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Tom.Kralidis at EC.GC.CA Fri Jul 6 08:00:53 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Fri, 6 Jul 2007 11:00:53 -0400 Subject: Mapscript and SOS In-Reply-To: A<2DC5CCA14756424BBBEE8B4B2E4A682F277F00@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Trying this with svn trunk gives me blanks for all responses for SOS. Yet WMS and WFS seem to work (for GetCapabilities). Using svn trunk, When testing a simple PHP Mapscript WxS: $v) { $request->setParameter($k, $v); } ms_ioinstallstdouttobuffer(); $oMap = ms_newMapobj("/path/to/config.map"); $oMap->owsdispatch($request); $contenttype = ms_iostripstdoutbuffercontenttype(); $buffer = ms_iogetstdoutbufferstring(); header('Content-type: text/xml'); echo $buffer; ms_ioresethandlers(); ?> - issuing a WMS 1.1.1 GetCapabilities works as expected - issuing a WFS 1.0.0 GetCapabilities works as expected - issuing a SOS 0.1.2b GetCapabilities returns a blank Assefa: is there anything else in mapogcsos.c we have to do to make it mapscript WxS friendly? ..Tom > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of > Kralidis,Tom [Burlington] > Sent: 03 July, 2007 11:51 AM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS > > Weird. What happens (in terms of the response) when you do a > GetCapabilities via mapscript and regular SOS request? I > wonder if the metadata is actually being set. > > ..Tom > > > > -----Original Message----- > > From: UMN MapServer Users List > > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of "Peter L?we" > > Sent: 03 July, 2007 11:46 AM > > To: MAPSERVER-USERS at LISTS.UMN.EDU > > Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS > > > > Hello Tom: > > > > After calling up > > http://localhost/swe/php_sos0.php?Request=GetObservation&servi > > ce=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik0 > > 01&version=0.0.31 > > > > the apache access_log holds: > > > > ::1 - - [03/Jul/2007:17:36:37 +0200] "GET > > /swe/php_sos0.php?Request=GetObservation&service=SOS&offering= > > oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.3 > > 1 HTTP/1.1" 200 790 > > > > and this piece of XML is returned: > > > > > > xmlns:gml="http://www.opengis.net/gml" > > xmlns:ows="http://www.opengis.net/ows" > > xmlns:swe="http://www.opengis.net/swe" > > xmlns:xlink="http://www.w3.org/1999/xlink" > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > > xmlns:sos="http://www.opengis.net/sos" > > xmlns:om="http://www.opengis.net/om" gml:id="oid_1" > > xsi:schemaLocation="http://www.opengeospatial.net/om > > http://schemas.opengeospatial.net/om.xsd"> > > > > > > > xmlns:gml="http://www.opengis.net/gml">1982 > > > xmlns:gml="http://www.opengis.net/gml">2007 > > > > > > > > > > > > > > ..Peter > > > > > > >Can you check your server logs see, exactly, what mapscript > > sends as the >GetObservation request? > > > > > >..Tom > > -- > > Dr. Peter L?we > > > > > > > > > > > > > > Psssst! Schon vom neuen GMX MultiMessenger geh?rt? > > Der kanns mit allen: http://www.gmx.net/de/go/multimessenger > > > From piero.cavalieri at GMAIL.COM Fri Jul 6 10:19:31 2007 From: piero.cavalieri at GMAIL.COM (Piero Cavalieri) Date: Fri, 6 Jul 2007 19:19:31 +0200 Subject: Architectural Question In-Reply-To: <200707050154.l651sns8007582@sprint1.tenix.com> Message-ID: I developed in .NET/javascript, so u can't use code (and my boss doesn't let me to give, also if it few lines of code...). However idea is that u could collect relevant values from user interface (the web page) which u need to build a new map (for example the list of layers, the current map extent which is returned by mapserver itself in the [mapextent] template variable, ecc...) and build a correct request for mapserver. The list of layers and other key elements for the request, u take via JavaScript with (for example): var layersString = getLayers(); //this call a function which cicle on the layers list and takes only those the user want. imgext = document.getElementById("imgext").value; imgbox = document.getElementById("imgbox").value; //setted by dbox/jbox imgxy = document.getElementById("imgxy").value; //setted by dbox/jbox Than u build request for Mapserver, for example: http://localhost/Scripts/mapserv.exe?map=D:/Web/Heidi_Service/HGis/trentino.map&layer=DTM&layer=ECW&imgext=1600000.1 5000123.4 1620003.7 5010567.9&imgbox=143 200 200 255&imgxy=143 200&mode=browse This request u need to pass mapserver cgi without doing a POST, otherwise u have a page reload. For doing this, I have used an Ajax library which, without doing a POST, let me to call a server side (.NET) function from a client side function (JavaScript). So then I do (I'm still in JavaScript) a call like: AjaxMethods.getMap(queryString, retrieveMapImage_callback); This JavaScript function, "invoke" a server side function (with the same signature, but without the retrieveMapImage_callback parameter). Details about how the Javascript function invoke the server side function are managed by the ajax library I used (and if u use other libraries, things will be different), important thing is that there is no page reload in this process. When the result of the server side function, come back to JavaScript, the retrieveMapImage_callback function is invoked. What I do in this function ? It update map elements: document.getElementById("mapwidth").value = res.value.mapwidth; document.getElementById("mapheight").value = res.value.mapheight; document.getElementById("imgxy").value = res.value.imgxy; document.getElementById("imgext").value = res.value.imgext; document.getElementById("legend").innerHTML = res.value.legend; document.getElementById("scale").value = res.value.scale; imgMap.src = res.value.mapImgUrl; imgRef.src = res.value.referenceMap; imgScalebar.src = res.value.scalebar; But how can I have in server side, new values based on the request above ? I use an System.Net.HttpWebRequest (this one is .NET, Java should have a similar method): HttpWebRequest webRequest = (HttpWebRequest) WebRequest.Create(queryString); And what's the response? In the .map file I specified to use a particular template: TEMPLATE "templates/web_template.xml" which is: Normally, when u use Mapserver in cgi mode, u have the html page which contains those template parameters ( [] ). The html page do a POST, mapserver substitute parameters in the page with new values and the page is sent back to the client. Here is different. The template is processed and remains on the server. You parse the response of the HttpWebRequest, and create an object to send to the client (the response to the Ajax call). Then the client update the page as I explained above. With Java, I think u colud use a library called DWR (Direct Web Remoting), which is conceptually similar to the AjaxPro I used (both are free). Note this is only a method I used, but u could do things in different ways (u could study some php framework). Also I used MapServer in cgi mode. Maybe u want to use Java Mapscript, so things will be different. Ciao Piero 2007/7/5, LITTLE Nelson : > > Thanks for your reply it was the only one I got. You mentioned a lot of > new technologies so I am not sure what to use. > > > > Currently my web page is one big HTML form. I was thinking that maybe when > the user clicks on 'Redraw Map' button then that button could call some > JavaScript code which would update the Map Image ? but how could JavaScript > do that? > > > > Even if I used iFrame I still need some JavaScript to refresh the iFrame. > > > > Thanks, > > Nelson > > > > > > > > > ------------------------------ > > *From:* Piero Cavalieri [mailto:piero.cavalieri at gmail.com] > *Sent:* Wednesday, 4 July 2007 5:25 PM > *To:* LITTLE Nelson > *Cc:* MAPSERVER-USERS at lists.umn.edu > *Subject:* Re: [UMN_MAPSERVER-USERS] Architectural Question > > > > You could use iframe or ajax ways. I used AjaxPro with.NET and cgi > Mapserver and I don't have a single page refresh (everything is updated in > background: map, scalebar, legend, query results). If u use Java, I think u > coluld try DWR (Direct Web Remoting). Seems to remember that JBox is more > suitable to use with Ajax, but try some ways. > > Cheers > Piero > > 2007/7/4, LITTLE Nelson : > > Hello Mapserver users, > > > > I have developed a web based mapserver application using Java Mapscript & > Servlets and it works well and looks great. I currently use the Rosa Applet > as the map window display. My application is very similar in behaviour to > the Mapserver Atlas application (AKA gmap) (online: > http://www.mapsherpa.com/gmap/gmap75.phtml). > > > > Whenever the user hits 'Redraw Map' or clicks on a tool button, it causes > the whole pages to be refreshed. My question is how could this be changed so > that only the map window is refreshed, not the whole page? I know this is an > architectural type question which is not really related to Mapserver, but if > anyone would know the answer it would be the people on this list. > > > > Thanks, > > Nelson > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From assefa at DMSOLUTIONS.CA Fri Jul 6 10:45:13 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Fri, 6 Jul 2007 13:45:13 -0400 Subject: Mapscript and SOS In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F23@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Kralidis,Tom [Burlington] wrote: > Trying this with svn trunk gives me blanks for all responses for SOS. Yet WMS and WFS seem to work (for GetCapabilities). > > > Using svn trunk, When testing a simple PHP Mapscript WxS: > > dl("php_mapscript.so"); > $request = ms_newowsrequestobj(); > foreach ($_GET as $k=>$v) { > $request->setParameter($k, $v); > } > ms_ioinstallstdouttobuffer(); > $oMap = ms_newMapobj("/path/to/config.map"); > $oMap->owsdispatch($request); > $contenttype = ms_iostripstdoutbuffercontenttype(); > $buffer = ms_iogetstdoutbufferstring(); > header('Content-type: text/xml'); > echo $buffer; > ms_ioresethandlers(); > ?> > > - issuing a WMS 1.1.1 GetCapabilities works as expected > > - issuing a WFS 1.0.0 GetCapabilities works as expected > > - issuing a SOS 0.1.2b GetCapabilities returns a blank > > Assefa: is there anything else in mapogcsos.c we have to do to make it mapscript WxS friendly? > Tom. I see the problem. Currently the sos output using something like xmlDocDump(stdout, psDoc); and thus does not take advantage of the ms_ioxxx functionalties. I am looking into how to modify this. > ..Tom > > > > > >> -----Original Message----- >> From: UMN MapServer Users List >> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of >> Kralidis,Tom [Burlington] >> Sent: 03 July, 2007 11:51 AM >> To: MAPSERVER-USERS at LISTS.UMN.EDU >> Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS >> >> Weird. What happens (in terms of the response) when you do a >> GetCapabilities via mapscript and regular SOS request? I >> wonder if the metadata is actually being set. >> >> ..Tom >> >> >>> -----Original Message----- >>> From: UMN MapServer Users List >>> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of "Peter L?we" >>> Sent: 03 July, 2007 11:46 AM >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >>> Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS >>> >>> Hello Tom: >>> >>> After calling up >>> http://localhost/swe/php_sos0.php?Request=GetObservation&servi >>> ce=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik0 >>> 01&version=0.0.31 >>> >>> the apache access_log holds: >>> >>> ::1 - - [03/Jul/2007:17:36:37 +0200] "GET >>> /swe/php_sos0.php?Request=GetObservation&service=SOS&offering= >>> oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.3 >>> 1 HTTP/1.1" 200 790 >>> >>> and this piece of XML is returned: >>> >>> >> >> xmlns:gml="http://www.opengis.net/gml" >>> xmlns:ows="http://www.opengis.net/ows" >>> xmlns:swe="http://www.opengis.net/swe" >>> xmlns:xlink="http://www.w3.org/1999/xlink" >>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >>> xmlns:sos="http://www.opengis.net/sos" >>> xmlns:om="http://www.opengis.net/om" gml:id="oid_1" >>> xsi:schemaLocation="http://www.opengeospatial.net/om >>> http://schemas.opengeospatial.net/om.xsd"> >>> >>> >>> >> xmlns:gml="http://www.opengis.net/gml">1982 >>> >> xmlns:gml="http://www.opengis.net/gml">2007 >>> >>> >>> >>> >>> >>> >>> ..Peter >>> >>> >>>> Can you check your server logs see, exactly, what mapscript >>> sends as the >GetObservation request? >>>> ..Tom >>> -- >>> Dr. Peter L?we >>> >>> >>> >>> >>> >>> >>> Psssst! Schon vom neuen GMX MultiMessenger geh?rt? >>> Der kanns mit allen: http://www.gmx.net/de/go/multimessenger >>> > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From williams at WEBSAWYER.COM Fri Jul 6 11:12:48 2007 From: williams at WEBSAWYER.COM (Doug Williams) Date: Fri, 6 Jul 2007 12:12:48 -0600 Subject: phpmapscript imagemap creation In-Reply-To: <1183731658.6149.10.camel@brantlhp-laptop> Message-ID: Huey, I'll cc: this to the list for others... On Fri, 06 Jul 2007 09:20:58 -0500, Huey Brantley wrote > Hi Doug, > > I'm experimenting with creating a imagemap can just can't seem to > get it to work. I've read your mail at http://www.mail- > archive.com/mapserver-users at lists.umn.edu/msg12670.html. > > I am doing something very similar as you except I use two map files > to generate the imagemap. Here's what I have done, if you don't mind > look over it and see if I'm doing something just blatently wrong. > > Ok, I create my map objects. > > $mapfile = "vanderbilt"; > > $map = ms_newMapObj($mappath.$mapfile.".map"); > $mapoverlay = ms_newMapObj($mappath.$mapfile."overlay.map") > You don't show your mappath here, but since you are getting coords later you must have have it declared in your script. I'm guessing that your second mapfile is called "vanderbiltoverlay.map! Correct? That has the ouputformat driver = imagemap, I again guess. Correct? > $img = $map->draw(); > $map_url = $img->saveWebImage(); > This creates an image and returns the URL to it. Are you displaying the image alright in your web page? > $img2 = $mapoverlay->draw(); > > // here is where things get odd > // gives me a url to map code.... > // > $imagemap_url = $img2->saveWebImage(); > This is not correct. Don't use saveWebImage, that does what you describe, returns a URL to the image you create. You don't show coords above so I suspect that saveWebImage does not really utilize the imagemap driver properly. You are not trying to create a web image, just trying to use the imagemap driver to create the w/ areas and coords to enable the imagemap in the browser. All the imagemap driver does is create the information. [In truth, what I state is what I suspect, I am not a phpmapscript developer, and have no connection to mapserver (other than I think it is supercool and promote it wholeheartedly). Assefa let me know that (if I remember right) mapfile.c is the only real source for indepth info. (Thanks Assefa) Look for that if you are able to read through c code. I have not yet had time to dig into that, but will. > I've tried this as well... > > $imagemap_data= $img2->saveImage($map->web->imagepath."/test.html", > $mapoverlay); > This one should write the info to the file test.html. Look at that with an editor, or load it into your browser and view the source and you should see the same stuff you are seeing below. > I get the same thing.... > > Now here's something interesting...This > > $imagemap_data= $img2->saveImage("",$mapoverlay); > > gives me the coords for my polys at the top of my page...stdout. > Yes, this method, where you do not declare where the output should be written writes to stdout by default. While I in my example write the file and then "require" it into my html returned to the server, it could have been achieved this way without saving the info to a file, but just sending it straight into the html returned to server. I have not tried this way. It sounds like you are seeing the coords on your web page. If that is true, then maybe this returns the coords without the prefixed and postfixed . If that seems right, try writing , then execute the command as above, then write , and you should not see the coords on your web page, but they should be in the html if you look at the source. I am out of town for a week or so and will have limited access to email. Hope this helps. Let me know what you find. -Doug > So, it seems I'm doing almost the same thing as you but just isn't > working. What MapServer, Apache and PHP versions are you using? > > Thanks, > Huey Brantley > Vanderbilt University From ihowat at APL.WASHINGTON.EDU Fri Jul 6 12:51:13 2007 From: ihowat at APL.WASHINGTON.EDU (Ian Howat) Date: Fri, 6 Jul 2007 13:51:13 -0600 Subject: Adding a url link object to a map Message-ID: Hello, I want to add points and/or labels to a map layer that will link to a URL when clicked by the user. Can anyone tell me the easiest way to do this? Thanks, Ian -- Ian Howat Research Associate Applied Physics Lab, University of Washington & National Snow & Ice Data Center, University of Colorado From gregor at HOSTGIS.COM Fri Jul 6 13:06:58 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Fri, 6 Jul 2007 14:06:58 -0600 Subject: Adding a url link object to a map In-Reply-To: <468E9D31.4030503@apl.washington.edu> Message-ID: > I want to add points and/or labels to a map layer that will link to a > URL when clicked by the user. > Can anyone tell me the easiest way to do this? Yup. You'd use the query template (the TEMPLATE setting for a layer) to display the URL in the apprpriate context. For example: Or, if the URL is derived from some field/attribute: Is that a good start? Of course, this assumes that you have a query template and that you have click-to-query stuff basically working. But from there it's easy. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From tnolte at ILPCS.COM Fri Jul 6 13:17:29 2007 From: tnolte at ILPCS.COM (Timothy J Nolte) Date: Fri, 6 Jul 2007 15:17:29 -0500 Subject: Chameleon & DM Solutions US Streets Data... Message-ID: We have been running fine the US Streets data from DM Solutions along with the latest version of Chameleon. I've recently been handed the responsibilities of our MapServer and have the most recent data (2006 SE) from DM Solutions. When I try to use the provided us streets map file, updated with our previous custom layers, I end up with a blank screen and the apache error_log reports a segfault. Is there anyone out there that is using the most recent US Streets data with Chameleon. What did you have to do to migrate from the 2005fe data to the 2006se? Any help would be appreciated. I am able to successfully run the included sample setup that came along with the 2006se map data, so there shouldn't be a problem there. I should note that I am pretty new to MapServer, so I might just be missing something simple. Thanks. From crystal.li at IDISIS.COM Fri Jul 6 20:44:20 2007 From: crystal.li at IDISIS.COM (Crystal Li) Date: Fri, 6 Jul 2007 21:44:20 -0600 Subject: MS4w installation Message-ID: HI all, I still have trouble with installation. two questions here: 1) can I install Mapserver in vista? how about configuration? any special to pay attention? 2) I installed everything the same as before which was running properly, now it shows the procedure entry point _apu_version_string at 0 could not be located in the dynamic link library libaputil.dll. Last time when I installed the MS4W with apache open ssl, once it showed this message, then I realized the ssl version does match the mapserver version. I changed to another ssl version, and it works. So this time, I used the version which once was working, there still is this message. Cause in my computer, there are coldfusion and IIS running, not sure this matters or not, even though I stop these services, still the same error. Please help! Appreciate the time! Have a nice weekend! Crystal -- ========================= Crystal Li Systems Analyst Idisis, Inc. 430, 318 11th Avenue S.E. Calgary, Alberta T2G 0Y2 www.idisis.com E-mail: crystal.li at idisis.com Office: (403)670-7351 Fax: (403) 670-7359 -------------- next part -------------- An HTML attachment was scrubbed... URL: From siukola.antti at GMAIL.COM Sun Jul 8 01:52:01 2007 From: siukola.antti at GMAIL.COM (antti siukola) Date: Sun, 8 Jul 2007 11:52:01 +0300 Subject: MySQL OGR connection Message-ID: Hi! I have an ovf file that uses the gdal mysql driver to load data from database but somehow when the data is returned two of three string columns are in binary form. So the string is now unreadable. What could cause this? Here's the ovf file that I use: MYSQL:bdname,user=user,password=password,host=localhost,port=3306 SQL clause Thanks in advance! Antti S From crystal.li at IDISIS.COM Sun Jul 8 10:46:45 2007 From: crystal.li at IDISIS.COM (Crystal Li) Date: Sun, 8 Jul 2007 11:46:45 -0600 Subject: MAXSCALE and MINSCALE Message-ID: Hi All, still confused about the mapserver scale, when we put in the MAXSCALE in a layer, which part is its show part regarding to the zoom in direction?? Please help! I consulted some examples, it made me more confused. ( I attached a file to display what I mean). Thanks! Crystal -- ========================= Crystal Li Systems Analyst Idisis, Inc. 430, 318 11th Avenue S.E. Calgary, Alberta T2G 0Y2 www.idisis.com E-mail: crystal.li at idisis.com Office: (403)670-7351 Fax: (403) 670-7359 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: mapserver scale.gif Type: image/gif Size: 10397 bytes Desc: not available URL: From bradleym06 at GMAIL.COM Sun Jul 8 18:52:23 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Mon, 9 Jul 2007 11:52:23 +1000 Subject: Projections In-Reply-To: Message-ID: This is kind of hard to explain but what I want to do is use Mapserver to project my data which is in the GDA94 projection as shown below: "# GDA94 / MGA zone 55 <28355> +proj=utm +zone=55 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" to a projection that will be able to be properly merged with Google maps (using OpenLayers) which uses a projection something like the following: "Update 4: Agreement frrom Melita Kennedy and David Burrows that Google Maps and Virtual Earth use spherical equations for the Mercator projection. The correct proj4 settings are: +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 +a=6378137.0 +b=6378137.0 +units=m Note this is different than using the ellipsoidal equations which would be: +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 +ellps=WGS84 +datum=WGS84 +units=m no_defs" I believe that I need to use Mapserver to do this but I have no idea how to go about it. Currently my Mapserver is running fine displaying the data correctly using the GDA94 projection except i had to use a .vrt file to correctly align the raster image which was slightly out of alignment. I have also set up and can call my Mapserver as a WMS (thought having issues with the WMS Layer function in OpenLayers, just displays a white screen but I believe that this is to do with projections) My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP and proj4. In my mapfile I have defined each layer using "init=epsg:28355" as well as globally defining the map using the same projection. This reason I am trying to do this is because currently I don't think that my projection can be properly imported into OpenLayers and merged with Google Maps. Thanks Brad -------------- next part -------------- An HTML attachment was scrubbed... URL: From topografia.oliva at CV.GVA.ES Mon Jul 9 03:40:42 2007 From: topografia.oliva at CV.GVA.ES (Lara Perez Bessone) Date: Mon, 9 Jul 2007 12:40:42 +0200 Subject: GIF don't display Message-ID: Rodrigo: muchiiiiisimas gracias por tu respuesta. He revisado lo que ma has dicho y sigue sin funcionar. La cuesti?n es que cuando tenia instalado el Apache 1.3 y Mapserver 4.4. funcionaban bien las p?ginas. Ahora simplemente no se pueden ver las im?genes. Puedo navegar, seleccionando el zoon recenter ( o pan) y cambia la escala y todo eso, pero no se ven las im?genes. He descartado que el problema est? en el fivhero httpd.conf de Apacha ya que he instalado el workshop de pruebe y la p?gina inicial se ve bien. Asi que sospecho de la plantilla *.html y del fichero *.map. Como informaci?n te comento que hay algunas p?ginas del workshop de prueba que me ocurre lo mismo, es decir, se ve toda la plantilla html pero no se muestran los mapas. Saludos, Lara. ----- Original Message ----- From: Rodrigo Mart?n L?PEZ GREGORIO To: MAPSERVER-USERS at LISTS.UMN.EDU Sent: Friday, July 06, 2007 3:19 PM Subject: Re: [UMN_MAPSERVER-USERS] GIF don't display Hi Lara. The first thing I noticed is that the action of your form is wrong. Your form action looks like: action=" http://cgi-bin/mapserv.exe" and it would look like: action="/cgi-bin/mapserv.exe" Also in the "map" and "imgext" parameters the values seems to be wrong (but I think this will seem ok when you access the php file through Apache): If you still have problems ask me again. (Of course in spanish would be much easier ;) ) Rodrigo. On 7/6/07, Lara Perez wrote: Hello, everybody. I have a little problem I had my mapserver 4.4. running under apache 1.3 and i'd actualizated to apache 2.2 and mapser 4.10. I'd made the necesaries changes, but when the html page opens, the images (*.map) are not shown. If I make a pan it works, but I don't see the images. I can navigate fine, but I can't see the maps. I?ve attached the files. Any idea? Thanks in advance ---------------------------------------------------------------- ---------------------------------------------------------------- Acercar Centrar Alejar Escala: [scale] Nucleos Urbanos: Elige una zona Kiko Sectores 6 y 19 Terranova Poblado Mar?timo Canyades Aig?es Blanques Rabdells Oliva Nova y San Fernando Jovades Sectores 3 y 16 Casco Urbano Sector 15 Sector 2 ---------------------------------------------------------------- Modo: Navegaci?n Consulta ---------------------------------------------------------------- Volver -------------- next part -------------- An HTML attachment was scrubbed... URL: From umberto.nicoletti at GMAIL.COM Mon Jul 9 03:41:52 2007 From: umberto.nicoletti at GMAIL.COM (Umberto Nicoletti) Date: Mon, 9 Jul 2007 12:41:52 +0200 Subject: Error: *** glibc detected *** double free or corruption (!prev) In-Reply-To: <46920CDA.9040407@ilu.ch> Message-ID: Dominik, this is getting very hard to do if you don't know a bit about programming. If you want to try anyway, run shp2img under gdb with the following command: #gdb /path/to/shp2img >run -m pathtothefile.map -o /tmp/map.png When it segfaults issue this command in the gdb shell: #backtrace and post its output here. Umberto On 7/9/07, Dominik Schmid wrote: > I have recompiled 4.0.1 with debug enabled. I then replaced the existing > shp2img and mapserv.cgi with the newly compiled binaries. Next I ran > shp2img with '-all_debug 9' and 'layer_debug 9' for the offending layer > (data from zp_au). Since I have no idea what possible debug levels there > are or what numbers can be set I have chosen to use a value of 9. Here's > the output of shp2img: > > [Mon Jul 9 12:18:03 2007].176107 msPOSTGISLayerOpen called > datastatement: the_geom from zp_au > [Mon Jul 9 12:18:03 2007].185943 msPOSTGISLayerFreeItemInfo called > [Mon Jul 9 12:18:03 2007].186621 msPOSTGISLayerInitItemInfo called > [Mon Jul 9 12:18:03 2007].189609 msPOSTGISLayerWhichShapes called > [Mon Jul 9 12:18:03 2007].190383 msPOSTGISLayerParseData: unique column > = OID, srid='', geom_column_name = the_geom, table_name=zp_au > [Mon Jul 9 12:18:03 2007].192024 query_string_0_6:DECLARE mycursor > BINARY CURSOR FOR SELECT > grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text > from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 > 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, > find_srid('','zp_au','the_geom') ) > *** glibc detected *** double free or corruption (!prev): 0x0956da40 *** > > > Since this debug information doesn't help me pinpoint the problem I have > to ask back here at the list if this tells anyone here anything. > > Any help is appreciated. > > Dominik > > > Umberto Nicoletti wrote: > > If you still have the 4.0.1 sources recompile them with enable debug > > and run shp2img under gdb. This at least will tell you where the > > double free is happening and then you might even be able to fix it. > > > > Umberto > > > > On 7/4/07, Dominik Schmid wrote: > >> Hi > >> > >> I have run into this persistent problem and I have already spent hours > >> upon > >> hours without any result whatsoever. First of all my setup: > >> > >> - Centos 4.4 > >> - apache 2.0.52 > >> - php 5.1.6 > >> - postgresql 8.1.8 > >> - mapserver 4.0.1 (I know, I should update mapserver, but having to > >> rebuild > >> all the legends in our system and possibly avoid some other side effects > >> would be a major headache and have so far kept me from doing this) > >> - gdal 1.4.0 > >> - postgis 1.2.1 > >> - geos 2.2.3 > >> - proj 4.5.0 > >> - glibc 2.3.4-2.25 > >> > >> The error in the httpd error_log reads as stated in the subject. > >> > >> I have added some multipolygon data that I had previously obtained by > >> converting it from a shape file using shp2pgsql. > >> > >> The odd part about this error is, that I use the same syntax in the > >> map file > >> as for a working multipolygon layer that I had imported using older > >> versions > >> of postgis etc. and the older data works just fine. > >> I have reimported said working data from the original shape file and > >> compared it to the existing data in the working table. the_geom and other > >> relevant stuff is identical. And still the newly imported data > >> produces this > >> error. > >> > >> I have checked projection, db access privs and just about everything else > >> that crossed my mind as playing a part to no avail. > >> > >> So, is this problem a known issue? What else could I try/look into? > >> Any advice? > >> > >> Thanks > >> Dominik > >> > > > > > -- > Dominik Schmid > Dipl. Umweltnaturwissenschafter ETH > > ilu AG > Zentralstrasse 2a > CH-8610 Uster > > Tel: +41 44 / 944 55 56 (Direktwahl) > Tel: +41 44 / 944 55 55 (allgemein) > Fax: +41 44 / 944 55 66 > > mailto:dominik.schmid at ilu.ch > http://www.ilu.ch > From dominik.schmid at ILU.CH Mon Jul 9 03:24:26 2007 From: dominik.schmid at ILU.CH (Dominik Schmid) Date: Mon, 9 Jul 2007 12:24:26 +0200 Subject: Error: *** glibc detected *** double free or corruption (!prev) In-Reply-To: <75b4b93e0707050125k1de617ccy75eb834269684f47@mail.gmail.com> Message-ID: I have recompiled 4.0.1 with debug enabled. I then replaced the existing shp2img and mapserv.cgi with the newly compiled binaries. Next I ran shp2img with '-all_debug 9' and 'layer_debug 9' for the offending layer (data from zp_au). Since I have no idea what possible debug levels there are or what numbers can be set I have chosen to use a value of 9. Here's the output of shp2img: [Mon Jul 9 12:18:03 2007].176107 msPOSTGISLayerOpen called datastatement: the_geom from zp_au [Mon Jul 9 12:18:03 2007].185943 msPOSTGISLayerFreeItemInfo called [Mon Jul 9 12:18:03 2007].186621 msPOSTGISLayerInitItemInfo called [Mon Jul 9 12:18:03 2007].189609 msPOSTGISLayerWhichShapes called [Mon Jul 9 12:18:03 2007].190383 msPOSTGISLayerParseData: unique column = OID, srid='', geom_column_name = the_geom, table_name=zp_au [Mon Jul 9 12:18:03 2007].192024 query_string_0_6:DECLARE mycursor BINARY CURSOR FOR SELECT grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, find_srid('','zp_au','the_geom') ) *** glibc detected *** double free or corruption (!prev): 0x0956da40 *** Since this debug information doesn't help me pinpoint the problem I have to ask back here at the list if this tells anyone here anything. Any help is appreciated. Dominik Umberto Nicoletti wrote: > If you still have the 4.0.1 sources recompile them with enable debug > and run shp2img under gdb. This at least will tell you where the > double free is happening and then you might even be able to fix it. > > Umberto > > On 7/4/07, Dominik Schmid wrote: >> Hi >> >> I have run into this persistent problem and I have already spent hours >> upon >> hours without any result whatsoever. First of all my setup: >> >> - Centos 4.4 >> - apache 2.0.52 >> - php 5.1.6 >> - postgresql 8.1.8 >> - mapserver 4.0.1 (I know, I should update mapserver, but having to >> rebuild >> all the legends in our system and possibly avoid some other side effects >> would be a major headache and have so far kept me from doing this) >> - gdal 1.4.0 >> - postgis 1.2.1 >> - geos 2.2.3 >> - proj 4.5.0 >> - glibc 2.3.4-2.25 >> >> The error in the httpd error_log reads as stated in the subject. >> >> I have added some multipolygon data that I had previously obtained by >> converting it from a shape file using shp2pgsql. >> >> The odd part about this error is, that I use the same syntax in the >> map file >> as for a working multipolygon layer that I had imported using older >> versions >> of postgis etc. and the older data works just fine. >> I have reimported said working data from the original shape file and >> compared it to the existing data in the working table. the_geom and other >> relevant stuff is identical. And still the newly imported data >> produces this >> error. >> >> I have checked projection, db access privs and just about everything else >> that crossed my mind as playing a part to no avail. >> >> So, is this problem a known issue? What else could I try/look into? >> Any advice? >> >> Thanks >> Dominik >> > -- Dominik Schmid Dipl. Umweltnaturwissenschafter ETH ilu AG Zentralstrasse 2a CH-8610 Uster Tel: +41 44 / 944 55 56 (Direktwahl) Tel: +41 44 / 944 55 55 (allgemein) Fax: +41 44 / 944 55 66 mailto:dominik.schmid at ilu.ch http://www.ilu.ch From dominik.schmid at ILU.CH Mon Jul 9 04:45:09 2007 From: dominik.schmid at ILU.CH (Dominik Schmid) Date: Mon, 9 Jul 2007 13:45:09 +0200 Subject: Error: *** glibc detected *** double free or corruption (!prev) In-Reply-To: <75b4b93e0707090341t21ce406ayf6315d365ef982ec@mail.gmail.com> Message-ID: Umberto, I have done as you suggested. The output reads as follows: Starting program: /tmp/shp2img -m /in/irr/mb/mb_test.map -l "Zonenplan" -all_debug 9 -layer_debug Zonenplan 9 -o test_img2.png [Thread debugging using libthread_db enabled] [New Thread -1208117568 (LWP 4843)] [Mon Jul 9 13:38:33 2007].267262 msPOSTGISLayerOpen called datastatement: the_geom from zp_au [Mon Jul 9 13:38:33 2007].288259 msPOSTGISLayerFreeItemInfo called [Mon Jul 9 13:38:33 2007].288715 msPOSTGISLayerInitItemInfo called [Mon Jul 9 13:38:33 2007].291176 msPOSTGISLayerWhichShapes called [Mon Jul 9 13:38:33 2007].291959 msPOSTGISLayerParseData: unique column = OID, srid='', geom_column_name = the_geom, table_name=zp_au [Mon Jul 9 13:38:33 2007].293130 query_string_0_6:DECLARE mycursor BINARY CURSOR FOR SELECT grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, find_srid('','zp_au','the_geom') ) *** glibc detected *** double free or corruption (!prev): 0x08f02a40 *** Program received signal SIGABRT, Aborted. [Switching to Thread -1208117568 (LWP 4843)] 0x005027a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 As I'm not a programmer but just a simple web developer my debugging abilities are naturally rather limited. Dominik Umberto Nicoletti schrieb: > Dominik, > this is getting very hard to do if you don't know a bit about programming. > > If you want to try anyway, run shp2img under gdb with the following > command: > > #gdb /path/to/shp2img >> run -m pathtothefile.map -o /tmp/map.png > > When it segfaults issue this command in the gdb shell: > > #backtrace > > and post its output here. > > Umberto > > On 7/9/07, Dominik Schmid wrote: >> I have recompiled 4.0.1 with debug enabled. I then replaced the existing >> shp2img and mapserv.cgi with the newly compiled binaries. Next I ran >> shp2img with '-all_debug 9' and 'layer_debug 9' for the offending layer >> (data from zp_au). Since I have no idea what possible debug levels there >> are or what numbers can be set I have chosen to use a value of 9. Here's >> the output of shp2img: >> >> [Mon Jul 9 12:18:03 2007].176107 msPOSTGISLayerOpen called >> datastatement: the_geom from zp_au >> [Mon Jul 9 12:18:03 2007].185943 msPOSTGISLayerFreeItemInfo called >> [Mon Jul 9 12:18:03 2007].186621 msPOSTGISLayerInitItemInfo called >> [Mon Jul 9 12:18:03 2007].189609 msPOSTGISLayerWhichShapes called >> [Mon Jul 9 12:18:03 2007].190383 msPOSTGISLayerParseData: unique column >> = OID, srid='', geom_column_name = the_geom, table_name=zp_au >> [Mon Jul 9 12:18:03 2007].192024 query_string_0_6:DECLARE mycursor >> BINARY CURSOR FOR SELECT >> grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text >> >> from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 >> 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, >> find_srid('','zp_au','the_geom') ) >> *** glibc detected *** double free or corruption (!prev): 0x0956da40 *** >> >> >> Since this debug information doesn't help me pinpoint the problem I have >> to ask back here at the list if this tells anyone here anything. >> >> Any help is appreciated. >> >> Dominik >> >> >> Umberto Nicoletti wrote: >> > If you still have the 4.0.1 sources recompile them with enable debug >> > and run shp2img under gdb. This at least will tell you where the >> > double free is happening and then you might even be able to fix it. >> > >> > Umberto >> > >> > On 7/4/07, Dominik Schmid wrote: >> >> Hi >> >> >> >> I have run into this persistent problem and I have already spent hours >> >> upon >> >> hours without any result whatsoever. First of all my setup: >> >> >> >> - Centos 4.4 >> >> - apache 2.0.52 >> >> - php 5.1.6 >> >> - postgresql 8.1.8 >> >> - mapserver 4.0.1 (I know, I should update mapserver, but having to >> >> rebuild >> >> all the legends in our system and possibly avoid some other side >> effects >> >> would be a major headache and have so far kept me from doing this) >> >> - gdal 1.4.0 >> >> - postgis 1.2.1 >> >> - geos 2.2.3 >> >> - proj 4.5.0 >> >> - glibc 2.3.4-2.25 >> >> >> >> The error in the httpd error_log reads as stated in the subject. >> >> >> >> I have added some multipolygon data that I had previously obtained by >> >> converting it from a shape file using shp2pgsql. >> >> >> >> The odd part about this error is, that I use the same syntax in the >> >> map file >> >> as for a working multipolygon layer that I had imported using older >> >> versions >> >> of postgis etc. and the older data works just fine. >> >> I have reimported said working data from the original shape file and >> >> compared it to the existing data in the working table. the_geom and >> other >> >> relevant stuff is identical. And still the newly imported data >> >> produces this >> >> error. >> >> >> >> I have checked projection, db access privs and just about >> everything else >> >> that crossed my mind as playing a part to no avail. >> >> >> >> So, is this problem a known issue? What else could I try/look into? >> >> Any advice? >> >> >> >> Thanks >> >> Dominik >> >> >> > >> >> >> -- >> Dominik Schmid >> Dipl. Umweltnaturwissenschafter ETH >> >> ilu AG >> Zentralstrasse 2a >> CH-8610 Uster >> >> Tel: +41 44 / 944 55 56 (Direktwahl) >> Tel: +41 44 / 944 55 55 (allgemein) >> Fax: +41 44 / 944 55 66 >> >> mailto:dominik.schmid at ilu.ch >> http://www.ilu.ch >> > -- Dominik Schmid Dipl. Umweltnaturwissenschafter ETH ilu AG Zentralstrasse 2a CH-8610 Uster Tel: +41 44 / 944 55 56 (Direktwahl) Tel: +41 44 / 944 55 55 (allgemein) Fax: +41 44 / 944 55 66 mailto:dominik.schmid at ilu.ch http://www.ilu.ch From jmckenna at DMSOLUTIONS.CA Mon Jul 9 06:35:56 2007 From: jmckenna at DMSOLUTIONS.CA (Jeff McKenna) Date: Mon, 9 Jul 2007 09:35:56 -0400 Subject: MS4w installation In-Reply-To: <417cc46d0707062044s67dc131enb9f0214ae4bc0c4f@mail.gmail.com> Message-ID: Hello again, Again, there is a separate MS4W mailing list for MS4W issues like this (join at http://lists.maptools.org/mailman/listinfo/ms4w-users). Comments inline below: Crystal Li wrote: > HI all, > > I still have trouble with installation. two questions here: > > 1) can I install Mapserver in vista? how about configuration? any > special to pay attention? Yes, and there are some notes regarding this in the MS4W README file (http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL.html#c-special-notes-for-microsoft-vista) > > 2) I installed everything the same as before which was running properly, > now it shows the procedure entry point _apu_version_string at 0 > could not be located in the dynamic link > library libaputil.dll. > > Last time when I installed the MS4W with apache open ssl, once it showed > this message, then I realized the ssl version does match the mapserver > version. I changed to another ssl version, and it works. So this time, I > used the version which once was working, there still is this message. > > Cause in my computer, there are coldfusion and IIS running, not sure > this matters or not, even though I stop these services, still the same > error. > I made some comments about this in your previous post regarding SSL, but I don't have any more information sorry. -- Jeff McKenna DM Solutions Group Inc. http://www.dmsolutions.ca From rwburgholzer at DEQ.VIRGINIA.GOV Mon Jul 9 08:22:37 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Mon, 9 Jul 2007 11:22:37 -0400 Subject: Projections Message-ID: Brad, If I understand your objective correctly, you want mapserver to re-project your layers for you to this custom projection. For that, I think that you should set the projection for each layer to their "source" projection, i.e., the projection that they are currently in. For you MAP, you should set the projection to the destination projection, i.e., the one that you want to re-project into. Mapserver will automatically re-project it for you (I think). That said, I have only used standard projections to do this, for example, I have combined UTM with decimal degrees in the same map with this approach. I do not know enough to say how you go about setting the custom google projection on your MAP object. HTH, Robert This is kind of hard to explain but what I want to do is use Mapserver to project my data which is in the GDA94 projection as shown below: "# GDA94 / MGA zone 55 <28355> +proj=utm +zone=55 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" to a projection that will be able to be properly merged with Google maps (using OpenLayers) which uses a projection something like the following: "Update 4: Agreement frrom Melita Kennedy and David Burrows that Google Maps and Virtual Earth use spherical equations for the Mercator projection. The correct proj4 settings are: +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 +a=6378137.0 +b=6378137.0 +units=m Note this is different than using the ellipsoidal equations which would be: -------------- next part -------------- An HTML attachment was scrubbed... URL: From assefa at DMSOLUTIONS.CA Mon Jul 9 09:09:15 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Mon, 9 Jul 2007 12:09:15 -0400 Subject: Mapscript and SOS In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F23@ecburexch1.ontario.int.ec.gc.ca> Message-ID: Tom, I entered a bug on this + comments on how to fix it : http://trac.osgeo.org/mapserver/ticket/2146 Later, Kralidis,Tom [Burlington] wrote: > Trying this with svn trunk gives me blanks for all responses for SOS. Yet WMS and WFS seem to work (for GetCapabilities). > > > Using svn trunk, When testing a simple PHP Mapscript WxS: > > dl("php_mapscript.so"); > $request = ms_newowsrequestobj(); > foreach ($_GET as $k=>$v) { > $request->setParameter($k, $v); > } > ms_ioinstallstdouttobuffer(); > $oMap = ms_newMapobj("/path/to/config.map"); > $oMap->owsdispatch($request); > $contenttype = ms_iostripstdoutbuffercontenttype(); > $buffer = ms_iogetstdoutbufferstring(); > header('Content-type: text/xml'); > echo $buffer; > ms_ioresethandlers(); > ?> > > - issuing a WMS 1.1.1 GetCapabilities works as expected > > - issuing a WFS 1.0.0 GetCapabilities works as expected > > - issuing a SOS 0.1.2b GetCapabilities returns a blank > > Assefa: is there anything else in mapogcsos.c we have to do to make it mapscript WxS friendly? > > ..Tom > > > > > >> -----Original Message----- >> From: UMN MapServer Users List >> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of >> Kralidis,Tom [Burlington] >> Sent: 03 July, 2007 11:51 AM >> To: MAPSERVER-USERS at LISTS.UMN.EDU >> Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS >> >> Weird. What happens (in terms of the response) when you do a >> GetCapabilities via mapscript and regular SOS request? I >> wonder if the metadata is actually being set. >> >> ..Tom >> >> >>> -----Original Message----- >>> From: UMN MapServer Users List >>> [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of "Peter L?we" >>> Sent: 03 July, 2007 11:46 AM >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >>> Subject: Re: [UMN_MAPSERVER-USERS] Mapscript and SOS >>> >>> Hello Tom: >>> >>> After calling up >>> http://localhost/swe/php_sos0.php?Request=GetObservation&servi >>> ce=SOS&offering=oid_1&observedproperty=1234&procedure=sputnik0 >>> 01&version=0.0.31 >>> >>> the apache access_log holds: >>> >>> ::1 - - [03/Jul/2007:17:36:37 +0200] "GET >>> /swe/php_sos0.php?Request=GetObservation&service=SOS&offering= >>> oid_1&observedproperty=1234&procedure=sputnik001&version=0.0.3 >>> 1 HTTP/1.1" 200 790 >>> >>> and this piece of XML is returned: >>> >>> >> >> xmlns:gml="http://www.opengis.net/gml" >>> xmlns:ows="http://www.opengis.net/ows" >>> xmlns:swe="http://www.opengis.net/swe" >>> xmlns:xlink="http://www.w3.org/1999/xlink" >>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >>> xmlns:sos="http://www.opengis.net/sos" >>> xmlns:om="http://www.opengis.net/om" gml:id="oid_1" >>> xsi:schemaLocation="http://www.opengeospatial.net/om >>> http://schemas.opengeospatial.net/om.xsd"> >>> >>> >>> >> xmlns:gml="http://www.opengis.net/gml">1982 >>> >> xmlns:gml="http://www.opengis.net/gml">2007 >>> >>> >>> >>> >>> >>> >>> ..Peter >>> >>> >>>> Can you check your server logs see, exactly, what mapscript >>> sends as the >GetObservation request? >>>> ..Tom >>> -- >>> Dr. Peter L?we >>> >>> >>> >>> >>> >>> >>> Psssst! Schon vom neuen GMX MultiMessenger geh?rt? >>> Der kanns mit allen: http://www.gmx.net/de/go/multimessenger >>> > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From work at XWB.COM Mon Jul 9 09:16:07 2007 From: work at XWB.COM (Chip Taylor) Date: Mon, 9 Jul 2007 09:16:07 -0700 Subject: Weather WMS In-Reply-To: <468E9D31.4030503@apl.washington.edu> Message-ID: Does anyone know of any US, North America, or world weather WMS map feeds? Thanks in advance. Chip From David.Fawcett at STATE.MN.US Mon Jul 9 09:29:05 2007 From: David.Fawcett at STATE.MN.US (Fawcett, David) Date: Mon, 9 Jul 2007 11:29:05 -0500 Subject: Weather WMS In-Reply-To: A<000801c7c244$7629e410$025aa8c0@DevChip> Message-ID: Chip, Check out what the Iowa Env Mesonet serves up. http://mesonet.agron.iastate.edu/ogc/ David. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Chip Taylor Sent: Monday, July 09, 2007 11:16 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: [UMN_MAPSERVER-USERS] Weather WMS Does anyone know of any US, North America, or world weather WMS map feeds? Thanks in advance. Chip From ed at TOPOZONE.COM Mon Jul 9 11:06:02 2007 From: ed at TOPOZONE.COM (Ed McNierney) Date: Mon, 9 Jul 2007 14:06:02 -0400 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: <352709B2-2499-4D24-83E0-5AC9EC10A1DD@dmsolutions.ca> Message-ID: Paul - This doesn't seem correct to me. You're suggesting a Transverse Mercator projection on an ellipsoid when the request was for a Mercator on a sphere. I did a little Googling around and while it appears that the 41001 projection is often referred to as "Transverse Mercator", and there are several references to the PROJ definition you mention (+proj=tmerc, etc.), there is a more sensible reference to 41001 being defined in a GeoServer install as: PROJCS["WGS84 / Simple Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS_1984", 6378137.0, 298.257223563]], PRIMEM["Greenwich", 0.0], UNIT["degree", 0.017453292519943295], AXIS["Lon", EAST], AXIS["Lat", NORTH]], PROJECTION["Mercator_1SP"], PARAMETER["central_meridian", 0.0], PARAMETER["scale_factor", 1.0], PARAMETER["false_easting", 0.0], PARAMETER["false_northing", 0.0], UNIT["m", 1.0], AXIS["x", EAST], AXIS["y", NORTH], AUTHORITY["EPSG","41001"]] This is more sensible (at least it's a Mercator projection!) but it is still a ellipsoidal rather than spherical projection, so it's not quite right. However, the entire universe of Web-based "geographic" projection fans, stimulated by Google and Microsoft, obviously don't really get bothered when their maps are "not quite right", so I should learn not to be so fussy. - Ed P.S. I modified the reply to go only to the MAPSERVER-USERS list, since the original cross-posting to both lists only complicates matters for people trying to help. > From: Paul Spencer > Reply-To: Paul Spencer > Date: Sun, 8 Jul 2007 22:17:03 -0400 > To: > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > You need what is commonly referred to as EPSG:41001, defined as: > > <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> > > To use this, add the above line to your 'epsg' file and also add a > projection object to your map object: > > PROJECTION > "init=epsg:41001" > END > > You will also need to make sure that every layer in your map file has > a proper projection so mapserver can reproject it correctly. > > Cheers > > Paul > > On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: > >> This is kind of hard to explain but what I want to do is use >> Mapserver to project my data which is in the GDA94 projection as >> shown below: >> >> "# GDA94 / MGA zone 55 >> <28355> +proj=utm +zone=55 +south +ellps=GRS80 >> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" >> >> to a projection that will be able to be properly merged with Google >> maps (using OpenLayers) which uses a projection something like the >> following: >> >> "Update 4: Agreement frrom Melita Kennedy and David Burrows that >> Google Maps and Virtual Earth use spherical equations for the >> Mercator projection. The correct proj4 settings are: >> >> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >> +a=6378137.0 +b=6378137.0 +units=m >> >> Note this is different than using the ellipsoidal equations which >> would be: >> >> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >> +ellps=WGS84 +datum=WGS84 +units=m no_defs" >> >> I believe that I need to use Mapserver to do this but I have no >> idea how to go about it. Currently my Mapserver is running fine >> displaying the data correctly using the GDA94 projection except i >> had to use a .vrt file to correctly align the raster image which >> was slightly out of alignment. I have also set up and can call my >> Mapserver as a WMS (thought having issues with the WMS Layer >> function in OpenLayers, just displays a white screen but I believe >> that this is to do with projections) >> >> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP >> and proj4. >> >> In my mapfile I have defined each layer using "init=epsg:28355" as >> well as globally defining the map using the same projection. >> >> This reason I am trying to do this is because currently I don't >> think that my projection can be properly imported into OpenLayers >> and merged with Google Maps. >> >> Thanks >> >> Brad > > +-----------------------------------------------------------------+ > |Paul Spencer pspencer at dmsolutions.ca | > +-----------------------------------------------------------------+ > |Chief Technology Officer | > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > +-----------------------------------------------------------------+ From mweinelt at PLANIGLOBE.COM Mon Jul 9 11:54:15 2007 From: mweinelt at PLANIGLOBE.COM (kk+w - digitale kartografie GmbH) Date: Mon, 9 Jul 2007 20:54:15 +0200 Subject: Mapscript, SVG and Annotations Message-ID: Hi, I am using addFeature to dynamically add site locations with a label to a map. It's Perl mapscript. @sites is an array of hash references, $sitesLyr is from the map file: ############### foreach my $site (@sites) { my $site_pt = $$site{'site_loc'}; $site_pt =~s/.*\((.*)\)*./$1/; # extract the points x and y my $line = new mapscript::lineObj(); my $siteShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); my $point = new mapscript::pointObj(); my($x,$y) = split(/ /, $site_pt); $point->setXY($x,$y); $line->add($point); $siteShp->add($line); $siteShp->{text} = $$site{'site_name'}; $siteShp->setBounds(); $sitesLyr->addFeature($siteShp); } my $img = $map->draw(); ############# This works perfectly for the usual PNG output map. Using the same routine for a SVG 'image' results in the symbols/markers getting plotted, but the labels are missing. If I switch to a static shapefile for this layer, the labels do appear in the SVG. Is there anything special with SVG output and the 'addFeature' method for layers that I am missing? Thanks, Martin From pspencer at DMSOLUTIONS.CA Mon Jul 9 11:55:22 2007 From: pspencer at DMSOLUTIONS.CA (Paul Spencer) Date: Mon, 9 Jul 2007 14:55:22 -0400 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: Message-ID: Thanks for the clarification Ed (and for fixing the cross-list- posting-bug :)). I just looked into this more and you are correct (I was completely wrong). From the site that Bradley quoted, they seem to think that the spherical projection is what is used by Google etc. The (unverified) proj.4 parameters for this seem to be: +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 +b=6378137.0 +units=m Cheers Paul On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > Paul - > > This doesn't seem correct to me. You're suggesting a Transverse > Mercator > projection on an ellipsoid when the request was for a Mercator on a > sphere. > > I did a little Googling around and while it appears that the 41001 > projection is often referred to as "Transverse Mercator", and there > are > several references to the PROJ definition you mention (+proj=tmerc, > etc.), > there is a more sensible reference to 41001 being defined in a > GeoServer > install as: > > PROJCS["WGS84 / Simple Mercator", > GEOGCS["WGS 84", > DATUM["WGS_1984", > SPHEROID["WGS_1984", 6378137.0, 298.257223563]], > PRIMEM["Greenwich", 0.0], > UNIT["degree", 0.017453292519943295], > AXIS["Lon", EAST], > AXIS["Lat", NORTH]], > PROJECTION["Mercator_1SP"], > PARAMETER["central_meridian", 0.0], > PARAMETER["scale_factor", 1.0], > PARAMETER["false_easting", 0.0], > PARAMETER["false_northing", 0.0], > UNIT["m", 1.0], > AXIS["x", EAST], > AXIS["y", NORTH], > AUTHORITY["EPSG","41001"]] > > This is more sensible (at least it's a Mercator projection!) but it > is still > a ellipsoidal rather than spherical projection, so it's not quite > right. > > However, the entire universe of Web-based "geographic" projection > fans, > stimulated by Google and Microsoft, obviously don't really get > bothered when > their maps are "not quite right", so I should learn not to be so > fussy. > > - Ed > > P.S. I modified the reply to go only to the MAPSERVER-USERS list, > since the > original cross-posting to both lists only complicates matters for > people > trying to help. > > >> From: Paul Spencer >> Reply-To: Paul Spencer >> Date: Sun, 8 Jul 2007 22:17:03 -0400 >> To: >> Subject: Re: [UMN_MAPSERVER-DEV] Projections >> >> You need what is commonly referred to as EPSG:41001, defined as: >> >> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> >> >> To use this, add the above line to your 'epsg' file and also add a >> projection object to your map object: >> >> PROJECTION >> "init=epsg:41001" >> END >> >> You will also need to make sure that every layer in your map file has >> a proper projection so mapserver can reproject it correctly. >> >> Cheers >> >> Paul >> >> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: >> >>> This is kind of hard to explain but what I want to do is use >>> Mapserver to project my data which is in the GDA94 projection as >>> shown below: >>> >>> "# GDA94 / MGA zone 55 >>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 >>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" >>> >>> to a projection that will be able to be properly merged with Google >>> maps (using OpenLayers) which uses a projection something like the >>> following: >>> >>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that >>> Google Maps and Virtual Earth use spherical equations for the >>> Mercator projection. The correct proj4 settings are: >>> >>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>> +a=6378137.0 +b=6378137.0 +units=m >>> >>> Note this is different than using the ellipsoidal equations which >>> would be: >>> >>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" >>> >>> I believe that I need to use Mapserver to do this but I have no >>> idea how to go about it. Currently my Mapserver is running fine >>> displaying the data correctly using the GDA94 projection except i >>> had to use a .vrt file to correctly align the raster image which >>> was slightly out of alignment. I have also set up and can call my >>> Mapserver as a WMS (thought having issues with the WMS Layer >>> function in OpenLayers, just displays a white screen but I believe >>> that this is to do with projections) >>> >>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP >>> and proj4. >>> >>> In my mapfile I have defined each layer using "init=epsg:28355" as >>> well as globally defining the map using the same projection. >>> >>> This reason I am trying to do this is because currently I don't >>> think that my projection can be properly imported into OpenLayers >>> and merged with Google Maps. >>> >>> Thanks >>> >>> Brad >> >> +-----------------------------------------------------------------+ >> |Paul Spencer pspencer at dmsolutions.ca | >> +-----------------------------------------------------------------+ >> |Chief Technology Officer | >> |DM Solutions Group Inc http://www.dmsolutions.ca/ | >> +-----------------------------------------------------------------+ > +-----------------------------------------------------------------+ |Paul Spencer pspencer at dmsolutions.ca | +-----------------------------------------------------------------+ |Chief Technology Officer | |DM Solutions Group Inc http://www.dmsolutions.ca/ | +-----------------------------------------------------------------+ From ed at TOPOZONE.COM Mon Jul 9 12:20:05 2007 From: ed at TOPOZONE.COM (Ed McNierney) Date: Mon, 9 Jul 2007 15:20:05 -0400 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: <6F012573-0BBD-4DC7-A8D7-75FCB8060BB6@DMSOLUTIONS.CA> Message-ID: Paul - Those parameters look good. There is obviously not a "standard" EPSG code for this projection. Bradley, you need to decide whether you need to serve these WMS images out to the wide world (i.e. clients over which you have no control) or only use them "internally" where you can control both your WMS server and the client. If it's the former, you have a problem, as there is no EPSG code describing the projection you need that seems to be in general usage so your clients can be expected to support it. If it's the latter, you're fine. You can simply pick any number you like that's not already taken and add that line to your EPSG file. It's just a text file. Let's assume you'll pick 41002 (since 41001 seems to be in popular usage, but is wrong). Then you'd add the single text line: <41002>+proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 +b=6378137.0 +units=m To the EPSG files on your server and on each client. Then you can refer to it as SRS=EPSG:41002 in your WMS requests and you're all set. - Ed > From: Paul Spencer > Date: Mon, 9 Jul 2007 14:55:22 -0400 > To: Ed McNierney > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > Thanks for the clarification Ed (and for fixing the cross-list- > posting-bug :)). I just looked into this more and you are correct (I > was completely wrong). From the site that Bradley quoted, they seem > to think that the spherical projection is what is used by Google > etc. The (unverified) proj.4 parameters for this seem to be: > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > Cheers > > Paul > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > >> Paul - >> >> This doesn't seem correct to me. You're suggesting a Transverse >> Mercator >> projection on an ellipsoid when the request was for a Mercator on a >> sphere. >> >> I did a little Googling around and while it appears that the 41001 >> projection is often referred to as "Transverse Mercator", and there >> are >> several references to the PROJ definition you mention (+proj=tmerc, >> etc.), >> there is a more sensible reference to 41001 being defined in a >> GeoServer >> install as: >> >> PROJCS["WGS84 / Simple Mercator", >> GEOGCS["WGS 84", >> DATUM["WGS_1984", >> SPHEROID["WGS_1984", 6378137.0, 298.257223563]], >> PRIMEM["Greenwich", 0.0], >> UNIT["degree", 0.017453292519943295], >> AXIS["Lon", EAST], >> AXIS["Lat", NORTH]], >> PROJECTION["Mercator_1SP"], >> PARAMETER["central_meridian", 0.0], >> PARAMETER["scale_factor", 1.0], >> PARAMETER["false_easting", 0.0], >> PARAMETER["false_northing", 0.0], >> UNIT["m", 1.0], >> AXIS["x", EAST], >> AXIS["y", NORTH], >> AUTHORITY["EPSG","41001"]] >> >> This is more sensible (at least it's a Mercator projection!) but it >> is still >> a ellipsoidal rather than spherical projection, so it's not quite >> right. >> >> However, the entire universe of Web-based "geographic" projection >> fans, >> stimulated by Google and Microsoft, obviously don't really get >> bothered when >> their maps are "not quite right", so I should learn not to be so >> fussy. >> >> - Ed >> >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, >> since the >> original cross-posting to both lists only complicates matters for >> people >> trying to help. >> >> >>> From: Paul Spencer >>> Reply-To: Paul Spencer >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 >>> To: >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections >>> >>> You need what is commonly referred to as EPSG:41001, defined as: >>> >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> >>> >>> To use this, add the above line to your 'epsg' file and also add a >>> projection object to your map object: >>> >>> PROJECTION >>> "init=epsg:41001" >>> END >>> >>> You will also need to make sure that every layer in your map file has >>> a proper projection so mapserver can reproject it correctly. >>> >>> Cheers >>> >>> Paul >>> >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: >>> >>>> This is kind of hard to explain but what I want to do is use >>>> Mapserver to project my data which is in the GDA94 projection as >>>> shown below: >>>> >>>> "# GDA94 / MGA zone 55 >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" >>>> >>>> to a projection that will be able to be properly merged with Google >>>> maps (using OpenLayers) which uses a projection something like the >>>> following: >>>> >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that >>>> Google Maps and Virtual Earth use spherical equations for the >>>> Mercator projection. The correct proj4 settings are: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +a=6378137.0 +b=6378137.0 +units=m >>>> >>>> Note this is different than using the ellipsoidal equations which >>>> would be: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" >>>> >>>> I believe that I need to use Mapserver to do this but I have no >>>> idea how to go about it. Currently my Mapserver is running fine >>>> displaying the data correctly using the GDA94 projection except i >>>> had to use a .vrt file to correctly align the raster image which >>>> was slightly out of alignment. I have also set up and can call my >>>> Mapserver as a WMS (thought having issues with the WMS Layer >>>> function in OpenLayers, just displays a white screen but I believe >>>> that this is to do with projections) >>>> >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP >>>> and proj4. >>>> >>>> In my mapfile I have defined each layer using "init=epsg:28355" as >>>> well as globally defining the map using the same projection. >>>> >>>> This reason I am trying to do this is because currently I don't >>>> think that my projection can be properly imported into OpenLayers >>>> and merged with Google Maps. >>>> >>>> Thanks >>>> >>>> Brad >>> >>> +-----------------------------------------------------------------+ >>> |Paul Spencer pspencer at dmsolutions.ca | >>> +-----------------------------------------------------------------+ >>> |Chief Technology Officer | >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | >>> +-----------------------------------------------------------------+ >> > > +-----------------------------------------------------------------+ > |Paul Spencer pspencer at dmsolutions.ca | > +-----------------------------------------------------------------+ > |Chief Technology Officer | > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > +-----------------------------------------------------------------+ > > > > > From jayzee.smith at GMAIL.COM Mon Jul 9 14:53:23 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Mon, 9 Jul 2007 17:53:23 -0400 Subject: imagemap with mode=browse? Message-ID: guys, how can i create imagemap (which requires mode=nquery and templates under layer), and zoom in/out (which requires mode=browse, and templates under map)?? i really want to get rid of the "identify" button. ;) i know some people have done cool popups. cheers, jzs From rwburgholzer at DEQ.VIRGINIA.GOV Mon Jul 9 15:14:42 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Mon, 9 Jul 2007 18:14:42 -0400 Subject: Dynamic map annotation in animated GIF file Message-ID: I am trying to produce a time series animated GIF, with an annotation at the bottom of the map that shows the time. Thanks to an example from Charlton Purvis found by a search of previous postings on making an animated GIF (modified to use a single layer, changing the filter to select for the data that is in my current time step): http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0304/msg00482.h tml And a Wiki entry from Jeff McKenna about making a copyright notation: http://mapserver.gis.umn.edu/docs/faq/copyright-layer I have the basics, that is, an animated time series, with a statically placed text entry at the bottom (at a map-specific point, rather than a lat lon). However, the annotation layer can only display a single entry, not one that is updated with the time step. I am wondering how to do this, if I can modify the property of the annotation layer, or if I need to create a point of some sort from a dynamic postgis call. I can't seem to set the TEXT portion of the feature via php mapscript. Anyone have any ideas? (code and mapfile follow) foreach ($gifmaps as $thismap) { $thislayer = $amap->map->getLayerByName('stream_stat'); $filter = " projectid = $projectid and thismetric = '$thismap' "; $listobject->querystring = " select count(*) as numrecs from proj_group_stat "; $listobject->querystring .= " where $filter "; $listobject->performQuery(); $numrecs = $listobject->getRecordValue(1,'numrecs'); #$annotlayer = $amap->map->getLayerByName('copyright'); #$annotation = $annotlayer->getFeature(1,-1); if ($numrecs > 0) { $thislayer->setFilter($filter); $thislayer->set("status",MS_ON); #$annotation->set("TEXT", $filter); $image[$i] = $amap->map->draw(); $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); $file_path[$i] = $amap->map->web->imagepath . substr(strrchr($image_url[$i], "/"),1); $anim_files = $anim_files . '"' . $file_path[$i] . '"' . " "; $i++; print(" Adding $filter, $image_url[$i]
"); } } // Create a unique filename and URL for the animated GIF output $anim_name = "anim".substr(strrchr($image_url[1], '/'),1); $anim_path = '"' . $amap->map->web->imagepath . $anim_name .'"'; $anim_url = $amap->map->web->imageurl . $anim_name; print("Creating $anim_path
"); $cmd = $anim_gif_cmd . " -o " . $anim_path . " " . $anim_files; print("Using: $cmd
"); system($cmd); # annotation layer LAYER NAME copyright STATUS ON TYPE annotation TRANSFORM false FEATURE POINTS 150 180 #this is the position of the text in image coordinates (pixels) END TEXT "From 2007/01/01 to 2007/06/30" #this is your displaying text END CLASS LABEL #defines the font, colors etc. of the text FONT "arial" TYPE TRUETYPE SIZE 10 BUFFER 1 COLOR 0 0 0 BACKGROUNDCOLOR 255 255 255 FORCE TRUE END END END Robert W. Burgholzer Surface Water Modeler Office of Water Supply and Planning Virginia Department of Environmental Quality rwburgholzer at deq.virginia.gov 804-698-4405 Open Source Modeling Tools: http://sourceforge.net/projects/npsource/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From jlacroix at MAPGEARS.COM Mon Jul 9 17:31:47 2007 From: jlacroix at MAPGEARS.COM (Julien-Samuel Lacroix) Date: Mon, 9 Jul 2007 20:31:47 -0400 Subject: Dynamic map annotation in animated GIF file In-Reply-To: <6C097DA58429B743A67070F98BE73A37025DD631@deqex01.deq.local> Message-ID: Hi, You are right. PHP/MapScript doesn't provide the TEXT portion of an annotation feature. It's because it's easier to add directly a point on the top of the map. Instead of adding a FEATURE object to the layer, simply create a point object and draw it on the map image. (Following code not tested) // Outside the loop create a pointObj $oPoint = ms_newPointObj(); $oPoint->setXY(1,1); [...snipp...] // Inside the foreach, draw your map without the copyright layer $thislayer->set("status",MS_OFF); $image[$i] = $amap->map->draw(); // Then draw the point on the top of it // Don't forget to remove the FEATURE object in the mapfile // Also you should give a name to your class in the copyright layer // For now, I'll use "CLASSNAME" $thislayer->set("status",MS_ON); $oPoint->draw($amap->map, $thislayer, $image[$i], "CLASSNAME", $filter); $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); [...snip...] The code is not tested, but it should give you a good idea. Julien Burgholzer,Robert wrote: > I am trying to produce a time series animated GIF, with an annotation at > the bottom of the map that shows the time. Thanks to an example from > Charlton Purvis found by a search of previous postings on making an > animated GIF (modified to use a single layer, changing the filter to > select for the data that is in my current time step): > > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0304/msg00482.html > > > > And a Wiki entry from Jeff McKenna about making a copyright notation: > > http://mapserver.gis.umn.edu/docs/faq/copyright-layer > > > > I have the basics, that is, an animated time series, with a statically > placed text entry at the bottom (at a map-specific point, rather than a > lat lon). However, the annotation layer can only display a single > entry, not one that is updated with the time step. I am wondering how > to do this, if I can modify the property of the annotation layer, or if > I need to create a point of some sort from a dynamic postgis call. I > can?t seem to set the TEXT portion of the feature via php mapscript. > > > > Anyone have any ideas? (code and mapfile follow) > > > > foreach ($gifmaps as $thismap) { > > $thislayer = $amap->map->getLayerByName('stream_stat'); > > $filter = " projectid = $projectid and thismetric = '$thismap' "; > > $listobject->querystring = " select count(*) as numrecs from > proj_group_stat "; > > $listobject->querystring .= " where $filter "; > > $listobject->performQuery(); > > $numrecs = $listobject->getRecordValue(1,'numrecs'); > > #$annotlayer = $amap->map->getLayerByName('copyright'); > > #$annotation = $annotlayer->getFeature(1,-1); > > if ($numrecs > 0) { > > $thislayer->setFilter($filter); > > $thislayer->set("status",MS_ON); > > #$annotation->set("TEXT", $filter); > > $image[$i] = $amap->map->draw(); > > $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); > > $file_path[$i] = $amap->map->web->imagepath > > . substr(strrchr($image_url[$i], "/"),1); > > $anim_files = $anim_files . '"' . $file_path[$i] . '"' . " "; > > $i++; > > print(" Adding $filter, $image_url[$i]
"); > > } > > } > > > > // Create a unique filename and URL for the animated GIF output > > $anim_name = "anim".substr(strrchr($image_url[1], '/'),1); > > $anim_path = '"' . $amap->map->web->imagepath . $anim_name .'"'; > > $anim_url = $amap->map->web->imageurl . $anim_name; > > > > print("Creating $anim_path
"); > > $cmd = $anim_gif_cmd . " -o " . $anim_path . " " . $anim_files; > > print("Using: $cmd
"); > > > > system($cmd); > > > > # annotation layer > > LAYER > > NAME copyright > > STATUS ON > > TYPE annotation > > TRANSFORM false > > FEATURE > > POINTS > > 150 180 #this is the position of the text in image coordinates > (pixels) > > END > > TEXT ?From 2007/01/01 to 2007/06/30" #this is your displaying text > > END > > CLASS > > LABEL #defines the font, colors etc. of the text > > FONT "arial" > > TYPE TRUETYPE > > SIZE 10 > > BUFFER 1 > > COLOR 0 0 0 > > BACKGROUNDCOLOR 255 255 255 > > FORCE TRUE > > END > > END > > END > > Robert W. Burgholzer > > Surface Water Modeler > > Office of Water Supply and Planning > > Virginia Department of Environmental Quality > > rwburgholzer at deq.virginia.gov > > 804-698-4405 > > Open Source Modeling Tools: > > http://sourceforge.net/projects/npsource/ > > > -- Julien-Samuel Lacroix Mapgears http://www.mapgears.com/ From bradleym06 at GMAIL.COM Mon Jul 9 18:11:47 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Tue, 10 Jul 2007 11:11:47 +1000 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: Message-ID: When I have the custom projection defined in my mapfile and the native projection defined for layers the map does not show up when doing a WMS getmap request, it just appears white. When I change it so that all layers have the custom projection, the map displays correctly from a WMS request but fails to display correctly in OpenLayers giving an SRS error. On 7/10/07, Ed McNierney wrote: > > Paul - > > Those parameters look good. There is obviously not a "standard" EPSG code > for this projection. > > Bradley, you need to decide whether you need to serve these WMS images out > to the wide world (i.e. clients over which you have no control) or only > use > them "internally" where you can control both your WMS server and the > client. > > If it's the former, you have a problem, as there is no EPSG code > describing > the projection you need that seems to be in general usage so your clients > can be expected to support it. If it's the latter, you're fine. You can > simply pick any number you like that's not already taken and add that line > to your EPSG file. It's just a text file. Let's assume you'll pick 41002 > (since 41001 seems to be in popular usage, but is wrong). Then you'd add > the single text line: > > <41002>+proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > To the EPSG files on your server and on each client. Then you can refer > to > it as SRS=EPSG:41002 in your WMS requests and you're all set. > > - Ed > > > From: Paul Spencer > > Date: Mon, 9 Jul 2007 14:55:22 -0400 > > To: Ed McNierney > > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > > > Thanks for the clarification Ed (and for fixing the cross-list- > > posting-bug :)). I just looked into this more and you are correct (I > > was completely wrong). From the site that Bradley quoted, they seem > > to think that the spherical projection is what is used by Google > > etc. The (unverified) proj.4 parameters for this seem to be: > > > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > > +b=6378137.0 +units=m > > > > Cheers > > > > Paul > > > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > > > >> Paul - > >> > >> This doesn't seem correct to me. You're suggesting a Transverse > >> Mercator > >> projection on an ellipsoid when the request was for a Mercator on a > >> sphere. > >> > >> I did a little Googling around and while it appears that the 41001 > >> projection is often referred to as "Transverse Mercator", and there > >> are > >> several references to the PROJ definition you mention (+proj=tmerc, > >> etc.), > >> there is a more sensible reference to 41001 being defined in a > >> GeoServer > >> install as: > >> > >> PROJCS["WGS84 / Simple Mercator", > >> GEOGCS["WGS 84", > >> DATUM["WGS_1984", > >> SPHEROID["WGS_1984", 6378137.0, 298.257223563]], > >> PRIMEM["Greenwich", 0.0], > >> UNIT["degree", 0.017453292519943295], > >> AXIS["Lon", EAST], > >> AXIS["Lat", NORTH]], > >> PROJECTION["Mercator_1SP"], > >> PARAMETER["central_meridian", 0.0], > >> PARAMETER["scale_factor", 1.0], > >> PARAMETER["false_easting", 0.0], > >> PARAMETER["false_northing", 0.0], > >> UNIT["m", 1.0], > >> AXIS["x", EAST], > >> AXIS["y", NORTH], > >> AUTHORITY["EPSG","41001"]] > >> > >> This is more sensible (at least it's a Mercator projection!) but it > >> is still > >> a ellipsoidal rather than spherical projection, so it's not quite > >> right. > >> > >> However, the entire universe of Web-based "geographic" projection > >> fans, > >> stimulated by Google and Microsoft, obviously don't really get > >> bothered when > >> their maps are "not quite right", so I should learn not to be so > >> fussy. > >> > >> - Ed > >> > >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, > >> since the > >> original cross-posting to both lists only complicates matters for > >> people > >> trying to help. > >> > >> > >>> From: Paul Spencer > >>> Reply-To: Paul Spencer > >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 > >>> To: > >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections > >>> > >>> You need what is commonly referred to as EPSG:41001, defined as: > >>> > >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> > >>> > >>> To use this, add the above line to your 'epsg' file and also add a > >>> projection object to your map object: > >>> > >>> PROJECTION > >>> "init=epsg:41001" > >>> END > >>> > >>> You will also need to make sure that every layer in your map file has > >>> a proper projection so mapserver can reproject it correctly. > >>> > >>> Cheers > >>> > >>> Paul > >>> > >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: > >>> > >>>> This is kind of hard to explain but what I want to do is use > >>>> Mapserver to project my data which is in the GDA94 projection as > >>>> shown below: > >>>> > >>>> "# GDA94 / MGA zone 55 > >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 > >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" > >>>> > >>>> to a projection that will be able to be properly merged with Google > >>>> maps (using OpenLayers) which uses a projection something like the > >>>> following: > >>>> > >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that > >>>> Google Maps and Virtual Earth use spherical equations for the > >>>> Mercator projection. The correct proj4 settings are: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +a=6378137.0 +b=6378137.0 +units=m > >>>> > >>>> Note this is different than using the ellipsoidal equations which > >>>> would be: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" > >>>> > >>>> I believe that I need to use Mapserver to do this but I have no > >>>> idea how to go about it. Currently my Mapserver is running fine > >>>> displaying the data correctly using the GDA94 projection except i > >>>> had to use a .vrt file to correctly align the raster image which > >>>> was slightly out of alignment. I have also set up and can call my > >>>> Mapserver as a WMS (thought having issues with the WMS Layer > >>>> function in OpenLayers, just displays a white screen but I believe > >>>> that this is to do with projections) > >>>> > >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP > >>>> and proj4. > >>>> > >>>> In my mapfile I have defined each layer using "init=epsg:28355" as > >>>> well as globally defining the map using the same projection. > >>>> > >>>> This reason I am trying to do this is because currently I don't > >>>> think that my projection can be properly imported into OpenLayers > >>>> and merged with Google Maps. > >>>> > >>>> Thanks > >>>> > >>>> Brad > >>> > >>> +-----------------------------------------------------------------+ > >>> |Paul Spencer pspencer at dmsolutions.ca | > >>> +-----------------------------------------------------------------+ > >>> |Chief Technology Officer | > >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | > >>> +-----------------------------------------------------------------+ > >> > > > > +-----------------------------------------------------------------+ > > |Paul Spencer pspencer at dmsolutions.ca | > > +-----------------------------------------------------------------+ > > |Chief Technology Officer | > > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > > +-----------------------------------------------------------------+ > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ed at TOPOZONE.COM Mon Jul 9 18:58:10 2007 From: ed at TOPOZONE.COM (Ed McNierney) Date: Mon, 9 Jul 2007 21:58:10 -0400 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: A Message-ID: Bradley - Don't just experiment with combinatorial testing - think about what you're trying to do, make sure you understand it, then be sure your map file and request do it. Since we've explained that whatever EPSG code you're using is not standard, you need to be sure that it is defined in both the server and all clients. Have you done that? Failure to do so would be an obvious cause of an "SRS error" from the client. Remember that when you change your map file output or your WMS request to a different SRS, you need to change the extent or BBOX parameters, too. In a WMS request the BBOX parameter always uses the units of the SRS used, so you can't just keep the same GDA94 coordinates and expect them to work. If you don't change them, you're requesting a Mercator output image at some random location that bears no relation to your input data, so it is quite likely to give you a white image (since no input data overlaps the requested map area). - Ed From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Bradley Mclain Sent: Monday, July 09, 2007 9:12 PM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections When I have the custom projection defined in my mapfile and the native projection defined for layers the map does not show up when doing a WMS getmap request, it just appears white. When I change it so that all layers have the custom projection, the map displays correctly from a WMS request but fails to display correctly in OpenLayers giving an SRS error. On 7/10/07, Ed McNierney wrote: Paul - Those parameters look good. There is obviously not a "standard" EPSG code for this projection. Bradley, you need to decide whether you need to serve these WMS images out to the wide world ( i.e. clients over which you have no control) or only use them "internally" where you can control both your WMS server and the client. If it's the former, you have a problem, as there is no EPSG code describing the projection you need that seems to be in general usage so your clients can be expected to support it. If it's the latter, you're fine. You can simply pick any number you like that's not already taken and add that line to your EPSG file. It's just a text file. Let's assume you'll pick 41002 (since 41001 seems to be in popular usage, but is wrong). Then you'd add the single text line: <41002>+proj=merc +lat_ts=0 +lon_0=0 +k= 1.0 +x_0=0 +y_0=0 +a=6378137.0 +b=6378137.0 +units=m To the EPSG files on your server and on each client. Then you can refer to it as SRS=EPSG:41002 in your WMS requests and you're all set. - Ed > From: Paul Spencer > Date: Mon, 9 Jul 2007 14:55:22 -0400 > To: Ed McNierney > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > Thanks for the clarification Ed (and for fixing the cross-list- > posting-bug :)). I just looked into this more and you are correct (I > was completely wrong). From the site that Bradley quoted, they seem > to think that the spherical projection is what is used by Google > etc. The (unverified) proj.4 parameters for this seem to be: > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > Cheers > > Paul > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > >> Paul - >> >> This doesn't seem correct to me. You're suggesting a Transverse >> Mercator >> projection on an ellipsoid when the request was for a Mercator on a >> sphere. >> >> I did a little Googling around and while it appears that the 41001 >> projection is often referred to as "Transverse Mercator", and there >> are >> several references to the PROJ definition you mention (+proj=tmerc, >> etc.), >> there is a more sensible reference to 41001 being defined in a >> GeoServer >> install as: >> >> PROJCS["WGS84 / Simple Mercator", >> GEOGCS["WGS 84", >> DATUM["WGS_1984", >> SPHEROID["WGS_1984", 6378137.0, 298.257223563 ]], >> PRIMEM["Greenwich", 0.0], >> UNIT["degree", 0.017453292519943295], >> AXIS["Lon", EAST], >> AXIS["Lat", NORTH]], >> PROJECTION["Mercator_1SP"], >> PARAMETER["central_meridian", 0.0], >> PARAMETER["scale_factor", 1.0], >> PARAMETER["false_easting", 0.0], >> PARAMETER["false_northing", 0.0], >> UNIT["m", 1.0], >> AXIS["x", EAST], >> AXIS["y", NORTH], >> AUTHORITY["EPSG","41001"]] >> >> This is more sensible (at least it's a Mercator projection!) but it >> is still >> a ellipsoidal rather than spherical projection, so it's not quite >> right. >> >> However, the entire universe of Web-based "geographic" projection >> fans, >> stimulated by Google and Microsoft, obviously don't really get >> bothered when >> their maps are "not quite right", so I should learn not to be so >> fussy. >> >> - Ed >> >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, >> since the >> original cross-posting to both lists only complicates matters for >> people >> trying to help. >> >> >>> From: Paul Spencer >>> Reply-To: Paul Spencer < pspencer at DMSOLUTIONS.CA> >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 >>> To: >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections >>> >>> You need what is commonly referred to as EPSG:41001, defined as: >>> >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> >>> >>> To use this, add the above line to your 'epsg' file and also add a >>> projection object to your map object: >>> >>> PROJECTION >>> "init=epsg:41001" >>> END >>> >>> You will also need to make sure that every layer in your map file has >>> a proper projection so mapserver can reproject it correctly. >>> >>> Cheers >>> >>> Paul >>> >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: >>> >>>> This is kind of hard to explain but what I want to do is use >>>> Mapserver to project my data which is in the GDA94 projection as >>>> shown below: >>>> >>>> "# GDA94 / MGA zone 55 >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" >>>> >>>> to a projection that will be able to be properly merged with Google >>>> maps (using OpenLayers) which uses a projection something like the >>>> following: >>>> >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that >>>> Google Maps and Virtual Earth use spherical equations for the >>>> Mercator projection. The correct proj4 settings are: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +a=6378137.0 +b=6378137.0 +units=m >>>> >>>> Note this is different than using the ellipsoidal equations which >>>> would be: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" >>>> >>>> I believe that I need to use Mapserver to do this but I have no >>>> idea how to go about it. Currently my Mapserver is running fine >>>> displaying the data correctly using the GDA94 projection except i >>>> had to use a .vrt file to correctly align the raster image which >>>> was slightly out of alignment. I have also set up and can call my >>>> Mapserver as a WMS (thought having issues with the WMS Layer >>>> function in OpenLayers, just displays a white screen but I believe >>>> that this is to do with projections) >>>> >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP >>>> and proj4. >>>> >>>> In my mapfile I have defined each layer using "init=epsg:28355" as >>>> well as globally defining the map using the same projection. >>>> >>>> This reason I am trying to do this is because currently I don't >>>> think that my projection can be properly imported into OpenLayers >>>> and merged with Google Maps. >>>> >>>> Thanks >>>> >>>> Brad >>> >>> +-----------------------------------------------------------------+ >>> |Paul Spencer pspencer at dmsolutions.ca | >>> +-----------------------------------------------------------------+ >>> |Chief Technology Officer | >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | >>> +-----------------------------------------------------------------+ >> > > +-----------------------------------------------------------------+ > |Paul Spencer pspencer at dmsolutions.ca | > +-----------------------------------------------------------------+ > |Chief Technology Officer | > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > +-----------------------------------------------------------------+ > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bradleym06 at GMAIL.COM Mon Jul 9 19:11:26 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Tue, 10 Jul 2007 12:11:26 +1000 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: <4BF377919225F449BB097CB76FFE9BC80198823C@ptolemy.topozone.com> Message-ID: Being defined by server and clients at the moment shouldn't be an issue because I am testing off the server at the moment which I have updated the proj epsg file. Is this correct have I correctly understood this concept? How do I get the correct extent for this new projection I have absolutely now idea how to do it? I'm not using bbox so this shouldn't be a problem. On 7/10/07, Ed McNierney wrote: > > Bradley ? > > > > Don't just experiment with combinatorial testing ? think about what you're > trying to do, make sure you understand it, then be sure your map file and > request do it. Since we've explained that whatever EPSG code you're using > is not standard, you need to be sure that it is defined in both the server > and all clients. Have you done that? Failure to do so would be an obvious > cause of an "SRS error" from the client. > > > > Remember that when you change your map file output or your WMS request to > a different SRS, you need to change the extent or BBOX parameters, too. In > a WMS request the BBOX parameter always uses the units of the SRS used, so > you can't just keep the same GDA94 coordinates and expect them to work. If > you don't change them, you're requesting a Mercator output image at some > random location that bears no relation to your input data, so it is quite > likely to give you a white image (since no input data overlaps the requested > map area). > > > > - Ed > > > > *From:* UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] *On > Behalf Of *Bradley Mclain > *Sent:* Monday, July 09, 2007 9:12 PM > *To:* MAPSERVER-USERS at LISTS.UMN.EDU > *Subject:* Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections > > > > When I have the custom projection defined in my mapfile and the native > projection defined for layers the map does not show up when doing a WMS > getmap request, it just appears white. > > When I change it so that all layers have the custom projection, the map > displays correctly from a WMS request but fails to display correctly in > OpenLayers giving an SRS error. > > On 7/10/07, *Ed McNierney* wrote: > > Paul - > > Those parameters look good. There is obviously not a "standard" EPSG code > for this projection. > > Bradley, you need to decide whether you need to serve these WMS images out > to the wide world ( i.e. clients over which you have no control) or only > use > them "internally" where you can control both your WMS server and the > client. > > If it's the former, you have a problem, as there is no EPSG code > describing > the projection you need that seems to be in general usage so your clients > can be expected to support it. If it's the latter, you're fine. You can > simply pick any number you like that's not already taken and add that line > > to your EPSG file. It's just a text file. Let's assume you'll pick 41002 > (since 41001 seems to be in popular usage, but is wrong). Then you'd add > the single text line: > > <41002>+proj=merc +lat_ts=0 +lon_0=0 +k= 1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > To the EPSG files on your server and on each client. Then you can refer > to > it as SRS=EPSG:41002 in your WMS requests and you're all set. > > - Ed > > > From: Paul Spencer > > Date: Mon, 9 Jul 2007 14:55:22 -0400 > > To: Ed McNierney > > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > > > Thanks for the clarification Ed (and for fixing the cross-list- > > posting-bug :)). I just looked into this more and you are correct (I > > was completely wrong). From the site that Bradley quoted, they seem > > to think that the spherical projection is what is used by Google > > etc. The (unverified) proj.4 parameters for this seem to be: > > > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > > +b=6378137.0 +units=m > > > > Cheers > > > > Paul > > > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > > > >> Paul - > >> > >> This doesn't seem correct to me. You're suggesting a Transverse > >> Mercator > >> projection on an ellipsoid when the request was for a Mercator on a > >> sphere. > >> > >> I did a little Googling around and while it appears that the 41001 > >> projection is often referred to as "Transverse Mercator", and there > >> are > >> several references to the PROJ definition you mention (+proj=tmerc, > >> etc.), > >> there is a more sensible reference to 41001 being defined in a > >> GeoServer > >> install as: > >> > >> PROJCS["WGS84 / Simple Mercator", > >> GEOGCS["WGS 84", > >> DATUM["WGS_1984", > >> SPHEROID["WGS_1984", 6378137.0, 298.257223563 ]], > >> PRIMEM["Greenwich", 0.0], > >> UNIT["degree", 0.017453292519943295], > >> AXIS["Lon", EAST], > >> AXIS["Lat", NORTH]], > >> PROJECTION["Mercator_1SP"], > >> PARAMETER["central_meridian", 0.0], > >> PARAMETER["scale_factor", 1.0], > >> PARAMETER["false_easting", 0.0], > >> PARAMETER["false_northing", 0.0], > >> UNIT["m", 1.0], > >> AXIS["x", EAST], > >> AXIS["y", NORTH], > >> AUTHORITY["EPSG","41001"]] > >> > >> This is more sensible (at least it's a Mercator projection!) but it > >> is still > >> a ellipsoidal rather than spherical projection, so it's not quite > >> right. > >> > >> However, the entire universe of Web-based "geographic" projection > >> fans, > >> stimulated by Google and Microsoft, obviously don't really get > >> bothered when > >> their maps are "not quite right", so I should learn not to be so > >> fussy. > >> > >> - Ed > >> > >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, > >> since the > >> original cross-posting to both lists only complicates matters for > >> people > >> trying to help. > >> > >> > >>> From: Paul Spencer > >>> Reply-To: Paul Spencer < pspencer at DMSOLUTIONS.CA> > >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 > >>> To: > >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections > >>> > >>> You need what is commonly referred to as EPSG:41001, defined as: > >>> > >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> > >>> > >>> To use this, add the above line to your 'epsg' file and also add a > >>> projection object to your map object: > >>> > >>> PROJECTION > >>> "init=epsg:41001" > >>> END > >>> > >>> You will also need to make sure that every layer in your map file has > >>> a proper projection so mapserver can reproject it correctly. > >>> > >>> Cheers > >>> > >>> Paul > >>> > >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: > >>> > >>>> This is kind of hard to explain but what I want to do is use > >>>> Mapserver to project my data which is in the GDA94 projection as > >>>> shown below: > >>>> > >>>> "# GDA94 / MGA zone 55 > >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 > >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" > >>>> > >>>> to a projection that will be able to be properly merged with Google > >>>> maps (using OpenLayers) which uses a projection something like the > >>>> following: > >>>> > >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that > >>>> Google Maps and Virtual Earth use spherical equations for the > >>>> Mercator projection. The correct proj4 settings are: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +a=6378137.0 +b=6378137.0 +units=m > >>>> > >>>> Note this is different than using the ellipsoidal equations which > >>>> would be: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" > >>>> > >>>> I believe that I need to use Mapserver to do this but I have no > >>>> idea how to go about it. Currently my Mapserver is running fine > >>>> displaying the data correctly using the GDA94 projection except i > >>>> had to use a .vrt file to correctly align the raster image which > >>>> was slightly out of alignment. I have also set up and can call my > >>>> Mapserver as a WMS (thought having issues with the WMS Layer > >>>> function in OpenLayers, just displays a white screen but I believe > >>>> that this is to do with projections) > >>>> > >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP > >>>> and proj4. > >>>> > >>>> In my mapfile I have defined each layer using "init=epsg:28355" as > >>>> well as globally defining the map using the same projection. > >>>> > >>>> This reason I am trying to do this is because currently I don't > >>>> think that my projection can be properly imported into OpenLayers > >>>> and merged with Google Maps. > >>>> > >>>> Thanks > >>>> > >>>> Brad > >>> > >>> +-----------------------------------------------------------------+ > >>> |Paul Spencer pspencer at dmsolutions.ca | > >>> +-----------------------------------------------------------------+ > >>> |Chief Technology Officer | > >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | > >>> +-----------------------------------------------------------------+ > >> > > > > +-----------------------------------------------------------------+ > > |Paul Spencer pspencer at dmsolutions.ca | > > +-----------------------------------------------------------------+ > > |Chief Technology Officer | > > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > > +-----------------------------------------------------------------+ > > > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ed at TOPOZONE.COM Mon Jul 9 19:32:45 2007 From: ed at TOPOZONE.COM (Ed McNierney) Date: Mon, 9 Jul 2007 22:32:45 -0400 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: Message-ID: Bradley - BBOX is a required WMS parameter, so you must be using it. You have to be able to express the geographic extents of your area of interest in the units used by your desired map projection. Otherwise there's no way you can know what you're asking for. I don't use OpenLayers and can't help you on its configuration, but you can use the PROJ command-line tools to reproject individual coordinate pairs from your input to your output projections so you can calculate a starting bounding box for your map. - Ed From: Bradley Mclain [mailto:bradleym06 at gmail.com] Sent: Monday, July 09, 2007 10:11 PM To: Ed McNierney Cc: MAPSERVER-USERS at lists.umn.edu Subject: Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections Being defined by server and clients at the moment shouldn't be an issue because I am testing off the server at the moment which I have updated the proj epsg file. Is this correct have I correctly understood this concept? How do I get the correct extent for this new projection I have absolutely now idea how to do it? I'm not using bbox so this shouldn't be a problem. On 7/10/07, Ed McNierney wrote: Bradley - Don't just experiment with combinatorial testing - think about what you're trying to do, make sure you understand it, then be sure your map file and request do it. Since we've explained that whatever EPSG code you're using is not standard, you need to be sure that it is defined in both the server and all clients. Have you done that? Failure to do so would be an obvious cause of an "SRS error" from the client. Remember that when you change your map file output or your WMS request to a different SRS, you need to change the extent or BBOX parameters, too. In a WMS request the BBOX parameter always uses the units of the SRS used, so you can't just keep the same GDA94 coordinates and expect them to work. If you don't change them, you're requesting a Mercator output image at some random location that bears no relation to your input data, so it is quite likely to give you a white image (since no input data overlaps the requested map area). - Ed From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Bradley Mclain Sent: Monday, July 09, 2007 9:12 PM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections When I have the custom projection defined in my mapfile and the native projection defined for layers the map does not show up when doing a WMS getmap request, it just appears white. When I change it so that all layers have the custom projection, the map displays correctly from a WMS request but fails to display correctly in OpenLayers giving an SRS error. On 7/10/07, Ed McNierney wrote: Paul - Those parameters look good. There is obviously not a "standard" EPSG code for this projection. Bradley, you need to decide whether you need to serve these WMS images out to the wide world ( i.e. clients over which you have no control) or only use them "internally" where you can control both your WMS server and the client. If it's the former, you have a problem, as there is no EPSG code describing the projection you need that seems to be in general usage so your clients can be expected to support it. If it's the latter, you're fine. You can simply pick any number you like that's not already taken and add that line to your EPSG file. It's just a text file. Let's assume you'll pick 41002 (since 41001 seems to be in popular usage, but is wrong). Then you'd add the single text line: <41002>+proj=merc +lat_ts=0 +lon_0=0 +k= 1.0 +x_0=0 +y_0=0 +a=6378137.0 +b=6378137.0 +units=m To the EPSG files on your server and on each client. Then you can refer to it as SRS=EPSG:41002 in your WMS requests and you're all set. - Ed > From: Paul Spencer > Date: Mon, 9 Jul 2007 14:55:22 -0400 > To: Ed McNierney > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > Thanks for the clarification Ed (and for fixing the cross-list- > posting-bug :)). I just looked into this more and you are correct (I > was completely wrong). From the site that Bradley quoted, they seem > to think that the spherical projection is what is used by Google > etc. The (unverified) proj.4 parameters for this seem to be: > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > Cheers > > Paul > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > >> Paul - >> >> This doesn't seem correct to me. You're suggesting a Transverse >> Mercator >> projection on an ellipsoid when the request was for a Mercator on a >> sphere. >> >> I did a little Googling around and while it appears that the 41001 >> projection is often referred to as "Transverse Mercator", and there >> are >> several references to the PROJ definition you mention (+proj=tmerc, >> etc.), >> there is a more sensible reference to 41001 being defined in a >> GeoServer >> install as: >> >> PROJCS["WGS84 / Simple Mercator", >> GEOGCS["WGS 84", >> DATUM["WGS_1984", >> SPHEROID["WGS_1984", 6378137.0, 298.257223563 ]], >> PRIMEM["Greenwich", 0.0], >> UNIT["degree", 0.017453292519943295], >> AXIS["Lon", EAST], >> AXIS["Lat", NORTH]], >> PROJECTION["Mercator_1SP"], >> PARAMETER["central_meridian", 0.0], >> PARAMETER["scale_factor", 1.0], >> PARAMETER["false_easting", 0.0], >> PARAMETER["false_northing", 0.0], >> UNIT["m", 1.0], >> AXIS["x", EAST], >> AXIS["y", NORTH], >> AUTHORITY["EPSG","41001"]] >> >> This is more sensible (at least it's a Mercator projection!) but it >> is still >> a ellipsoidal rather than spherical projection, so it's not quite >> right. >> >> However, the entire universe of Web-based "geographic" projection >> fans, >> stimulated by Google and Microsoft, obviously don't really get >> bothered when >> their maps are "not quite right", so I should learn not to be so >> fussy. >> >> - Ed >> >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, >> since the >> original cross-posting to both lists only complicates matters for >> people >> trying to help. >> >> >>> From: Paul Spencer >>> Reply-To: Paul Spencer < pspencer at DMSOLUTIONS.CA> >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 >>> To: >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections >>> >>> You need what is commonly referred to as EPSG:41001, defined as: >>> >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> >>> >>> To use this, add the above line to your 'epsg' file and also add a >>> projection object to your map object: >>> >>> PROJECTION >>> "init=epsg:41001" >>> END >>> >>> You will also need to make sure that every layer in your map file has >>> a proper projection so mapserver can reproject it correctly. >>> >>> Cheers >>> >>> Paul >>> >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: >>> >>>> This is kind of hard to explain but what I want to do is use >>>> Mapserver to project my data which is in the GDA94 projection as >>>> shown below: >>>> >>>> "# GDA94 / MGA zone 55 >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" >>>> >>>> to a projection that will be able to be properly merged with Google >>>> maps (using OpenLayers) which uses a projection something like the >>>> following: >>>> >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that >>>> Google Maps and Virtual Earth use spherical equations for the >>>> Mercator projection. The correct proj4 settings are: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +a=6378137.0 +b=6378137.0 +units=m >>>> >>>> Note this is different than using the ellipsoidal equations which >>>> would be: >>>> >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" >>>> >>>> I believe that I need to use Mapserver to do this but I have no >>>> idea how to go about it. Currently my Mapserver is running fine >>>> displaying the data correctly using the GDA94 projection except i >>>> had to use a .vrt file to correctly align the raster image which >>>> was slightly out of alignment. I have also set up and can call my >>>> Mapserver as a WMS (thought having issues with the WMS Layer >>>> function in OpenLayers, just displays a white screen but I believe >>>> that this is to do with projections) >>>> >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP >>>> and proj4. >>>> >>>> In my mapfile I have defined each layer using "init=epsg:28355" as >>>> well as globally defining the map using the same projection. >>>> >>>> This reason I am trying to do this is because currently I don't >>>> think that my projection can be properly imported into OpenLayers >>>> and merged with Google Maps. >>>> >>>> Thanks >>>> >>>> Brad >>> >>> +-----------------------------------------------------------------+ >>> |Paul Spencer pspencer at dmsolutions.ca | >>> +-----------------------------------------------------------------+ >>> |Chief Technology Officer | >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | >>> +-----------------------------------------------------------------+ >> > > +-----------------------------------------------------------------+ > |Paul Spencer pspencer at dmsolutions.ca | > +-----------------------------------------------------------------+ > |Chief Technology Officer | > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > +-----------------------------------------------------------------+ > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bradleym06 at GMAIL.COM Mon Jul 9 23:41:09 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Tue, 10 Jul 2007 16:41:09 +1000 Subject: [UMN_MAPSERVER-DEV] Projections In-Reply-To: <4BF377919225F449BB097CB76FFE9BC80198823F@ptolemy.topozone.com> Message-ID: Any tips on how to do this? I've looked through0 the proj manual but I'm a bit unsure how to go about it. On 7/10/07, Ed McNierney wrote: > > Bradley ? > > > > BBOX is a required WMS parameter, so you must be using it. > > > > You have to be able to express the geographic extents of your area of > interest in the units used by your desired map projection. Otherwise > there's no way you can know what you're asking for. I don't use OpenLayers > and can't help you on its configuration, but you can use the PROJ > command-line tools to reproject individual coordinate pairs from your input > to your output projections so you can calculate a starting bounding box for > your map. > > > > - Ed > > > > *From:* Bradley Mclain [mailto:bradleym06 at gmail.com] > *Sent:* Monday, July 09, 2007 10:11 PM > *To:* Ed McNierney > *Cc:* MAPSERVER-USERS at lists.umn.edu > *Subject:* Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections > > > > Being defined by server and clients at the moment shouldn't be an issue > because I am testing off the server at the moment which I have updated the > proj epsg file. Is this correct have I correctly understood this concept? > > How do I get the correct extent for this new projection I have absolutely > now idea how to do it? I'm not using bbox so this shouldn't be a problem. > > On 7/10/07, *Ed McNierney* wrote: > > Bradley ? > > > > Don't just experiment with combinatorial testing ? think about what you're > trying to do, make sure you understand it, then be sure your map file and > request do it. Since we've explained that whatever EPSG code you're using > is not standard, you need to be sure that it is defined in both the server > and all clients. Have you done that? Failure to do so would be an obvious > cause of an "SRS error" from the client. > > > > Remember that when you change your map file output or your WMS request to > a different SRS, you need to change the extent or BBOX parameters, too. In > a WMS request the BBOX parameter always uses the units of the SRS used, so > you can't just keep the same GDA94 coordinates and expect them to work. If > you don't change them, you're requesting a Mercator output image at some > random location that bears no relation to your input data, so it is quite > likely to give you a white image (since no input data overlaps the requested > map area). > > > > - Ed > > > > *From:* UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] *On > Behalf Of *Bradley Mclain > *Sent:* Monday, July 09, 2007 9:12 PM > *To:* MAPSERVER-USERS at LISTS.UMN.EDU > *Subject:* Re: [UMN_MAPSERVER-USERS] [UMN_MAPSERVER-DEV] Projections > > > > When I have the custom projection defined in my mapfile and the native > projection defined for layers the map does not show up when doing a WMS > getmap request, it just appears white. > > When I change it so that all layers have the custom projection, the map > displays correctly from a WMS request but fails to display correctly in > OpenLayers giving an SRS error. > > On 7/10/07, *Ed McNierney* wrote: > > Paul - > > Those parameters look good. There is obviously not a "standard" EPSG code > for this projection. > > Bradley, you need to decide whether you need to serve these WMS images out > to the wide world ( i.e. clients over which you have no control) or only > use > them "internally" where you can control both your WMS server and the > client. > > If it's the former, you have a problem, as there is no EPSG code > describing > the projection you need that seems to be in general usage so your clients > can be expected to support it. If it's the latter, you're fine. You can > simply pick any number you like that's not already taken and add that line > > to your EPSG file. It's just a text file. Let's assume you'll pick 41002 > (since 41001 seems to be in popular usage, but is wrong). Then you'd add > the single text line: > > <41002>+proj=merc +lat_ts=0 +lon_0=0 +k= 1.0 +x_0=0 +y_0=0 +a=6378137.0 > +b=6378137.0 +units=m > > To the EPSG files on your server and on each client. Then you can refer > to > it as SRS=EPSG:41002 in your WMS requests and you're all set. > > - Ed > > > From: Paul Spencer > > Date: Mon, 9 Jul 2007 14:55:22 -0400 > > To: Ed McNierney > > Cc: "MAPSERVER-USERS at LISTS.UMN.EDU" > > Subject: Re: [UMN_MAPSERVER-DEV] Projections > > > > Thanks for the clarification Ed (and for fixing the cross-list- > > posting-bug :)). I just looked into this more and you are correct (I > > was completely wrong). From the site that Bradley quoted, they seem > > to think that the spherical projection is what is used by Google > > etc. The (unverified) proj.4 parameters for this seem to be: > > > > +proj=merc +lat_ts=0 +lon_0=0 +k=1.0 +x_0=0 +y_0=0 +a=6378137.0 > > +b=6378137.0 +units=m > > > > Cheers > > > > Paul > > > > On 9-Jul-07, at 2:06 PM, Ed McNierney wrote: > > > >> Paul - > >> > >> This doesn't seem correct to me. You're suggesting a Transverse > >> Mercator > >> projection on an ellipsoid when the request was for a Mercator on a > >> sphere. > >> > >> I did a little Googling around and while it appears that the 41001 > >> projection is often referred to as "Transverse Mercator", and there > >> are > >> several references to the PROJ definition you mention (+proj=tmerc, > >> etc.), > >> there is a more sensible reference to 41001 being defined in a > >> GeoServer > >> install as: > >> > >> PROJCS["WGS84 / Simple Mercator", > >> GEOGCS["WGS 84", > >> DATUM["WGS_1984", > >> SPHEROID["WGS_1984", 6378137.0, 298.257223563 ]], > >> PRIMEM["Greenwich", 0.0], > >> UNIT["degree", 0.017453292519943295], > >> AXIS["Lon", EAST], > >> AXIS["Lat", NORTH]], > >> PROJECTION["Mercator_1SP"], > >> PARAMETER["central_meridian", 0.0], > >> PARAMETER["scale_factor", 1.0], > >> PARAMETER["false_easting", 0.0], > >> PARAMETER["false_northing", 0.0], > >> UNIT["m", 1.0], > >> AXIS["x", EAST], > >> AXIS["y", NORTH], > >> AUTHORITY["EPSG","41001"]] > >> > >> This is more sensible (at least it's a Mercator projection!) but it > >> is still > >> a ellipsoidal rather than spherical projection, so it's not quite > >> right. > >> > >> However, the entire universe of Web-based "geographic" projection > >> fans, > >> stimulated by Google and Microsoft, obviously don't really get > >> bothered when > >> their maps are "not quite right", so I should learn not to be so > >> fussy. > >> > >> - Ed > >> > >> P.S. I modified the reply to go only to the MAPSERVER-USERS list, > >> since the > >> original cross-posting to both lists only complicates matters for > >> people > >> trying to help. > >> > >> > >>> From: Paul Spencer > >>> Reply-To: Paul Spencer < pspencer at DMSOLUTIONS.CA> > >>> Date: Sun, 8 Jul 2007 22:17:03 -0400 > >>> To: > >>> Subject: Re: [UMN_MAPSERVER-DEV] Projections > >>> > >>> You need what is commonly referred to as EPSG:41001, defined as: > >>> > >>> <41001> +proj=tmerc +ellps=WGS84 +units=m +no_defs <> > >>> > >>> To use this, add the above line to your 'epsg' file and also add a > >>> projection object to your map object: > >>> > >>> PROJECTION > >>> "init=epsg:41001" > >>> END > >>> > >>> You will also need to make sure that every layer in your map file has > >>> a proper projection so mapserver can reproject it correctly. > >>> > >>> Cheers > >>> > >>> Paul > >>> > >>> On 8-Jul-07, at 9:44 PM, Bradley Mclain wrote: > >>> > >>>> This is kind of hard to explain but what I want to do is use > >>>> Mapserver to project my data which is in the GDA94 projection as > >>>> shown below: > >>>> > >>>> "# GDA94 / MGA zone 55 > >>>> <28355> +proj=utm +zone=55 +south +ellps=GRS80 > >>>> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>" > >>>> > >>>> to a projection that will be able to be properly merged with Google > >>>> maps (using OpenLayers) which uses a projection something like the > >>>> following: > >>>> > >>>> "Update 4: Agreement frrom Melita Kennedy and David Burrows that > >>>> Google Maps and Virtual Earth use spherical equations for the > >>>> Mercator projection. The correct proj4 settings are: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +a=6378137.0 +b=6378137.0 +units=m > >>>> > >>>> Note this is different than using the ellipsoidal equations which > >>>> would be: > >>>> > >>>> +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 > >>>> +ellps=WGS84 +datum=WGS84 +units=m no_defs" > >>>> > >>>> I believe that I need to use Mapserver to do this but I have no > >>>> idea how to go about it. Currently my Mapserver is running fine > >>>> displaying the data correctly using the GDA94 projection except i > >>>> had to use a .vrt file to correctly align the raster image which > >>>> was slightly out of alignment. I have also set up and can call my > >>>> Mapserver as a WMS (thought having issues with the WMS Layer > >>>> function in OpenLayers, just displays a white screen but I believe > >>>> that this is to do with projections) > >>>> > >>>> My Mapserver has been compiled with GD, GDAL, GEOS, PostGIS, PHP > >>>> and proj4. > >>>> > >>>> In my mapfile I have defined each layer using "init=epsg:28355" as > >>>> well as globally defining the map using the same projection. > >>>> > >>>> This reason I am trying to do this is because currently I don't > >>>> think that my projection can be properly imported into OpenLayers > >>>> and merged with Google Maps. > >>>> > >>>> Thanks > >>>> > >>>> Brad > >>> > >>> +-----------------------------------------------------------------+ > >>> |Paul Spencer pspencer at dmsolutions.ca | > >>> +-----------------------------------------------------------------+ > >>> |Chief Technology Officer | > >>> |DM Solutions Group Inc http://www.dmsolutions.ca/ | > >>> +-----------------------------------------------------------------+ > >> > > > > +-----------------------------------------------------------------+ > > |Paul Spencer pspencer at dmsolutions.ca | > > +-----------------------------------------------------------------+ > > |Chief Technology Officer | > > |DM Solutions Group Inc http://www.dmsolutions.ca/ | > > +-----------------------------------------------------------------+ > > > > > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mizerkin at WIRZ-KOELN.DE Tue Jul 10 00:24:40 2007 From: mizerkin at WIRZ-KOELN.DE (Dmitri Mizerkin) Date: Tue, 10 Jul 2007 02:24:40 -0500 Subject: OGC-Filter in GetFeature request Message-ID: Hi list, I'm trying to send a WFS GetFeature request to the Mapserver, applying a ogc-filter on the features to be included in the response. Though, I get an error message in the response stating "msWFSGetFeature(): WFS server error. Invalid or Unsupported FILTER in GetFeature". My request is: http://localhost:8080/cgi-bin/mapserv.exe?map=/ms4w/apps/Avenida/htdocs/Avenida.map&layers=Achse&REQUEST=GetFeature&SERVICE=WFS&VERSION=1.0.0&BBOX=2574985.815002%2C5643233.501443%2C2587295.900005%2C5658111.118461&TYPENAME=ms:Achse&MAXFEATURES=10&FILTER= Has anybody an idea what could be wrong? Cheers, Dmitri Mizerkin From adams at TERRESTRIS.DE Tue Jul 10 02:01:30 2007 From: adams at TERRESTRIS.DE (Till Adams) Date: Tue, 10 Jul 2007 11:01:30 +0200 Subject: wfs getfeature on oracle layer In-Reply-To: Message-ID: Dear list, is there a known issue getting features out of oracle per wfs-getfeatue request? I have a working wfs, the getcapabilities works fine. I use mapserver 4.10. If I use a shapefile as datasource and then request with "GetFeature", I get a valid GML, if I change the datasource to an oracle (non-spatial, only locator) layer, I get no objects, just sth. including minx,miny,maxx,maxy I read about the wfs-server documentation and deleted all projection entrys for this layer. If I request the same layer with a wms getmap request, I see objects. If I use the same bbox in my getfeature request, I just get the above described xml. Is there a known problem as oracle uses its own internal sird (82032) ? I think the wfs is allright and only the requested bbox is wrong. Did anyone have the same problem before? Regards, Till -- ***************************************** terrestris ist umgezogen! Die neue Adresse ab 01.07.2007 lautet: Irmintrudisstra?e 17, 53111 Bonn http://www.terrestris.de ***************************************** ---------------------------------------------------------- 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 mlinden at ZEELANDNET.NL Tue Jul 10 04:05:12 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Tue, 10 Jul 2007 13:05:12 +0200 Subject: Hide and show city labels depending on population Message-ID: Hello list, I have been puzzling a bit and am not finding the correct answer. I have a city mapinfo tab that holds population values. I want to display: - The labels of the major cities when zoomed out far, - add the labels of medium cities when I zoom in further - show all labels when zoomed in max Currently my syntax in the mapfile is as below, but I can't get a map that shows only the labels of the major cities! Any help is appreciated LABELITEM 'City' CLASSITEM 'City_Population' CLASS NAME '0 < City_Population < 100000' EXPRESSION ( ([City_Population] >= 0) AND ([City_Population] <= 100000) ) STYLE SYMBOL 'CIRCLE' SIZE 3 OUTLINECOLOR 0 0 0 COLOR 255 170 0 END LABEL TYPE TRUETYPE FONT Arial SIZE 8 COLOR 255 255 250 #OUTLINECOLOR 255 255 255 ANTIALIAS TRUE MINFEATURESIZE 500 ANGLE 0 FORCE false END END CLASS NAME '100001 < City_Population < 500000' EXPRESSION ( ([City_Population] >= 100001) AND ([City_Population] <= 500000) ) STYLE SYMBOL 'CIRCLE' SIZE 4 OUTLINECOLOR 0 0 0 COLOR 255 170 0 END LABEL TYPE TRUETYPE FONT Arial SIZE 10 COLOR 255 255 250 #OUTLINECOLOR 255 255 255 ANTIALIAS TRUE MINFEATURESIZE 500 ANGLE 0 FORCE false END END -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 250 bytes Desc: OpenPGP digital signature URL: From Tom.Kralidis at EC.GC.CA Tue Jul 10 04:24:42 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Tue, 10 Jul 2007 07:24:42 -0400 Subject: OGC-Filter in GetFeature request In-Reply-To: A Message-ID: > I'm trying to send a WFS GetFeature request to the Mapserver, > applying a ogc-filter on the features to be included in the > response. Though, I get an error message in the response > stating "msWFSGetFeature(): WFS server error. > Invalid or Unsupported FILTER in GetFeature". > > My request is: > http://localhost:8080/cgi-bin/mapserv.exe?map=/ms4w/apps/Aveni da/htdocs/Avenida.map&layers=Achse&REQUEST=GetFeature&SERVICE=WFS&VERSIO N=1.0.0&BBOX=2574985.815002%2C5643233.501443%> 2C2587295.900005%2C5658111.118461&TYPENAME=ms:Achse&MAXFEATURE > S=10&FILTER= mn.edu/mapserver"%20xmlns:wfs="http://www.opengis.net/wfs"%20x > mlns:gml="http://www.opengis.net/gml"%20xmlns:ogc="http://www. > opengis.net/ogc"%20xmlns:xsi="http://www.w3.org/2001/XMLSchema > -instance"%20xsi:schemaLocation="http://www.opengis.net/wfs%20 > http://schemas.opengis.net/wfs/1.0.0/WFS-basic.xsd%20http://ma > pserver.gis.umn.edu/mapserver"> "/> > This is currently not implemented. There is a ticket to support this at: http://trac.osgeo.org/mapserver/ticket/2102 ..Tom From rodrigomlg at GMAIL.COM Tue Jul 10 05:32:29 2007 From: rodrigomlg at GMAIL.COM (=?ISO-8859-1?Q?Rodrigo_Mart=EDn_L=D3PEZ_GREGORIO?=) Date: Tue, 10 Jul 2007 13:32:29 +0100 Subject: Hide and show city labels depending on population In-Reply-To: <469367E8.1070400@zeelandnet.nl> Message-ID: Hi Milo. I think your problem is that you have no defined the MAXSCALE of the medium cities. This parameter tell mapserver at wich scale will stop drawing the elements of a layer (MINSCALE is how far in (MAXSCALE how far out) will be drawed the elements). So, i think if you add a MAXSCALE to the medium cities CLASS your problem will be solved: LABELITEM 'City' CLASSITEM 'City_Population' CLASS MAXSCALE 80000 NAME '0 < City_Population < 100000' EXPRESSION ( ([City_Population] >= 0) AND ([City_Population] <= 100000) ) STYLE SYMBOL 'CIRCLE' SIZE 3 OUTLINECOLOR 0 0 0 COLOR 255 170 0 END LABEL TYPE TRUETYPE FONT Arial SIZE 8 COLOR 255 255 250 #OUTLINECOLOR 255 255 255 ANTIALIAS TRUE MINFEATURESIZE 500 ANGLE 0 FORCE false END END CLASS NAME '100001 < City_Population < 500000' EXPRESSION ( ([City_Population] >= 100001) AND ([City_Population] <= 500000) ) STYLE SYMBOL 'CIRCLE' SIZE 4 OUTLINECOLOR 0 0 0 COLOR 255 170 0 END LABEL TYPE TRUETYPE FONT Arial SIZE 10 COLOR 255 255 250 #OUTLINECOLOR 255 255 255 ANTIALIAS TRUE MINFEATURESIZE 500 ANGLE 0 FORCE false END END The MAXSCALE value will depend on your map. I hope it works. Rodrigo. On 7/10/07, Milo van der Linden wrote: > > Hello list, > > I have been puzzling a bit and am not finding the correct answer. > > I have a city mapinfo tab that holds population values. I want to display: > - The labels of the major cities when zoomed out far, > - add the labels of medium cities when I zoom in further > - show all labels when zoomed in max > > Currently my syntax in the mapfile is as below, but I can't get a map that > shows only the labels of the major cities! > > Any help is appreciated > > LABELITEM 'City' > CLASSITEM 'City_Population' > CLASS > NAME '0 < City_Population < 100000' > EXPRESSION ( ([City_Population] >= 0) AND ([City_Population] <= > 100000) ) > STYLE > SYMBOL 'CIRCLE' > SIZE 3 > OUTLINECOLOR 0 0 0 > COLOR 255 170 0 > END > LABEL > TYPE TRUETYPE > FONT Arial > SIZE 8 > COLOR 255 255 250 > #OUTLINECOLOR 255 255 255 > ANTIALIAS TRUE > MINFEATURESIZE 500 > ANGLE 0 > FORCE false > END > END > CLASS > NAME '100001 < City_Population < 500000' > EXPRESSION ( ([City_Population] >= 100001) AND ([City_Population] <= > 500000) ) > STYLE > SYMBOL 'CIRCLE' > SIZE 4 > OUTLINECOLOR 0 0 0 > COLOR 255 170 0 > END > LABEL > TYPE TRUETYPE > FONT Arial > SIZE 10 > COLOR 255 255 250 > #OUTLINECOLOR 255 255 255 > ANTIALIAS TRUE > MINFEATURESIZE 500 > ANGLE 0 > FORCE false > END > END > -- > > > Milo van der Linden > mlinden at zeelandnet.nl > milovanderlinden at gmail.com > milo at 3dsite.nl > http://www.3dsite.nl > > > De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet > die van een bedrijf of instantie. Aan de informatie kunnen geen rechten > worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list > of community dan gelden automatisch de bijbehorende voorwaarden. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jayzee.smith at GMAIL.COM Tue Jul 10 07:40:19 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Tue, 10 Jul 2007 10:40:19 -0400 Subject: imagemap with mode=browse? In-Reply-To: Message-ID: guys, sorry for double posting and putting anyone on the spot :), but lee you include a link at http://www.nabble.com/Geocoder-and-scripts-tf4020206.html#a11418265 to a sweet mapserver/postgis app http://hud.uai.com/hudpls/ViewMap.aspx?FindAddTI=1 (openlayers?). when i click on hud properties, how do you popup the identify info? looks like you don't download the info when the layer shows up, but do a on-the-fly lookup? how?? cool app btw thanks, jzs On 7/9/07, John Smith wrote: > guys, > how can i create imagemap (which requires mode=nquery and templates > under layer), and zoom in/out (which requires mode=browse, and > templates under map)?? > > i really want to get rid of the "identify" button. ;) i know some > people have done cool popups. > cheers, jzs From David.Fawcett at STATE.MN.US Tue Jul 10 07:53:38 2007 From: David.Fawcett at STATE.MN.US (Fawcett, David) Date: Tue, 10 Jul 2007 09:53:38 -0500 Subject: imagemap with mode=browse? In-Reply-To: A Message-ID: John, Download and install open layers. There are examples similar to this included in the download package. David. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of John Smith Sent: Tuesday, July 10, 2007 9:40 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] imagemap with mode=browse? guys, sorry for double posting and putting anyone on the spot :), but lee you include a link at http://www.nabble.com/Geocoder-and-scripts-tf4020206.html#a11418265 to a sweet mapserver/postgis app http://hud.uai.com/hudpls/ViewMap.aspx?FindAddTI=1 (openlayers?). when i click on hud properties, how do you popup the identify info? looks like you don't download the info when the layer shows up, but do a on-the-fly lookup? how?? cool app btw thanks, jzs On 7/9/07, John Smith wrote: > guys, > how can i create imagemap (which requires mode=nquery and templates > under layer), and zoom in/out (which requires mode=browse, and > templates under map)?? > > i really want to get rid of the "identify" button. ;) i know some > people have done cool popups. cheers, jzs From mweinelt at PLANIGLOBE.COM Tue Jul 10 09:52:10 2007 From: mweinelt at PLANIGLOBE.COM (Martin Weinelt) Date: Tue, 10 Jul 2007 18:52:10 +0200 Subject: Mapscript, SVG and Annotations In-Reply-To: <1184007255.469284574eee1@webmail.mytng.de> Message-ID: I tried $map->drawLabelCache($SVGImg ), but that returns MS_FAILURE. Actually, there seems a problem with labeling on a SVG-'image'. I work around with: open SVGMAP, '>>', '/path/to/saved/svgimg.svg'; for (my $labnum=0; $labnum < $map->{labelcache}->{numlabels};$labnum++ ) { my $next_lab = $map->nextLabel() ; my $lab_txt = $next_lab->{text}; my $lab_x = $next_lab->{point}->{x}; my $lab_y = $next_lab->{point}->{y}; print SVGMAP ''.$lab_txt.'' . "\n"; } print SVGMAP ''; close SVGMAP; Of course, I would much more like to make use of MapServers anti-overposting mechanics for labels. Really nobody else came across that problem? Martin On Montag 09 Juli 2007, Martin Weinelt wrote: > Hi, > > I am using addFeature to dynamically add site locations with a > label to a map. It's Perl mapscript. > > @sites is an array of hash references, $sitesLyr is from the map > file: > > ############### > foreach my $site (@sites) { > my $site_pt = $$site{'site_loc'}; > $site_pt =~s/.*\((.*)\)*./$1/; # extract the points x and y > my $line = new mapscript::lineObj(); > my $siteShp = new > mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > > my $point = new mapscript::pointObj(); > my($x,$y) = split(/ /, $site_pt); > $point->setXY($x,$y); > $line->add($point); > $siteShp->add($line); > $siteShp->{text} = $$site{'site_name'}; > $siteShp->setBounds(); > $sitesLyr->addFeature($siteShp); > } > > my $img = $map->draw(); > > ############# > > This works perfectly for the usual PNG output map. Using the same > routine for a SVG 'image' results in the symbols/markers getting > plotted, but the labels are missing. If I switch to a static > shapefile for this layer, the labels do appear in the SVG. > > Is there anything special with SVG output and the 'addFeature' > method for layers that I am missing? > > Thanks, > > Martin -- --- Martin Weinelt --- kk+w - digital cartography --- Kiel, Germany --- Tel: +49.431.5791165 --- http://www.planiglobe.com From ezenaide at GMAIL.COM Tue Jul 10 10:57:22 2007 From: ezenaide at GMAIL.COM (Eduardo Zenaide) Date: Tue, 10 Jul 2007 14:57:22 -0300 Subject: query by rect Message-ID: hi list. i'm using some javascript to do a query. it gets information from html combo boxes. ############################## function determinaQSTRING() { //converting everything into variables: //host information: var hostPar = "http://localhost:82/zaal/al.php?"; //keymap: var keymapPar = "KEYMAPXSIZE=100&KEYMAPYSIZE=75&"; //fixed layers: var layerFixa = "Limite_Estadual_AL=Y&grid=Y&"; //get layer used on query from combobox: var layer = document.pesquisa.layersList.value; var modePar = "&CMD=QUERY_POINT&INPUT_TYPE=submit&"; //map image attributes: var imagePar = "imagewidth=760&imageheight=570"; //get query string from combobox: var queryEntry = document.pesquisa.nameList.option; //get operator from combobox: var operador = document.pesquisa.operadores.value; //get coordinates from combobox: var allComboValue = document.pesquisa.nameList.value; var allComboValueArray = allComboValue.split(','); var minx = "minx=" + allComboValueArray['0'] + "&"; var miny = "miny=" + allComboValueArray['1'] + "&"; var maxx = "maxx=" + allComboValueArray['2'] + "&"; var maxy = "maxy=" + allComboValueArray['3'] + "&"; //query string: document.pesquisa.qstring.value = "(\"[NOME]\" "+ operador +" /"+ queryEntry +"/)"; //reload map: window.opener.document.location = hostPar + keymapPar + layerFixa + layer + "=Y&" + minx + miny + maxx + maxy + imagePar + modePar + "INPUT_COORD=390%2C285%3B390%2C285"; } ############################ ok, its very ugly, but i though it would work. my problem is in the type of query. var modePar = "&CMD=QUERY_POINT&INPUT_TYPE=submit&"; it only does query by point, i'm trying to use query by rect. already tried auto_rect but didn't work too. what can i do? thanks in advance :) -- Eduardo Zenaide -------------- next part -------------- An HTML attachment was scrubbed... URL: From ebalas at GRNOC.IU.EDU Tue Jul 10 11:37:33 2007 From: ebalas at GRNOC.IU.EDU (Edward G. Balas) Date: Tue, 10 Jul 2007 14:37:33 -0400 Subject: Try to adjust projection parameters via CGI In-Reply-To: <468513A3.5157.008F.0@dnr.state.mn.us> Message-ID: Hey Steve, I finally got back around to verifying that this does work as you describe. The only slight trick was getting the correct format for the value associated with the map_PROJECTION attribute in the URL. http://localhost/cgi-bin/mapserv?map=/gnoc/mapserver/ grnoc.map&mapext=-125%2024%20-60%2070&mode=map&map_PROJECTION=proj% 3dortho,lon_0%3d-90,lat_0%3d-10 Thanks for the assist. On Jun 29, 2007, at 3:13 PM, Steve Lime wrote: > You can change projections using the map_... syntax. I believe simply > setting map_projection=new projection string in a url will suffice. > > Steve > >>>> On 6/28/2007 at 1:08 PM, in message > <4AAF5153-6BED-4288-B381-4EF5F66741BA at grnoc.iu.edu>, "Edward G. Balas" > wrote: >> Hey all, >> >> Ive been dorking with mapserver for a while now and cant seem to >> figure out how to do something which >> on the surface would seem to be a common task. >> >> Within my map, I would like keep lon_0 centered between MINX and MAXX >> of my extent. >> The objective is keep the projection centered on what the user is >> looking at while also allowing the >> user to change their extent via the CGI interface. >> >> I explored using variable substitution but it would appear as if this >> is not supported in the PROJECTION >> stanza. >> >> >> Any thoughts on how this might best be accomplished? >> >> >> --- >> Edward G. Balas >> ebalas at grnoc.iu.edu --- Edward G. Balas ebalas at grnoc.iu.edu -------------- next part -------------- An HTML attachment was scrubbed... URL: From assefa at DMSOLUTIONS.CA Tue Jul 10 11:48:23 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Tue, 10 Jul 2007 14:48:23 -0400 Subject: Mapscript, SVG and Annotations In-Reply-To: <1184007255.469284574eee1@webmail.mytng.de> Message-ID: Hi there, I did a quick test using php mapscript and an svg output. The poplace layer in the map file is a point layer and has a class with a label object (note that there is no labelitem set) LAYER NAME popplace TYPE POINT STATUS ON ... CLASS style SYMBOL 'circle' SIZE 6 COLOR 0 0 255 END LABEL COLOR 255 0 0 # FONT fritqat-italic FONT Arial TYPE truetype SIZE 12 ANGLE 10 POSITION AUTO PARTIALS FALSE OUTLINECOLOR 255 255 255 END ... script looks something like this $oMap = ms_newmapobj("c:/msapps/gmap-ms40/htdocs/gmap75.map"); $oShp = ms_newShapeObj(MS_SHAPE_POINT); $oLine = ms_newLineObj(); $oLine->addXY(-2299954.0642738,-612631); $oShp->add( $oLine ); $oShp->set("text", "mytext"); $numlayers = $oMap->numlayers; for ($i=0; $i<$numlayers; $i++) { $oLayer = $oMap->getlayer($i); $oLayer->set("status", MS_OFF); } $oLayer = $oMap->getlayerbyname('popplace'); $oLayer->set("status", MS_ON); $oLayer->addfeature($oShp); $img = $oMap->draw(); $url = $img->saveWebImage(); header("Content-type: image/svg+xml"); $url = $img->saveImage(""); It produces an svg point with the label my text : ... mytext Not sure what the issue would be in your case, the only time I did not have the text produced was when I set the labelitem object. Could that be the case ? Later kk+w - digitale kartografie GmbH wrote: > Hi, > > I am using addFeature to dynamically add site locations with a label to a map. > It's Perl mapscript. > > @sites is an array of hash references, $sitesLyr is from the map file: > > ############### > foreach my $site (@sites) { > my $site_pt = $$site{'site_loc'}; > $site_pt =~s/.*\((.*)\)*./$1/; # extract the points x and y > my $line = new mapscript::lineObj(); > my $siteShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > > my $point = new mapscript::pointObj(); > my($x,$y) = split(/ /, $site_pt); > $point->setXY($x,$y); > $line->add($point); > $siteShp->add($line); > $siteShp->{text} = $$site{'site_name'}; > $siteShp->setBounds(); > $sitesLyr->addFeature($siteShp); > } > > my $img = $map->draw(); > > ############# > > This works perfectly for the usual PNG output map. Using the same routine for a > SVG 'image' results in the symbols/markers getting plotted, but the labels are > missing. If I switch to a static shapefile for this layer, the labels do appear > in the SVG. > > Is there anything special with SVG output and the 'addFeature' method for layers > that I am missing? > > Thanks, > > Martin > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From ezenaide at GMAIL.COM Tue Jul 10 13:05:21 2007 From: ezenaide at GMAIL.COM (Eduardo Zenaide) Date: Tue, 10 Jul 2007 17:05:21 -0300 Subject: query by rect In-Reply-To: <7af310f80707101057r7c04a522h784efe9bbbe7dfde@mail.gmail.com> Message-ID: ok, after trying a lot, it worked with auto_rect. don't know where the error was but it's working. i restarted apache and windows too. thanks anyway. 2007/7/10, Eduardo Zenaide : > > hi list. > > i'm using some javascript to do a query. it gets information from html > combo boxes. > > ############################## > > function determinaQSTRING() { > //converting everything into variables: > //host information: > var hostPar = "http://localhost:82/zaal/al.php?"; > //keymap: > var keymapPar = "KEYMAPXSIZE=100&KEYMAPYSIZE=75&"; > //fixed layers: > var layerFixa = "Limite_Estadual_AL=Y&grid=Y&"; > //get layer used on query from combobox: > var layer = document.pesquisa.layersList.value; > > var modePar = "&CMD=QUERY_POINT&INPUT_TYPE=submit&"; > > //map image attributes: > var imagePar = "imagewidth=760&imageheight=570"; > > //get query string from combobox: > var queryEntry = document.pesquisa.nameList.option; > //get operator from combobox: > var operador = document.pesquisa.operadores.value; > > //get coordinates from combobox: > var allComboValue = document.pesquisa.nameList.value; > var allComboValueArray = allComboValue.split(','); > var minx = "minx=" + allComboValueArray['0'] + "&"; > var miny = "miny=" + allComboValueArray['1'] + "&"; > var maxx = "maxx=" + allComboValueArray['2'] + "&"; > var maxy = "maxy=" + allComboValueArray['3'] + "&"; > > //query string: > document.pesquisa.qstring.value = "(\"[NOME]\" "+ operador +" /"+ > queryEntry +"/)"; > > //reload map: > window.opener.document.location = hostPar + keymapPar + layerFixa > + layer + "=Y&" + minx + miny + maxx + maxy + imagePar + modePar + > "INPUT_COORD=390%2C285%3B390%2C285"; > } > > ############################ > > ok, its very ugly, but i though it would work. my problem is in the type > of query. > > var modePar = "&CMD=QUERY_POINT&INPUT_TYPE=submit&"; > > it only does query by point, i'm trying to use query by rect. > already tried auto_rect but didn't work too. > > what can i do? > > > thanks in advance :) > > > -- > Eduardo Zenaide -- Eduardo Zenaide -------------- next part -------------- An HTML attachment was scrubbed... URL: From assefa at DMSOLUTIONS.CA Tue Jul 10 13:44:50 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Tue, 10 Jul 2007 16:44:50 -0400 Subject: SOS disconnect In-Reply-To: <035c01c7bfc8$0b608db0$650fa8c0@latitude> Message-ID: Charlton, I was able to reproduce the GetCapabilities issues with 4.10.2. The bugs were corrected in the current svn version (to be 5.0). I also back ported them in the 4.10.x branch in case there is a 4.10.3 release. If possible please upgrade to either versions and so the tests. http://trac.osgeo.org/mapserver/ticket/1938 http://trac.osgeo.org/mapserver/ticket/2146 Best Regards, Charlton Purvis wrote: > Hi, Tom and Assefa: > >> N.B. are you intentionally setting observedproperty to a URL in the >> mapfile? Note that it can also be a plain old string, etc. :) > > Yes, that's intentional. It's not the most readable thing, I agree, but > that's the way this particular booger needs to be done. > >> When I try: >> >> http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation >> &version=0.0.31&offering=ndbc_44029&format=application/com-xml&observedP >> roperty=http://marinemetadata.org/cf%23sea_surface_temperature&eventTime >> =2007-06> osition>2007-07 >> >> It seems to work; mind you there looks to be only one record. How are >> you passing the time query? > > Oh. Interesting. One record is correct. This particular table only holds > the latest obs for a given sensor / platform combo. I was originally trying > to pass &time=yyyymmddThhmiZ and that caused it to be unhappy. But Example2 > from http://mapserver.gis.umn.edu/docs/howto/sos_server passes a time param, > so maybe I'm doing something wrong, or should I stick w/ the syntax you > described above? > > Assefa, MapServer version 4.10.2. > >>> The getcaps behind all of this is here: >>> http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=getc >> apabilities&ve >>> rsion=0.0.31. > > Tom, you're right, the GetCaps works fine, but that's because I took out a > layer that seemed to set the GetCaps over the edge. I'll put together a > barebones .map and pass around that will hopefully be able to reproduce the > problem. > > Many thanks, fellas! > > Charlton > > > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From rdmailings at DUIF.NET Tue Jul 10 14:29:35 2007 From: rdmailings at DUIF.NET (Richard Duivenvoorde) Date: Tue, 10 Jul 2007 23:29:35 +0200 Subject: more exact scalebar positioning Message-ID: Hi List, I'm using a 'normal' embedded scalebar: SCALEBAR LABEL COLOR 0 0 0 SIZE SMALL END SIZE 233 5 COLOR 255 255 255 BACKGROUNDCOLOR 0 0 0 OUTLINECOLOR 0 0 0 TRANSPARENT off UNITS meters STATUS embed POSITION ul END and while I succeeded to put in in the every corner using 'position', I'm wondering if I can put it in the lowerleft corner, but 20 pixels higher then the 'default' (?) position. Reason for this: I have a 20 pixels high very long copyright notice on the bottom of the map, which is hiding the scalebar partly now... and I really want it to have in he lower left corner... In: http://umn.mapserver.ch/index_en.php I found something like: "(Please note that embedding scale bars require that you define a markerset. In essence the scale bar becomes a custom marker that is handled just like any other annotation.)". but I don't know howto define a markerset of what it is (other than in relation with an reference map) I find the possibilities of annotationlayers amazing by the way: - using text, or transparent images or custom truetype font's you can put everything everywhere fixed on your map (after reading: http://mapserver.gis.umn.edu/development/rfc/ms-rfc-14). Is it an idea to put something in documentation about this? Specially for printing you often have to put copyright notices, custom north arrows or compasses etc in you final image. TIA, Richard Duivenvoorde From mweinelt at PLANIGLOBE.COM Wed Jul 11 01:46:25 2007 From: mweinelt at PLANIGLOBE.COM (Martin Weinelt) Date: Wed, 11 Jul 2007 10:46:25 +0200 Subject: Mapscript, SVG and Annotations In-Reply-To: <4693D477.4060400@dmsolutions.ca> Message-ID: Thanks a lot, your tips at least kept trying. What I did was translate your example to Perl mapscript. Some PHP methods are not available or a bit different in the SWIG versions. That looks like this: my $oShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); my $oLine = new mapscript::lineObj; my $oPt = new mapscript::pointObj; $oPt->setXY(-11, 22); # DD $oLine->add($oPt); $oShp->add($oLine); $oShp->{text} = 'Hello World'; my $numlayers = $map->{numlayers}; my $oLayer; for (my $h=0; $h<$numlayers; $h++) { $oLayer = $map->getLayer($h); $oLayer->{status} = $mapscript::MS_OFF; } $oLayer = $map->getLayerByName('popplace'); $oLayer->{status} = $mapscript::MS_ON; $oLayer->addFeature($oShp); # here the loop below is going to be inserted my $SVGimg = $map->draw(); my $svg_file = '/path/to/willi.svg'; $SVGimg->save($svg_file); The result is exactly like yours: including the label. Ok. But now I add the following: for (my $foo=0; $foo < 3; $foo++) { $oShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); $oLine = new mapscript::lineObj; $oPt = new mapscript::pointObj; $oPt->setXY($foo,$foo); $oLine->add($oPt); $oShp->add($oLine); $oShp->{text} = 'Hello World ' . "$foo"; $oLayer->addFeature($oShp); $oShp=$oLine=$oPt=undef; # don't know if this is needed } this is the result: Hello World What you see is that the labels from the loop are missing while the label from the first addFeature is there. Weird. Going through the MAP-file reference I find the 'FORCE' property for labels. Setting 'FORCE' to 'true' did the trick. All labels, including those from the loop, do now appear in the SVG. I do not know if this is exactly what I want, but at least I got my labels. Cheers, Martin On Dienstag 10 Juli 2007, Yewondwossen Assefa wrote: > Hi there, > > I did a quick test using php mapscript and an svg output. The > poplace layer in the map file is a point layer and has a class with > a label object (note that there is no labelitem set) > > LAYER > NAME popplace > TYPE POINT > STATUS ON > ... > CLASS > style > SYMBOL 'circle' > SIZE 6 > COLOR 0 0 255 > END > LABEL > COLOR 255 0 0 > # FONT fritqat-italic > FONT Arial > TYPE truetype > SIZE 12 > ANGLE 10 > POSITION AUTO > PARTIALS FALSE > OUTLINECOLOR 255 255 255 > END > ... > > script looks something like this > > $oMap = ms_newmapobj("c:/msapps/gmap-ms40/htdocs/gmap75.map"); > > $oShp = ms_newShapeObj(MS_SHAPE_POINT); > > $oLine = ms_newLineObj(); > > $oLine->addXY(-2299954.0642738,-612631); > $oShp->add( $oLine ); > > $oShp->set("text", "mytext"); > > $numlayers = $oMap->numlayers; > for ($i=0; $i<$numlayers; $i++) > { > $oLayer = $oMap->getlayer($i); > $oLayer->set("status", MS_OFF); > } > $oLayer = $oMap->getlayerbyname('popplace'); > $oLayer->set("status", MS_ON); > $oLayer->addfeature($oShp); > > $img = $oMap->draw(); > $url = $img->saveWebImage(); > > header("Content-type: image/svg+xml"); > $url = $img->saveImage(""); > > > It produces an svg point with the label my text : > > ... > > > fill="#ff0000" stroke="#ffffff" stroke-width="0.5" > transform="rotate(-10.000000 38 581)">mytext > > > Not sure what the issue would be in your case, the only time I > did not have the text produced was when I set the labelitem object. > Could that be the case ? > > > Later > > kk+w - digitale kartografie GmbH wrote: > > Hi, > > > > I am using addFeature to dynamically add site locations with a > > label to a map. It's Perl mapscript. > > > > @sites is an array of hash references, $sitesLyr is from the map > > file: > > > > ############### > > foreach my $site (@sites) { > > my $site_pt = $$site{'site_loc'}; > > $site_pt =~s/.*\((.*)\)*./$1/; # extract the points x and > > y my $line = new mapscript::lineObj(); > > my $siteShp = new > > mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > > > > my $point = new mapscript::pointObj(); > > my($x,$y) = split(/ /, $site_pt); > > $point->setXY($x,$y); > > $line->add($point); > > $siteShp->add($line); > > $siteShp->{text} = $$site{'site_name'}; > > $siteShp->setBounds(); > > $sitesLyr->addFeature($siteShp); > > } > > > > my $img = $map->draw(); > > > > ############# > > > > This works perfectly for the usual PNG output map. Using the same > > routine for a SVG 'image' results in the symbols/markers getting > > plotted, but the labels are missing. If I switch to a static > > shapefile for this layer, the labels do appear in the SVG. > > > > Is there anything special with SVG output and the 'addFeature' > > method for layers that I am missing? > > > > Thanks, > > > > Martin From satsuman at GMAIL.COM Wed Jul 11 02:28:23 2007 From: satsuman at GMAIL.COM (SATish In Athens +30 6947758275) Date: Wed, 11 Jul 2007 12:28:23 +0300 Subject: Not able to navigate through reference map Message-ID: Hey all.. I am trying to create my own map and it is working correct but when I click on the reference map then instead of navigating to the right place in main map , the map looses the focus.. And, after that map is required to be reloaded again.. So, this is something missing in map file or in HTML of the page ? Any response will be highly appreciated.. Thank you -------------- next part -------------- An HTML attachment was scrubbed... URL: From siki at AGT.BME.HU Wed Jul 11 06:30:09 2007 From: siki at AGT.BME.HU (Siki Zoltan) Date: Wed, 11 Jul 2007 12:30:09 -0100 Subject: Not able to navigate through reference map {Scanned} {Scanned} In-Reply-To: Message-ID: Hi, Did you put the reference map into a input field of your form? Like: Bye Zoltan On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: > Hey all.. > I am trying to create my own map and it is working correct but when I click > on the reference map then instead of navigating to the right place in main > map , the map looses the focus.. > And, after that map is required to be reloaded again.. > So, this is something missing in map file or in HTML of the page ? > > > Any response will be highly appreciated.. > Thank you > From siki at AGT.BME.HU Wed Jul 11 07:59:08 2007 From: siki at AGT.BME.HU (Siki Zoltan) Date: Wed, 11 Jul 2007 13:59:08 -0100 Subject: Not able to navigate through reference map {Scanned} {Scanned} {Scanned} In-Reply-To: Message-ID: Hi, Your solution use a static image, not clickable. Change your reference image from this > width="120" border="1"> to this Meanwhile you should insert REFERENCE block into your map file, e.g. REFERENCE IMAGE graphics/reference.gif EXTENT ??? ??? ??? ??? SIZE 120 120 STATUS ON ... # see the map file reference END I send the mail to the list to, it can help someone else. Bye, Zoltan On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: > Thanks a lot.. > but yes, i have tried with putting in a form.. when I attached "input" tag > with it, got an error.. > Well, my reference tag is like below, please have a look of it > > >
  • > >
    > >
    > > >
    > > width="120" border="1">
    > >
  • > > > So, i m not sure how to use input tag in it.. > regards.. > Satish > > > > On 7/11/07, Siki Zoltan wrote: >> >> Hi, >> >> Did you put the reference map into a input field of your form? >> Like: >> >> >> Bye >> Zoltan >> >> On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: >> >> > Hey all.. >> > I am trying to create my own map and it is working correct but when I >> click >> > on the reference map then instead of navigating to the right place in >> main >> > map , the map looses the focus.. >> > And, after that map is required to be reloaded again.. >> > So, this is something missing in map file or in HTML of the page ? >> > >> > >> > Any response will be highly appreciated.. >> > Thank you >> > >> > From satsuman at GMAIL.COM Wed Jul 11 05:22:36 2007 From: satsuman at GMAIL.COM (SATish In Athens +30 6947758275) Date: Wed, 11 Jul 2007 15:22:36 +0300 Subject: Not able to navigate through reference map {Scanned} {Scanned} {Scanned} In-Reply-To: Message-ID: Well.. I have REFERENCE block in map file.. my box and marker are working. but this tag is not working.. When i put this tag, reference as well as main image disappear.. Thanx Satish On 7/11/07, Siki Zoltan wrote: > > Hi, > > Your solution use a static image, not clickable. > Change your reference image from this > > > width="120" border="1"> > > to this > width="120" border="1"> > > Meanwhile you should insert REFERENCE block into your map file, e.g. > REFERENCE > IMAGE graphics/reference.gif > EXTENT ??? ??? ??? ??? > SIZE 120 120 > STATUS ON > ... # see the map file reference > END > > I send the mail to the list to, it can help someone else. > > Bye, > Zoltan > > On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: > > > Thanks a lot.. > > but yes, i have tried with putting in a form.. when I attached "input" > tag > > with it, got an error.. > > Well, my reference tag is like below, please have a look of it > > > > > >
  • > > > >
    > > > >
    > > > > > >
    > > > > > width="120" border="1">
    > > > >
  • > > > > > > So, i m not sure how to use input tag in it.. > > regards.. > > Satish > > > > > > > > On 7/11/07, Siki Zoltan wrote: > >> > >> Hi, > >> > >> Did you put the reference map into a input field of your form? > >> Like: > >> > >> > >> Bye > >> Zoltan > >> > >> On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: > >> > >> > Hey all.. > >> > I am trying to create my own map and it is working correct but when I > >> click > >> > on the reference map then instead of navigating to the right place in > >> main > >> > map , the map looses the focus.. > >> > And, after that map is required to be reloaded again.. > >> > So, this is something missing in map file or in HTML of the page ? > >> > > >> > > >> > Any response will be highly appreciated.. > >> > Thank you > >> > > >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From siki at AGT.BME.HU Wed Jul 11 08:56:11 2007 From: siki at AGT.BME.HU (Siki Zoltan) Date: Wed, 11 Jul 2007 14:56:11 -0100 Subject: Not able to navigate through reference map {Scanned} {Scanned} {Scanned} {Scanned} In-Reply-To: Message-ID: Hi, Did you check web server log file when the main image diappears? There should be there some error messages ... Zoltan On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: > Well.. I have REFERENCE block in map file.. > my box and marker are working. > but this tag is not working.. > When i put this tag, reference as well as main image disappear.. > Thanx > Satish > > On 7/11/07, Siki Zoltan wrote: >> >> Hi, >> >> Your solution use a static image, not clickable. >> Change your reference image from this >> > > > width="120" border="1"> >> >> to this >> > width="120" border="1"> >> >> Meanwhile you should insert REFERENCE block into your map file, e.g. >> REFERENCE >> IMAGE graphics/reference.gif >> EXTENT ??? ??? ??? ??? >> SIZE 120 120 >> STATUS ON >> ... # see the map file reference >> END >> >> I send the mail to the list to, it can help someone else. >> >> Bye, >> Zoltan >> >> On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: >> >> > Thanks a lot.. >> > but yes, i have tried with putting in a form.. when I attached "input" >> tag >> > with it, got an error.. >> > Well, my reference tag is like below, please have a look of it >> > >> > >> >
  • >> > >> >
    >> > >> >
    >> > >> > >> >
    >> > >> > > > width="120" border="1">
    >> > >> >
  • >> > >> > >> > So, i m not sure how to use input tag in it.. >> > regards.. >> > Satish >> > >> > >> > >> > On 7/11/07, Siki Zoltan wrote: >> >> >> >> Hi, >> >> >> >> Did you put the reference map into a input field of your form? >> >> Like: >> >> >> >> >> >> Bye >> >> Zoltan >> >> >> >> On Wed, 11 Jul 2007, SATish In Athens +30 6947758275 wrote: >> >> >> >> > Hey all.. >> >> > I am trying to create my own map and it is working correct but when I >> >> click >> >> > on the reference map then instead of navigating to the right place in >> >> main >> >> > map , the map looses the focus.. >> >> > And, after that map is required to be reloaded again.. >> >> > So, this is something missing in map file or in HTML of the page ? >> >> > >> >> > >> >> > Any response will be highly appreciated.. >> >> > Thank you >> >> > >> >> >> > >> > From rwburgholzer at DEQ.VIRGINIA.GOV Wed Jul 11 07:04:53 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Wed, 11 Jul 2007 10:04:53 -0400 Subject: Dynamic map annotation in animated GIF file Message-ID: Julien, Thanks for your suggestions. I am close, although the points are not being rendered. They return a "MS_SUCCESS", however, it does not show on the map. I have tried many possibilities, but am thus far unable to get success. r.b. -----Original Message----- From: Julien-Samuel Lacroix [mailto:jlacroix at mapgears.com] Sent: Monday, July 09, 2007 8:32 PM To: Burgholzer,Robert Cc: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Dynamic map annotation in animated GIF file Hi, You are right. PHP/MapScript doesn't provide the TEXT portion of an annotation feature. It's because it's easier to add directly a point on the top of the map. Instead of adding a FEATURE object to the layer, simply create a point object and draw it on the map image. (Following code not tested) // Outside the loop create a pointObj $oPoint = ms_newPointObj(); $oPoint->setXY(1,1); [...snipp...] // Inside the foreach, draw your map without the copyright layer $thislayer->set("status",MS_OFF); $image[$i] = $amap->map->draw(); // Then draw the point on the top of it // Don't forget to remove the FEATURE object in the mapfile // Also you should give a name to your class in the copyright layer // For now, I'll use "CLASSNAME" $thislayer->set("status",MS_ON); $oPoint->draw($amap->map, $thislayer, $image[$i], "CLASSNAME", $filter); $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); [...snip...] The code is not tested, but it should give you a good idea. Julien Burgholzer,Robert wrote: > I am trying to produce a time series animated GIF, with an annotation at > the bottom of the map that shows the time. Thanks to an example from > Charlton Purvis found by a search of previous postings on making an > animated GIF (modified to use a single layer, changing the filter to > select for the data that is in my current time step): > > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0304/msg00482.h tml > > > > And a Wiki entry from Jeff McKenna about making a copyright notation: > > http://mapserver.gis.umn.edu/docs/faq/copyright-layer > > > > I have the basics, that is, an animated time series, with a statically > placed text entry at the bottom (at a map-specific point, rather than a > lat lon). However, the annotation layer can only display a single > entry, not one that is updated with the time step. I am wondering how > to do this, if I can modify the property of the annotation layer, or if > I need to create a point of some sort from a dynamic postgis call. I > can't seem to set the TEXT portion of the feature via php mapscript. > > > > Anyone have any ideas? (code and mapfile follow) > > > > foreach ($gifmaps as $thismap) { > > $thislayer = $amap->map->getLayerByName('stream_stat'); > > $filter = " projectid = $projectid and thismetric = '$thismap' "; > > $listobject->querystring = " select count(*) as numrecs from > proj_group_stat "; > > $listobject->querystring .= " where $filter "; > > $listobject->performQuery(); > > $numrecs = $listobject->getRecordValue(1,'numrecs'); > > #$annotlayer = $amap->map->getLayerByName('copyright'); > > #$annotation = $annotlayer->getFeature(1,-1); > > if ($numrecs > 0) { > > $thislayer->setFilter($filter); > > $thislayer->set("status",MS_ON); > > #$annotation->set("TEXT", $filter); > > $image[$i] = $amap->map->draw(); > > $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); > > $file_path[$i] = $amap->map->web->imagepath > > . substr(strrchr($image_url[$i], "/"),1); > > $anim_files = $anim_files . '"' . $file_path[$i] . '"' . " "; > > $i++; > > print(" Adding $filter, $image_url[$i]
    "); > > } > > } > > > > // Create a unique filename and URL for the animated GIF output > > $anim_name = "anim".substr(strrchr($image_url[1], '/'),1); > > $anim_path = '"' . $amap->map->web->imagepath . $anim_name .'"'; > > $anim_url = $amap->map->web->imageurl . $anim_name; > > > > print("Creating $anim_path
    "); > > $cmd = $anim_gif_cmd . " -o " . $anim_path . " " . $anim_files; > > print("Using: $cmd
    "); > > > > system($cmd); > > > > # annotation layer > > LAYER > > NAME copyright > > STATUS ON > > TYPE annotation > > TRANSFORM false > > FEATURE > > POINTS > > 150 180 #this is the position of the text in image coordinates > (pixels) > > END > > TEXT "From 2007/01/01 to 2007/06/30" #this is your displaying text > > END > > CLASS > > LABEL #defines the font, colors etc. of the text > > FONT "arial" > > TYPE TRUETYPE > > SIZE 10 > > BUFFER 1 > > COLOR 0 0 0 > > BACKGROUNDCOLOR 255 255 255 > > FORCE TRUE > > END > > END > > END > > Robert W. Burgholzer > > Surface Water Modeler > > Office of Water Supply and Planning > > Virginia Department of Environmental Quality > > rwburgholzer at deq.virginia.gov > > 804-698-4405 > > Open Source Modeling Tools: > > http://sourceforge.net/projects/npsource/ > > > -- Julien-Samuel Lacroix Mapgears http://www.mapgears.com/ From cplist at SECONDCREEK.ORG Wed Jul 11 07:27:22 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Wed, 11 Jul 2007 10:27:22 -0400 Subject: SOS disconnect In-Reply-To: <4693EFC2.6070804@dmsolutions.ca> Message-ID: Thanks, Assefa! > I was able to reproduce the GetCapabilities issues with 4.10.2. The > bugs were corrected in the current svn version (to be 5.0). I also back > ported them in the 4.10.x branch in case there is a 4.10.3 release. If > possible please upgrade to either versions and so the tests. We'll upgrade ASAP and report back. Charlton From rwburgholzer at DEQ.VIRGINIA.GOV Wed Jul 11 09:11:31 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Wed, 11 Jul 2007 12:11:31 -0400 Subject: symbol file maxed out Message-ID: So, I have a custom icon application (a pie graph for each county in the state), and am using these as symbols. It worked great while I was testing, but when I went into full application I ran into the symbol file limitation of 64 symbols. I am using a pre-compiled version of MS 4.10 for Windows, and am stuck whilst waiting for the Linux box to arrive :-) Anyone have a pre-compiled MS 4.10 with at least 255 symbols, or an idea of a better way to do this (there has to be, I mean, my map and symbol files are gi-normous). Thanks, r.b. Robert W. Burgholzer Surface Water Modeler Office of Water Supply and Planning Virginia Department of Environmental Quality rwburgholzer at deq.virginia.gov 804-698-4405 Open Source Modeling Tools: http://sourceforge.net/projects/npsource/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From beck at IR.GESS.ETHZ.CH Wed Jul 11 09:56:14 2007 From: beck at IR.GESS.ETHZ.CH (Lucas Beck) Date: Wed, 11 Jul 2007 18:56:14 +0200 Subject: qgis - colorrange Message-ID: Hello, I am using MapServer version 4.8.3. I just started to generate a map-file using qgis which generated an output using "COLORRANGE". However, by trying to embed the map-file into my web application I can only see very small dots. All other layers are OK. Here the generated layer LAYER NAME 'SUBASINS' TYPE POLYGON DATA "SUBASINS" METADATA 'wms_title' 'SUBASINS' END STATUS DEFAULT TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=clrk66' 'datum=NAD27' 'no_defs' END CLASS STYLE COLORRANGE 7 11 250 128 215 255 DATARANGE 2.000000 14.000000 RANGEITEM "SUBASINS_" END STYLE OUTLINECOLOR 0 0 50 END END END greets Lucas From veeraswamyd at YAHOO.CO.IN Wed Jul 11 10:33:09 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Wed, 11 Jul 2007 10:33:09 -0700 Subject: download error Message-ID: i have installed ms4w 2.2.4 apache is not starting it is displaying error as "windows could not stsrt the apache ms4w web server on local computer." plz tell me this -- View this message in context: http://www.nabble.com/download-error-tf4063403.html#a11544958 Sent from the Mapserver - User mailing list archive at Nabble.com. From urvashig at GMAIL.COM Wed Jul 11 10:38:35 2007 From: urvashig at GMAIL.COM (Urvashi Gadi) Date: Wed, 11 Jul 2007 13:38:35 -0400 Subject: unusual response from mapserver when making WFS request with filter encoding on a layer that uses a tile index Message-ID: Hi, I'm getting an unusual response from mapserver when I make a WFS request with filter encoding on a layer that uses a tile index; it returns a box with -1 as all corners. Is there anything that can be done to make this work, or is this a know limitation of mapserver? WFS works on the layer with the tile index as long as I don't use any FE. WFS with FE works on a test layer that references one of the shapefiles directly instead of the tile index. Below is some information about what I'm trying and my environment: Sample WFS Requests with FE: http://wilson.library.emory.edu/~mapserver/cgi-bin/south?SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=Urban_Areas&Filter= NAMEArcola http://wilson.library.emory.edu/~mapserver/cgi-bin/south?SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=Urban_Areas&Filter= PLACE01820 The response: -1.000000,-1.000000 -1.000000,- 1.000000 Sample WFS Request without FE: http://wilson.library.emory.edu/~mapserver/cgi-bin/south?SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=Urban_Areas&MAXFEATURES=1 The response: -91.429176,24.844480 -75.562841, 36.641761 -90.885096,33.266165 -90.875910, 33.274779 -90.884500,33.269424 -90.885040,33.269421 -90.885082,33.272127 -90.885096,33.273023 -90.883338,33.273026 -90.879469, 33.273030 -90.879464,33.273206 -90.879413,33.274749 -90.876712,33.274772 -90.875930, 33.274779 -90.875910,33.272084 -90.876238,33.270229 -90.876375,33.269817 -90.876403, 33.269665 -90.876649,33.268329 -90.877004,33.266749 -90.877707,33.266755 -90.880544, 33.266781 -90.880502,33.266688 -90.880420,33.266507 -90.881163,33.266376 -90.882357, 33.266165 -90.882984,33.267974 -90.883487,33.269427 -90.883781,33.269426 -90.884500, 33.269424 1 28151 01820 Arcola 60 P C1 0 GetCapabilities report for the layer: Urban_Areas Urban Areas EPSG:4326 Excerpts from the mapfile: WEB METADATA 'wms_title' 'SouthComb WMS Server' 'wms_onlineresource' ' http://wilson.library.emory.edu/~mapserver/cgi-bin/south? ' 'wms_srs' 'EPSG:4326' 'wfs_title' 'SouthComb WFS Server' 'wfs_onlineresource' ' http://wilson.library.emory.edu/~mapserver/cgi-bin/south? ' 'wfs_srs' 'EPSG:4326' END END LAYER NAME 'Urban_Areas' TYPE POLYGON TILEINDEX 'placecu.shp' TILEITEM 'location' DUMP TRUE # allow GML export METADATA 'wms_title' 'Urban Areas' 'wfs_title' 'Urban Areas' 'gml_featureid' 'name' 'gml_include_items' 'all' END STATUS OFF LABELCACHE ON LABELITEM 'NAME' PROJECTION 'init=epsg:4326' END CLASS NAME placecu MAXSCALE 1000000 STYLE SYMBOL 0 SIZE 6 OUTLINECOLOR 106 46 34 COLOR 248 241 223 END LABEL TYPE TRUETYPE FONT sans SIZE 14 COLOR 0 0 0 END END END Attributes reported by ogrinfo for one of the shapfiles that the tile index file placecu.shp references: GIST_ID: Integer (8.0) COUNTY: String (5.0) PLACE: String (5.0) NAME: String (60.0) LSADC: String (2.0) ENTITY: String (1.0) FIPSCC: String (2.0) PLACEDC: String (1.0) Thanks, Urvashi Gadi -------------- next part -------------- An HTML attachment was scrubbed... URL: From David.Fawcett at STATE.MN.US Wed Jul 11 12:07:47 2007 From: David.Fawcett at STATE.MN.US (Fawcett, David) Date: Wed, 11 Jul 2007 14:07:47 -0500 Subject: qgis - colorrange In-Reply-To: A<46950BAE.6010402@ir.gess.ethz.ch> Message-ID: Lucas, It doesn't look like you have any symbols defined. I am pretty sure that with no symbol, you will just get a one pixel symbol. In your STYLE definition, you will want to add SYMBOL 'circle' SIZE 10 For this to work, you will also need a symbol definition for 'circle' either in a symbols.sym file or in your map file. The symbol definition would look like this: Symbol Name 'circle' Type ELLIPSE Filled TRUE Points 1 1 END END David. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Lucas Beck Sent: Wednesday, July 11, 2007 11:56 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: [UMN_MAPSERVER-USERS] qgis - colorrange Hello, I am using MapServer version 4.8.3. I just started to generate a map-file using qgis which generated an output using "COLORRANGE". However, by trying to embed the map-file into my web application I can only see very small dots. All other layers are OK. Here the generated layer LAYER NAME 'SUBASINS' TYPE POLYGON DATA "SUBASINS" METADATA 'wms_title' 'SUBASINS' END STATUS DEFAULT TRANSPARENCY 100 PROJECTION 'proj=longlat' 'ellps=clrk66' 'datum=NAD27' 'no_defs' END CLASS STYLE COLORRANGE 7 11 250 128 215 255 DATARANGE 2.000000 14.000000 RANGEITEM "SUBASINS_" END STYLE OUTLINECOLOR 0 0 50 END END END greets Lucas From thomas.rokkjaer at GMAIL.COM Wed Jul 11 12:11:11 2007 From: thomas.rokkjaer at GMAIL.COM (Thomas Rokkjaer) Date: Wed, 11 Jul 2007 14:11:11 -0500 Subject: Compiling with OGR version supporting SQL server connection Message-ID: I have followed the guidelines for setting up a virtual spatial data connection at http://mapserver.gis.umn.edu/docs/reference/vector_data/VirtualSpatialData, installed FWTools 1.3.4, tested the connection via ogrinfo successfully, tested the mapfile (specific layer attached) with the shp2img tool successfully, but I am having problems with displaying this newly generated layer in my map window. At http://mapserver.gis.umn.edu/docs/howto/ogrmysql I found a how-to for OGR connection to MySQL, where it is stated the following prerequisite "MapServer compiled with OGR version supporting this functinality". How is it possible to compile my current MapServer to support OGR for SQL server or should it already work with the current settings? mapserv -v MapServer version 4.99 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=FASTCGI SUPPORTS=TH READS INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE DEBUG=MSDEBUG Thanks! BR Thomas -------------- next part -------------- LAYER CONNECTION " ODBC:test/test at DVHenvendelse DVHenvendelse wkbPoint " CONNECTIONTYPE OGR DATA "DVHenvendelse" METADATA "wms_srs" "EPSG:25832" "wms_title" "DVHenvendelse" END NAME "DVHenvendelse" SIZEUNITS PIXELS STATUS ON TOLERANCE 0 TOLERANCEUNITS PIXELS TYPE POINT UNITS METERS CLASS STYLE COLOR 255 0 255 MAXSIZE 100 MINSIZE 1 SIZE 10 SYMBOL "punkt" END END STYLEITEM "AUTO" HEADER 'header' TEMPLATE 'template.html' FOOTER 'footer.html' END From warmerdam at POBOX.COM Wed Jul 11 13:10:44 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Wed, 11 Jul 2007 16:10:44 -0400 Subject: Compiling with OGR version supporting SQL server connection In-Reply-To: Message-ID: Thomas Rokkjaer wrote: > I have followed the guidelines for setting up a virtual spatial data connection > at > http://mapserver.gis.umn.edu/docs/reference/vector_data/VirtualSpatialData, > installed FWTools 1.3.4, tested the connection via ogrinfo successfully, tested > the mapfile (specific layer attached) with the shp2img tool successfully, but I > am having problems with displaying this newly generated layer in my map > window. > At http://mapserver.gis.umn.edu/docs/howto/ogrmysql I found a how-to for > OGR connection to MySQL, where it is stated the following > prerequisite "MapServer compiled with OGR version supporting this > functinality". How is it possible to compile my current MapServer to support > OGR for SQL server or should it already work with the current settings? Thomas, You are configured to use the OGR ODBC driver, which should be available in any GDAL/OGR windows build. So there is nothing special required. The MySQL case is accessing MySQL directly rather than through ODBC. If shp2img is working, I'd suggest you carefully review permissions for use of the ODBC DSN for whatever user your web server is running as. > STYLEITEM "AUTO" BTW, I don't believe that STYLEITEM "AUTO" is going to do anything for ODBC/VRT datasources. It mostly is useful for mapinfo, and dgn file formats. 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 | President OSGeo, http://osgeo.org From szekerest at GMAIL.COM Wed Jul 11 15:44:05 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Thu, 12 Jul 2007 00:44:05 +0200 Subject: download error In-Reply-To: <11544958.post@talk.nabble.com> Message-ID: Isn't that another application like IIS is listening on the same TCP port in the computer? Do you have a more specific error message? Best regards, Tamas 2007/7/11, lakku : > i have installed ms4w 2.2.4 > apache is not starting > it is displaying error as "windows could not stsrt the apache ms4w web > server on local computer." > plz tell me this > -- > View this message in context: http://www.nabble.com/download-error-tf4063403.html#a11544958 > Sent from the Mapserver - User mailing list archive at Nabble.com. > From friendvn2000 at YAHOO.COM Wed Jul 11 19:45:02 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Wed, 11 Jul 2007 21:45:02 -0500 Subject: Adding a url link object to a map Message-ID: Good idea, can you explain more detail. From friendvn2000 at YAHOO.COM Wed Jul 11 20:11:22 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Wed, 11 Jul 2007 22:11:22 -0500 Subject: Open a shapefile and read its shapes' attributes Message-ID: Hi all, I want to open a line shapefile (routes.shp) and read attribute (RouteName) from it. My codes here: numshapes; if($numshapes > 0) { for($i = 0; $i < $numshapes; $i++) { $Line = $LineFile->getShape($i); $RouteName = $Line->values["RouteName"]; printf($RouteName ); // it show nothing $Line->free(); } } $LineFile->free(); ?> But it doesn't works! Can someone explain to me. Thanks! From Steve.Lime at DNR.STATE.MN.US Wed Jul 11 21:42:49 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Wed, 11 Jul 2007 23:42:49 -0500 Subject: Dynamic map annotation in animated GIF file Message-ID: Robert: I think I would approach this slightly differently using a layer definition like: LAYER NAME 'copyright' TYPE ANNOTATION STATUS OFF FEATURE POINTS ... END END CLASS LABEL ... END TEXT 'Image Date Goes Here' END END Then in the script you'd use the classObj setText() method to alter the timestamp. Essentially the TEXT property allows you to set a text constant that is applied to all features. In this case it's only one. I think you'll find it's a bit more straight forward. Steve >>> "Burgholzer,Robert" 07/11/07 9:04 AM >>> Julien, Thanks for your suggestions. I am close, although the points are not being rendered. They return a "MS_SUCCESS", however, it does not show on the map. I have tried many possibilities, but am thus far unable to get success. r.b. -----Original Message----- From: Julien-Samuel Lacroix [mailto:jlacroix at mapgears.com] Sent: Monday, July 09, 2007 8:32 PM To: Burgholzer,Robert Cc: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Dynamic map annotation in animated GIF file Hi, You are right. PHP/MapScript doesn't provide the TEXT portion of an annotation feature. It's because it's easier to add directly a point on the top of the map. Instead of adding a FEATURE object to the layer, simply create a point object and draw it on the map image. (Following code not tested) // Outside the loop create a pointObj $oPoint = ms_newPointObj(); $oPoint->setXY(1,1); [...snipp...] // Inside the foreach, draw your map without the copyright layer $thislayer->set("status",MS_OFF); $image[$i] = $amap->map->draw(); // Then draw the point on the top of it // Don't forget to remove the FEATURE object in the mapfile // Also you should give a name to your class in the copyright layer // For now, I'll use "CLASSNAME" $thislayer->set("status",MS_ON); $oPoint->draw($amap->map, $thislayer, $image[$i], "CLASSNAME", $filter); $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); [...snip...] The code is not tested, but it should give you a good idea. Julien Burgholzer,Robert wrote: > I am trying to produce a time series animated GIF, with an annotation at > the bottom of the map that shows the time. Thanks to an example from > Charlton Purvis found by a search of previous postings on making an > animated GIF (modified to use a single layer, changing the filter to > select for the data that is in my current time step): > > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0304/msg00482.h tml > > > > And a Wiki entry from Jeff McKenna about making a copyright notation: > > http://mapserver.gis.umn.edu/docs/faq/copyright-layer > > > > I have the basics, that is, an animated time series, with a statically > placed text entry at the bottom (at a map-specific point, rather than a > lat lon). However, the annotation layer can only display a single > entry, not one that is updated with the time step. I am wondering how > to do this, if I can modify the property of the annotation layer, or if > I need to create a point of some sort from a dynamic postgis call. I > can't seem to set the TEXT portion of the feature via php mapscript. > > > > Anyone have any ideas? (code and mapfile follow) > > > > foreach ($gifmaps as $thismap) { > > $thislayer = $amap->map->getLayerByName('stream_stat'); > > $filter = " projectid = $projectid and thismetric = '$thismap' "; > > $listobject->querystring = " select count(*) as numrecs from > proj_group_stat "; > > $listobject->querystring .= " where $filter "; > > $listobject->performQuery(); > > $numrecs = $listobject->getRecordValue(1,'numrecs'); > > #$annotlayer = $amap->map->getLayerByName('copyright'); > > #$annotation = $annotlayer->getFeature(1,-1); > > if ($numrecs > 0) { > > $thislayer->setFilter($filter); > > $thislayer->set("status",MS_ON); > > #$annotation->set("TEXT", $filter); > > $image[$i] = $amap->map->draw(); > > $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); > > $file_path[$i] = $amap->map->web->imagepath > > . substr(strrchr($image_url[$i], "/"),1); > > $anim_files = $anim_files . '"' . $file_path[$i] . '"' . " "; > > $i++; > > print(" Adding $filter, $image_url[$i]
    "); > > } > > } > > > > // Create a unique filename and URL for the animated GIF output > > $anim_name = "anim".substr(strrchr($image_url[1], '/'),1); > > $anim_path = '"' . $amap->map->web->imagepath . $anim_name .'"'; > > $anim_url = $amap->map->web->imageurl . $anim_name; > > > > print("Creating $anim_path
    "); > > $cmd = $anim_gif_cmd . " -o " . $anim_path . " " . $anim_files; > > print("Using: $cmd
    "); > > > > system($cmd); > > > > # annotation layer > > LAYER > > NAME copyright > > STATUS ON > > TYPE annotation > > TRANSFORM false > > FEATURE > > POINTS > > 150 180 #this is the position of the text in image coordinates > (pixels) > > END > > TEXT "From 2007/01/01 to 2007/06/30" #this is your displaying text > > END > > CLASS > > LABEL #defines the font, colors etc. of the text > > FONT "arial" > > TYPE TRUETYPE > > SIZE 10 > > BUFFER 1 > > COLOR 0 0 0 > > BACKGROUNDCOLOR 255 255 255 > > FORCE TRUE > > END > > END > > END > > Robert W. Burgholzer > > Surface Water Modeler > > Office of Water Supply and Planning > > Virginia Department of Environmental Quality > > rwburgholzer at deq.virginia.gov > > 804-698-4405 > > Open Source Modeling Tools: > > http://sourceforge.net/projects/npsource/ > > > -- Julien-Samuel Lacroix Mapgears http://www.mapgears.com/ From veeraswamyd at YAHOO.CO.IN Thu Jul 12 00:00:22 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Thu, 12 Jul 2007 00:00:22 -0700 Subject: warning In-Reply-To: <11544958.post@talk.nabble.com> Message-ID: hi apache is running and also my application is also running but is displaying warning as "Warning: imagettfbbox() [function.imagettfbbox]: Invalid font filename in C:\ms4w\apps\chameleon\htdocs\common\buttonizer\buttonizer.php on line 533" plz tell me this -- View this message in context: http://www.nabble.com/download-error-tf4063403.html#a11554680 Sent from the Mapserver - User mailing list archive at Nabble.com. From veeraswamyd at YAHOO.CO.IN Thu Jul 12 00:02:36 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Thu, 12 Jul 2007 00:02:36 -0700 Subject: imagettfbbox() Message-ID: hi apache is running and also my application is also running but is displaying warning as "Warning: imagettfbbox() [function.imagettfbbox]: Invalid font filename in C:\ms4w\apps\chameleon\htdocs\common\buttonizer\buttonizer.php on line 533" plz tell me this -- View this message in context: http://www.nabble.com/imagettfbbox%28%29-tf4066443.html#a11554723 Sent from the Mapserver - User mailing list archive at Nabble.com. From mweinelt at PLANIGLOBE.COM Thu Jul 12 00:45:43 2007 From: mweinelt at PLANIGLOBE.COM (Martin Weinelt) Date: Thu, 12 Jul 2007 09:45:43 +0200 Subject: Mapscript, SVG and Annotations In-Reply-To: <200707111046.26115.mweinelt@planiglobe.com> Message-ID: We talked a bit about that issue here and one guy brought up the anti-overposting feature with labels POSITION set to 'auto'. I did not look at the code, but he mentioned that anti-overposting often is based on matrices. This would be straight forward for output on raster maps, but would that count for vector output as well? Just an idea, Martin On Mittwoch 11 Juli 2007, Martin Weinelt wrote: > Thanks a lot, > > your tips at least kept trying. What I did was translate your > example to Perl mapscript. Some PHP methods are not available or a > bit different in the SWIG versions. That looks like this: > > my $oShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > my $oLine = new mapscript::lineObj; > my $oPt = new mapscript::pointObj; > $oPt->setXY(-11, 22); # DD > $oLine->add($oPt); > $oShp->add($oLine); > $oShp->{text} = 'Hello World'; > my $numlayers = $map->{numlayers}; > my $oLayer; > for (my $h=0; $h<$numlayers; $h++) { > $oLayer = $map->getLayer($h); > $oLayer->{status} = $mapscript::MS_OFF; > } > > $oLayer = $map->getLayerByName('popplace'); > $oLayer->{status} = $mapscript::MS_ON; > $oLayer->addFeature($oShp); > # here the loop below is going to be inserted > my $SVGimg = $map->draw(); > my $svg_file = '/path/to/willi.svg'; > $SVGimg->save($svg_file); > > The result is exactly like yours: including the label. Ok. > But now I add the following: > > for (my $foo=0; $foo < 3; $foo++) { > $oShp = new mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > $oLine = new mapscript::lineObj; > $oPt = new mapscript::pointObj; > $oPt->setXY($foo,$foo); > $oLine->add($oPt); > $oShp->add($oLine); > $oShp->{text} = 'Hello World ' . "$foo"; > $oLayer->addFeature($oShp); > $oShp=$oLine=$oPt=undef; # don't know if this is needed > } > > this is the result: > > > xmlns="http://www.w3.org/2000/svg" > xmlns:xlink="http://www.w3.org/1999/xlink"> > > > > > > > fill="#ff0000" stroke="#ffffff" stroke-width="0.5" > transform="rotate(-10.000000 249 142)">Hello World > > > What you see is that the labels from the loop are missing while the > label from the first addFeature is there. Weird. > > Going through the MAP-file reference I find the 'FORCE' property > for labels. Setting 'FORCE' to 'true' did the trick. All labels, > including those from the loop, do now appear in the SVG. I do not > know if this is exactly what I want, but at least I got my labels. > > Cheers, > > Martin > > On Dienstag 10 Juli 2007, Yewondwossen Assefa wrote: > > Hi there, > > > > I did a quick test using php mapscript and an svg output. The > > poplace layer in the map file is a point layer and has a class > > with a label object (note that there is no labelitem set) > > > > LAYER > > NAME popplace > > TYPE POINT > > STATUS ON > > ... > > CLASS > > style > > SYMBOL 'circle' > > SIZE 6 > > COLOR 0 0 255 > > END > > LABEL > > COLOR 255 0 0 > > # FONT fritqat-italic > > FONT Arial > > TYPE truetype > > SIZE 12 > > ANGLE 10 > > POSITION AUTO > > PARTIALS FALSE > > OUTLINECOLOR 255 255 255 > > END > > ... > > > > script looks something like this > > > > $oMap = ms_newmapobj("c:/msapps/gmap-ms40/htdocs/gmap75.map"); > > > > $oShp = ms_newShapeObj(MS_SHAPE_POINT); > > > > $oLine = ms_newLineObj(); > > > > $oLine->addXY(-2299954.0642738,-612631); > > $oShp->add( $oLine ); > > > > $oShp->set("text", "mytext"); > > > > $numlayers = $oMap->numlayers; > > for ($i=0; $i<$numlayers; $i++) > > { > > $oLayer = $oMap->getlayer($i); > > $oLayer->set("status", MS_OFF); > > } > > $oLayer = $oMap->getlayerbyname('popplace'); > > $oLayer->set("status", MS_ON); > > $oLayer->addfeature($oShp); > > > > $img = $oMap->draw(); > > $url = $img->saveWebImage(); > > > > header("Content-type: image/svg+xml"); > > $url = $img->saveImage(""); > > > > > > It produces an svg point with the label my text : > > > > ... > > > > > > > fill="#ff0000" stroke="#ffffff" stroke-width="0.5" > > transform="rotate(-10.000000 38 581)">mytext > > > > > > Not sure what the issue would be in your case, the only time I > > did not have the text produced was when I set the labelitem > > object. Could that be the case ? > > > > > > Later > > > > kk+w - digitale kartografie GmbH wrote: > > > Hi, > > > > > > I am using addFeature to dynamically add site locations with a > > > label to a map. It's Perl mapscript. > > > > > > @sites is an array of hash references, $sitesLyr is from the > > > map file: > > > > > > ############### > > > foreach my $site (@sites) { > > > my $site_pt = $$site{'site_loc'}; > > > $site_pt =~s/.*\((.*)\)*./$1/; # extract the points x > > > and y my $line = new mapscript::lineObj(); > > > my $siteShp = new > > > mapscript::shapeObj($mapscript::MS_SHAPE_POINT); > > > > > > my $point = new mapscript::pointObj(); > > > my($x,$y) = split(/ /, $site_pt); > > > $point->setXY($x,$y); > > > $line->add($point); > > > $siteShp->add($line); > > > $siteShp->{text} = $$site{'site_name'}; > > > $siteShp->setBounds(); > > > $sitesLyr->addFeature($siteShp); > > > } > > > > > > my $img = $map->draw(); > > > > > > ############# > > > > > > This works perfectly for the usual PNG output map. Using the > > > same routine for a SVG 'image' results in the symbols/markers > > > getting plotted, but the labels are missing. If I switch to a > > > static shapefile for this layer, the labels do appear in the > > > SVG. > > > > > > Is there anything special with SVG output and the 'addFeature' > > > method for layers that I am missing? > > > > > > Thanks, > > > > > > Martin From thomas.rokkjaer at GMAIL.COM Thu Jul 12 02:06:50 2007 From: thomas.rokkjaer at GMAIL.COM (Thomas Rokkjaer) Date: Thu, 12 Jul 2007 11:06:50 +0200 Subject: Compiling with OGR version supporting SQL server connection In-Reply-To: <46953944.8090508@pobox.com> Message-ID: Great thanks Frank. You pointed me in the right direction. Found that I simply had to set the ODBC to System DSN. BR Thomas Rokkjaer On 7/11/07, Frank Warmerdam wrote: > > Thomas Rokkjaer wrote: > > I have followed the guidelines for setting up a virtual spatial data > connection > > at > > > http://mapserver.gis.umn.edu/docs/reference/vector_data/VirtualSpatialData > , > > installed FWTools 1.3.4, tested the connection via ogrinfo successfully, > tested > > the mapfile (specific layer attached) with the shp2img tool > successfully, but I > > am having problems with displaying this newly generated layer in my map > > window. > > At http://mapserver.gis.umn.edu/docs/howto/ogrmysql I found a how-to for > > OGR connection to MySQL, where it is stated the following > > prerequisite "MapServer compiled with OGR version supporting this > > functinality". How is it possible to compile my current MapServer to > support > > OGR for SQL server or should it already work with the current settings? > > Thomas, > > You are configured to use the OGR ODBC driver, which should be available > in any GDAL/OGR windows build. So there is nothing special required. The > MySQL case is accessing MySQL directly rather than through ODBC. > > If shp2img is working, I'd suggest you carefully review permissions for > use of the ODBC DSN for whatever user your web server is running as. > > > STYLEITEM "AUTO" > > BTW, I don't believe that STYLEITEM "AUTO" is going to do anything > for ODBC/VRT datasources. It mostly is useful for mapinfo, and dgn > file formats. > > 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 | President OSGeo, http://osgeo.org > > -- Med venlig hilsen Thomas Rokkj?r Mobil 3095 0774 http://picasaweb.google.com/thomas.rokkjaer -------------- next part -------------- An HTML attachment was scrubbed... URL: From pgiannini at BYTEWISE.IT Thu Jul 12 05:47:51 2007 From: pgiannini at BYTEWISE.IT (Pietro Giannini) Date: Thu, 12 Jul 2007 14:47:51 +0200 Subject: Open a shapefile and read its shapes' attributes In-Reply-To: Message-ID: Hi Knight, the php_mapscript ShapefileObj object do not read the values of the shapes (?!?), it seems. You must to read the values in the .dbf file; the dbf entries are in the same order of the shapes. Your php need the "php_dbase" extension. the code: numshapes; if($numshapes > 0) { for($i = 0; $i < $numshapes; $i++) { $Line = $LineFile->getShape($i); $aLineValues = dbase_get_record_with_names($LineDBFFile,$i); $RouteName = $aLineValues["RouteName"]; printf($RouteName ); $Line->free(); } } $LineFile->free(); dbase_close($LineDBFFile); ?> ciao ...............................pg -- Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E On Gio, Luglio 12, 2007 05:11, Jedi Knight wrote: > Hi all, > I want to open a line shapefile (routes.shp) and read attribute > (RouteName) > from it. > My codes here: > $Path = '\ms4w\apps\map\routes.shp'; // must use full path [:(] > $LineFile = ms_newShapefileObj($Path,-1); // open for read-only > $numshapes = $LineFile->numshapes; > if($numshapes > 0) > { > for($i = 0; $i < $numshapes; $i++) > { > $Line = $LineFile->getShape($i); > $RouteName = $Line->values["RouteName"]; > printf($RouteName ); // it show nothing > $Line->free(); > } > } > $LineFile->free(); > ?> > > But it doesn't works! > Can someone explain to me. Thanks! > From Dejan.Gambin at PULA.HR Thu Jul 12 05:33:00 2007 From: Dejan.Gambin at PULA.HR (Gambin Dejan) Date: Thu, 12 Jul 2007 14:33:00 +0200 Subject: Help with TIFFTAGs resolutions Message-ID: Hi, I have a situation that I need to understand, I hope someone can help: I have a number of ortophoto images in tif format (with .tfw files). When I show them on my map they should be spatialy "connected" but the "empty" space shows between them. Here is the example gdalinfo result of the two horizontally adjacent images that should be "connected": gdalinfo first.tif-> Driver: GTiff/GeoTIFF Size is 2812, 3750 Coordinate System is `' Origin = (5405500.000000000000000,4980000.000000000000000) Pixel Size = (0.500000000000000,-0.500000000000000) Metadata: TIFFTAG_XRESOLUTION=45 TIFFTAG_YRESOLUTION=45 TIFFTAG_RESOLUTIONUNIT=2 (pixels/inch) Corner Coordinates: Upper Left ( 5405500.000, 4980000.000) Lower Left ( 5405500.000, 4978125.000) Upper Right ( 5406906.000, 4980000.000) Lower Right ( 5406906.000, 4978125.000) Center ( 5406203.000, 4979062.500) Band 1 Block=2812x1 Type=Byte, ColorInterp=Red Band 2 Block=2812x1 Type=Byte, ColorInterp=Green Band 3 Block=2812x1 Type=Byte, ColorInterp=Blue gdalinfo second.tif: Driver: GTiff/GeoTIFF Size is 2812, 3750 Coordinate System is `' Origin = (5407750.000000000000000,4980000.000000000000000) Pixel Size = (0.500000000000000,-0.500000000000000) Metadata: TIFFTAG_XRESOLUTION=45 TIFFTAG_YRESOLUTION=45 TIFFTAG_RESOLUTIONUNIT=2 (pixels/inch) Corner Coordinates: Upper Left ( 5407750.000, 4980000.000) Lower Left ( 5407750.000, 4978125.000) Upper Right ( 5409156.000, 4980000.000) Lower Right ( 5409156.000, 4978125.000) Center ( 5408453.000, 4979062.500) Band 1 Block=2812x1 Type=Byte, ColorInterp=Red Band 2 Block=2812x1 Type=Byte, ColorInterp=Green Band 3 Block=2812x1 Type=Byte, ColorInterp=Blue Now, I have the similar set of ortophoto images that show correctly and they come from the same source (the National State Geodetic Administration). I have compared them and the difference is that this "correct" images have the size of 4500x6000 (exactly 1.6 bigger than the first one) and their TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are 72 (that is 45x1.6). My question is: who "made the mistake" and what do I have to do to show them correctly (they are shown correctly from a dwg file that is referencing them all)? Are the TFW files wrong for this resolution? Do I have to change the resolution, image size, or what? I would appreciate any information, Thanks very much regards, dejan From cplist at SECONDCREEK.ORG Thu Jul 12 06:07:21 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 12 Jul 2007 09:07:21 -0400 Subject: SOS disconnect Message-ID: > > I was able to reproduce the GetCapabilities issues with 4.10.2. The > > bugs were corrected in the current svn version (to be 5.0). I also back > > ported them in the 4.10.x branch in case there is a 4.10.3 release. If > > possible please upgrade to either versions and so the tests. > > We'll upgrade ASAP and report back. Assefa, it works like a charm. Many thanks! I still have a problem w/ eventTime being handled properly. I'll send that out as a separate post w/ a simple test case and see if you and Tom would like for me to file it as a bug. We really appreciate your quick and hard work. Charlton From cplist at SECONDCREEK.ORG Thu Jul 12 06:12:42 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 12 Jul 2007 09:12:42 -0400 Subject: SOS eventTime apparently not working Message-ID: Hi, all: The following long URL should not return any hits since there is no record in our db that falls between the eventTime range I specify as part of the URL. http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetObservation&ver sion=0.1.2&offering=ndbc_44029&responseFormat=text/xml;%20subtype=om/0.14.7& observedProperty=http://marinemetadata.org/cf%23air_pressure_at_sea_level&ev entTime=1990-01-011990-02-01 There is always only 1 row that should be returned -- the most recent observation. As of right now, the time is which isn't anywhere near the TimePeriods defined in the query URL. Am I doing something wrong -- that is likely! "sos_timeitem" "m_date" "sos_offering_timeextent" "20070530T1800Z" It appears that I'm registering the time column properly since it does show up in the XML. MapServer version 4.99 TIA! Charlton From Tom.Kralidis at EC.GC.CA Thu Jul 12 06:24:35 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Thu, 12 Jul 2007 09:24:35 -0400 Subject: SOS eventTime apparently not working In-Reply-To: A<008501c7c486$5557fd00$650fa8c0@latitude> Message-ID: > The following long URL should not return any hits since there > is no record in our db that falls between the eventTime range > I specify as part of the URL. > > http://sos-web.tamu.edu/sos-cgi/madis?service=sos&request=GetO > bservation&ver > sion=0.1.2&offering=ndbc_44029&responseFormat=text/xml;%20subt > ype=om/0.14.7& > observedProperty=http://marinemetadata.org/cf%23air_pressure_a > t_sea_level&ev > entTime=1990-01-01 inPosition> l:endPosition>1990-02-01 > > There is always only 1 row that should be returned -- the > most recent observation. As of right now, the time is > which isn't anywhere near > the TimePeriods defined in the query URL. > > Am I doing something wrong -- that is likely! > > "sos_timeitem" "m_date" > "sos_offering_timeextent" "20070530T1800Z" > > It appears that I'm registering the time column properly > since it does show up in the XML. > > MapServer version 4.99 What does your underlying data connection look like? Any chance you can wrap up a test case (.map file and small sample data?) ..Tom From cplist at SECONDCREEK.ORG Thu Jul 12 06:57:52 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 12 Jul 2007 09:57:52 -0400 Subject: SOS eventTime apparently not working In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F49@ecburexch1.ontario.int.ec.gc.ca> Message-ID: > What does your underlying data connection look like? Any chance you can > wrap up a test case (.map file and small sample data?) The underlying data is in postgis. I have created a simple csv via ogr test case here. Untar into /tmp to keep the pathnames in sync. http://your.box.here/cgi-bin/mapserv?map=/tmp/madis_tst.map&service=sos&requ est=GetObservation&version=0.1.2&offering=ndbc_44029&responseFormat=text/xml ;%20subtype=om/0.14.7&observedProperty=http://marinemetadata.org/cf%23air_pr essure_at_sea_level&eventTime=1990-01-01< /gml:beginPosition>1990-02-01
    That shouldn't return any hits, but it does. Thanks! Charlton -------------- next part -------------- A non-text attachment was scrubbed... Name: sos_tst.tar Type: application/x-tar Size: 10240 bytes Desc: not available URL: From Tom.Kralidis at EC.GC.CA Thu Jul 12 07:25:20 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Thu, 12 Jul 2007 10:25:20 -0400 Subject: SOS eventTime apparently not working In-Reply-To: <008a01c7c48c$a4658290$650fa8c0@latitude> Message-ID: > > > What does your underlying data connection look like? Any > chance you > > can wrap up a test case (.map file and small sample data?) > > The underlying data is in postgis. I have created a simple > csv via ogr test case here. Untar into /tmp to keep the > pathnames in sync. > > http://your.box.here/cgi-bin/mapserv?map=/tmp/madis_tst.map&se > rvice=sos&requ > est=GetObservation&version=0.1.2&offering=ndbc_44029&responseF > ormat=text/xml > ;%20subtype=om/0.14.7&observedProperty=http://marinemetadata.o > rg/cf%23air_pr > essure_at_sea_level&eventTime= on>1990-01-01< > /gml:beginPosition>1990-02-01 n> riod> > > That shouldn't return any hits, but it does. > I'm able to reproduce the issue. I've opened a ticket at http://trac.osgeo.org/mapserver/ticket/2154 From pgiannini at BYTEWISE.IT Thu Jul 12 07:51:43 2007 From: pgiannini at BYTEWISE.IT (Pietro Giannini) Date: Thu, 12 Jul 2007 16:51:43 +0200 Subject: Open a shapefile and read its shapes' attributes In-Reply-To: <469623BA.6040706@neogeo-online.net> Message-ID: you are right!! the code is: numshapes; if($numshapes > 0) { for($i = 0; $i < $numshapes; $i++) { $Line = $LineFile->getShape($i); // note the index: '$i+1' $aLineValues = dbase_get_record_with_names($LineDBFFile,$i+1); $RouteName = $aLineValues["RouteName"]; printf($RouteName ); $Line->free(); } } $LineFile->free(); dbase_close($LineDBFFile); ?> .................pg -- Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E On Gio, Luglio 12, 2007 14:51, Guillaume Sueur wrote: > Be careful, DBF index starts at 1, not 0 if I'm right ! > > > Pietro Giannini a ?crit : >> Hi Knight, >> >> the php_mapscript ShapefileObj object do not read the values of the >> shapes >> (?!?), it seems. >> You must to read the values in the .dbf file; the dbf entries are in the >> same order of the shapes. >> Your php need the "php_dbase" extension. >> >> the code: >> >> > >> $Path = '\ms4w\apps\map\routes.shp'; >> // the dbf file identifier: >> $LineDBFFile = dbase_open("\ms4w\apps\map\routes.dbf",0); >> $LineFile = ms_newShapefileObj($Path,-1); >> $numshapes = $LineFile->numshapes; >> if($numshapes > 0) >> { >> for($i = 0; $i < $numshapes; $i++) >> { >> $Line = $LineFile->getShape($i); >> $aLineValues = dbase_get_record_with_names($LineDBFFile,$i); >> $RouteName = $aLineValues["RouteName"]; >> printf($RouteName ); >> $Line->free(); >> } >> } >> $LineFile->free(); >> dbase_close($LineDBFFile); >> >> ?> >> >> ciao >> ...............................pg >> >> > > -- > Guillaume SUEUR > Expert SIG et OpenSource > NEOGEO > 46 RUE MATABIAU > 31000 TOULOUSE > 06 65 58 88 82 > Site web : http://www.neogeo-online.net > > From rwburgholzer at DEQ.VIRGINIA.GOV Thu Jul 12 09:48:04 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Thu, 12 Jul 2007 12:48:04 -0400 Subject: Dynamic map annotation in animated GIF file Message-ID: Thanks Steve, that worked like a charm! Robert -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Steve Lime Sent: Thursday, July 12, 2007 12:43 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Dynamic map annotation in animated GIF file Robert: I think I would approach this slightly differently using a layer definition like: LAYER NAME 'copyright' TYPE ANNOTATION STATUS OFF FEATURE POINTS ... END END CLASS LABEL ... END TEXT 'Image Date Goes Here' END END Then in the script you'd use the classObj setText() method to alter the timestamp. Essentially the TEXT property allows you to set a text constant that is applied to all features. In this case it's only one. I think you'll find it's a bit more straight forward. Steve >>> "Burgholzer,Robert" 07/11/07 9:04 AM >>> Julien, Thanks for your suggestions. I am close, although the points are not being rendered. They return a "MS_SUCCESS", however, it does not show on the map. I have tried many possibilities, but am thus far unable to get success. r.b. -----Original Message----- From: Julien-Samuel Lacroix [mailto:jlacroix at mapgears.com] Sent: Monday, July 09, 2007 8:32 PM To: Burgholzer,Robert Cc: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Dynamic map annotation in animated GIF file Hi, You are right. PHP/MapScript doesn't provide the TEXT portion of an annotation feature. It's because it's easier to add directly a point on the top of the map. Instead of adding a FEATURE object to the layer, simply create a point object and draw it on the map image. (Following code not tested) // Outside the loop create a pointObj $oPoint = ms_newPointObj(); $oPoint->setXY(1,1); [...snipp...] // Inside the foreach, draw your map without the copyright layer $thislayer->set("status",MS_OFF); $image[$i] = $amap->map->draw(); // Then draw the point on the top of it // Don't forget to remove the FEATURE object in the mapfile // Also you should give a name to your class in the copyright layer // For now, I'll use "CLASSNAME" $thislayer->set("status",MS_ON); $oPoint->draw($amap->map, $thislayer, $image[$i], "CLASSNAME", $filter); $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); [...snip...] The code is not tested, but it should give you a good idea. Julien Burgholzer,Robert wrote: > I am trying to produce a time series animated GIF, with an annotation at > the bottom of the map that shows the time. Thanks to an example from > Charlton Purvis found by a search of previous postings on making an > animated GIF (modified to use a single layer, changing the filter to > select for the data that is in my current time step): > > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0304/msg00482.h tml > > > > And a Wiki entry from Jeff McKenna about making a copyright notation: > > http://mapserver.gis.umn.edu/docs/faq/copyright-layer > > > > I have the basics, that is, an animated time series, with a statically > placed text entry at the bottom (at a map-specific point, rather than a > lat lon). However, the annotation layer can only display a single > entry, not one that is updated with the time step. I am wondering how > to do this, if I can modify the property of the annotation layer, or if > I need to create a point of some sort from a dynamic postgis call. I > can't seem to set the TEXT portion of the feature via php mapscript. > > > > Anyone have any ideas? (code and mapfile follow) > > > > foreach ($gifmaps as $thismap) { > > $thislayer = $amap->map->getLayerByName('stream_stat'); > > $filter = " projectid = $projectid and thismetric = '$thismap' "; > > $listobject->querystring = " select count(*) as numrecs from > proj_group_stat "; > > $listobject->querystring .= " where $filter "; > > $listobject->performQuery(); > > $numrecs = $listobject->getRecordValue(1,'numrecs'); > > #$annotlayer = $amap->map->getLayerByName('copyright'); > > #$annotation = $annotlayer->getFeature(1,-1); > > if ($numrecs > 0) { > > $thislayer->setFilter($filter); > > $thislayer->set("status",MS_ON); > > #$annotation->set("TEXT", $filter); > > $image[$i] = $amap->map->draw(); > > $image_url[$i] = $image[$i]->saveWebImage(MS_GIF,1,1,0); > > $file_path[$i] = $amap->map->web->imagepath > > . substr(strrchr($image_url[$i], "/"),1); > > $anim_files = $anim_files . '"' . $file_path[$i] . '"' . " "; > > $i++; > > print(" Adding $filter, $image_url[$i]
    "); > > } > > } > > > > // Create a unique filename and URL for the animated GIF output > > $anim_name = "anim".substr(strrchr($image_url[1], '/'),1); > > $anim_path = '"' . $amap->map->web->imagepath . $anim_name .'"'; > > $anim_url = $amap->map->web->imageurl . $anim_name; > > > > print("Creating $anim_path
    "); > > $cmd = $anim_gif_cmd . " -o " . $anim_path . " " . $anim_files; > > print("Using: $cmd
    "); > > > > system($cmd); > > > > # annotation layer > > LAYER > > NAME copyright > > STATUS ON > > TYPE annotation > > TRANSFORM false > > FEATURE > > POINTS > > 150 180 #this is the position of the text in image coordinates > (pixels) > > END > > TEXT "From 2007/01/01 to 2007/06/30" #this is your displaying text > > END > > CLASS > > LABEL #defines the font, colors etc. of the text > > FONT "arial" > > TYPE TRUETYPE > > SIZE 10 > > BUFFER 1 > > COLOR 0 0 0 > > BACKGROUNDCOLOR 255 255 255 > > FORCE TRUE > > END > > END > > END > > Robert W. Burgholzer > > Surface Water Modeler > > Office of Water Supply and Planning > > Virginia Department of Environmental Quality > > rwburgholzer at deq.virginia.gov > > 804-698-4405 > > Open Source Modeling Tools: > > http://sourceforge.net/projects/npsource/ > > > -- Julien-Samuel Lacroix Mapgears http://www.mapgears.com/ From bthoen at GISNET.COM Thu Jul 12 10:30:02 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Thu, 12 Jul 2007 11:30:02 -0600 Subject: Changing Map Projection Dynamically Message-ID: This has probably been asked before, but I can't find any info on it. Basically, I'd like to know how to change the map projection in MapServer as I zoom in to a larger scale map view. Specifically, I start at a national scale using a Lambert projection, but when I zoom into a state scale, I'd like to choose a more appropriate projection (like State Plane). Can this be done easily with a map file or an HTML template? What's the best way to solve this problem? - Bill Thoen From ebalas at GRNOC.IU.EDU Thu Jul 12 11:20:53 2007 From: ebalas at GRNOC.IU.EDU (Edward G. Balas) Date: Thu, 12 Jul 2007 14:20:53 -0400 Subject: Changing Map Projection Dynamically In-Reply-To: <4696651A.9050109@gisnet.com> Message-ID: Bill, I ran into a similar issue, basically the question came to if you can specify the projection inside the request URL I think you'd be able to put it in the HTML template. The value associated with map_PROJECTION has commas in it that need encodeing. http://localhost/cgi-bin/mapserv?map=/gnoc/mapserver/ grnoc.map&mapext=-125%2024%20-60%2070&mode=map&map_PROJECTION=proj% 3dortho,lon_0%3d-90,lat_0%3d-10 On Jul 12, 2007, at 1:30 PM, Bill Thoen wrote: > This has probably been asked before, but I can't find any info on > it. Basically, I'd like to know how to change the map projection in > MapServer as I zoom in to a larger scale map view. Specifically, I > start at a national scale using a Lambert projection, but when I > zoom into a state scale, I'd like to choose a more appropriate > projection (like State Plane). > > Can this be done easily with a map file or an HTML template? What's > the best way to solve this problem? > > - Bill Thoen --- Edward G. Balas ebalas at grnoc.iu.edu -------------- next part -------------- An HTML attachment was scrubbed... URL: From condit at SDSC.EDU Thu Jul 12 11:36:56 2007 From: condit at SDSC.EDU (Christopher Condit) Date: Thu, 12 Jul 2007 11:36:56 -0700 Subject: very large tile index In-Reply-To: A<6C097DA58429B743A67070F98BE73A37025EF879@deqex01.deq.local> Message-ID: I've got a fairly large set of .tif files (A total of 2774 images at roughly 400mgs each). They've all had gdaladdo run (at 2 4 8 16), and then a tile index created. If I attempt to draw the map with mapserver at the full extents, the cgi request times out. I realize this is too much data, but the question is: how do I find out at what point the tile index will break down and overview should be used? Also, if MapServer won't draw the composite image, will shp2image work? This is running on a linux machine with 4 2.8 ghz Pentiums and 4gb RAM... Thanks, Chris Condit condit at sdsc.edu San Diego Supercomputer Center 9500 Gilman Drive La Jolla, CA 92093-0505 From warmerdam at POBOX.COM Thu Jul 12 11:49:53 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 12 Jul 2007 14:49:53 -0400 Subject: Changing Map Projection Dynamically In-Reply-To: <4696651A.9050109@gisnet.com> Message-ID: Bill Thoen wrote: > This has probably been asked before, but I can't find any info on it. > Basically, I'd like to know how to change the map projection in > MapServer as I zoom in to a larger scale map view. Specifically, I start > at a national scale using a Lambert projection, but when I zoom into a > state scale, I'd like to choose a more appropriate projection (like > State Plane). > > Can this be done easily with a map file or an HTML template? What's the > best way to solve this problem? Bill, I likely shouldn't speak up since I don't really know the best way to do this. But I do not believe it can be done entirely from the server side with mapserv cgi and a map file. Either you would have to have a mapscript application on the server that decided at some point to switch projections or you would have to engineer all the logic on the client side. With WMS you can request specific projections using the SRS (or CRS?) item in the request. With the non-OGC "classic" mapserver interface there is also a way of overriding the map projection which I think has been recently discussed on this list though I don't know the exact details. But one important thing to remember is that the region requested is going to have to match the projection which means there has to be quite a bit of smarts either in the client (to change the coordinate system of the BBOX) or in a mapscript script on the server to reproject the requested box into the alternate projection. And in that case the returned window won't be exactly what was requested. 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 | President OSGeo, http://osgeo.org From warmerdam at POBOX.COM Thu Jul 12 11:52:30 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 12 Jul 2007 14:52:30 -0400 Subject: very large tile index In-Reply-To: <845AADAC1106E44996327D62097E4C6BDACC2E@et.ad.sdsc.edu> Message-ID: Christopher Condit wrote: > I've got a fairly large set of .tif files (A total of 2774 images at > roughly 400mgs each). They've all had gdaladdo run (at 2 4 8 16), and > then a tile index created. If I attempt to draw the map with mapserver > at the full extents, the cgi request times out. I realize this is too > much data, but the question is: how do I find out at what point the tile > index will break down and overview should be used? Also, if MapServer > won't draw the composite image, will shp2image work? > This is running on a linux machine with 4 2.8 ghz Pentiums and 4gb > RAM... Chris, Mapserv *should* work if given enough time but for a full overview image processing through 2700 files still takes quite a while. Likewise shp2img should work. The operational solution is to create a low resolution mosaiced layer all in one file and use MINSCALE/MAXSCALE on the layers to switch between the tileindex layer and the overview layer at appropriate scales. 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 | President OSGeo, http://osgeo.org From warmerdam at POBOX.COM Thu Jul 12 11:58:22 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 12 Jul 2007 14:58:22 -0400 Subject: Help with TIFFTAGs resolutions In-Reply-To: Message-ID: Gambin Dejan wrote: > Hi, > > I have a situation that I need to understand, I hope someone can help: > > I have a number of ortophoto images in tif format (with .tfw files). > When I show them on my map they should be spatialy "connected" but the > "empty" space shows between them. Here is the example gdalinfo result of > the two horizontally adjacent images that should be "connected": ... > Now, I have the similar set of ortophoto images that show correctly and > they come from the same source (the National State Geodetic > Administration). I have compared them and the difference is that this > "correct" images have the size of 4500x6000 (exactly 1.6 bigger than the > first one) and their TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are 72 > (that is 45x1.6). > > My question is: who "made the mistake" and what do I have to do to show > them correctly (they are shown correctly from a dwg file that is > referencing them all)? Are the TFW files wrong for this resolution? Do I > have to change the resolution, image size, or what? Dejan, It is unlikely that the DWG is utilizing the world files (.tfw) at all. So if the DWG view is correct it is likely that the world files are wrong. If you think the origin's in the world files are correct you could try changing the resolution in the world files to 0.8 from 0.5 and see if things are properly placed. The TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are not used for georeferenced placement or scaling by MapServer or other applications. BTW, GDAL and MapServer will utilize internal GeoTIFF tags in preference to the world files. So if there is wrong internal geotiff info it will get used instead of potentially correct worldfiles. Keep this in mind if the world files don't seem to agree with what gdalinfo is reporting. 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 | President OSGeo, http://osgeo.org From woodbri at SWOODBRIDGE.COM Thu Jul 12 11:58:27 2007 From: woodbri at SWOODBRIDGE.COM (Stephen Woodbridge) Date: Thu, 12 Jul 2007 14:58:27 -0400 Subject: very large tile index In-Reply-To: <845AADAC1106E44996327D62097E4C6BDACC2E@et.ad.sdsc.edu> Message-ID: Christopher Condit wrote: > I've got a fairly large set of .tif files (A total of 2774 images at > roughly 400mgs each). They've all had gdaladdo run (at 2 4 8 16), and > then a tile index created. If I attempt to draw the map with mapserver > at the full extents, the cgi request times out. I realize this is too > much data, but the question is: how do I find out at what point the tile > index will break down and overview should be used? Also, if MapServer > won't draw the composite image, will shp2image work? > This is running on a linux machine with 4 2.8 ghz Pentiums and 4gb > RAM... At full extents you still have to open 2774 images and depending on the zoom scale you might still need to take the 16th over and reprocess that. What you need to do is create external overviews using gdalwarp and then use min/max scale to control when to use the external overviews -Steve W From ed at TOPOZONE.COM Thu Jul 12 12:15:34 2007 From: ed at TOPOZONE.COM (Ed McNierney) Date: Thu, 12 Jul 2007 15:15:34 -0400 Subject: very large tile index In-Reply-To: <4696786E.90101@pobox.com> Message-ID: Chris - I will echo Frank's point from experience. Your disk subsystem, while it may be good, is the slowest part of your system and you don't mention what it is. Any disk is slowest at doing seeks from one location to another (as opposed to linear reads). Your request is, at a minimum, asking your system to open and read 2,774 individual files. Under optimal conditions this will probably require 2,774 seeks and possibly quite a few more (it wouldn't be surprising to have 5,000 - 10,000 seeks occur). A typical 7,200 RPM ATA drive will have a seek time of about 9 milliseconds, and will have an average latency of about 4.2 milliseconds. That means that a command to "open this file and read the header" will take a minimum of 13.2 milliseconds. You can only do 70 of those in one second, so if you want to do it 2,774 times you will need 40 seconds just to open all those files. Your overviews can make things considerably worse. If you wrote 2,774 TIF files to one directory, then ran gdaladdo 2,774 times on those files, you're going to append quite a bit of data to each file. If you were doing this on a blank disk, the first overview for the first file would probably need to go after the 2,774th file, etc. since the overviews are relatively big compared to your likely block size (if your files are 400MB those overviews will be 375MB). 2,774 files of 400MB each means that your first overview is over one terabyte away - that's a LONG seek. And then you'll have to go back for the next header, then back to the overview, etc. I presume you don't have a single 7200 RPM ATA drive holding your 2 terabytes of imagery , but you get the idea. Jumping around among a lot of files is a very time-consuming thing to do. Using GDAL to mosaic those file overviews together is an excellent idea. Instead of 2,774 files of 25MB each (for the 16x overview), an arrangement with 174 files of 400MB each will very likely be nearly 16 times faster. - Ed -- Ed McNierney Chief Mapmaker TopoZone.com 73 Princeton Street, Suite 305 North Chelmsford, MA 01863 Phone: (978) 251-4242 Fax: (978) 251-1396 ed at topozone.com > From: Frank Warmerdam > Reply-To: Frank Warmerdam > Date: Thu, 12 Jul 2007 14:52:30 -0400 > To: > Subject: Re: [UMN_MAPSERVER-USERS] very large tile index > > Christopher Condit wrote: >> I've got a fairly large set of .tif files (A total of 2774 images at >> roughly 400mgs each). They've all had gdaladdo run (at 2 4 8 16), and >> then a tile index created. If I attempt to draw the map with mapserver >> at the full extents, the cgi request times out. I realize this is too >> much data, but the question is: how do I find out at what point the tile >> index will break down and overview should be used? Also, if MapServer >> won't draw the composite image, will shp2image work? >> This is running on a linux machine with 4 2.8 ghz Pentiums and 4gb >> RAM... > > Chris, > > Mapserv *should* work if given enough time but for a full overview image > processing through 2700 files still takes quite a while. Likewise > shp2img should work. The operational solution is to create a low resolution > mosaiced layer all in one file and use MINSCALE/MAXSCALE on the layers to > switch between the tileindex layer and the overview layer at appropriate > scales. > > 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 | President OSGeo, http://osgeo.org From warmerdam at POBOX.COM Thu Jul 12 13:33:46 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 12 Jul 2007 16:33:46 -0400 Subject: very large tile index In-Reply-To: Message-ID: Ed McNierney wrote: > Your overviews can make things considerably worse. Folks, Ed has hit on a dirty little secret of overviews here. Because of the way they are stored in TIFF files and the way libtiff and GDAL scan for their availability, opening a TIFF file with overviews is presumably substantially more expensive than opening a file without them. The TIFF directories will tend to be distributed through the file meaning quite a bit of seeking to get them all, and a standard GDALOpen will scan for them all. I don't want to discourage use of internal overviews. They are great from many angles. But when in use, it is still important to avoid having to touch too many files. 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 | President OSGeo, http://osgeo.org From wef1 at CEC.WUSTL.EDU Thu Jul 12 13:57:04 2007 From: wef1 at CEC.WUSTL.EDU (Edward Fialkowski) Date: Thu, 12 Jul 2007 15:57:04 -0500 Subject: WFS from PostGIS, layer not found Message-ID: Hello, I'm trying to get MapServer to read from my postGIS database. I have a WFS set up, but I cannot get my layer to appear in the FeatureTypeList for the WFS getCapabilities, thus requests for this layer throw an error. I'm not quite sure what else to include, but here's my layer definition: LAYER CONNECTIONTYPE POSTGIS NAME FireHistory CONNECTION "dbname=test user=postgres" DATA "geometry FROM temp" STATUS ON TYPE POINT CLASS COLOR 114 106 255 END END getCapabilities request: http://niceguy.wustl.edu/cgi-bin/mapserv?map=/var/www/html/mapserver/gis.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getCapabilities I can provide any and all information requested ASAP. I would be extremely grateful for any help. Any ideas? -Ed -------------- next part -------------- An HTML attachment was scrubbed... URL: From gregor at HOSTGIS.COM Thu Jul 12 14:59:58 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Thu, 12 Jul 2007 15:59:58 -0600 Subject: WFS from PostGIS, layer not found In-Reply-To: Message-ID: Edward Fialkowski wrote: > I have a WFS set up, but I cannot get my layer to appear in the > FeatureTypeList for the WFS getCapabilities, thus requests for this > layer throw an error. To be accessible via WFS, a layer must have DUMP TRUE set. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From richard.greenwood at GMAIL.COM Thu Jul 12 20:02:29 2007 From: richard.greenwood at GMAIL.COM (Richard Greenwood) Date: Thu, 12 Jul 2007 21:02:29 -0600 Subject: Changing Map Projection Dynamically In-Reply-To: <469677D1.3050902@pobox.com> Message-ID: On 7/12/07, Frank Warmerdam wrote: > Bill Thoen wrote: > > This has probably been asked before, but I can't find any info on it. > > Basically, I'd like to know how to change the map projection in > > MapServer as I zoom in to a larger scale map view. Specifically, I start > > at a national scale using a Lambert projection, but when I zoom into a > > state scale, I'd like to choose a more appropriate projection (like > > State Plane). > > > > Can this be done easily with a map file or an HTML template? What's the > > best way to solve this problem? > > Bill, > > I likely shouldn't speak up since I don't really know the best way to do > this. But I do not believe it can be done entirely from the server side > with mapserv cgi and a map file. Either you would have to have a mapscript > application on the server that decided at some point to switch projections > or you would have to engineer all the logic on the client side. > > With WMS you can request specific projections using the SRS (or CRS?) > item in the request. With the non-OGC "classic" mapserver interface > there is also a way of overriding the map projection which I think has > been recently discussed on this list though I don't know the exact > details. > > But one important thing to remember is that the region requested is going > to have to match the projection which means there has to be quite a bit > of smarts either in the client (to change the coordinate system of the BBOX) > or in a mapscript script on the server to reproject the requested box into > the alternate projection. And in that case the returned window won't > be exactly what was requested. > > 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 | President OSGeo, http://osgeo.org > Bill, You have a pretty interesting problem. Frank summarized the challenges that you may encounter . If you decide to do it on the client side, there is a JavaScript port of some of the Proj.4 code at: http://svn.codehaus.org/mapbuilder/cscs/trunk/cscs/ that might be useful. I am particularly interested determining an appropriate coordinate system based on location. Please keep us posted. Rich -- Richard Greenwood richard.greenwood at gmail.com www.greenwoodmap.com From friendvn2000 at YAHOO.COM Thu Jul 12 21:36:42 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Thu, 12 Jul 2007 23:36:42 -0500 Subject: Open a shapefile and read its shapes' attributes Message-ID: Thank you, Sir! I follow your instruction and it works :) From lalo at SURNET.CL Thu Jul 12 21:56:08 2007 From: lalo at SURNET.CL (Gerardo Felmer) Date: Thu, 12 Jul 2007 23:56:08 -0500 Subject: find point when i use TOLERANCE in map file Message-ID: Hi, this is my first post :D . So i have a layer with POINT from postgis, and i add a circle symbol and TOLERANCE parameter in the map file, too i add queryByPoint because i need to know when some point is clicked, if it's SUCCESS, so y catch the point (geo) and i execute a query to postgis, something like this : select * from clients where geom = GeomFromText('POINT(var_x var_y)',32718); where var_x and var_y are georeferences in UTM. But, here is the problem, because i set TOLERANCE parameter and the point that i caught, maybe exactly the point or maybe too near. I don't found anything about that (i use java mapscript), maybe i did it wrong?. Help please. Best Regards. From Dejan.Gambin at PULA.HR Thu Jul 12 23:39:31 2007 From: Dejan.Gambin at PULA.HR (Gambin Dejan) Date: Fri, 13 Jul 2007 08:39:31 +0200 Subject: Help with TIFFTAGs resolutions Message-ID: Frank, I have tried changing tfws from 0.5 to 0.8 and the things are displayed correctly. So it is obvious the world files are not correct. I am little surprised because the data is provided by National State Geodetic Administration. I have this data for my town that is correct, tfw files have the same resolution (0.5) but the size of the images is 4500x6000, while here the size is 2812x3750 and the TIFFTAG resolution is 72 while here is 45. That is exactly the same proportion so I am really interested in what could happen :-)) thanks very much regards, dejan > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Frank Warmerdam > Sent: Thursday, July 12, 2007 8:58 PM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Help with TIFFTAGs resolutions > > Gambin Dejan wrote: > > Hi, > > > > I have a situation that I need to understand, I hope > someone can help: > > > > I have a number of ortophoto images in tif format (with .tfw files). > > When I show them on my map they should be spatialy > "connected" but the > > "empty" space shows between them. Here is the example > gdalinfo result > > of the two horizontally adjacent images that should be "connected": > ... > > Now, I have the similar set of ortophoto images that show correctly > > and they come from the same source (the National State Geodetic > > Administration). I have compared them and the difference is > that this > > "correct" images have the size of 4500x6000 (exactly 1.6 > bigger than > > the first one) and their TIFFTAG_XRESOLUTION and > TIFFTAG_YRESOLUTION > > are 72 (that is 45x1.6). > > > > My question is: who "made the mistake" and what do I have to do to > > show them correctly (they are shown correctly from a dwg > file that is > > referencing them all)? Are the TFW files wrong for this > resolution? Do > > I have to change the resolution, image size, or what? > > Dejan, > > It is unlikely that the DWG is utilizing the world files > (.tfw) at all. > So if the DWG view is correct it is likely that the world > files are wrong. If you think the origin's in the world > files are correct you could try changing the resolution in > the world files to 0.8 from 0.5 and see if things are properly placed. > > The TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are not used > for georeferenced placement or scaling by MapServer or other > applications. > > BTW, GDAL and MapServer will utilize internal GeoTIFF tags in > preference to the world files. So if there is wrong internal > geotiff info it will get used instead of potentially correct > worldfiles. Keep this in mind if the world files don't seem > to agree with what gdalinfo is reporting. > > 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 | President OSGeo, > http://osgeo.org > From thomas.rokkjaer at GMAIL.COM Fri Jul 13 00:58:18 2007 From: thomas.rokkjaer at GMAIL.COM (Thomas Rokkjaer) Date: Fri, 13 Jul 2007 02:58:18 -0500 Subject: Accessing database views through Virtual Spatial Data Connection Message-ID: I am now trying to retrieve the data from a database view (SQL Server) instead of a database table. This is possible right? My LAYER definiton from map file looks like the following: # # HENVENDELSE (OGR) LAYER # LAYER CONNECTION " ODBC:test/test at DVHenvendelse DVHenvendelse_v wkbPoint " CONNECTIONTYPE OGR DATA "DVHenvendelse_v" METADATA "wms_srs" "EPSG:25832" "wms_title" "DVHenvendelse_v" END NAME "DVHenvendelse_v" SIZEUNITS PIXELS STATUS ON TOLERANCE 0 TOLERANCEUNITS PIXELS TYPE POINT UNITS METERS CLASSITEM 'Skadedyr' LABELITEM 'ID' LABELMAXSCALE 25000 CLASS LABEL COLOR 0 0 0 FONT arial TYPE truetype SIZE 8 POSITION AUTO PARTIALS TRUE OUTLINECOLOR 255 255 255 END EXPRESSION 'N' STYLE COLOR 255 255 0 MAXSIZE 100 MINSIZE 1 SIZE 8 SYMBOL "punkt" END TEXT (([ID]) [Vejnavn] ([DVOpgaveID])) END CLASS LABEL COLOR 0 0 0 FONT arial TYPE truetype SIZE 8 POSITION AUTO PARTIALS TRUE OUTLINECOLOR 255 255 255 END EXPRESSION 'J' STYLE COLOR 139 69 19 MAXSIZE 100 MINSIZE 1 SIZE 8 SYMBOL "punkt" END TEXT (([ID]) [Vejnavn] ([DVOpgaveID])) END HEADER 'header' TEMPLATE 'template.html' FOOTER 'footer.html' END Best regards Thomas Rokkjaer From nkdiitd2002 at GMAIL.COM Fri Jul 13 01:11:21 2007 From: nkdiitd2002 at GMAIL.COM (nishith datta) Date: Fri, 13 Jul 2007 13:41:21 +0530 Subject: querying maps Message-ID: hi all, can someone refer to me some place about querying maps -----the basics. And I donot have good understanding of the mapserver cgi functioning also...without that things are just happening and I hate to think I am doing things without knowing whatz going on! So how does mapserver work .....any references. Its a cgi so the server routes the request to it and the output is displayed as a html through a template that much is easy but I need to understand the software functioning more intricately thanks nishith -------------- next part -------------- An HTML attachment was scrubbed... URL: From veeraswamyd at YAHOO.CO.IN Fri Jul 13 01:23:09 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Fri, 13 Jul 2007 01:23:09 -0700 Subject: C# mapserver Message-ID: hi iam woking with ms4w2.24 in php it is working now iam working with mapscript Csharp if i have to run the project in c# ,i have to stop the apache service then only it is running and it is displaying error as "unable to load mapscipt_csharp.dll". if i start the apache service then i have to stop the default website in IIS then csharp project is not running. plz solve my problem -- View this message in context: http://www.nabble.com/C--mapserver-tf4072921.html#a11575284 Sent from the Mapserver - User mailing list archive at Nabble.com. From Dejan.Gambin at PULA.HR Fri Jul 13 02:01:32 2007 From: Dejan.Gambin at PULA.HR (Gambin Dejan) Date: Fri, 13 Jul 2007 11:01:32 +0200 Subject: Help with TIFFTAGs resolutions Message-ID: I have just one question and that will be all: regarding the screen resolution - which are the parameters that impact the screen resolution of my map? If I shiw those images in DWG viewer they are very "sharp" and look much better than shown on the map, with nearly the same display dimensions.... Is there a way of modifying it? regards, dejan > -----Original Message----- > From: Frank Warmerdam [mailto:warmerdam at pobox.com] > Sent: Thursday, July 12, 2007 8:58 PM > To: Gambin Dejan > Cc: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Help with TIFFTAGs resolutions > > Gambin Dejan wrote: > > Hi, > > > > I have a situation that I need to understand, I hope > someone can help: > > > > I have a number of ortophoto images in tif format (with .tfw files). > > When I show them on my map they should be spatialy > "connected" but the > > "empty" space shows between them. Here is the example > gdalinfo result > > of the two horizontally adjacent images that should be "connected": > ... > > Now, I have the similar set of ortophoto images that show correctly > > and they come from the same source (the National State Geodetic > > Administration). I have compared them and the difference is > that this > > "correct" images have the size of 4500x6000 (exactly 1.6 > bigger than > > the first one) and their TIFFTAG_XRESOLUTION and > TIFFTAG_YRESOLUTION > > are 72 (that is 45x1.6). > > > > My question is: who "made the mistake" and what do I have to do to > > show them correctly (they are shown correctly from a dwg > file that is > > referencing them all)? Are the TFW files wrong for this > resolution? Do > > I have to change the resolution, image size, or what? > > Dejan, > > It is unlikely that the DWG is utilizing the world files > (.tfw) at all. > So if the DWG view is correct it is likely that the world > files are wrong. If you think the origin's in the world > files are correct you could try changing the resolution in > the world files to 0.8 from 0.5 and see if things are properly placed. > > The TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are not used > for georeferenced placement or scaling by MapServer or other > applications. > > BTW, GDAL and MapServer will utilize internal GeoTIFF tags in > preference to the world files. So if there is wrong internal > geotiff info it will get used instead of potentially correct > worldfiles. Keep this in mind if the world files don't seem > to agree with what gdalinfo is reporting. > > 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 | President OSGeo, > http://osgeo.org > > From josevicente.higon at GMAIL.COM Fri Jul 13 03:53:28 2007 From: josevicente.higon at GMAIL.COM (=?utf-8?q?Jos=C3=A9_Vicente_Hig=C3=B3n?=) Date: Fri, 13 Jul 2007 12:53:28 +0200 Subject: Problem with WMS getFeatureInfo and UTF8 encoding in postGIS Message-ID: Hi, I'm using mapserver 4.10.2 and postGIS with UTF-8 encoding. When I request a GetFeatureInfo from a record with special characters like '?' or '?' I get an empty XML. However, if the record doesn't have these special characters I'll get a correct XML. ?Is there any problem with the operation GetFeatureInfo in UTF-8 databases? Thanks in advance. -- Jos? Vicente Hig?n Valero Grupo desarrollo gvSIG. IVER TI S.A. C/Salamanca, 50-52 46005-Valencia Tlf.+34963163400 http://www.iver.es http://www.gvsig.com http://www.gvsig.gva.es From Dejan.Gambin at PULA.HR Fri Jul 13 04:17:19 2007 From: Dejan.Gambin at PULA.HR (Gambin Dejan) Date: Fri, 13 Jul 2007 13:17:19 +0200 Subject: Strange imagetype/outputformat behaviour Message-ID: Hi, Maybe someone can explain my imagetype/outputformat behaviour. I am displaying a set of RGB tif rasters. I set: IMAGETYPE png OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE RGB FORMATOPTION INTERLACE=OFF TRANSPARENT OFF OUTPUTFORMAT NAME png8 DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE PC256 FORMATOPTION INTERLACE=OFF TRANSPARENT OFF END END The resulting 556x424 png image is 303KB in size. When setting some user defined IMAGETYPE/NAME, for example: IMAGETYPE custom OUTPUTFORMAT NAME custom ... I get a much worse display, and the png file is 53KB in size. Is it allowed to set the custom names here? Also, I get the same result with png8 and png IMAGETYPE. I don't know why? Maybe I am missing something? regards, dejan From p.shapley at GMAIL.COM Fri Jul 13 06:00:51 2007 From: p.shapley at GMAIL.COM (Paul Shapley) Date: Fri, 13 Jul 2007 14:00:51 +0100 Subject: What do you know about Maps and Spatial Information? In-Reply-To: Message-ID: Hello, My name is Paul Shapley and I'm undertaking some research with the University of Glamorgan into public awareness of Mapping and Spatial Information presented on the web. I am looking for willing individuals to complete a quick seven question test with (easy option answers). Would you be kind enough to follow the link below. Please feel free to forward this email to your colleagues and friends, the more responses I get the better. http://www.paulshapley.com/map_pass.html Password:- mapquest Many thanks for your time. -- Paul J. Shapley -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.l.h.hartmann at UVA.NL Fri Jul 13 06:53:31 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Fri, 13 Jul 2007 15:53:31 +0200 Subject: Changing Map Projection Dynamically In-Reply-To: Message-ID: Richard Greenwood wrote: > On 7/12/07, Frank Warmerdam wrote: >> Bill Thoen wrote: >> > This has probably been asked before, but I can't find any info on it. >> > Basically, I'd like to know how to change the map projection in >> > MapServer as I zoom in to a larger scale map view. Specifically, I >> start >> > at a national scale using a Lambert projection, but when I zoom into a >> > state scale, I'd like to choose a more appropriate projection (like >> > State Plane). >> > >> > Can this be done easily with a map file or an HTML template? What's the >> > best way to solve this problem? >> >> Bill, >> >> I likely shouldn't speak up since I don't really know the best way to do >> this. But I do not believe it can be done entirely from the server side >> with mapserv cgi and a map file. Either you would have to have a >> mapscript >> application on the server that decided at some point to switch >> projections >> or you would have to engineer all the logic on the client side. >> >> With WMS you can request specific projections using the SRS (or CRS?) >> item in the request. With the non-OGC "classic" mapserver interface >> there is also a way of overriding the map projection which I think has >> been recently discussed on this list though I don't know the exact >> details. >> >> But one important thing to remember is that the region requested is going >> to have to match the projection which means there has to be quite a bit >> of smarts either in the client (to change the coordinate system of the >> BBOX) >> or in a mapscript script on the server to reproject the requested box >> into >> the alternate projection. And in that case the returned window won't >> be exactly what was requested. >> >> 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 | President OSGeo, >> http://osgeo.org >> > > Bill, > > You have a pretty interesting problem. Frank summarized the challenges > that you may encounter . If you decide to do it on the client side, > there is a JavaScript port of some of the Proj.4 code at: > http://svn.codehaus.org/mapbuilder/cscs/trunk/cscs/ > that might be useful. I am particularly interested determining an > appropriate coordinate system based on location. > > Please keep us posted. > Rich > At the Server-side you can do a lot with PHP/MapScript. If you have PostGIS running, you can install the EPSG database in it (see e.g. http://docs.codehaus.org/display/GEOTOOLS/How+to+install+the+EPSG+database+in+PostgreSQL You can query this database for regions of interest for certain projections, and get their extents. A bit of work, as this is not exactly database with a user-friendly structure, but doable and the principles aren't hard. Jan From warmerdam at POBOX.COM Fri Jul 13 07:50:06 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Fri, 13 Jul 2007 10:50:06 -0400 Subject: Strange imagetype/outputformat behaviour In-Reply-To: Message-ID: Gambin Dejan wrote: > Hi, > > Maybe someone can explain my imagetype/outputformat behaviour. I am > displaying a set of RGB tif rasters. I set: > > IMAGETYPE png > OUTPUTFORMAT > NAME png > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE RGB > FORMATOPTION INTERLACE=OFF > TRANSPARENT OFF > OUTPUTFORMAT > NAME png8 > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE PC256 > FORMATOPTION INTERLACE=OFF > TRANSPARENT OFF > END > END Dejan, I assume you don't really nest outputformat declarations like you show above, right? > The resulting 556x424 png image is 303KB in size. > When setting some user > defined IMAGETYPE/NAME, for example: > > IMAGETYPE custom > OUTPUTFORMAT > NAME custom > ... > I get a much worse display, and the png file is 53KB in size. Is it > allowed to set the custom names here? Yes, it is allowed (in fact encouraged) to use your own custom name for custom output format declarations. > Also, I get the same result with png8 and png IMAGETYPE. I don't know > why? Maybe I am missing something? I'm not sure your attempt to override the PNG output format really worked. I normally never use a pre-defined output format name for a custom output format declaration in a mapfile. 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 | President OSGeo, http://osgeo.org From warmerdam at POBOX.COM Fri Jul 13 08:37:05 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Fri, 13 Jul 2007 11:37:05 -0400 Subject: Help with TIFFTAGs resolutions In-Reply-To: Message-ID: Gambin Dejan wrote: > I have just one question and that will be all: regarding the screen > resolution - which are the parameters that impact the screen resolution > of my map? If I shiw those images in DWG viewer they are very "sharp" > and look much better than shown on the map, with nearly the same display > dimensions.... > > Is there a way of modifying it? Dejan, MapServer uses full resolution imagery when you are zoomed in to full resolution. Perhaps the DWG viewer uses sub-pixel interpolation when you are zoomed in past full resolution. MapServer does not, by default, so things will start to pixelate at that leve. 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 | President OSGeo, http://osgeo.org From szekerest at GMAIL.COM Fri Jul 13 08:51:14 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Fri, 13 Jul 2007 17:51:14 +0200 Subject: C# mapserver In-Reply-To: <11575284.post@talk.nabble.com> Message-ID: I'm afraid I couldn't understand the problem exactly. However I would suggest you to copy all of the dll-s (the mapscript dll-s and all of the dependencies) into your application directory. I suppose apache and IIS are listening on the same port (probably on TCP 80) so you might want to configure any of them into a different port, either by: - Changing 'Listen 80' in httpd.conf or - Changing the TCP Port setting on the default web side using the Internet Information Services snap-in. Best regards Tamas 2007/7/13, lakku : > hi > iam woking with ms4w2.24 > in php it is working > now iam working with mapscript Csharp > if i have to run the project in c# ,i have to stop the apache service then > only it is running and it is > displaying error as "unable to load mapscipt_csharp.dll". > if i start the apache service then i have to stop the default website in > IIS then csharp project is not > running. > plz solve my problem > > > -- > View this message in context: http://www.nabble.com/C--mapserver-tf4072921.html#a11575284 > Sent from the Mapserver - User mailing list archive at Nabble.com. > From jmckenna at DMSOLUTIONS.CA Fri Jul 13 09:59:03 2007 From: jmckenna at DMSOLUTIONS.CA (Jeff McKenna) Date: Fri, 13 Jul 2007 12:59:03 -0400 Subject: C# mapserver In-Reply-To: Message-ID: As Tamas is mentioning, regarding Apache port and MS4W, here is a section from the MS4W README (http://www.maptools.org/ms4w/index.phtml?page=README_INSTALL.html) "Apache with MS4W is configured to use port 80. Your system might be already using this port (IIS could cause this for example). If you want to change the port that Apache uses modify the following file: /ms4w/Apache/conf/httpd.conf line 120: Listen 80 TCPView (http://www.sysinternals.com/Utilities/TcpView.html) is an example of shareware that lets you see how the ports on your machine are being used." jeff Tamas Szekeres wrote: > I'm afraid I couldn't understand the problem exactly. > > However I would suggest you to copy all of the dll-s (the mapscript > dll-s and all of the dependencies) into your application directory. > > I suppose apache and IIS are listening on the same port (probably on > TCP 80) so you might want to configure any of them into a different > port, either by: > > - Changing 'Listen 80' in httpd.conf or > - Changing the TCP Port setting on the default web side using the > Internet Information Services snap-in. > > > Best regards > > Tamas > > > 2007/7/13, lakku : >> hi >> iam woking with ms4w2.24 >> in php it is working >> now iam working with mapscript Csharp >> if i have to run the project in c# ,i have to stop the apache service >> then >> only it is running and it is >> displaying error as "unable to load mapscipt_csharp.dll". >> if i start the apache service then i have to stop the default website in >> IIS then csharp project is not >> running. >> plz solve my problem >> >> >> -- >> View this message in context: >> http://www.nabble.com/C--mapserver-tf4072921.html#a11575284 >> Sent from the Mapserver - User mailing list archive at Nabble.com. >> > -- Jeff McKenna DM Solutions Group Inc. http://www.dmsolutions.ca From tnolte at ILPCS.COM Fri Jul 13 10:15:09 2007 From: tnolte at ILPCS.COM (Timothy J Nolte) Date: Fri, 13 Jul 2007 12:15:09 -0500 Subject: DBDriver unset Message-ID: I'm trying to build a simple Chameleon app using the App Dev Guide. Whenever I try to test the app I get: [Fri Jul 13 13:05:30 2007] [crit] (70023)This function has not been implemented on this platform: DBD: driver for [DBDriver unset] not available [Fri Jul 13 13:05:30 2007] [crit] (70023)This function has not been implemented on this platform: DBD: failed to initialise [Fri Jul 13 13:05:31 2007] [notice] child pid 2534 exit signal Segmentation fault (11) This is while tailing the apache error_log. I've tried other full-blown apps and had the same error. I have been able to run some sample apps under MapServer but not this simple one. Any ideas, anyone? From tnolte at ILPCS.COM Fri Jul 13 10:39:25 2007 From: tnolte at ILPCS.COM (Timothy J Nolte) Date: Fri, 13 Jul 2007 12:39:25 -0500 Subject: DBDriver unset Message-ID: Hey Bob, Well, actually after doing some Goggling and some more testing it appears those errors are coming up outside of just the map environment I'm trying to setup. I've had to do some recompiling of PHP for a couple of projects, one included setting up TDS to connect to a MSSQL database, and I suspect that might be the root of this. I am having problems with the Chameleon app segfaulting however. Not sure why this is...all of the Chameleon and other sample apps I've tried seem to work just fine. ---- Timothy J Nolte - tnolte at ilpcs.com Associate 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: Bob Basques [mailto:Bob.Basques at ci.stpaul.mn.us] Sent: Friday, July 13, 2007 1:31 PM To: Nolte, Tim Subject: Re: DBDriver unset Tim, I don't know much about Chameleon, but those are database connection LIB problems of some sort. The DBD/DBI package allows for database connections. I've used it over the years with perl to connect to different databases. Might help you in the right direction. bobb From alexey.udovydchenko at GMAIL.COM Fri Jul 13 12:10:59 2007 From: alexey.udovydchenko at GMAIL.COM (Alexey Udovydchenko) Date: Fri, 13 Jul 2007 22:10:59 +0300 Subject: ? wbmp and gif output Message-ID: Is it possible to get wbmp and 16-colored gifs output with mapserver? From bthoen at GISNET.COM Fri Jul 13 13:02:28 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 13 Jul 2007 14:02:28 -0600 Subject: SUM: [UMN_MAPSERVER-USERS] Changing Map Projection Dynamically In-Reply-To: <469783DB.8070801@uva.nl> Message-ID: Thanks everyone for your help with my question about changing the map projection dynamically as one zooms into a local area. Edward Bates mentioned that you can pass the map_PROJECTION setting on the request URL (but you'll also have to set the mapext parameter to a valid setting in the new projection's coordinate system.) If you open a MapServer map showing the USA in a Lambert projection and then append the mapext and map_PROJECTION parameters (escaping spaces and '=' signs) like so: &mapext=-122%2030%20-75%2050&map_PROJECTION=proj%3dlatlong%2cellps%3dWGS84%2cdatum%3dWGS84 to the request URL, you can change the projection on the fly. As Frank Warmerdam pointed out this will involve a bit of work to calculate the region limits in the new coordinate system. To do that on the client side, Richard Greenwood suggested a JavaScript port of some of the Proj.4 code at: http://svn.codehaus.org/mapbuilder/cscs/trunk/cscs/, and to handle it on the server side, Jan Hartmann suggested coding the solution with PHP/MapScript code and to install PostGIS and the EPSG database (http://docs.codehaus.org/display/GEOTOOLS/How+to+install+the+EPSG+database+in+PostgreSQL) The problem is bigger than I want to tackle right now, but for the meantime I can probably use something like what Bates' suggested in the form of a list of pre-selected URLs in a select control that lists a collection of fixed views for various locations and scales. - Bill Thoen From Steve.Lime at DNR.STATE.MN.US Fri Jul 13 15:47:05 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Fri, 13 Jul 2007 17:47:05 -0500 Subject: Changing Map Projection Dynamically In-Reply-To: Message-ID: It is an interesting problem. MapServer templates do allow you access to the bbox for an map in both lat/lon and the projection of choice. If you are willing to live with a bit of slop you could change projections on the client and use the lat/lon bbox as an intermediate value. I would be tempted to change projections after a user submits a request (e.g. onSubmit). You have the scale value of the current map, you also have the current extent and the requested zoom value. You could with just a little bit of javascript determine a rough new scale by multiplying the old scale by the zoom factor and then change the projection (e.g. map_projection accordingly) and use the lat/lon bbox. It wouldn't be exact but would work I think. MapServer also has a little known feature called scale dependent templates. They were added for a purpose like this but I've never used them. Basically in the webObj you can set MINTEMPLATE and MAXTEMPLATE and when you hit the MINSCALE or MAXSCALE values those templates are used if defined. The can be HTML templates or URL templates. So for example, you could have an application where you zoom in to a point and then hand off to another application. The lat/lon values become the bridge. So for example, you might have separate mapfiles for each projection. They could use the same guts: MAP NAME 'scale1000to10000' ... PROJECTION ... END WEB MINSCALE 1000 MAXSCALE 10000 MINTEMPLATE 'http://mapserver.mydomain.com?map=scale0to1000.map&mapext=[mapext_latlon]&[layers]' MAXTEMPLATE 'http://mapserver.mydomain.com?map=scale10000to100000.map&mapext=[mapext_latlon]&[layers]' ... END INCLUDE 'layers.map' END MAP NAME 'scale0to1000' ... PROJECTION ... END WEB MAXSCALE 1000 MAXTEMPLATE 'http://mapserver.mydomain.com?map=scale1000to10000.map&mapext=[mapext_latlon]&[layers]' ... END INCLUDE 'layers.map' END and so on... Then you'd move between the applications as the scale changed, or at least that was the idea. This handles the in/out issue but not the east/west issue. Now, off course the min/max template could trigger a query that might, for example, set the write state plane or UTM zone and the query result fires off the right URL with the right projection, the layer list and so on. That would be all server based... Steve >>> On 7/12/2007 at 10:02 PM, in message , Richard Greenwood wrote: > On 7/12/07, Frank Warmerdam wrote: >> Bill Thoen wrote: >> > This has probably been asked before, but I can't find any info on it. >> > Basically, I'd like to know how to change the map projection in >> > MapServer as I zoom in to a larger scale map view. Specifically, I start >> > at a national scale using a Lambert projection, but when I zoom into a >> > state scale, I'd like to choose a more appropriate projection (like >> > State Plane). >> > >> > Can this be done easily with a map file or an HTML template? What's the >> > best way to solve this problem? >> >> Bill, >> >> I likely shouldn't speak up since I don't really know the best way to do >> this. But I do not believe it can be done entirely from the server side >> with mapserv cgi and a map file. Either you would have to have a mapscript >> application on the server that decided at some point to switch projections >> or you would have to engineer all the logic on the client side. >> >> With WMS you can request specific projections using the SRS (or CRS?) >> item in the request. With the non-OGC "classic" mapserver interface >> there is also a way of overriding the map projection which I think has >> been recently discussed on this list though I don't know the exact >> details. >> >> But one important thing to remember is that the region requested is going >> to have to match the projection which means there has to be quite a bit >> of smarts either in the client (to change the coordinate system of the BBOX) >> or in a mapscript script on the server to reproject the requested box into >> the alternate projection. And in that case the returned window won't >> be exactly what was requested. >> >> 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 | President OSGeo, http://osgeo.org >> > > Bill, > > You have a pretty interesting problem. Frank summarized the challenges > that you may encounter . If you decide to do it on the client side, > there is a JavaScript port of some of the Proj.4 code at: > http://svn.codehaus.org/mapbuilder/cscs/trunk/cscs/ > that might be useful. I am particularly interested determining an > appropriate coordinate system based on location. > > Please keep us posted. > Rich From richard.greenwood at GMAIL.COM Fri Jul 13 20:21:38 2007 From: richard.greenwood at GMAIL.COM (Richard Greenwood) Date: Fri, 13 Jul 2007 21:21:38 -0600 Subject: Changing Map Projection Dynamically In-Reply-To: <4697BA93.5157.008F.0@dnr.state.mn.us> Message-ID: On 7/13/07, Steve Lime wrote: > It is an interesting problem. MapServer templates do allow you access to the bbox for an map > in both lat/lon and the projection of choice. Can you get both in a single request to the server? > If you are willing to live with a bit of slop you could > change projections on the client and use the lat/lon bbox as an intermediate value. Doesn't seem that sloppy, at least not for a guy who goes by "mapslob". Rich -- Richard Greenwood richard.greenwood at gmail.com www.greenwoodmap.com From dejan.gambin at PULA.HR Sat Jul 14 04:17:44 2007 From: dejan.gambin at PULA.HR (Dejan Gambin) Date: Sat, 14 Jul 2007 13:17:44 +0200 Subject: Spam: Re: [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour In-Reply-To: <4697911E.2060706@pobox.com> Message-ID: Frank, No the declarations are not nested, I just made a mistake while pasting it in the message. I am trying to use a custom outputformat. I set something like: IMAGETYPE "custom" OUTPUTFORMAT NAME "custom" DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE RGB FORMATOPTION INTERLACE=OFF TRANSPARENT OFF END ...the resulting display is lower color quality than the first one and the image size is 53KB. I tried the same without the quotation marks, it is the same. Then I have tried different combinations using DRIVER "GDAL/PNG", nothing works...then I tried using IMAGETYPE png without having OUTPUTFORMAT png defined - the same. But when I replace both and set: IMAGETYPE png OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE RGB FORMATOPTION INTERLACE=OFF TRANSPARENT OFF END ...the resulting display is better color quality and the image size is 303KB ! So I really don't understand what is happening. I am using MS4W. Mapserv.exe -v shows: MapServer version 4.10.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE DEBUG=MSDEBUG The problem is that I don't know if the "better display result" is indeed the best one I can get... Thanks for any help regards, dejan > -----Original Message----- > From: Frank Warmerdam [mailto:warmerdam at pobox.com] > Sent: Friday, July 13, 2007 4:50 PM > To: Gambin Dejan > Cc: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Spam: Re: [UMN_MAPSERVER-USERS] Strange > imagetype/outputformat behaviour > > Gambin Dejan wrote: > > Hi, > > > > Maybe someone can explain my imagetype/outputformat behaviour. I am > > displaying a set of RGB tif rasters. I set: > > > > IMAGETYPE png > > OUTPUTFORMAT > > NAME png > > DRIVER "GD/PNG" > > MIMETYPE "image/png" > > IMAGEMODE RGB > > FORMATOPTION INTERLACE=OFF > > TRANSPARENT OFF > > OUTPUTFORMAT > > NAME png8 > > DRIVER "GD/PNG" > > MIMETYPE "image/png" > > IMAGEMODE PC256 > > FORMATOPTION INTERLACE=OFF > > TRANSPARENT OFF > > END > > END > > Dejan, > > I assume you don't really nest outputformat declarations like > you show above, right? > > > The resulting 556x424 png image is 303KB in size. > > When setting some user > > defined IMAGETYPE/NAME, for example: > > > > IMAGETYPE custom > > OUTPUTFORMAT > > NAME custom > > ... > > I get a much worse display, and the png file is 53KB in > size. Is it > > allowed to set the custom names here? > > Yes, it is allowed (in fact encouraged) to use your own > custom name for custom output format declarations. > > > Also, I get the same result with png8 and png IMAGETYPE. I > don't know > > why? Maybe I am missing something? > > I'm not sure your attempt to override the PNG output format > really worked. I normally never use a pre-defined output > format name for a custom output format declaration in a mapfile. > > 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 | President OSGeo, > http://osgeo.org > > From warmerdam at POBOX.COM Sat Jul 14 07:05:25 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Sat, 14 Jul 2007 10:05:25 -0400 Subject: Spam: Re: [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour In-Reply-To: <000601c7c608$9a552da0$0401a8c0@gradpula.local> Message-ID: Dejan Gambin wrote: > Frank, > > No the declarations are not nested, I just made a mistake while pasting it > in the message. > > I am trying to use a custom outputformat. I set something like: > > IMAGETYPE "custom" > OUTPUTFORMAT > NAME "custom" > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE RGB > FORMATOPTION INTERLACE=OFF > TRANSPARENT OFF > END > > ...the resulting display is lower color quality than the first one and the > image size is 53KB. I tried the same without the quotation marks, it is the > same. Then I have tried different combinations using DRIVER "GDAL/PNG", > nothing works...then I tried using IMAGETYPE png without having OUTPUTFORMAT > png defined - the same. But when I replace both and set: > > IMAGETYPE png > OUTPUTFORMAT > NAME png > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE RGB > FORMATOPTION INTERLACE=OFF > TRANSPARENT OFF > END > > ...the resulting display is better color quality and the image size is 303KB > ! > > So I really don't understand what is happening. I am using MS4W. Mapserv.exe > -v shows: > > MapServer version 4.10.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP > OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE > SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER > SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=THREADS > SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE > DEBUG=MSDEBUG > > The problem is that I don't know if the "better display result" is indeed > the best one I can get... Dejan, What sort of requests are you making to mapserv? Perhaps the custom format isn't working because you are overriding the format in the mapserv request? (for instance with the FORMAT= flag in WMS requests). Other than that, I don't see any explanation for what is happening. 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 | President OSGeo, http://osgeo.org From dejan.gambin at PULA.HR Sun Jul 15 06:13:46 2007 From: dejan.gambin at PULA.HR (Dejan Gambin) Date: Sun, 15 Jul 2007 15:13:46 +0200 Subject: Spam: Re: [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour In-Reply-To: <4698D825.6080900@pobox.com> Message-ID: Frank, I am using MS4W and p.mapper framework. The request is very simple - I have a raster layer made by tileindex shape file, like this: LAYER # raster NAME "ortofoto" GROUP "ortofoto" STATUS ON TYPE RASTER METADATA "DESCRIPTION" "Ortofoto" END TILEINDEX "vodnjan" TILEITEM "LOCATION" CLASS Name 'ortofoto' COLOR 51 102 160 OUTLINECOLOR 0 0 0 TEMPLATE void END END Maybe I need to look in the p.mapper somewhere and debug the requests...I'll try... regards, dejan > -----Original Message----- > From: UMN MapServer Users List > [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Frank Warmerdam > Sent: Saturday, July 14, 2007 4:05 PM > To: MAPSERVER-USERS at LISTS.UMN.EDU > Subject: Re: [UMN_MAPSERVER-USERS] Spam: Re: > [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour > > Dejan Gambin wrote: > > Frank, > > > > No the declarations are not nested, I just made a mistake while > > pasting it in the message. > > > > I am trying to use a custom outputformat. I set something like: > > > > IMAGETYPE "custom" > > OUTPUTFORMAT > > NAME "custom" > > DRIVER "GD/PNG" > > MIMETYPE "image/png" > > IMAGEMODE RGB > > FORMATOPTION INTERLACE=OFF > > TRANSPARENT OFF > > END > > > > ...the resulting display is lower color quality than the > first one and > > the image size is 53KB. I tried the same without the > quotation marks, > > it is the same. Then I have tried different combinations > using DRIVER > > "GDAL/PNG", nothing works...then I tried using IMAGETYPE > png without > > having OUTPUTFORMAT png defined - the same. But when I > replace both and set: > > > > IMAGETYPE png > > OUTPUTFORMAT > > NAME png > > DRIVER "GD/PNG" > > MIMETYPE "image/png" > > IMAGEMODE RGB > > FORMATOPTION INTERLACE=OFF > > TRANSPARENT OFF > > END > > > > ...the resulting display is better color quality and the > image size is > > 303KB ! > > > > So I really don't understand what is happening. I am using MS4W. > > Mapserv.exe -v shows: > > > > MapServer version 4.10.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG > OUTPUT=WBMP > > OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE > > SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER > > SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER > > SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR > > INPUT=GDAL INPUT=SHAPEFILE DEBUG=MSDEBUG > > > > The problem is that I don't know if the "better display result" is > > indeed the best one I can get... > > Dejan, > > What sort of requests are you making to mapserv? Perhaps the > custom format isn't working because you are overriding the > format in the mapserv request? (for instance with the > FORMAT= flag in WMS requests). > > Other than that, I don't see any explanation for what is happening. > > 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 | President OSGeo, > http://osgeo.org > From deuce4 at BIGWALLS.NET Sun Jul 15 14:44:01 2007 From: deuce4 at BIGWALLS.NET (John Middendorf) Date: Sun, 15 Jul 2007 16:44:01 -0500 Subject: One-to-many attribute queries Message-ID: Bravo! I have been looking for a way to join my .dbf files, and though there are numerous references and (complex) examples posted elsewhere, this one by Wlm Blanken provides the necessary information without the complexity. I was able to quickly join a dbf with no trouble, thanks to your clear explanation of the mapfile code and the proper format for the Template files. Thank you! John Middendorf From friendvn2000 at YAHOO.COM Sun Jul 15 19:11:52 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Sun, 15 Jul 2007 21:11:52 -0500 Subject: Limit of Mapserver Message-ID: Do someone give the estimation about the limit power of Mapserver. Example how many interactive-users on 1 CPU ( of course which CPU, which data it shows... ). Thanks! From Dejan.Gambin at PULA.HR Sun Jul 15 23:55:03 2007 From: Dejan.Gambin at PULA.HR (Gambin Dejan) Date: Mon, 16 Jul 2007 08:55:03 +0200 Subject: Strange imagetype/outputformat behaviour - SOLVED Message-ID: Frank, You were right of course. I found that p-mapper selects the output format by selectOutputFormat function that has an input defined in p.mapper config file as "png". So I suppose it just couldn't work using custom imagetype/name. Now I know the image I see is RGB and the "better" one shown in DWG viewer is probably using sub-pixel rendering thanks very much Frank regards, dejan > -----Original Message----- > From: Frank Warmerdam [mailto:warmerdam at pobox.com] > Sent: Sunday, July 15, 2007 4:12 PM > To: Gambin Dejan > Subject: Re: [UMN_MAPSERVER-USERS] Spam: Re: > [UMN_MAPSERVER-USERS] Strange imagetype/outputformat behaviour > > Dejan Gambin wrote: > > Frank, > > > > I am using MS4W and p.mapper framework. The request is very > simple - I > > have a raster layer made by tileindex shape file, like this: > > > > LAYER # raster > > NAME "ortofoto" > > GROUP "ortofoto" > > STATUS ON > > TYPE RASTER > > METADATA > > "DESCRIPTION" "Ortofoto" > > END > > TILEINDEX "vodnjan" > > TILEITEM "LOCATION" > > CLASS > > Name 'ortofoto' > > COLOR 51 102 160 > > OUTLINECOLOR 0 0 0 > > TEMPLATE void > > END > > END > > > > Maybe I need to look in the p.mapper somewhere and debug the > > requests...I'll try... > > Dejan, > > I am not familiar with the details of p.mapper, but I do > think you need to understand the requests it is making. > > 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 | President OSGeo, > http://osgeo.org > > From bradleym06 at GMAIL.COM Sun Jul 15 23:56:22 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Mon, 16 Jul 2007 16:56:22 +1000 Subject: Installing Mapserver Through Yum Message-ID: Hi guys what I'm wondering is it possible to easily install Mapserver through yum, I would like to also have proj.4, GD, GDAL, GEOS, PHP and Apache installed. My main problem is simply how do I set up/use these after downloading them though yum? I mean I was previously compiling from source and basing everything out of /usr/local but now everything is all over the place and I have no idea on how to configure all of this to work together again. My reasons for this was I have run into complication in rebuilding my server from source again and I am looking for an easier way to rebuild. I am running Fedora 7. Cheers Brad -------------- next part -------------- An HTML attachment was scrubbed... URL: From anhtin at GMAIL.COM Mon Jul 16 00:06:37 2007 From: anhtin at GMAIL.COM (anhtin) Date: Mon, 16 Jul 2007 00:06:37 -0700 Subject: Change color on Mapserver Message-ID: hi all i have project using asp.net, Mapserver And Database Postgis i have problem with change dynamic color on classObj this is layer on map file: LAYER #MainRoad NAME "MainRoad" STATUS OFF CONNECTIONTYPE postgis CONNECTION "host=127.0.0.1 dbname=vietnamairlines user=postgres password=123456 port=5432" DATA "the_geom FROM mainroad" TYPE LINE MINSCALE 90000 CLASS STYLE COLOR 0 0 0 SIZE 4 END END END and this layer have colunm on database: gid,name,code,the_geom I want to change dynamic color some Line on Mapserver i try layerObj layer = objMapServer.getLayerByName("MainRoad"); classObj objclass = layer.getClass(1); styleObj objstyle = objclass.getStyle(0); colorObj objColor = new colorObj(184, 212, 252, 0); objstyle.color = objColor; if i define class in map file is: CLASS NAME "Hoa Binh" EXPRESSION ([code]=305) STYLE COLOR 182 249 252 END END it change color successful. but with my layer "main road" have many item class so i can't define in map file and now i think a way is create new classObj and assign to this layer ("Main Road") but i dont know how will i do that. if u can solve it. could u show me! -- View this message in context: http://www.nabble.com/Change-color-on-Mapserver-tf4084861.html#a11610134 Sent from the Mapserver - User mailing list archive at Nabble.com. From dominik.schmid at ILU.CH Mon Jul 16 00:30:21 2007 From: dominik.schmid at ILU.CH (Dominik Schmid) Date: Mon, 16 Jul 2007 09:30:21 +0200 Subject: Error: *** glibc detected *** double free or corruption (!prev) In-Reply-To: <46921FC5.6030304@ilu.ch> Message-ID: I am replying to my own message to give an update on my own findings in this matter. I have, after a week of unsuccessful tinkering, finally given in and imported the new shapes into an existing (working) table that already contained shapes within the same topic. I had hoped to keep the two data sets separate because they involve two countries and two different terminologies on the same subject. I added some columns to accomodate the second country's data. I then copied (using a simple SQL statement of the type INSERT INTO ... SELECT ...) the data from the non-working table (the one that threw the glibc error) into the abovementioned older table and - lo and behold - it worked! Why that is, is beyond me. In my understanding there must be an incompatibility in the way the newer Postgis version behaviour when one calls CreateGeometryColumn. Somehow, only geometry columns created with the older Postgis are compatible with Mapserver 4.0.1. This explains why all the older tables still worked after migrating to a new server and updating all except Mapserver. This also explains why converting the data on the old server and then pg_dumping and reimporting it into the new server doesn't help. I think I now have enough reason to justify the migration to Mapserver 4.10, costly as it may be for us. Otherwise I can't add any more tables containing geometry. What I still wonder is if I should wait for Mapserver 5 (well, more likely 5.0.1 or 5.0.2 to be on the stable side) or if I should take the 4.10 update first. Dominik Dominik Schmid wrote: > Umberto, > > I have done as you suggested. The output reads as follows: > > Starting program: /tmp/shp2img -m /in/irr/mb/mb_test.map -l "Zonenplan" > -all_debug 9 -layer_debug Zonenplan 9 -o test_img2.png > [Thread debugging using libthread_db enabled] > [New Thread -1208117568 (LWP 4843)] > [Mon Jul 9 13:38:33 2007].267262 msPOSTGISLayerOpen called > datastatement: the_geom from zp_au > [Mon Jul 9 13:38:33 2007].288259 msPOSTGISLayerFreeItemInfo called > [Mon Jul 9 13:38:33 2007].288715 msPOSTGISLayerInitItemInfo called > [Mon Jul 9 13:38:33 2007].291176 msPOSTGISLayerWhichShapes called > [Mon Jul 9 13:38:33 2007].291959 msPOSTGISLayerParseData: unique column > = OID, srid='', geom_column_name = the_geom, table_name=zp_au > [Mon Jul 9 13:38:33 2007].293130 query_string_0_6:DECLARE mycursor > BINARY CURSOR FOR SELECT > grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text > from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 > 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, > find_srid('','zp_au','the_geom') ) > *** glibc detected *** double free or corruption (!prev): 0x08f02a40 *** > > Program received signal SIGABRT, Aborted. > [Switching to Thread -1208117568 (LWP 4843)] > 0x005027a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 > > > As I'm not a programmer but just a simple web developer my debugging > abilities are naturally rather limited. > > > Dominik > > > Umberto Nicoletti schrieb: >> Dominik, >> this is getting very hard to do if you don't know a bit about >> programming. >> >> If you want to try anyway, run shp2img under gdb with the following >> command: >> >> #gdb /path/to/shp2img >>> run -m pathtothefile.map -o /tmp/map.png >> >> When it segfaults issue this command in the gdb shell: >> >> #backtrace >> >> and post its output here. >> >> Umberto >> >> On 7/9/07, Dominik Schmid wrote: >>> I have recompiled 4.0.1 with debug enabled. I then replaced the existing >>> shp2img and mapserv.cgi with the newly compiled binaries. Next I ran >>> shp2img with '-all_debug 9' and 'layer_debug 9' for the offending layer >>> (data from zp_au). Since I have no idea what possible debug levels there >>> are or what numbers can be set I have chosen to use a value of 9. Here's >>> the output of shp2img: >>> >>> [Mon Jul 9 12:18:03 2007].176107 msPOSTGISLayerOpen called >>> datastatement: the_geom from zp_au >>> [Mon Jul 9 12:18:03 2007].185943 msPOSTGISLayerFreeItemInfo called >>> [Mon Jul 9 12:18:03 2007].186621 msPOSTGISLayerInitItemInfo called >>> [Mon Jul 9 12:18:03 2007].189609 msPOSTGISLayerWhichShapes called >>> [Mon Jul 9 12:18:03 2007].190383 msPOSTGISLayerParseData: unique column >>> = OID, srid='', geom_column_name = the_geom, table_name=zp_au >>> [Mon Jul 9 12:18:03 2007].192024 query_string_0_6:DECLARE mycursor >>> BINARY CURSOR FOR SELECT >>> grundnut::text,asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text >>> >>> from zp_au WHERE the_geom && setSRID('BOX3D(760644.999999999 >>> 249797.999999997,769195.000000001 261197.000000002)'::BOX3D, >>> find_srid('','zp_au','the_geom') ) >>> *** glibc detected *** double free or corruption (!prev): 0x0956da40 *** >>> >>> >>> Since this debug information doesn't help me pinpoint the problem I have >>> to ask back here at the list if this tells anyone here anything. >>> >>> Any help is appreciated. >>> >>> Dominik >>> >>> >>> Umberto Nicoletti wrote: >>> > If you still have the 4.0.1 sources recompile them with enable debug >>> > and run shp2img under gdb. This at least will tell you where the >>> > double free is happening and then you might even be able to fix it. >>> > >>> > Umberto >>> > >>> > On 7/4/07, Dominik Schmid wrote: >>> >> Hi >>> >> >>> >> I have run into this persistent problem and I have already spent >>> hours >>> >> upon >>> >> hours without any result whatsoever. First of all my setup: >>> >> >>> >> - Centos 4.4 >>> >> - apache 2.0.52 >>> >> - php 5.1.6 >>> >> - postgresql 8.1.8 >>> >> - mapserver 4.0.1 (I know, I should update mapserver, but having to >>> >> rebuild >>> >> all the legends in our system and possibly avoid some other side >>> effects >>> >> would be a major headache and have so far kept me from doing this) >>> >> - gdal 1.4.0 >>> >> - postgis 1.2.1 >>> >> - geos 2.2.3 >>> >> - proj 4.5.0 >>> >> - glibc 2.3.4-2.25 >>> >> >>> >> The error in the httpd error_log reads as stated in the subject. >>> >> >>> >> I have added some multipolygon data that I had previously obtained by >>> >> converting it from a shape file using shp2pgsql. >>> >> >>> >> The odd part about this error is, that I use the same syntax in the >>> >> map file >>> >> as for a working multipolygon layer that I had imported using older >>> >> versions >>> >> of postgis etc. and the older data works just fine. >>> >> I have reimported said working data from the original shape file and >>> >> compared it to the existing data in the working table. the_geom >>> and other >>> >> relevant stuff is identical. And still the newly imported data >>> >> produces this >>> >> error. >>> >> >>> >> I have checked projection, db access privs and just about >>> everything else >>> >> that crossed my mind as playing a part to no avail. >>> >> >>> >> So, is this problem a known issue? What else could I try/look into? >>> >> Any advice? >>> >> >>> >> Thanks >>> >> Dominik >>> >> >>> > >>> >>> >>> -- >>> Dominik Schmid >>> Dipl. Umweltnaturwissenschafter ETH >>> >>> ilu AG >>> Zentralstrasse 2a >>> CH-8610 Uster >>> >>> Tel: +41 44 / 944 55 56 (Direktwahl) >>> Tel: +41 44 / 944 55 55 (allgemein) >>> Fax: +41 44 / 944 55 66 >>> >>> mailto:dominik.schmid at ilu.ch >>> http://www.ilu.ch >>> >> > > -- Dominik Schmid Dipl. Umweltnaturwissenschafter ETH ilu AG Zentralstrasse 2a CH-8610 Uster Tel: +41 44 / 944 55 56 (Direktwahl) Tel: +41 44 / 944 55 55 (allgemein) Fax: +41 44 / 944 55 66 mailto:dominik.schmid at ilu.ch http://www.ilu.ch From satsuman at GMAIL.COM Mon Jul 16 02:49:38 2007 From: satsuman at GMAIL.COM (SATish In Athens +30 6947758275) Date: Mon, 16 Jul 2007 12:49:38 +0300 Subject: Cursor position Message-ID: Hello all.. When i take my mouse on the image , i want to display the image co-ordinates (in Kilometers or miles) and it should change as the cursor changes its position.. secondly, i want to display one graphics image for "Please Wait , map is loading" whenever map is refreshed.. I do not know how to implement these features.. your concern will be heavily appreciated.. -------------- next part -------------- An HTML attachment was scrubbed... URL: From veeraswamyd at YAHOO.CO.IN Mon Jul 16 03:05:45 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Mon, 16 Jul 2007 03:05:45 -0700 Subject: tcp Message-ID: hi iam working with ms4w 2.2.4 iis and apache are using port 80 so simultaniously iis and apache are not ruuning so i have changed port value in C:\ms4w\Apache\conf\httpd.conf file consists LISTEN 80 and i have changed it as LISTEN 8080,but it is not working when i runned the application it is displaying as "page not found" but i haved changed the LISTEN 80 to LISTEN 8080 in ms4w2.1 there it is working plz tell me this -- View this message in context: http://www.nabble.com/tcp-tf4085692.html#a11612493 Sent from the Mapserver - User mailing list archive at Nabble.com. From rodrigomartin at LOPEZGREGORIO.COM.AR Mon Jul 16 04:36:34 2007 From: rodrigomartin at LOPEZGREGORIO.COM.AR (=?ISO-8859-1?Q?Rodrigo_Mart=EDn_L=D3PEZ_GREGORIO?=) Date: Mon, 16 Jul 2007 12:36:34 +0100 Subject: tcp In-Reply-To: <11612493.post@talk.nabble.com> Message-ID: Hi Iakku. - Do you have restarted the apache service? You can do this directly from the apache-restart.bat located on ms4w folder or from "Services" on "Administrative Tools" on Windows Control Panel (I'm guessing the english names of the icons cause my windows is in spanish). - When you access to the page, do you put the 8080 port in the url? like: http://localhost:8080/mypage.php - Isn't there any other service running on port 8080? sorry if I ask some dumb questions. Rodrigo. On 7/16/07, lakku wrote: > > hi > iam working with ms4w 2.2.4 > iis and apache are using port 80 > so simultaniously iis and apache are not ruuning > so i have changed port value in C:\ms4w\Apache\conf\httpd.conf file > consists > LISTEN 80 and i have changed it as LISTEN 8080,but it is not working when > i > runned the application it is displaying as "page not found" > but i haved changed the LISTEN 80 to LISTEN 8080 in ms4w2.1 there it is > working > plz tell me this > -- > View this message in context: > http://www.nabble.com/tcp-tf4085692.html#a11612493 > Sent from the Mapserver - User mailing list archive at Nabble.com. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From steve at SJK.NET.AU Mon Jul 16 04:57:04 2007 From: steve at SJK.NET.AU (Stephen Kelly) Date: Mon, 16 Jul 2007 21:57:04 +1000 Subject: tcp In-Reply-To: <10cf58b30707160436y69db3897q4718b9ce052d6263@mail.gmail.com> Message-ID: If you are getting a page not found error, that message has to come from a WWW server, so it is finding the server, just not either the correct server or the page on the server, so it is probably having a problem finding the default document, Try stopping IIS, Reinstall the standard MS4W and see if that works Good Luck Stephen Kelly Peepel www.Peepel.com _____ From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Rodrigo Mart?n L?PEZ GREGORIO Sent: Monday, 16 July 2007 9:37 PM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] tcp Hi Iakku. - Do you have restarted the apache service? You can do this directly from the apache-restart.bat located on ms4w folder or from "Services" on "Administrative Tools" on Windows Control Panel (I'm guessing the english names of the icons cause my windows is in spanish). - When you access to the page, do you put the 8080 port in the url? like: http://localhost:8080/mypage.php - Isn't there any other service running on port 8080? sorry if I ask some dumb questions. Rodrigo. On 7/16/07, lakku wrote: hi iam working with ms4w 2.2.4 iis and apache are using port 80 so simultaniously iis and apache are not ruuning so i have changed port value in C:\ms4w\Apache\conf\httpd.conf file consists LISTEN 80 and i have changed it as LISTEN 8080,but it is not working when i runned the application it is displaying as "page not found" but i haved changed the LISTEN 80 to LISTEN 8080 in ms4w2.1 there it is working plz tell me this -- View this message in context: http://www.nabble.com/tcp-tf4085692.html#a11612493 Sent from the Mapserver - User mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bthoen at GISNET.COM Mon Jul 16 07:50:14 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Mon, 16 Jul 2007 08:50:14 -0600 Subject: Using PHP Shared Object Library with PHP/Mapscript, MapServer and PostGIS Message-ID: I would like to try out PHP/Mapscript, but the data source for my MapServer includes PostGIS files, and the installed version of PHP was not compiled using the --with-pgsql switch. Rather than go through the hassle of recompiling PHP, I noticed that you can use the dl() function in PHP to load the necessary library. Specifically, I need the database access functions pg_connect() and friends, and I'm using a Fedora Core 5 box. My question is, where would I find the correct shared object library to use with dl() or is this not the right approach? TIA, -- - Bill Thoen GISnet - www.gisnet.com 303-786-9961 From Kyle.Wilcox at NOAA.GOV Mon Jul 16 09:02:03 2007 From: Kyle.Wilcox at NOAA.GOV (Kyle Wilcox) Date: Mon, 16 Jul 2007 12:02:03 -0400 Subject: Using PHP Shared Object Library with PHP/Mapscript, MapServer and PostGIS In-Reply-To: <469B85A6.90302@gisnet.com> Message-ID: $ sudo yum install php-pgsql Bill Thoen wrote: > I would like to try out PHP/Mapscript, but the data source for my > MapServer includes PostGIS files, and the installed version of PHP was > not compiled using the --with-pgsql switch. Rather than go through the > hassle of recompiling PHP, I noticed that you can use the dl() function > in PHP to load the necessary library. Specifically, I need the database > access functions pg_connect() and friends, and I'm using a Fedora Core 5 > box. > > My question is, where would I find the correct shared object library to > use with dl() or is this not the right approach? > > TIA, > -- Kyle Wilcox NOAA Chesapeake Bay Office 410 Severn Avenue Suite 107A Annapolis, MD 21403 office: (410) 295-3151 Kyle.Wilcox at noaa.gov "It is from the wellspring of our despair and the places that we are broken that we come to repair the world." - Murray Waas From bthoen at GISNET.COM Mon Jul 16 09:34:19 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Mon, 16 Jul 2007 10:34:19 -0600 Subject: Using PHP Shared Object Library with PHP/Mapscript, MapServer and PostGIS In-Reply-To: <469B967B.6040801@Noaa.gov> Message-ID: Ooh, perfect! Just the level of difficulty I was hoping for -- dead easy! Kyle Wilcox wrote: > $ sudo yum install php-pgsql > > > Bill Thoen wrote: > >> I would like to try out PHP/Mapscript, but the data source for my >> MapServer includes PostGIS files, and the installed version of PHP was >> not compiled using the --with-pgsql switch. Rather than go through the >> hassle of recompiling PHP, I noticed that you can use the dl() function >> in PHP to load the necessary library. Specifically, I need the database >> access functions pg_connect() and friends, and I'm using a Fedora Core 5 >> box. >> >> My question is, where would I find the correct shared object library to >> use with dl() or is this not the right approach? >> >> TIA, >> >> > > From fantognini at GMAIL.COM Mon Jul 16 12:13:38 2007 From: fantognini at GMAIL.COM (Francesco Antognini) Date: Mon, 16 Jul 2007 21:13:38 +0200 Subject: Setting attributes of shapes on php-mapscript Message-ID: Hello I'm stuck with this and need advice. I'm working with ms4w version 2.2.3. In php mapscript, I'm trying to assign values to attributes of newly created shape objects. However, whatever I do it doesn't seem to work. First of all shapeobj->setValue() is not defined: $shpn= ms_newShapeObj(MS_SHAPE_POLYGON); $shpn->setvalue(0,"foobar"); // >>> php generates error Then setting the directly the values array works on the php object: $shpn->value[0]='bar'; $shpn->value['foo']='bar'; However changes are never transferred to the actual peer in the layer, as print_r clearly shows: .... [values] => Array ( ) ..... At this point I wonder whether this is possible at all, at least in php-mapscript. If anyone can give me hint it would be very helpful. Even a negative one. TIA F. Antognini -- Francesco Antognini Computer Consultant Switzerland fantognini at gmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From wzhu at CERT.UCR.EDU Mon Jul 16 13:02:29 2007 From: wzhu at CERT.UCR.EDU (Shawn Zhu) Date: Mon, 16 Jul 2007 13:02:29 -0700 Subject: a question about generating map data structure Message-ID: HI, Dear all, I just joined this emailist and was excited to find such a group. I am not alone :). I am doing some GIS stuff and have a question. I am trying to develop some algorithm similar to dijkstra, and have finished debugging with my testing hand-built graph. Now I want to test this algorithm with real map data. The problem is I don't know how to convert a map data(e.g. shape file) to a data structure(like graph node matrix/linked list) I can use. Is there any way or software I can use? Can anybody give me any hint? Thanks a lot. Shawn Zhu. July 16, 2007 From frdcn at HOTMAIL.COM Mon Jul 16 13:26:20 2007 From: frdcn at HOTMAIL.COM (godofredo contreras) Date: Mon, 16 Jul 2007 20:26:20 +0000 Subject: a question about generating map data structure Message-ID: Hi, Shawn Zhu: There is a similar work based on postgresql and mapserver, this is the url where you can find information : http://www.cartoweb.org/contribs.html Best regards Godofredo Contreras > Date: Mon, 16 Jul 2007 13:02:29 -0700> From: wzhu at CERT.UCR.EDU> Subject: [UMN_MAPSERVER-USERS] a question about generating map data structure> To: MAPSERVER-USERS at LISTS.UMN.EDU> > HI, Dear all,> > I just joined this emailist and was excited to find such a group. I am not > alone :).> I am doing some GIS stuff and have a question.> I am trying to develop some algorithm similar to dijkstra, and have > finished debugging with my testing hand-built graph. Now I want to test this > algorithm with real map data.> The problem is I don't know how to convert a map data(e.g. shape file) to a > data structure(like graph node matrix/linked list) I can use. Is there any way > or software I can use? Can anybody give me any hint? Thanks a lot.> > > Shawn Zhu.> July 16, 2007 _________________________________________________________________ See what you?re getting into?before you go there. http://newlivehotmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From bthoen at GISNET.COM Mon Jul 16 13:50:01 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Mon, 16 Jul 2007 14:50:01 -0600 Subject: Building PHP Mapscript Message-ID: I want to build PHP Mapscript from source on my Fedora Core 5 box, but I need some help with the 'DIR' part of the MapServer configuration switch --with-PHP=DIR. I have PHP installed from an rpm and so I don't know where to find the PHP include directory. Any suggestions how I can make this work? - Bill Thoen From gregor at HOSTGIS.COM Mon Jul 16 14:54:18 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Mon, 16 Jul 2007 15:54:18 -0600 Subject: Building PHP Mapscript In-Reply-To: <469BD9F9.3070703@gisnet.com> Message-ID: Bill Thoen wrote: > I want to build PHP Mapscript from source on my Fedora Core 5 box, but I > need some help with the 'DIR' part of the MapServer configuration switch > --with-PHP=DIR. I have PHP installed from an rpm and so I don't know > where to find the PHP include directory. Any suggestions how I can make > this work? It wants the PHP source code. What I usually do is grab a copy of the source and extract it, then ./configure it the same as my existing installation. Ta-da, a usable source with the same configuration and all. Use phpinfo() to find out what ./configure arguments were used originally, and trim out those annoying ' characters. Easy. :) -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From rob at DATAFLOWDESIGN.COM Mon Jul 16 15:23:17 2007 From: rob at DATAFLOWDESIGN.COM (R. P.) Date: Mon, 16 Jul 2007 17:23:17 -0500 Subject: Building PHP Mapscript In-Reply-To: <469BD9F9.3070703@gisnet.com> Message-ID: On Mon, 16 Jul 2007 14:50:01 -0600 Bill Thoen wrote: >I want to build PHP Mapscript from source on my Fedora Core 5 box, but I need some help with the 'DIR' part of the MapServer configuration switch --with-PHP=DIR. I have PHP installed from an rpm and so I don't know where to find the PHP include directory. Any suggestions how I can make this work? > >- Bill Thoen Bill, Not sure about this, but ir your are using yum, the php default install may not include the header files. Instead, you need to install the development version of php. Something like php-devel(??) and that will give you the header files. I think this holds true for other yum installs as well. Rob From satsuman at GMAIL.COM Tue Jul 17 02:48:17 2007 From: satsuman at GMAIL.COM (SATish In Athens +30 6947758275) Date: Tue, 17 Jul 2007 12:48:17 +0300 Subject: Cursor position In-Reply-To: Message-ID: I have tried with dBox.. I put this in head.. function mousemove_handler(name, x, y) { document.getElementById('coordinates').value = " x= " + Math.round (Number(ms.extent[0] + x*ms.cellsize)) + " and y= " + Math.round(Number( ms.extent[3] - y*ms.cellsize)); } and this in body.. But I am getting the co-ordinates value in co-ordinates box only when i click on the image... But, it should come as soon as I move my cursor on the image. I tried with installing a separate jBox but i dint get the image so i left.. :) Now, what to do? Well, and I am not able to configure things with my "waiting graphics".. Can some one explain that please.. regards Satish On 7/17/07, Luis Trevi?o wrote: > > you could try jBox. it's an applet that does what you want. Take a look at > http://mapserver.gis.umn.edu/docs/howto/jbox > > cheers, > Luis > > > 2007/7/16, SATish In Athens +30 6947758275 : > > > > Hello all.. > > When i take my mouse on the image , i want to display the image > > co-ordinates (in Kilometers or miles) and it should change as the cursor > > changes its position.. > > secondly, i want to display one graphics image for "Please Wait , map is > > loading" whenever map is refreshed.. > > I do not know how to implement these features.. > > your concern will be heavily appreciated.. > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From josevicente.higon at GMAIL.COM Tue Jul 17 03:00:40 2007 From: josevicente.higon at GMAIL.COM (=?utf-8?q?Jos=C3=A9_Vicente_Hig=C3=B3n?=) Date: Tue, 17 Jul 2007 12:00:40 +0200 Subject: Problem with WMS getFeatureInfo and UTF8 encoding in postGIS In-Reply-To: <200707131253.28936.josevicente.higon@iver.es> Message-ID: On Friday 13 July 2007 12:53:28 you wrote: > Hi, > I'm using mapserver 4.10.2 and postGIS with UTF-8 encoding. When I request > a GetFeatureInfo from a record with special characters like '?' or '?' I > get an empty XML. However, if the record doesn't have these special > characters I'll get a correct XML. > ?Is there any problem with the operation GetFeatureInfo in UTF-8 databases? > > Thanks in advance. Sorry! I was wrong, Mapserver works fine. I was doing a wrong request, the point didn't intersect with any geometry. Sorry. Bye. -- Jos? Vicente Hig?n Valero Grupo desarrollo gvSIG. IVER TI S.A. C/Salamanca, 50-52 46005-Valencia Tlf.+34963163400 http://www.iver.es http://www.gvsig.com http://www.gvsig.gva.es From dmorissette at MAPGEARS.COM Tue Jul 17 05:45:39 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 17 Jul 2007 08:45:39 -0400 Subject: Building PHP Mapscript In-Reply-To: <469BE90A.5000802@hostgis.com> Message-ID: Gregor Mosheh wrote: > > It wants the PHP source code. What I usually do is grab a copy of the > source and extract it, then ./configure it the same as my existing > installation. Ta-da, a usable source with the same configuration and all. > > Use phpinfo() to find out what ./configure arguments were used > originally, and trim out those annoying ' characters. Easy. :) > R. P. wrote: > Not sure about this, but ir your are using yum, the php default install > may not include the header files. Instead, you need to install the > development version of php. Something like php-devel(??) and that will > give you the header files. I think this holds true for other yum installs > as well. > Rob Bill, Gregor and Rob are both right. You can point --with-php=DIR either to the original source tree that was used to compile PHP or to the install directory where the PHP header files are installed by the php-devel package or equivalent (e.g. /usr). Basically what MapServer's configure script needs is the location of the PHP header files that were used to compile your PHP installation. Daniel -- Daniel Morissette http://www.mapgears.com/ From satsuman at GMAIL.COM Tue Jul 17 06:19:00 2007 From: satsuman at GMAIL.COM (SATish ...) Date: Tue, 17 Jul 2007 16:19:00 +0300 Subject: Cursor position Message-ID: Hey Martin.. It was very nice of you that you replied and it was really a nice effort.. But, It did not work and now I am afraid if some basic thing is missing in my code or what.. I just kept refining the itasca demo as for my need and many things I implemented in it.. But somethings are still lacking which I am not able to figure out.. 1. When I click on Reference map, the original map loses focus instead of navigating itself to that position. 2. The loading image when map is refreshed. 3. The cursor position (real world) when mouse is over the map. 4. I want to zoom-out more and the initial map should be smaller than it is now. 5. I put on copyright symbol with help of layer but (c) symbol is not clear because of font and other than that can I use graphics for this too. 6. How to resize map window for different computer screens. 7. Grids are not working. I have pasted my html code below the message. I am trying hard for getting these answers and please see if you are able in solving at least some of my problems Thanks and Regards Satish ---------------------------------------------------------------------------------------------------------------------------------------------------------------- MapServer - Itasca Application

    MapServer - Itasca Application


    pan
northwest pan
north pan
northeast
    pan
west
    pan
east
    pan
southwest pan
south pan
southeast
    scalebar (km) scalebar (mi)

    Map controls:

    • Reference map
    • Browse
      • Zoom In
      • Zoom Out
      • Center map
      • Zoom extents
      •  Zoom factor
        • Low
        • Normal
        • High
    • Query

        Choose an Action:

      • Browse map
      • Query feature
      • Query multiple features
      • Search

      •    

    • Resize Window

    Layer controls:

    • Geography
      • Cities
      • Coast
      • Geology
    • Weather
      • Rain Contoors
      • Temp Contoors
    • Infrastructure
      • Roads
    • Grid
      • 5 deg gridlines
      • 1 deg gridlines


    Legend:



    back to start

    ------------------------------------------------------------------------------------------------------------------------------------------------------------------ On 7/17/07, Rodrigo Mart?n L?PEZ GREGORIO wrote: > > Hi Satish > > try this: > > width="600" onMouseOver="mousemove_handler(name, x, y)"> > > I use the MouseOver event instead MouseMove. > > about the loading image what you must do is something like this: > > First add an element on your page, give it a name and the same id, > and preferable position it absolutelly on your page. Also give it a z-index > value so it will be over other elements(i.e. the map). And finally a > "display:none;" in the style will make it to not be showed by default... > something like: > > style="position: absolute; display:none; left:480px; top:360px;width: > 120px; height: 30px; z-index: 50; > > > then when you are going to retrieve the new map image (in some place > inside the javascript function of jBox that gets the new image) you must > change the display property of your loading image so it will be visible: > > document.getElementById('loadingimage').style.display = ''; > > and if there is a jBox function that handles the onload of the image > element you must add the next code to that function. > > document.getElementById ('loadingimage').style.display = 'none'; > > if there is no jBox function that handles the onload event of your image, > what you can do is put that code inside the onLoad event of the map > element, like: > > width="600" onMouseOver="mousemove_handler(name, x, y)" onLoad=" > document.getElementById('loadingimage').style.display = 'none';"> > > I hope you understand what I'm talking about but ask me again if you can't > get it working. > > Rodrigo. > > On 7/17/07, SATish In Athens +30 6947758275 < satsuman at gmail.com> wrote: > > > > I have tried with dBox.. > > > > > > I put this in head.. > > > > function mousemove_handler(name, x, y) { > > document.getElementById('coordinates').value = " x= " + Math.round(Number( > > ms.extent[0] + x* ms.cellsize)) + " and y= " + Math.round(Number( > > ms.extent[3] - y*ms.cellsize)); > > } > > > > > > > > and this in body.. > > > > > width="600" onMouseMove= "mousemove_handler(name, x, y)" > > onMouseOver="isCursorOver=true" onMouseOut="isCursorOver=false"> > > > > > > But I am getting the co-ordinates value in co-ordinates box only when i > > click on the image... > > But, it should come as soon as I move my cursor on the image. > > I tried with installing a separate jBox but i dint get the image so i > > left.. :) > > Now, what to do? > > > > > > Well, and I am not able to configure things with my "waiting > > graphics".. Can some one explain that please.. > > > > regards > > Satish > > > > > > > > > > > > > > > > On 7/17/07, Luis Trevi?o wrote: > > > > > > you could try jBox. it's an applet that does what you want. Take a > > > look at http://mapserver.gis.umn.edu/docs/howto/jbox > > > > > > cheers, > > > Luis > > > > > > > > > 2007/7/16, SATish In Athens +30 6947758275 : > > > > > > > > Hello all.. > > > > When i take my mouse on the image , i want to display the image > > > > co-ordinates (in Kilometers or miles) and it should change as the cursor > > > > changes its position.. > > > > secondly, i want to display one graphics image for "Please Wait , > > > > map is loading" whenever map is refreshed.. > > > > I do not know how to implement these features.. > > > > your concern will be heavily appreciated.. > > > > > > > > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From David.Fawcett at STATE.MN.US Tue Jul 17 06:34:20 2007 From: David.Fawcett at STATE.MN.US (Fawcett, David) Date: Tue, 17 Jul 2007 08:34:20 -0500 Subject: Cursor position In-Reply-To: A Message-ID: Satish, You are really asking the list to do a lot of homework for you. You may want to look at dBox, it has many of the features that you are looking for. http://maps.dnr.state.mn.us/tools/dbox/ You could either use it out of the box, or use the code to modify your existing application. David. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of SATish ... Sent: Tuesday, July 17, 2007 8:19 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: [UMN_MAPSERVER-USERS] Cursor position Hey Martin.. It was very nice of you that you replied and it was really a nice effort.. But, It did not work and now I am afraid if some basic thing is missing in my code or what.. I just kept refining the itasca demo as for my need and many things I implemented in it.. But somethings are still lacking which I am not able to figure out.. 1. When I click on Reference map, the original map loses focus instead of navigating itself to that position. 2. The loading image when map is refreshed. 3. The cursor position (real world) when mouse is over the map. 4. I want to zoom-out more and the initial map should be smaller than it is now. 5. I put on copyright symbol with help of layer but ? symbol is not clear because of font and other than that can I use graphics for this too. 6. How to resize map window for different computer screens. 7. Grids are not working. I have pasted my html code below the message. I am trying hard for getting these answers and please see if you are able in solving at least some of my problems Thanks and Regards Satish ---------------------------------------------------------------------------------------------------------------------------------------------------------------- MapServer - Itasca Application

    MapServer - Itasca Application


    pan northwest pan north pan northeast
    pan west
    pan east
    pan southwest pan south pan southeast
    scalebar (km) scalebar (mi)

    Map controls:

    • Reference map
    • Browse
      • Zoom In
      • Zoom Out
      • Center map
      • Zoom extents
      •  Zoom factor
        • Low
        • Normal
        • High
    • Query

        Choose an Action:

      • Browse map
      • Query feature
      • Query multiple features
      • Search

      •    

    • Resize Window

    Layer controls:

    • Geography
      • Cities
      • Coast
      • Geology
    • Weather
      • Rain Contoors
      • Temp Contoors
    • Infrastructure
      • Roads
    • Grid
      • 5 deg gridlines
      • 1 deg gridlines


    Legend:



    back to start

    ------------------------------------------------------------------------------------------------------------------------------------------------------------------ On 7/17/07, Rodrigo Mart?n L?PEZ GREGORIO wrote: Hi Satish try this: I use the MouseOver event instead MouseMove. about the loading image what you must do is something like this: First add an element on your page, give it a name and the same id, and preferable position it absolutelly on your page. Also give it a z-index value so it will be over other elements(i.e. the map). And finally a "display:none;" in the style will make it to not be showed by default... something like: I hope you understand what I'm talking about but ask me again if you can't get it working. Rodrigo. On 7/17/07, SATish In Athens +30 6947758275 < satsuman at gmail.com > wrote: I have tried with dBox.. I put this in head.. function mousemove_handler(name, x, y) { document.getElementById('coordinates').value = " x= " + Math.round(Number( ms.extent[0] + x* ms.cellsize)) + " and y= " + Math.round(Number(ms.extent[3] - y*ms.cellsize)); } and this in body.. But I am getting the co-ordinates value in co-ordinates box only when i click on the image... But, it should come as soon as I move my cursor on the image. I tried with installing a separate jBox but i dint get the image so i left.. :) Now, what to do? Well, and I am not able to configure things with my "waiting graphics".. Can some one explain that please.. regards Satish On 7/17/07, Luis Trevi?o wrote: you could try jBox. it's an applet that does what you want. Take a look at http://mapserver.gis.umn.edu/docs/howto/jbox cheers, Luis 2007/7/16, SATish In Athens +30 6947758275 : Hello all.. When i take my mouse on the image , i want to display the image co-ordinates (in Kilometers or miles) and it should change as the cursor changes its position.. secondly, i want to display one graphics image for "Please Wait , map is loading" whenever map is refreshed.. I do not know how to implement these features.. your concern will be heavily appreciated.. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bpicinbono at WORLDONLINE.FR Tue Jul 17 06:31:23 2007 From: bpicinbono at WORLDONLINE.FR (Blaise) Date: Tue, 17 Jul 2007 15:31:23 +0200 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <2b9c84c00707161213i29aa461ci9a2ee39f29b8de54@mail.gmail.com> Message-ID: Le lundi 16 juillet 2007 21:13, Francesco Antognini a ?crit?: > Hello > I'm stuck with this and need advice. I'm working with ms4w version 2.2.3. > > In php mapscript, I'm trying to assign values to attributes of newly > created shape objects. However, whatever I do it doesn't seem to work. > > First of all shapeobj->setValue() is not defined: > > $shpn= ms_newShapeObj(MS_SHAPE_POLYGON); > $shpn->setvalue(0,"foobar"); // >>> php generates error > > Then setting the directly the values array works on the php object: > > $shpn->value[0]='bar'; > $shpn->value['foo']='bar'; > > However changes are never transferred to the actual peer in the layer, as > print_r clearly shows: > > .... [values] => Array ( ) ..... > > > At this point I wonder whether this is possible at all, at least in > php-mapscript. If anyone can give me hint it would be very helpful. Even a > negative one. > TIA > F. Antognini Hi Assuming your are working with esri shape files (*.shp, *shx, and *.dbf), php_mapscript allows you to add new shapes and you can use php dbase functions to add new records (and datas) to the dbf file. Have a look over here : http://www.php.net/manual/en/ref.dbase.php Regards Blaise From rodrigo.andrade at DIGITRO.COM.BR Tue Jul 17 06:21:46 2007 From: rodrigo.andrade at DIGITRO.COM.BR (Rodrigo Del C. Andrade) Date: Tue, 17 Jul 2007 10:21:46 -0300 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <2b9c84c00707161213i29aa461ci9a2ee39f29b8de54@mail.gmail.com> Message-ID: Hi. As of mapscript 4.10 you need to initialize the shapes to receive values. try issuing a $shp->initValues(1); before setValue. The int argument is the number of values you will set in that shape. I know this was changed for the SWIG versions of mapscript, I am not sure about it on the PHP front, but someone will correct me if its not the case. Cheers, Rodrigo -- *Rodrigo Del C. Andrade* /Programador/ /SIC - SSE - Solu??es Seguran?a P?blica/ *D?GITRO TECNOLOGIA* *E-mail:* rodrigo.andrade at digitro.com.br *Fone:* +55 48 3281-7314 / +55 48 3281-7000 *Fax:* +55 48 3281-7299 *Site:* www.digitro.com Francesco Antognini wrote: > Hello > I'm stuck with this and need advice. I'm working with ms4w version 2.2.3. > > In php mapscript, I'm trying to assign values to attributes of newly > created shape objects. However, whatever I do it doesn't seem to work. > > First of all shapeobj->setValue() is not defined: > > $shpn= ms_newShapeObj(MS_SHAPE_POLYGON); > $shpn->setvalue(0,"foobar"); // >>> php generates error > > Then setting the directly the values array works on the php object: > > $shpn->value[0]='bar'; > $shpn->value['foo']='bar'; > > However changes are never transferred to the actual peer in the layer, > as print_r clearly shows: > > .... [values] => Array ( ) ..... > > > At this point I wonder whether this is possible at all, at least in > php-mapscript. If anyone can give me hint it would be very helpful. > Even a negative one. > TIA > F. Antognini > > -- > Francesco Antognini > Computer Consultant > Switzerland > fantognini at gmail.com From dmorissette at MAPGEARS.COM Tue Jul 17 06:57:14 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 17 Jul 2007 09:57:14 -0400 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <469CC26A.6000804@digitro.com.br> Message-ID: I'm not sure about SWIG MapScript, but in PHP MapScript, the shape->values[] array is read-only and there is no way to set the values[] with PHP MapScript. If working with a shapefile then the recommended way to update attributes is to use the PHP dbase functions as was pointed out in another post earlier in this thread. Daniel Rodrigo Del C. Andrade wrote: > Hi. > > As of mapscript 4.10 you need to initialize the shapes to receive > values. > try issuing a > > $shp->initValues(1); > > before setValue. The int argument is the number of values you will > set in that shape. > I know this was changed for the SWIG versions of mapscript, I am not > sure about it on the PHP front, but someone will correct me if its not > the case. > > Cheers, > > Rodrigo > > -- Daniel Morissette http://www.mapgears.com/ From rodrigo.andrade at DIGITRO.COM.BR Tue Jul 17 07:45:06 2007 From: rodrigo.andrade at DIGITRO.COM.BR (Rodrigo Del C. Andrade) Date: Tue, 17 Jul 2007 11:45:06 -0300 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <469CCABA.2050604@mapgears.com> Message-ID: I stand corrected. Rodrigo Daniel Morissette wrote: > I'm not sure about SWIG MapScript, but in PHP MapScript, the > shape->values[] array is read-only and there is no way to set the > values[] with PHP MapScript. > > If working with a shapefile then the recommended way to update > attributes is to use the PHP dbase functions as was pointed out in > another post earlier in this thread. > > Daniel > > > Rodrigo Del C. Andrade wrote: >> but someone will correct me if its not the case. >> From fantognini at GMAIL.COM Tue Jul 17 08:11:30 2007 From: fantognini at GMAIL.COM (Francesco Antognini) Date: Tue, 17 Jul 2007 17:11:30 +0200 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <469CD5F2.2010103@digitro.com.br> Message-ID: Thanks for all the replies. Calling $shp->initValues() generates this error Fatal error: Call to undefined method ms_shape_obj::initValues() in C:\ms4w\Apache\htdocs\test\test-ms_caplib.php on line 151 Checking the php_mapscript.dll extension reveals that both initValues and setValues are not defined. So php does not support them. Using the dbf tables is a kind of a last resort approach, since the attributes must be generated dynamically for each user (specifications are still sketchy so I can't be more precise). That implies creating temporary dbf tables and shape files, which is not ideal. The other idea I have is to build a module in a different language (java) just to perform the requested functionality and then let php call it when needed. Php can invoke java classes and java seems to support both initValues() and setValues(). However even this approach is less than perfect as it requires additional stuff to be installed and may well present other unexpected pitfalls. Is there any hope that one day php mapscript will be updated ? (shpeobj::clone is missing too...) Thanks for the help. F.Antognini On 7/17/07, Daniel Morissette < dmorissette at mapgears.com> wrote: > I'm not sure about SWIG MapScript, but in PHP MapScript, the > shape->values[] array is read-only and there is no way to set the > values[] with PHP MapScript. > > If working with a shapefile then the recommended way to update > attributes is to use the PHP dbase functions as was pointed out in > another post earlier in this thread. > > Daniel > > > Rodrigo Del C. Andrade wrote: > > Hi. > > > > As of mapscript 4.10 you need to initialize the shapes to receive > > values. > > try issuing a > > > > $shp->initValues(1); > > > > before setValue. The int argument is the number of values you will > > set in that shape. > > I know this was changed for the SWIG versions of mapscript, I am not > > sure about it on the PHP front, but someone will correct me if its not > > the case. > > > > Cheers, > > > > Rodrigo > > > > > > > -- > Daniel Morissette > http://www.mapgears.com/ > -- Francesco Antognini Computer Consultant Switzerland fantognini at gmail.com From rwburgholzer at DEQ.VIRGINIA.GOV Tue Jul 17 08:14:46 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Tue, 17 Jul 2007 11:14:46 -0400 Subject: Setting attributes of shapes on php-mapscript Message-ID: Francesco, This may not be what you are looking for, or it may be stating the obvious, but why not create your shapes in a PostGIS table? Then you could manipulate them quite easily via SQL calls? HTH, r.b. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Francesco Antognini Sent: Tuesday, July 17, 2007 11:12 AM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Setting attributes of shapes on php-mapscript Thanks for all the replies. Calling $shp->initValues() generates this error Fatal error: Call to undefined method ms_shape_obj::initValues() in C:\ms4w\Apache\htdocs\test\test-ms_caplib.php on line 151 Checking the php_mapscript.dll extension reveals that both initValues and setValues are not defined. So php does not support them. Using the dbf tables is a kind of a last resort approach, since the attributes must be generated dynamically for each user (specifications are still sketchy so I can't be more precise). That implies creating temporary dbf tables and shape files, which is not ideal. The other idea I have is to build a module in a different language (java) just to perform the requested functionality and then let php call it when needed. Php can invoke java classes and java seems to support both initValues() and setValues(). However even this approach is less than perfect as it requires additional stuff to be installed and may well present other unexpected pitfalls. Is there any hope that one day php mapscript will be updated ? (shpeobj::clone is missing too...) Thanks for the help. F.Antognini On 7/17/07, Daniel Morissette < dmorissette at mapgears.com> wrote: > I'm not sure about SWIG MapScript, but in PHP MapScript, the > shape->values[] array is read-only and there is no way to set the > values[] with PHP MapScript. > > If working with a shapefile then the recommended way to update > attributes is to use the PHP dbase functions as was pointed out in > another post earlier in this thread. > > Daniel > > > Rodrigo Del C. Andrade wrote: > > Hi. > > > > As of mapscript 4.10 you need to initialize the shapes to receive > > values. > > try issuing a > > > > $shp->initValues(1); > > > > before setValue. The int argument is the number of values you will > > set in that shape. > > I know this was changed for the SWIG versions of mapscript, I am not > > sure about it on the PHP front, but someone will correct me if its not > > the case. > > > > Cheers, > > > > Rodrigo > > > > > > > -- > Daniel Morissette > http://www.mapgears.com/ > -- Francesco Antognini Computer Consultant Switzerland fantognini at gmail.com From dmorissette at MAPGEARS.COM Tue Jul 17 08:41:42 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 17 Jul 2007 11:41:42 -0400 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <2b9c84c00707170811h201b2be3hda7148e122b17f89@mail.gmail.com> Message-ID: Francesco Antognini wrote: > > Checking the php_mapscript.dll extension reveals that both initValues > and setValues are not defined. So php does not support them. > ... > > Is there any hope that one day php mapscript will be updated ? > (shpeobj::clone is missing too...) > I think the first step would be to file a enhancement ticket in Trac listing the missing methods. It may be too late to get that in 5.0 since the feature freeze is this coming Monday and our plates are already full, but ya never know, if you provide a good enough use case then someone might be able to get that in. Daniel -- Daniel Morissette http://www.mapgears.com/ From Steve.Lime at DNR.STATE.MN.US Tue Jul 17 10:46:49 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Tue, 17 Jul 2007 12:46:49 -0500 Subject: ? wbmp and gif output In-Reply-To: <35df1f800707131210q36e75f9aqb68bbc2f2ce43240@mail.gmail.com> Message-ID: I believe so but I'll have to investigate how... >>> On 7/13/2007 at 2:10 PM, in message <35df1f800707131210q36e75f9aqb68bbc2f2ce43240 at mail.gmail.com>, Alexey Udovydchenko wrote: > Is it possible to get wbmp and 16-colored gifs output with mapserver? From bthoen at GISNET.COM Tue Jul 17 10:53:07 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Tue, 17 Jul 2007 11:53:07 -0600 Subject: SUM: Building PHP Mapscript In-Reply-To: <469CB9F3.30107@mapgears.com> Message-ID: Thanks everyone for helping get PHP MapScript to compile. I managed to get it to work finally. A word of warning though for anyone else who might need to do this. Unless you plan to rebuild your copy of PHP, make sure you use the same version of PHP source that you are running on your machine. I first tried downloading the latest PHP source, but since that was a few versions newer than what's running on my machine, the resulting php_mapscript.so library wouldn't work (the API versions didn't match). But when I used the same version of PHP source as I have installed on my machine, everything worked fine. In retrospect, I should have expected this, but I seem to have to bang my head against the wall a few times before I realize why I have a headache... Daniel Morissette wrote: > Gregor Mosheh wrote: >> >> It wants the PHP source code. What I usually do is grab a copy of the >> source and extract it, then ./configure it the same as my existing >> installation. Ta-da, a usable source with the same configuration and >> all. >> >> Use phpinfo() to find out what ./configure arguments were used >> originally, and trim out those annoying ' characters. Easy. :) >> > > R. P. wrote: >> Not sure about this, but ir your are using yum, the php default >> install may not include the header files. Instead, you need to >> install the development version of php. Something like php-devel(??) >> and that will give you the header files. I think this holds true for >> other yum installs >> as well. >> Rob > > > Bill, > > Gregor and Rob are both right. You can point --with-php=DIR either to > the original source tree that was used to compile PHP or to the > install directory where the PHP header files are installed by the > php-devel package or equivalent (e.g. /usr). > > Basically what MapServer's configure script needs is the location of > the PHP header files that were used to compile your PHP installation. > > Daniel From dmorissette at MAPGEARS.COM Tue Jul 17 11:06:37 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 17 Jul 2007 14:06:37 -0400 Subject: SUM: Building PHP Mapscript In-Reply-To: <469D0203.8010906@gisnet.com> Message-ID: Bill Thoen wrote: > Thanks everyone for helping get PHP MapScript to compile. I managed to > get it to work finally. A word of warning though for anyone else who > might need to do this. Unless you plan to rebuild your copy of PHP, make > sure you use the same version of PHP source that you are running on your > machine. I first tried downloading the latest PHP source, but since that > was a few versions newer than what's running on my machine, the > resulting php_mapscript.so library wouldn't work (the API versions > didn't match). But when I used the same version of PHP source as I have > installed on my machine, everything worked fine. In retrospect, I should > have expected this, but I seem to have to bang my head against the wall > a few times before I realize why I have a headache... > Well, by downloading and using the PHP source of the same version as what is installed on your machine the build worked fine, but there is a small possibility that you may still encounter intermittent crashes at runtime because the PHP headers are customized to match your build options by PHP's configure, and you didn't use the headers that match exactly your PHP build options. Options such as the version of REGEX or GD used by PHP have an impact on MapScript. The only safe way to go is to either point to the PHP source tree that has been configured and compiled for your local install of PHP, or point to the installed header files (installed by make install or by a php-devel package). Of course things may still work if you're lucky, but if you encounter intermittent crashes you'll know where to start looking. Daniel -- Daniel Morissette http://www.mapgears.com/ From bthoen at GISNET.COM Tue Jul 17 11:46:32 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Tue, 17 Jul 2007 12:46:32 -0600 Subject: SUM: Building PHP Mapscript In-Reply-To: <469D052D.2000702@mapgears.com> Message-ID: I think my version of PHP just came with the distro and I didn't have its header files. So are you saying that I really should build a new version of PHP from source or just hope I get lucky? If one has just the binary PHP is there any other option than rebuilding PHP? Daniel Morissette wrote: > Bill Thoen wrote: >> Thanks everyone for helping get PHP MapScript to compile. I managed >> to get it to work finally. A word of warning though for anyone else >> who might need to do this. Unless you plan to rebuild your copy of >> PHP, make sure you use the same version of PHP source that you are >> running on your machine. I first tried downloading the latest PHP >> source, but since that was a few versions newer than what's running >> on my machine, the resulting php_mapscript.so library wouldn't work >> (the API versions didn't match). But when I used the same version of >> PHP source as I have installed on my machine, everything worked fine. >> In retrospect, I should have expected this, but I seem to have to >> bang my head against the wall a few times before I realize why I have >> a headache... >> > > Well, by downloading and using the PHP source of the same version as > what is installed on your machine the build worked fine, but there is > a small possibility that you may still encounter intermittent crashes > at runtime because the PHP headers are customized to match your build > options by PHP's configure, and you didn't use the headers that match > exactly your PHP build options. Options such as the version of REGEX > or GD used by PHP have an impact on MapScript. > > The only safe way to go is to either point to the PHP source tree that > has been configured and compiled for your local install of PHP, or > point to the installed header files (installed by make install or by a > php-devel package). > > Of course things may still work if you're lucky, but if you encounter > intermittent crashes you'll know where to start looking. > > Daniel -- - Bill Thoen GISnet - www.gisnet.com 303-786-9961 From dmorissette at MAPGEARS.COM Tue Jul 17 11:55:11 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 17 Jul 2007 14:55:11 -0400 Subject: SUM: Building PHP Mapscript In-Reply-To: <469D0E88.3030308@gisnet.com> Message-ID: Bill Thoen wrote: > I think my version of PHP just came with the distro and I didn't have > its header files. So are you saying that I really should build a new > version of PHP from source or just hope I get lucky? If one has just the > binary PHP is there any other option than rebuilding PHP? > Yes there is another option. most (all?) distros that distribute a php binary package will also offer a php-devel to accompany it that includes the headers. You need to get and install this php-devel package. I think you're using Fedora Code 5? See http://mirror.cpsc.ucalgary.ca/mirror/fedora/linux/core/5/i386/os/repodata/repoview/php-devel-0-5.1.2-5.html Daniel -- Daniel Morissette http://www.mapgears.com/ From slone3 at LLNL.GOV Tue Jul 17 17:23:18 2007 From: slone3 at LLNL.GOV (Dale Slone) Date: Tue, 17 Jul 2007 17:23:18 -0700 Subject: Server & map files on differing machines Message-ID: Hi How might I go about having MapServer run on one machine (with some linux variant) and have it render map files residing on my local machine? Thanx Dale From woodbri at SWOODBRIDGE.COM Tue Jul 17 17:52:06 2007 From: woodbri at SWOODBRIDGE.COM (Stephen Woodbridge) Date: Tue, 17 Jul 2007 20:52:06 -0400 Subject: Server & map files on differing machines In-Reply-To: <7.0.1.0.2.20070717171744.0296b088@llnl.gov> Message-ID: Dale Slone wrote: > Hi > > How might I go about having MapServer run on one machine (with some > linux variant) > and have it render map files residing on my local machine? > > Thanx > > Dale NFS/SMB/etc mount you mapfile directory from you local machine to the Mapserver machine. Beyond that it is probably a security risk to do anything more and mapserver does not support it. -Steve W From satsuman at GMAIL.COM Tue Jul 17 23:01:59 2007 From: satsuman at GMAIL.COM (SATish ...) Date: Wed, 18 Jul 2007 09:01:59 +0300 Subject: Cursor position In-Reply-To: <6246727221874A4FB8D3F9BBC37D9BD5021FB561@s-sp22.pca.state.mn.us> Message-ID: Well thanks David Yeah, I have problem in all that fields. Actually, in order to incorporate new features , i changed the demo a lot and so I am afraid if I messed up with some essential basic and that is why these are not working. And so I sent the code. Well, I am trying again and lets see if I can move further. Regards Satish On 7/17/07, Fawcett, David wrote: > > Satish, > > You are really asking the list to do a lot of homework for you. You may > want to look at dBox, it has many of the features that you are looking for. > http://maps.dnr.state.mn.us/tools/dbox/ > > You could either use it out of the box, or use the code to modify your > existing application. > > David. > > -----Original Message----- > *From:* UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] *On > Behalf Of *SATish ... > *Sent:* Tuesday, July 17, 2007 8:19 AM > *To:* MAPSERVER-USERS at LISTS.UMN.EDU > *Subject:* [UMN_MAPSERVER-USERS] Cursor position > > > Hey Martin.. > It was very nice of you that you replied and it was really a nice effort.. > But, It did not work and now I am afraid if some basic thing is missing in > my code or what.. > > I just kept refining the itasca demo as for my need and many things I > implemented in it.. > But somethings are still lacking which I am not able to figure out.. > > 1. When I click on Reference map, the original map loses focus instead of > navigating itself to that position. > > 2. The loading image when map is refreshed. > > 3. The cursor position (real world) when mouse is over the map. > > 4. I want to zoom-out more and the initial map should be smaller than it > is now. > > 5. I put on copyright symbol with help of layer but (c) symbol is not clear > because of font and other than that can I use graphics for this too. > > 6. How to resize map window for different computer screens. > > 7. Grids are not working. > > I have pasted my html code below the message. > > I am trying hard for getting these answers and please see if you are able > in solving at least some of my problems > > > Thanks and Regards > Satish > > > ---------------------------------------------------------------------------------------------------------------------------------------------------------------- > > > MapServer - Itasca Application > > > > > > > > > > > > > > > > > > > > > > > > > > > > > bgcolor=#FFFFFF onResize=" main.sync();reference.sync()"> > >

    MapServer - Itasca Application

    >
    > > > >
    style="margin-left:0;margin-bottom:0;margin-top:0;line-height:100%"> > > > > > >
    > > > > > >
    > > > > > align="center" bgcolor="#666666"> > > > > > > > > > > > > > > > > >
    src="graphics/nw.gif" width="18" height="18" border="0" alt="pan > northwest"> src="graphics/n.gif" width="23" height="18" border="0" alt="pan > north"> src="graphics/ne.gif" width="18" height="18" border="0" alt="pan > northeast">
    src="graphics/w.gif" width="18" height="23" border="0" alt="pan > west"> > >
    src="graphics/white_pixel.gif" height="600" width="600">
    > >
    src="graphics/transparent_pixel.gif" height="600" width="600" onMouseOver= > "mousemove_handler(name, x, y)">
    >
    src="graphics/e.gif" width="18" height="23" border="0" alt="pan > east">
    src="graphics/sw.gif" width="18" height="18" border="0" alt="pan > southwest"> src="graphics/s.gif" width="23" height="18" border="0" alt="pan > south"> src="graphics/se.gif" width="18" height="18" border="0" alt="pan > southeast">
    > alt="scalebar (km)" src="graphics/red_pixel.gif"> > scalebar (mi) src="graphics/red_pixel.gif"> >
    >
    > >
    > > >

    style="color:#00ee00;margin-left:6;margin-bottom:6;line-height:100%">Map > controls:

    >
      >
    • Reference map >
        >
      • > >
        >
        > >
        > width="120" border="1">
        >
      • >
      >
    • >
    >
      >
    • Browse >
        >
      • Zoom In
      • >
      • Zoom > Out
      • >
      • Center > map
      • >
      • style="vertical-align: middle;">Zoom extents
      • >
      •  Zoom > factor >
          >
        • onclick="ms.zoomsize=1.071;">Low
        • >
        • onclick="ms.zoomsize=2;" checked>Normal
        • >
        • type="radio" name="zf" onclick=" ms.zoomsize=3.5;">High
        • >
        >
      • >
      >
    • Query >
        >

        Choose an Action:
        >

      • checked> Browse map
      • >
      • > Query feature
      • >
      • > Query multiple features
      • > >
      • Search
      • > >
        > name="qstring1" value="">    > name="qstring2" value=""> >
        > > > >
        >
      >
    • >
    > >
      >
    • Resize Window > >
    • >
    > > > >
    > >

    style="color:#00ee00;margin-left:6;margin-bottom:6;line-height:100%">Layer > controls:

    >
      > >
    • Geography class="count"> >
        >
      • Cities
      • >
      • Coast
      • >
      • Geology
      • >
      >
    • >
    • Weather >
        >
      • Rain Contoors
      • >
      • Temp Contoors
      • > > >
      >
    • >
    • Infrastructure class="count"> >
        >
      • Roads
      • >
      >
    • > >
    • Grid class="count"> >
        >
      • 5 deg gridlines
      • >
      • onclick=" ms.togglelayers(this)" id="count-grid"> 1 deg gridlines
      • >
      >
    • > > >
    > > > > > > >
    > >
    > > >

    Legend:
    > > > > > > >


    > > > >
    > > >
    > > > >
    > >
    >
    > >


    > > > >

    > > back to start

    > > > > > ------------------------------------------------------------------------------------------------------------------------------------------------------------------ > > > > > > > > > > > > > > > > > > > > > On 7/17/07, Rodrigo Mart?n L?PEZ GREGORIO wrote: > > > > Hi Satish > > > > try this: > > > > > width="600" onMouseOver="mousemove_handler(name, x, y)"> > > > > I use the MouseOver event instead MouseMove. > > > > about the loading image what you must do is something like this: > > > > First add an element on your page, give it a name and the same id, > > and preferable position it absolutelly on your page. Also give it a z-index > > value so it will be over other elements(i.e. the map). And finally a > > "display:none;" in the style will make it to not be showed by default... > > something like: > > > > > style="position: absolute; display:none; left:480px; top:360px;width: > > 120px; height: 30px; z-index: 50; > > > > > then when you are going to retrieve the new map image (in some place > > inside the javascript function of jBox that gets the new image) you must > > change the display property of your loading image so it will be visible: > > > > document.getElementById('loadingimage').style.display = ''; > > > > and if there is a jBox function that handles the onload of the image > > element you must add the next code to that function. > > > > document.getElementById ('loadingimage').style.display = 'none'; > > > > if there is no jBox function that handles the onload event of your > > image, what you can do is put that code inside the onLoad event of the map > > element, like: > > > > > width="600" onMouseOver="mousemove_handler(name, x, y)" onLoad=" > > document.getElementById('loadingimage').style.display = 'none';"> > > > > I hope you understand what I'm talking about but ask me again if you > > can't get it working. > > > > Rodrigo. > > > > On 7/17/07, SATish In Athens +30 6947758275 < satsuman at gmail.com> wrote: > > > > > > I have tried with dBox.. > > > > > > > > > I put this in head.. > > > > > > function mousemove_handler(name, x, y) { > > > document.getElementById('coordinates').value = " x= " + > > > Math.round(Number( ms.extent[0] + x* ms.cellsize)) + " and y= " + > > > Math.round(Number(ms.extent[3] - y*ms.cellsize)); > > > } > > > > > > > > > > > > and this in body.. > > > > > > > > width="600" onMouseMove= "mousemove_handler(name, x, y)" > > > onMouseOver="isCursorOver=true" onMouseOut="isCursorOver=false"> > > > > > > > > > But I am getting the co-ordinates value in co-ordinates box only when > > > i click on the image... > > > But, it should come as soon as I move my cursor on the image. > > > I tried with installing a separate jBox but i dint get the image so i > > > left.. :) > > > Now, what to do? > > > > > > > > > Well, and I am not able to configure things with my "waiting > > > graphics".. Can some one explain that please.. > > > > > > regards > > > Satish > > > > > > > > > > > > > > > > > > > > > > > > On 7/17/07, Luis Trevi?o wrote: > > > > > > > > you could try jBox. it's an applet that does what you want. Take a > > > > look at http://mapserver.gis.umn.edu/docs/howto/jbox > > > > > > > > cheers, > > > > Luis > > > > > > > > > > > > 2007/7/16, SATish In Athens +30 6947758275 : > > > > > > > > > > Hello all.. > > > > > When i take my mouse on the image , i want to display the image > > > > > co-ordinates (in Kilometers or miles) and it should change as the cursor > > > > > changes its position.. > > > > > secondly, i want to display one graphics image for "Please Wait , > > > > > map is loading" whenever map is refreshed.. > > > > > I do not know how to implement these features.. > > > > > your concern will be heavily appreciated.. > > > > > > > > > > > > > > > > > > > > > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rwburgholzer at DEQ.VIRGINIA.GOV Wed Jul 18 05:22:03 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Wed, 18 Jul 2007 08:22:03 -0400 Subject: 3D rotation and graphics Message-ID: I hope this isn't too far afield, but I was requested to produce a map rotated into the 3rd dimension, with some 3D pie charts on it. ArcFoo is supposed to be able to do this, but when I ran into trouble I got this response from the folks at ESRI: > This is a known limit. Chart symbology is not able to work under the current software architecture. > Workaround : > Chart symbology can not be used in ArcScene at this time. Anyhow, I was wondering if this was something that anyone has fiddled with using the OS tools such as Mapserver or other. Thanks, r.b. Robert W. Burgholzer Surface Water Modeler Office of Water Supply and Planning Virginia Department of Environmental Quality rwburgholzer at deq.virginia.gov 804-698-4405 Open Source Modeling Tools: http://sourceforge.net/projects/npsource/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From Guiera at COPEL.COM Wed Jul 18 05:48:32 2007 From: Guiera at COPEL.COM (Anderson Guiera) Date: Wed, 18 Jul 2007 09:48:32 -0300 Subject: Performance problems - ORACLE and OGR VRT? Message-ID: Hi list. I'm using an ovf file to build an layer with oracle non-spatial data as folow: ODBC:user/pass at odbcconnection empresa_geradora_residuo NUM_SEQ_EGR wkbPoint WGS84 in the map file i did this: LAYER NAME "residuos" TYPE point CONNECTIONTYPE ogr CONNECTION "residuos/residuos.ovf" DATA "residuos" CLASS NAME "Residuos" STYLE COLOR 0 128 128 SYMBOL "Ponto4px" END #style END #class HEADER residuos_header.xml TEMPLATE residuos_template.xml FOOTER residuos_footer.xml TOLERANCE 3 TOLERANCEUNITS pixels END #layer It's works but the response time is almost 40 seconds. In the database i have almost 7600 records. This performance is normal or not? if isn't, what i must to do to improve this perform? I'll appreciate your help. Best regards, Anderson J. Azambuja Guiera Analista de Sistemas COPEL - Companhia Paranaense de Energia S/A DGC/STI/DGEP/VSGT Tel: (55) 41 3331-3916 e-mail: guiera at copel.com From trondmm-mapserver at CRUSADERS.NO Wed Jul 18 05:55:28 2007 From: trondmm-mapserver at CRUSADERS.NO (Trond Michelsen) Date: Wed, 18 Jul 2007 14:55:28 +0200 Subject: Reprojection issues Message-ID: Hi. I have a set of shapefiles in epsg:4326 projection, that I want to display in a mercator projection. But, when I reproject the shapefiles (either by letting mapserver reproject on the fly, or by using shpproj first), I end up with some very ugly stripes on the map. There's an example here: http://wms2.oslo.dnmi.no/collins/demo_mercator.html http://wms2.oslo.dnmi.no/collins/demo_latlon.html Does anyone what causes this, and how I can avoid it? -- Trond Michelsen From j.l.h.hartmann at UVA.NL Wed Jul 18 11:00:22 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Wed, 18 Jul 2007 20:00:22 +0200 Subject: Changing Map Projection Dynamically In-Reply-To: <4697BA93.5157.008F.0@dnr.state.mn.us> Message-ID: Is it possible to put this explanation of MINTEMPLATE into the documentation. At the moment it has only MINTEMPLATE Template to be used if above the minimum scale for the app, useful for nesting apps. This is so oracular (and slightly ungrammatical), that I can understand why nobody uses it Steve Lime wrote: > It is an interesting problem. MapServer templates do allow you access to the bbox for an map > in both lat/lon and the projection of choice. If you are willing to live with a bit of slop you could > change projections on the client and use the lat/lon bbox as an intermediate value. > > I would be tempted to change projections after a user submits a request (e.g. onSubmit). You > have the scale value of the current map, you also have the current extent and the requested > zoom value. You could with just a little bit of javascript determine a rough new scale by multiplying > the old scale by the zoom factor and then change the projection (e.g. map_projection accordingly) > and use the lat/lon bbox. It wouldn't be exact but would work I think. > > MapServer also has a little known feature called scale dependent templates. They were added > for a purpose like this but I've never used them. Basically in the webObj you can set MINTEMPLATE > and MAXTEMPLATE and when you hit the MINSCALE or MAXSCALE values those templates are > used if defined. The can be HTML templates or URL templates. So for example, you could have an > application where you zoom in to a point and then hand off to another application. The lat/lon > values become the bridge. > > So for example, you might have separate mapfiles for each projection. They could use the same > guts: > > MAP > NAME 'scale1000to10000' > ... > PROJECTION > ... > END > > WEB > MINSCALE 1000 > MAXSCALE 10000 > MINTEMPLATE 'http://mapserver.mydomain.com?map=scale0to1000.map&mapext=[mapext_latlon]&[layers]' > MAXTEMPLATE 'http://mapserver.mydomain.com?map=scale10000to100000.map&mapext=[mapext_latlon]&[layers]' > ... > END > > INCLUDE 'layers.map' > END > > MAP > NAME 'scale0to1000' > ... > PROJECTION > ... > END > > WEB > MAXSCALE 1000 > MAXTEMPLATE 'http://mapserver.mydomain.com?map=scale1000to10000.map&mapext=[mapext_latlon]&[layers]' > ... > END > > INCLUDE 'layers.map' > END > > > and so on... > > Then you'd move between the applications as the scale changed, or at least that was the idea. This handles the in/out > issue but not the east/west issue. Now, off course the min/max template could trigger a query that might, for example, > set the write state plane or UTM zone and the query result fires off the right URL with the right projection, the layer list > and so on. That would be all server based... > > Steve > >>>> On 7/12/2007 at 10:02 PM, in message > , Richard Greenwood > wrote: >> On 7/12/07, Frank Warmerdam wrote: >>> Bill Thoen wrote: >>>> This has probably been asked before, but I can't find any info on it. >>>> Basically, I'd like to know how to change the map projection in >>>> MapServer as I zoom in to a larger scale map view. Specifically, I start >>>> at a national scale using a Lambert projection, but when I zoom into a >>>> state scale, I'd like to choose a more appropriate projection (like >>>> State Plane). >>>> >>>> Can this be done easily with a map file or an HTML template? What's the >>>> best way to solve this problem? >>> Bill, >>> >>> I likely shouldn't speak up since I don't really know the best way to do >>> this. But I do not believe it can be done entirely from the server side >>> with mapserv cgi and a map file. Either you would have to have a mapscript >>> application on the server that decided at some point to switch projections >>> or you would have to engineer all the logic on the client side. >>> >>> With WMS you can request specific projections using the SRS (or CRS?) >>> item in the request. With the non-OGC "classic" mapserver interface >>> there is also a way of overriding the map projection which I think has >>> been recently discussed on this list though I don't know the exact >>> details. >>> >>> But one important thing to remember is that the region requested is going >>> to have to match the projection which means there has to be quite a bit >>> of smarts either in the client (to change the coordinate system of the BBOX) >>> or in a mapscript script on the server to reproject the requested box into >>> the alternate projection. And in that case the returned window won't >>> be exactly what was requested. >>> >>> 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 | President OSGeo, http://osgeo.org >>> >> Bill, >> >> You have a pretty interesting problem. Frank summarized the challenges >> that you may encounter . If you decide to do it on the client side, >> there is a JavaScript port of some of the Proj.4 code at: >> http://svn.codehaus.org/mapbuilder/cscs/trunk/cscs/ >> that might be useful. I am particularly interested determining an >> appropriate coordinate system based on location. >> >> Please keep us posted. >> Rich > From fantognini at GMAIL.COM Wed Jul 18 12:15:00 2007 From: fantognini at GMAIL.COM (Francesco Antognini) Date: Wed, 18 Jul 2007 21:15:00 +0200 Subject: Setting attributes of shapes on php-mapscript In-Reply-To: <469CE336.3050802@mapgears.com> Message-ID: As a follow up: On 7/17/07, Daniel Morissette wrote: > I think the first step would be to file a enhancement ticket in Trac > listing the missing methods. It may be too late to get that in 5.0 since > the feature freeze is this coming Monday and our plates are already > full, but ya never know, if you provide a good enough use case then > someone might be able to get that in. > > Daniel I posted an enhancement request in Trac. Let's hope I was convincing enough :-) On 7/17/07, Burgholzer,Robert wrote: > Francesco, > This may not be what you are looking for, or it may be stating the > obvious, but why not create your shapes in a PostGIS table? Then you > could manipulate them quite easily via SQL calls? Interesting idea since PostGis supports temporary tables. However I'm not sure Mapserver could reuse the same session/transaction initiated by php (to access the temp shape table). -- Francesco Antognini Computer Consultant Switzerland fantognini at gmail.com From Brent.Lund at STATE.MN.US Wed Jul 18 12:19:50 2007 From: Brent.Lund at STATE.MN.US (Brent Lund) Date: Wed, 18 Jul 2007 14:19:50 -0500 Subject: HTML legend (Premature end of script headers) Message-ID: I am able to render a HTML legend with MapServer 4.6.2 but with MapServer 4.10 (and 4.10.2) the legend is not created. The message in my error log is "Premature end of script headers". Any ideas? Thanks, Brent -------------- next part -------------- An HTML attachment was scrubbed... URL: From bthoen at GISNET.COM Wed Jul 18 14:46:32 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Wed, 18 Jul 2007 15:46:32 -0600 Subject: Tool Buttons with PHP Mapscript Message-ID: Are there any examples of creating a tool button interface based on PHP Mapscript? If this is possible, I'd like to see a simple example that implements a box-drawing Zoom In tool. Or is this too much for PHP? My other option would be to try and figure out how this is done in MapSurfer using JavaScript, but I know that route will take me a while to learn. I'm hoping there may be something simple out there that doesn't require mastery of two or more new languages. TIA, - Bill Thoen From bradleym06 at GMAIL.COM Wed Jul 18 16:29:18 2007 From: bradleym06 at GMAIL.COM (Bradley Mclain) Date: Thu, 19 Jul 2007 09:29:18 +1000 Subject: Information/Advice about placing markers Message-ID: Ok what I want to do is place a series of markers on different farm blocks and properties, I currently have a Webserver using OpenLayers to import Google Maps and my own custom Mapserver WMS data. I am looking for any advice hints and tips on how to go about all of this. I have a list of all the info I need about the different farm blocks, names of growers, variety of produce etc and I would like to place a marker so that when you hover over it it displays this data. (Also a potential future feature would be a full outline of the property but this is probably a while off. Currently all I have is markers being placed on the specific locations with no pop-up info or anything. I don't want to cram my html file full of this info and would prefer if I could import from some sort of a database or text file. (Preferably textfile in the short term for testing but eventually a database would be ideal). Cheers Brad -------------- next part -------------- An HTML attachment was scrubbed... URL: From gregor at HOSTGIS.COM Wed Jul 18 17:02:37 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Wed, 18 Jul 2007 18:02:37 -0600 Subject: Information/Advice about placing markers In-Reply-To: Message-ID: All of what you're asking here sounds to me like OL questions, rather than Mapserver. You may have better fortune asking there. Fortunately, I've dabbled in OL a bit, so I'll go a little off-topic for ya. :) > I have a list of all the info I need about the different farm blocks, > names of growers, variety of produce etc and I would like to place a > marker so that when you hover over it it displays this data. Using OL's mechanisms, I'd do something along these lines: Set up the OL map to do click-queries via WFS's getfeatureinfo. See http://world.freemap.in/ You'll have to set up your mapfile to act as a WFS server, which is very simple following the WFS Server howto on the Mapserver documentation site. Since you want it to click the map on a hover instead of a click, I'd probably throw together a combination of JavaScript setTimeout(), and extending the map's mouse movement handlers so they the timer is reset whenever the mouse moves, and is started when the movement ends. > Currently all I have is markers being placed on the specific locations > with no pop-up info or anything. I don't want to cram my html file full > of this info and would prefer if I could import from some sort of a > database or text file. (Preferably textfile in the short term for > testing but eventually a database would be ideal). If you use WFS, the data comes from the same data source you're already using, saving you the trouble of duplicating it, or writing a database app to fetch a single feature and generate XML for it, etc. Hooray for OGC standards and to Mapserver for making them easy. As far as popups go, I think that only RSS layers support that in OL, and that's probably not at all what you want. Mapserver itself doesn't do anything of the sort, unless you count labels with a colored background. Then again, if you're creative, your WFS-query click-handler could probably populate a HTML div like in the example at the URL I gave, and position the div at the mouse's current location; it'd be some work, but probably nothing too arduous if you're handy with JS and HTML. I hope that helps. Aside from setting up your mapfile to be a WFS server, I suspect that most of your work will be in OL or in general JavaScript. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From hindemit at TISCALI.IT Thu Jul 19 00:34:50 2007 From: hindemit at TISCALI.IT (Antonio) Date: Thu, 19 Jul 2007 09:34:50 +0200 Subject: newbie and cmap Message-ID: hi all, I'm an italian developer at the first post on this ml ... now the question ;-))) i'm trying to implement a mapserver to catch the gps signal from some boat and reproduce their movement on the map ... I'm using postgis+linux/freebsd with python mapscript ... the problem is that I can't find a detailed naval map of the italian harbour I need ! a society offer me a map, but it's in c-map format ... is there a way to use the map as RASTER for the map ? o better, can I convert the cmap into a shapefile ? where can I found detailed map of the Italian harbour ? thank in advance ... -- #include int main(void){char c[]={10,65,110,116,111,110,105,111,32,98,97,114,98,111,110, 101,32,60,104,105,110,100,101,109,105,116,64,116,105,115,99,97,108,105,110,101, 116,46,105,116,62,10,10,0};printf("%s",c);return 0;} From shoaib at NOMAD-LABS.COM Thu Jul 19 00:44:46 2007 From: shoaib at NOMAD-LABS.COM (Shoaib Burq) Date: Thu, 19 Jul 2007 17:44:46 +1000 Subject: Geospatial @ RailsConf Europe 2007 Message-ID: Folks, Sorry about the cross post, but a quick announcement: I have finally gotten around to collating some of the ideas Andrew, Guilhem, Mikel and Kashif had discussed at the last FOSS4G'06 into a Ruby/Rails mapping tutorial. This has lead to Kashif and I giving a tute at the RailsConf Europe 07 titled "Rails GIS Hacks". Unfortunately at this stage I might not be able to make it to FOSS4G'07 in Victoria Now for the marketing spin: http://www.railsconfeurope.com/cs/railseurope2007/view/e_sess/14212 So if you are not planning to be at FOSS4G perhaps I will see you in beautiful Berlin. Cheers, Shoaib PS. The name is obviously inspired by Howard Butler and Sean Gillies "Python GIS Hacks" from OSGIS'05 From christian.braun at TUDOR.LU Thu Jul 19 01:02:00 2007 From: christian.braun at TUDOR.LU (Christian Braun) Date: Thu, 19 Jul 2007 10:02:00 +0200 Subject: Christian Braun is out of the office. Message-ID: I will be out of the office starting 19.07.2007 and will not return until 24.07.2007. I will respond to your message when I return. From hulst at ARGOSS.NL Thu Jul 19 03:44:36 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Thu, 19 Jul 2007 12:44:36 +0200 Subject: PROCESSING "LUT=.... issue Message-ID: Dear all, I have been working on a method to display my freshly computed netCDF data through mapserver and are finally there. However, I find one last issue with the scaling / processing lut= combination. Please see the map on http://mapserver.argoss.nl. The mapserver is svn revision 6353. There is a white spot on there that should be red. See the relevant map section below: LAYER NAME "Hs" DATA "netCDF:windwave/ww3_output.nc:sign_wave_height" PROCESSING "SCALE=0,10" PROCESSING "SCALE_BUCKETS=200" PROCESSING "BANDS=1,1,1" PROCESSING "LUT_1=96:0,157:255,221:255,255:240" PROCESSING "LUT_2=29:0,93:255,157:255,221:0,255:0" PROCESSING "LUT_3=28:255,93:255,157:0,255:0" TYPE RASTER STATUS ON OFFSITE 0 0 0 END The data in this layer is in [0 13.457]. I want to scale the image to [0 10] because more details of lower waves show. What happens is that the RGB values in the area that is clipped (eg Hs > 10m) are set to 255, regardless of anything in the PROCESSING instruction. Am I overlooking something or should I report a bug (or feature ;) )? Best regards, Sander From warmerdam at POBOX.COM Thu Jul 19 09:39:38 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 19 Jul 2007 12:39:38 -0400 Subject: PROCESSING "LUT=.... issue In-Reply-To: <200707191244.37023.hulst@argoss.nl> Message-ID: A.Th.C. Hulst wrote: > Dear all, > > I have been working on a method to display my freshly computed netCDF data > through mapserver and are finally there. However, I find one last issue with > the scaling / processing lut= combination. > > Please see the map on http://mapserver.argoss.nl. The mapserver is svn > revision 6353. There is a white spot on there that should be red. See the > relevant map section below: > > LAYER > NAME "Hs" > DATA "netCDF:windwave/ww3_output.nc:sign_wave_height" > PROCESSING "SCALE=0,10" > PROCESSING "SCALE_BUCKETS=200" > PROCESSING "BANDS=1,1,1" > PROCESSING "LUT_1=96:0,157:255,221:255,255:240" > PROCESSING "LUT_2=29:0,93:255,157:255,221:0,255:0" > PROCESSING "LUT_3=28:255,93:255,157:0,255:0" > TYPE RASTER > STATUS ON > OFFSITE 0 0 0 > END > > The data in this layer is in [0 13.457]. I want to scale the image to [0 10] > because more details of lower waves show. What happens is that the RGB values > in the area that is clipped (eg Hs > 10m) are set to 255, regardless of > anything in the PROCESSING instruction. > > Am I overlooking something or should I report a bug (or feature ;) )? Sander, Do you have a sense where things are going wrong? Is it the scaling or the LUT application? I will note that the lut management code assumes that 0 maps to 0 and 255 maps to 255. So I don't think your 255:0 specifications are going to work. 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 | President OSGeo, http://osgeo.org From listario at GMAIL.COM Thu Jul 19 09:49:52 2007 From: listario at GMAIL.COM (J. Parapar) Date: Thu, 19 Jul 2007 18:49:52 +0200 Subject: HTML legend (Premature end of script headers) In-Reply-To: Message-ID: Brent: Your problem, perhaps, is the same as the one commented in http://trac.osgeo.org/mapserver/ticket/1946. nfarrell has submitted a workaround. We have not try it but could be useful for you. Best regards, Jorge 2007/7/18, Brent Lund : > > > I am able to render a HTML legend with MapServer 4.6.2 but with MapServer > 4.10 (and 4.10.2) the legend is not created. The message in my error log > is "Premature end of script headers". > > Any ideas? > > > > Thanks, > > > > Brent From bob.b at GRITECHNOLOGIES.COM Thu Jul 19 10:06:43 2007 From: bob.b at GRITECHNOLOGIES.COM (Bob Basques) Date: Thu, 19 Jul 2007 12:06:43 -0500 Subject: dataset extents from MapServer CGI Message-ID: All, Is there any way to get a dataset extents from MapServer CGI directly (no Mapscript)? Thanks bobb From patrice.canonici at GMAIL.COM Thu Jul 19 11:11:49 2007 From: patrice.canonici at GMAIL.COM (patrice canonici) Date: Thu, 19 Jul 2007 20:11:49 +0200 Subject: Get Image by url in database Message-ID: Hi all fist, know that It is my first message on this list and I'm working for the first time with MapServer. I'm trying to configure WMS MapServer. I'm using a PostGIS database to store polygon, called datastrip. For each datastrip I have an image, the path to the image is store into an other table (image). an image entry refer a datastrip. I successfully write the mapfile to get datastrip. But now, I would like to get image for datastrip. I tryed the following bloc into the mapfile, but it doesn't work : LAYER NAME "image" CONNECTIONTYPE postgis CONNECTION "user=testeur dbname=pocdb host=localhost" TYPE RASTER DATA "imagename from (SELECT i.folder_url || '\' || i.filename as imagename from datastrip d, image i WHERE d.datastrip_id=i.datastrip_id)" END it seams that the meaning to get the data information (i.e. db connection) is not take n into account. the return message is something like "unable to acces file imagename from (SELECT i.folder_url || '\' || i.filename as imagename from datastrip d, image i WHERE d.datastrip_id=i.datastrip_id)" I set the SHAPEPATH attribute, to complete the image path (the path into db is relative to the SHAPEPATH value) I try to replace DATA value by "foo.gif", and it works. Is there a way to get the image url from my db ? without catch the request, get the BBOX, make an interest with it and the datastrip table and finally get image for each datastrip on this BBOX, write on the fly a mapfile ..etc ... thanks Patrice From patrice.canonici at GMAIL.COM Thu Jul 19 11:55:38 2007 From: patrice.canonici at GMAIL.COM (Patrice Canonici) Date: Thu, 19 Jul 2007 13:55:38 -0500 Subject: Get Image by url in database Message-ID: Hi all fist, know that It is my first message on this list and I'm working for the first time with MapServer. I'm trying to configure WMS MapServer. I'm using a PostGIS database to store polygon, called datastrip. For each datastrip I have an image, the path to the image is store into an other table (image). an image entry refer a datastrip. I successfully write the mapfile to get datastrip. But now, I would like to get image for datastrip. I tryed the following bloc into the mapfile, but it doesn't work : LAYER NAME "image" CONNECTIONTYPE postgis CONNECTION "user=testeur dbname=pocdb host=localhost" TYPE RASTER DATA "imagename from (SELECT i.folder_url || '\' || i.filename as imagename from datastrip d, image i WHERE d.datastrip_id=i.datastrip_id)" END it seams that the meaning to get the data information (i.e. db connection) is not take n into account. the return message is something like "unable to acces file imagename from (SELECT i.folder_url || '\' || i.filename as imagename from datastrip d, image i WHERE d.datastrip_id=i.datastrip_id)" I set the SHAPEPATH attribute, to complete the image path (the path into db is relative to the SHAPEPATH value) I try to replace DATA value by "foo.gif", and it works. Is there a way to get the image url from my db ? without catch the request, get the BBOX, make an interest with it and the datastrip table and finally get image for each datastrip on this BBOX, write on the fly a mapfile ..etc ... thanks Patrice From patrice.canonici at GMAIL.COM Thu Jul 19 11:57:10 2007 From: patrice.canonici at GMAIL.COM (patrice canonici) Date: Thu, 19 Jul 2007 20:57:10 +0200 Subject: Get Image by url in database In-Reply-To: Message-ID: sorry, t post, 2 times, Ididn't see it was sorted by subject ... 2007/7/19, Patrice Canonici : > Hi all > > fist, know that It is my first message on this list and I'm working > for the first time with MapServer. > > I'm trying to configure WMS MapServer. I'm using a PostGIS database to > store polygon, called datastrip. For each datastrip I have an image, > the path to the image is store into an other table (image). > an image entry refer a datastrip. > > I successfully write the mapfile to get datastrip. But now, I would > like to get image for datastrip. > > I tryed the following bloc into the mapfile, but it doesn't work : > > LAYER > NAME "image" > CONNECTIONTYPE postgis > CONNECTION "user=testeur dbname=pocdb host=localhost" > TYPE RASTER > DATA "imagename from (SELECT i.folder_url || '\' || i.filename as > imagename from datastrip d, image i WHERE > d.datastrip_id=i.datastrip_id)" > END > > it seams that the meaning to get the data information (i.e. db > connection) is not take n into account. the return message is > something like "unable to acces file imagename from (SELECT > i.folder_url || '\' || i.filename as imagename from datastrip d, image > i WHERE d.datastrip_id=i.datastrip_id)" > > I set the SHAPEPATH attribute, to complete the image path (the path > into db is relative to the SHAPEPATH value) > > I try to replace DATA value by "foo.gif", and it works. > > Is there a way to get the image url from my db ? without catch the > request, get the BBOX, make an interest with it and the datastrip > table and finally get image for each datastrip on this BBOX, write on > the fly a mapfile ..etc ... > > thanks > Patrice > > From j.l.h.hartmann at UVA.NL Thu Jul 19 12:04:18 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Thu, 19 Jul 2007 21:04:18 +0200 Subject: dataset extents from MapServer CGI In-Reply-To: <469F9A23.1010603@gritechnologies.com> Message-ID: I second that question. If not, could it be implemented? Very useful feature Jan Bob Basques wrote: > All, > > Is there any way to get a dataset extents from MapServer CGI directly > (no Mapscript)? > > Thanks > > bobb > From warmerdam at POBOX.COM Thu Jul 19 12:20:39 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 19 Jul 2007 15:20:39 -0400 Subject: dataset extents from MapServer CGI In-Reply-To: <469FB5B2.9030504@uva.nl> Message-ID: Jan Hartmann wrote: > I second that question. If not, could it be implemented? Very useful > feature > > Jan > > Bob Basques wrote: >> All, >> >> Is there any way to get a dataset extents from MapServer CGI directly >> (no Mapscript)? Jan / Bob, How would you see this working? Would it be a request made against a particular layer? Against the map as a whole? Internally in the code we have: int msLayerGetExtent(layerObj *layer, rectObj *extent) which calls the data source specific GetExtent function. But I don't think this works for raster layers. There is also msOWSGetLayerExtent() which first consults the layer metadata for extents. Perhaps this would be the logical place to look? Well, I suppose the other side of this is that for WMS and WCS the layer and coverage descriptions include extents already. Is that sufficient for your needs? 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 | President OSGeo, http://osgeo.org From hulst at ARGOSS.NL Thu Jul 19 12:20:27 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Thu, 19 Jul 2007 21:20:27 +0200 Subject: PROCESSING "LUT=.... issue In-Reply-To: <469F93CA.3040500@pobox.com> Message-ID: Frank, On Thursday 19 July 2007 18:39:38 Frank Warmerdam wrote: > Do you have a sense where things are going wrong? ?Is it the scaling or > the LUT application? I think the problem lies in the LUT application. When all 3 bands end with 255:255 then you really say that the highest value is always white. When you apply a max scaling then the area with the maximum value is larger and more apparent. > > I will note that the lut management code assumes that 0 maps to 0 and > 255 maps to 255. ?So I don't think your 255:0 specifications are > going to work. If I don't put the 255:0 there then there's an interpolation between the last pair (157:0) and 255:255 which is undesirable. By putting the 255:0 there I prevent the code from interpolating "back up". My last pair should formally be 254:0 which then is appended with 255:255. All in all I don't think that automatic catenation of pairs is a good idea because min and max values are fixed to black and white repectively. Best regards, Sander From Brent.Lund at STATE.MN.US Thu Jul 19 13:34:35 2007 From: Brent.Lund at STATE.MN.US (Brent Lund) Date: Thu, 19 Jul 2007 15:34:35 -0500 Subject: HTML legend (Premature end of script headers) In-Reply-To: <4ac992660707190949k54be1277o6698e6b41d236e60@mail.gmail.com> Message-ID: Thanks, I'll give it a try. bl -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at lists.umn.edu] On Behalf Of J. Parapar Sent: Thursday, July 19, 2007 11:50 AM To: MAPSERVER-USERS at lists.umn.edu Subject: Re: [UMN_MAPSERVER-USERS] HTML legend (Premature end of script headers) Brent: Your problem, perhaps, is the same as the one commented in http://trac.osgeo.org/mapserver/ticket/1946. nfarrell has submitted a workaround. We have not try it but could be useful for you. Best regards, Jorge 2007/7/18, Brent Lund : > > > I am able to render a HTML legend with MapServer 4.6.2 but with MapServer > 4.10 (and 4.10.2) the legend is not created. The message in my error log > is "Premature end of script headers". > > Any ideas? > > > > Thanks, > > > > Brent From j.l.h.hartmann at UVA.NL Thu Jul 19 13:55:59 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Thu, 19 Jul 2007 22:55:59 +0200 Subject: dataset extents from MapServer CGI In-Reply-To: <469FB987.6070004@pobox.com> Message-ID: Frank, For my part, I would at least like to be able to get the map extent, but I don't think implementing an extent query for separate layers would be much more difficult to program. You are right that WMS and WCS will give back the extent via a GetCapabilities request, but that is exactly the thing that I would like to do with native MapServer. I just want to be able, before I request the actual map, to get its extents via a separate call. AFAICS the problem is not so much implementing this functionality (it's already there for WMS and friends), but to agree how to send back the results (XML, GeoJSON, etc) Jan Frank Warmerdam wrote: > Jan Hartmann wrote: >> I second that question. If not, could it be implemented? Very useful >> feature >> >> Jan >> >> Bob Basques wrote: >>> All, >>> >>> Is there any way to get a dataset extents from MapServer CGI directly >>> (no Mapscript)? > > Jan / Bob, > > How would you see this working? Would it be a request made against a > particular layer? Against the map as a whole? Internally in the code we > have: > > int msLayerGetExtent(layerObj *layer, rectObj *extent) > > which calls the data source specific GetExtent function. But I don't think > this works for raster layers. There is also msOWSGetLayerExtent() which > first consults the layer metadata for extents. Perhaps this would be the > logical place to look? > > Well, I suppose the other side of this is that for WMS and WCS the layer > and coverage descriptions include extents already. Is that sufficient for > your needs? > > Best regards, From jayzee.smith at GMAIL.COM Thu Jul 19 14:53:23 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Thu, 19 Jul 2007 17:53:23 -0400 Subject: layer type annotation ...label?? Message-ID: guys, racked my brains on what may be a simple problem- trying to add some copyright info like so: LAYER NAME "copyright" GROUP "metadata" STATUS on TYPE annotation FEATURE POINTS 30 30 # position of text in image pixel coordinates END TEXT "2007" END CLASS LABEL TYPE bitmap COLOR 0 0 0 POSITION auto END END END # layer what gives?? jzs From jayzee.smith at GMAIL.COM Thu Jul 19 15:26:46 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Thu, 19 Jul 2007 18:26:46 -0400 Subject: layer type annotation ...label?? In-Reply-To: Message-ID: if i just leave the annotation layer shown below in the map file, this is what gives? msDrawLegend(): GD library error. Unable to initialize image. msImageCreateGD(): Image handling error. Cannot create GD image of size 40 x 0. but why?? i can label shape layers fine, just not annotation layers?? jzs On 7/19/07, John Smith wrote: > guys, > racked my brains on what may be a simple problem- trying to add some > copyright info like so: > > LAYER > NAME "copyright" > GROUP "metadata" > STATUS on > TYPE annotation > FEATURE > POINTS > 30 30 # position of text in image pixel coordinates > END > TEXT "2007" > END > CLASS > LABEL > TYPE bitmap > COLOR 0 0 0 > POSITION auto > END > END > END # layer > > what gives?? > jzs > From rjames57 at YAHOO.COM Thu Jul 19 15:42:21 2007 From: rjames57 at YAHOO.COM (Randy James) Date: Thu, 19 Jul 2007 15:42:21 -0700 Subject: layer type annotation ...label?? In-Reply-To: Message-ID: Try this LAYER NAME "copyright" GROUP "metadata" STATUS on TYPE annotation FEATURE POINTS 30 30 # position of text in image pixel coordinates TEXT "2007" END CLASS LABEL TYPE bitmap COLOR 0 0 0 POSITION auto END END END # layer John Smith wrote: guys, racked my brains on what may be a simple problem- trying to add some copyright info like so: LAYER NAME "copyright" GROUP "metadata" STATUS on TYPE annotation FEATURE POINTS 30 30 # position of text in image pixel coordinates END TEXT "2007" END CLASS LABEL TYPE bitmap COLOR 0 0 0 POSITION auto END END END # layer what gives?? jzs --------------------------------- Building a website is a piece of cake. Yahoo! Small Business gives you all the tools to get online. -------------- next part -------------- An HTML attachment was scrubbed... URL: From David.Hunter at FNF.COM Thu Jul 19 16:18:51 2007 From: David.Hunter at FNF.COM (Hunter, David - St. Louis Park, MN) Date: Thu, 19 Jul 2007 18:18:51 -0500 Subject: layer derived from another? Message-ID: I would like to display a state map that has a sector layer. The sectors are defined by ZIP codes: the Thief River Falls sector consists of one list of ZIPs, the International Falls sector consists of another list of ZIPs, etc. Given a ZIP code dataset, could I define these sectors in a layer in a map file using the lists of ZIP codes? David S. Hunter Sr. Software Engineer Fidelity National Geographic Solutions division of Fidelity National Financial 5353 Gamble Drive, Suite 201 St. Louis Park, MN 55416 * Email: david.hunter at fnf.com ' Phone: 952.542.1440 ext. 256 * Fax: 952.542.3859 -------------- next part -------------- An HTML attachment was scrubbed... URL: From bob.b at GRITECHNOLOGIES.COM Thu Jul 19 16:39:47 2007 From: bob.b at GRITECHNOLOGIES.COM (Bob Basques) Date: Thu, 19 Jul 2007 18:39:47 -0500 Subject: dataset extents from MapServer CGI In-Reply-To: <469FB987.6070004@pobox.com> Message-ID: Frank, My preference is to provide a layer list (one or few layers in my use case) and get the extents of all the layers in the list. Either seperately or as a composite extent. A XML output would be good for example, but not required. I could build a wrapper to do a composite from an individual list if a composited version is too much overhead. My use case: My Client application deals with layers on an individual basis with separate calls, etc.: * I would like to have a displayable layer (user controlled) in my client application that shows the extent of a particular layer. * This same capability allows me to gray out a layer that is turned on, but not visible in a current View. * This would also allow me to filter for layers that are out of bounds and not request them automatically (as I do now) and and up displaying a blank image. A definite performance enhancement I think. * An addidtional feature I would like to add to my client is a Reference image/map, that shows the layer extents. This would be used as a thumbnail in a layer metadata lookup/popup. Some WishList things (not really expected near term): * Using a bounding polygon vs a rectangle. * Feature counting (We've been over this feature with Steve L a couple of times), basically a method of counting features in a layer. o Further enhancement, would be to be able to count the features inside of a mapext. * Adding in Layer (data source) feature lists (metadata kinds o f things that could be derived by MapServer, either by examining the data or the file/db that contains it. o Date of sourced data (last update in a DB environment) o TYPE (Raster, Line, Polyline, Polygon, etc.) -------------- Some possible thoughts/solutions I had on the subject: * Set up some commandline utility that can generate the extents from a layer(shpfile) list as a new layer specifically related to Spatial metadata (actually this idea has a bunch more too it, that goes beyond this topic). This new layer could be queried for all the appropriate info, it would also allow for adding in some additional link mechanisms that would be layer based. * Use the previous setup to build this type of data layer by default as a setup feature of MapServer. Again there are some other things here that could obviously be added to an indexing system like this. Possible use some sort of MapServer Configuration step periodically to keep the extents layer up to date. * Don't know if/when I would be able to get to it, but I would build this in PERL/MapScript myself if it's not plausible to include in MapServer. bobb Frank Warmerdam wrote: > Jan Hartmann wrote: >> I second that question. If not, could it be implemented? Very useful >> feature >> >> Jan >> >> Bob Basques wrote: >>> All, >>> >>> Is there any way to get a dataset extents from MapServer CGI >>> directly (no Mapscript)? > > Jan / Bob, > > How would you see this working? Would it be a request made against a > particular layer? Against the map as a whole? Internally in the code we > have: > > int msLayerGetExtent(layerObj *layer, rectObj *extent) > > which calls the data source specific GetExtent function. But I don't > think > this works for raster layers. There is also msOWSGetLayerExtent() which > first consults the layer metadata for extents. Perhaps this would be the > logical place to look? > > Well, I suppose the other side of this is that for WMS and WCS the layer > and coverage descriptions include extents already. Is that sufficient > for > your needs? > > Best regards, -------------- next part -------------- An HTML attachment was scrubbed... URL: From hal at MOBILEGEOGRAPHICS.COM Thu Jul 19 17:59:16 2007 From: hal at MOBILEGEOGRAPHICS.COM (Hal Mueller) Date: Thu, 19 Jul 2007 17:59:16 -0700 Subject: 3D rotation and graphics In-Reply-To: <6C097DA58429B743A67070F98BE73A37025DD639@deqex01.deq.local> Message-ID: I think you would be able to do this with Quartz Composer. Generate your map as an image in a supported format, and then you can render it onto a horizontal surface ("billboard", in Quartz Composer terminology) with the pie charts floating above the appropriate locations. You can change your viewpoint/rotation once the objects are in place. Quartz Composer is installed as part of the Apple developer tools, which are free and included on the system disk, but which are not loaded onto your machine by default. http://developer.apple.com/graphicsimaging/quartz/quartzcomposer.html http://developer.apple.com/documentation/GraphicsImaging/Conceptual/QuartzComposer/qc_intro/chapter_1_section_1.html -- Hal Mueller hal at mobilegeographics.com My Treo beat up your iPhone. From hal at MOBILEGEOGRAPHICS.COM Thu Jul 19 18:05:04 2007 From: hal at MOBILEGEOGRAPHICS.COM (Hal Mueller) Date: Thu, 19 Jul 2007 18:05:04 -0700 Subject: newbie and cmap In-Reply-To: <20070719073450.GA32217@antonio.scafi.home> Message-ID: http://emit.demon.co.uk/map2.php and http://sailwx.info/maps/shipplotter.phtml might get you started. These are both designed as underlay maps for AIS/ship tracking. Eventually you're going to have to come up with whatever basemap data is appropriate for the map you're producing. -- Hal Mueller hal at mobilegeographics.com My Treo beat up your iPhone. From pgiannini at BYTEWISE.IT Fri Jul 20 01:13:43 2007 From: pgiannini at BYTEWISE.IT (Pietro Giannini) Date: Fri, 20 Jul 2007 10:13:43 +0200 Subject: layer type annotation ...label?? In-Reply-To: Message-ID: ciao John, add this row to the layer: TRANSFORM false so the coordinates will not be transformed into the map's projection. for the msDrawLegend() error, please attach the entire map file ciao .......................................p -- Pietro Giannini Bytewise srl - Area GIS 41?50'38.58"N 12?29'13.39"E On Ven, Luglio 20, 2007 00:26, John Smith wrote: > if i just leave the annotation layer shown below in the map file, this > is what gives? > > msDrawLegend(): GD library error. Unable to initialize image. > msImageCreateGD(): Image handling error. Cannot create GD image of size 40 > x 0. > > but why?? > > i can label shape layers fine, just not annotation layers?? > jzs > > On 7/19/07, John Smith wrote: >> guys, >> racked my brains on what may be a simple problem- trying to add some >> copyright info like so: >> >> LAYER >> NAME "copyright" >> GROUP "metadata" >> STATUS on >> TYPE annotation >> FEATURE >> POINTS >> 30 30 # position of text in image pixel >> coordinates >> END >> TEXT "2007" >> END >> CLASS >> LABEL >> TYPE bitmap >> COLOR 0 0 0 >> POSITION auto >> END >> END >> END # layer >> >> what gives?? >> jzs >> > From rdmailings at DUIF.NET Fri Jul 20 01:59:17 2007 From: rdmailings at DUIF.NET (Richard Duivenvoorde) Date: Fri, 20 Jul 2007 10:59:17 +0200 Subject: layer type annotation ...label?? In-Reply-To: Message-ID: Hi John, I've been fiddling with annotations myself recently and was suprised by the (sometimes a little hidden) possibilities of it: - there are several types of annotation: 1) pure text 2) use an image (SYMBOL CLASS) see http://www.nabble.com/Example-of-placing-a-PNG-symbol-in-a-map.-tf1007115.html#a2610844 3) use your own font (eg truetype made from an image) and use that as copyright (much like the little google txts all over the map in GoogleMaps) - if you have varying size of maps, and still want to show your copyright always in the lower right (50,50 pixels from the corner) of your maps you can use TRANSFORM in combination with the LABEL-POSITION stuff (see: http://mapserver.gis.umn.edu/development/rfc/ms-rfc-14) Some examples: ad 1: pure text LAYER NAME txtcopyright STATUS default TYPE annotation TRANSFORM lr # we use lower right as 0,0 (lr, ll, ul, ur ...) FEATURE POINTS 0 -22 #this is the position of this point with 'lr' as 0,0 END TEXT "? my copyright" #this is your displaying text END CLASS # normal label stuff: LABEL #defines the font, colors etc. of the text FONT "arial" # as defined in your fonts.txt TYPE TRUETYPE ANTIALIAS TRUE SIZE 8 BUFFER 3 OFFSET 2 2 POSITION ul COLOR 128 128 128 FORCE TRUE PARTIALS FALSE END END END ad 2: use of an image (via SYMBOL CLASS) LAYER NAME northnarrow STATUS default TYPE annotation TRANSFORM ul # upper left corner FEATURE POINTS 90 90 #this is the position in image coordinates (pixels) END END CLASS SYMBOL "north" # this is a SYMBOL COLOR 0 0 0 LABEL MINFEATURESIZE 50 MINDISTANCE 150 SIZE TINY COLOR 0 0 0 PARTIALS FALSE FORCE TRUE END END END from mysymbols.sym file: SYMBOL NAME "north" TYPE PIXMAP IMAGE "mysymbols/north.png" END ad 3: use your own font (eg true type font made from an image) LAYER NAME logos STATUS default TYPE annotation TRANSFORM false FEATURE POINTS 150 150 # some positions in the map 150 550 150 950 350 350 350 750 550 150 550 550 550 950 750 350 750 750 950 150 950 550 950 950 END TEXT " " #this is your displaying text END CLASS LABEL #defines the font, colors etc. of the text # this is a custom truetype font build from an image # defined in fonts.txt as: "myfont myfont.ttf" FONT "myfont" TYPE TRUETYPE SIZE 48 BUFFER 2 COLOR 224 224 224 FORCE TRUE PARTIALS FALSE END END END Hope this is helpfull for somebody. Richard Duivenvoorde John Smith wrote: > if i just leave the annotation layer shown below in the map file, this > is what gives? > > msDrawLegend(): GD library error. Unable to initialize image. > msImageCreateGD(): Image handling error. Cannot create GD image of size > 40 x 0. > > but why?? > > i can label shape layers fine, just not annotation layers?? > jzs > > On 7/19/07, John Smith wrote: >> guys, >> racked my brains on what may be a simple problem- trying to add some >> copyright info like so: >> >> LAYER >> NAME "copyright" >> GROUP "metadata" >> STATUS on >> TYPE annotation >> FEATURE >> POINTS >> 30 30 # position of text in image pixel >> coordinates >> END >> TEXT "2007" >> END >> CLASS >> LABEL >> TYPE bitmap >> COLOR 0 0 0 >> POSITION auto >> END >> END >> END # layer >> >> what gives?? >> jzs >> > > From Christian.Mairamhof at KTN.GV.AT Thu Jul 19 23:40:13 2007 From: Christian.Mairamhof at KTN.GV.AT (Christian Mairamhof) Date: Fri, 20 Jul 2007 08:40:13 +0200 Subject: mapserver & ubuntu Message-ID: Hi list, We tryed to install Mapserver 4.10 on Version 4.7.11 Ubuntu with LAMP option. As you can see in config.log the compilation run without problem. By testing mapserver we get the following error-message: root at mapserver:/var/src/mapserver-4.10.0# ./mapserv -v ./mapserv: error while loading shared libraries: libiconv.so.2: cannot open shared object file: No such file or directory We guess there is a problem with libiconv even it is installed and compiled. Does anybody have an idea? Best regards, Christian & Christian _______________________________ AMT DER K?RNTNER LANDEREGIERUNG Abt. 18 - Wasserwirtschaft / IKT Ing. Christian MAIRAMHOF Mie?taler Stra?e 1 , A-9020 Klagenfurt Tel +43 (0) 463 536-31826 e-mail: christian.mairamhof at ktn.gv.at homepage: wasser.ktn.gv.at _______________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: config.log Type: application/octet-stream Size: 6773 bytes Desc: not available URL: From hulst at ARGOSS.NL Fri Jul 20 03:44:26 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Fri, 20 Jul 2007 12:44:26 +0200 Subject: mapserver & ubuntu In-Reply-To: Message-ID: > root at mapserver:/var/src/mapserver-4.10.0# ./mapserv -v > ./mapserv: error while loading shared libraries: libiconv.so.2: cannot > open shared object file: No such file or directory > > We guess there is a problem with libiconv even it is installed and > compiled. > > Does anybody have an idea? You'll probably have to add /usr/local/lib to /etc/ld.so.conf and run ldconfig. Cheers, Sander From rwburgholzer at DEQ.VIRGINIA.GOV Fri Jul 20 05:09:50 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Fri, 20 Jul 2007 08:09:50 -0400 Subject: 3D rotation and graphics Message-ID: Hal, thanks. Alas, this seems to be an exclusively Mac package. r.b. -----Original Message----- From: Hal Mueller [mailto:hal at mobilegeographics.com] Sent: Thursday, July 19, 2007 8:59 PM To: Burgholzer,Robert Cc: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: 3D rotation and graphics I think you would be able to do this with Quartz Composer. Generate your map as an image in a supported format, and then you can render it onto a horizontal surface ("billboard", in Quartz Composer terminology) with the pie charts floating above the appropriate locations. You can change your viewpoint/rotation once the objects are in place. Quartz Composer is installed as part of the Apple developer tools, which are free and included on the system disk, but which are not loaded onto your machine by default. http://developer.apple.com/graphicsimaging/quartz/quartzcomposer.html http://developer.apple.com/documentation/GraphicsImaging/Conceptual/Quar tzComposer/qc_intro/chapter_1_section_1.html -- Hal Mueller hal at mobilegeographics.com My Treo beat up your iPhone. From bthoen at GISNET.COM Fri Jul 20 07:23:43 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 20 Jul 2007 08:23:43 -0600 Subject: MapScript Syntax Message-ID: I'm trying to learn PHP Mapscript and reading through "Map Configuration with MapScript" (http://mapserver.gis.umn.edu/docs/howto/mapscript_map_config/) I'm a little confused by the syntax in the code examples. For instance, the first code line: empty_map = new mapscript.mapObj doesn't work. I get an error about the mapscript class being missing. In other places, it doesn't like the dot notation (and I thought that PHP uses an arrow -> instead anyway). I suppose the problem here is that this isn't really *PHP* mapscript, but if it's not, how do I translate this "code" into something useful? - Bill Thoen From hulst at ARGOSS.NL Fri Jul 20 07:23:14 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Fri, 20 Jul 2007 16:23:14 +0200 Subject: PROCESSING "LUT=.... issue In-Reply-To: <469F93CA.3040500@pobox.com> Message-ID: Frank, I have a fix (ugly, but it works): in mapdrawgdal.c --------------ParseDefaultLUT()------------ int user_defined=FALSE; while( !all_done ) { int this_in, this_out; int lut_i; while( isspace(*lut_read) ) lut_read++; /* if we are at end, assum 255:255 */ if( *lut_read == '\0') { all_done = TRUE; if ( !user_defined ){ // Only assume 255:255 end when user did not specify PROCESSING option this_in = 255; this_out = 255; } } /* otherwise read "in:out", and skip past */ else { user_defined = TRUE; the rest of the code ------------------------------ From warmerdam at POBOX.COM Fri Jul 20 08:34:01 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Fri, 20 Jul 2007 11:34:01 -0400 Subject: PROCESSING "LUT=.... issue In-Reply-To: <200707201623.14876.hulst@argoss.nl> Message-ID: A.Th.C. Hulst wrote: > Frank, > > I have a fix (ugly, but it works): > > in mapdrawgdal.c > --------------ParseDefaultLUT()------------ > int user_defined=FALSE; > while( !all_done ) > { > int this_in, this_out; > int lut_i; > > while( isspace(*lut_read) ) > lut_read++; > > /* if we are at end, assum 255:255 */ > if( *lut_read == '\0') > { > all_done = TRUE; > if ( !user_defined ){ > // Only assume 255:255 end when user did not specify PROCESSING option > this_in = 255; > this_out = 255; > } > } > > /* otherwise read "in:out", and skip past */ > else > { > user_defined = TRUE; > the rest of the code > ------------------------------ Sander, It seems that this code change just ignores the implicit 255:255 if there is any user provided lut points at all. I'm not sure that this is advisable. I'd suggest you file a specific bug against MapServer indicating what you consider is the issue, and your proposed solution. But I think that the above code won't quite do as is, unless I am misunderstanding 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 | President OSGeo, http://osgeo.org From mlinden at ZEELANDNET.NL Fri Jul 20 08:42:33 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Fri, 20 Jul 2007 17:42:33 +0200 Subject: WFS encoding problem Message-ID: I went on and found out that the gml_encoding can be set on layer and map level, however; My MapInfo table is in WindowsLatin1; I cannot find a way to convert it to UTF-8 When I convert it to shape and try to access the shape layer with UTF-8 set, it still returns windows latin! It only displays UTF-8 in the header of the XML. Is this a possible bug? -------- Originele bericht -------- Onderwerp: WFS encoding problem Datum: Fri, 20 Jul 2007 15:30:03 +0200 Van: Milo van der Linden Antwoord-naar: mlinden at zeelandnet.nl Aan: mapserver-users at lists.umn.edu For others to benefit from this discussion, I hereby post it to the Mapserver list, Daniel, special thanks for your response! I cannot find information about the gml_encoding parameter anywhere, and when I add it to my mapfile, it doesn't influence the encoding that is returned. This is a link to the mapfile that has "gml_encoding" set to "UTF-8" http://82.176.214.209/cgi-bin/mapserv.exe?map=/ms4w/apps/mappingworlds/service/wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=worldcities&maxfeatures=3&OUTPUTFORMAT=gml2 Can it be that it should be "wfs_encoding"? Should it be placed in the web metadata section of the MAP or of the Layer? Kind regards, Milo > > When I query my WFS for towns within the bounding box of for instance > Chili; > towns that are named with special characters in my mapinfo table like > CURIC? Are misinterpreted by the mapserver xml-generator: the output > gml is CURIC?/ms:City> > > Can you tell me how to fix this? I am using Mapserver 4.10.2 > Hi Milo, I think what you need to do is find out which encoding is used by your TAB file (you'll find that on the Charset line of the .tab file if you open it in a text editor) and then specify a "gml_encoding" metadata in the web section of your mapfile. The name you use for the encoding in the gml_encoding metadata may not be exactly the same as what you find in the .tab file's Charset line, you may have to find the encodig name that is suitable for use in a element. Unfortunately I can't find anything about this in the docs, but I do know that the option is available and has been there for a while. BTW, next time please use the mapserver-users list. Others on the list may have the answer to your questions or may benefit from seeing your questions/answers in the list archives. Daniel -- Daniel Morissette http://www.mapgears.com/ -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From tell_thao_ilovehers at YAHOO.COM Fri Jul 20 09:53:33 2007 From: tell_thao_ilovehers at YAHOO.COM (Sunday Long) Date: Fri, 20 Jul 2007 11:53:33 -0500 Subject: All about query!!! Message-ID: Hi all, I want to save a query and load it for keeping the result when zoom and pan... I use savequery(*.py) and loadquery(*.py) and it works. But how can I delete the *.py file. May I use freequery() function ? I have a layer that have a field name ID. And I want to select the shapes those have ID = 1 or 3 or 5. I use queryByAttributes(,,) but I'm getting trouble with make QSTRING! By this way,can someone show me a good example of query by PHPMapScript. It's difficult to find on Net! Thank you. From pcreso at PCRESO.COM Sat Jul 21 01:37:03 2007 From: pcreso at PCRESO.COM (Brent Wood) Date: Sat, 21 Jul 2007 01:37:03 -0700 Subject: 2008 GIS conference in Brazil Message-ID: Apologies for the cross posting, but this may be of interest.... FOURTH INTERNATIONAL SYMPOSIUM ON GIS/SPATIAL ANALYSES IN FISHERY AND AQUATIC SCIENCES (August 25-29, 2008) This is to be held at the University of Saint Ursula, Rio de Janeiro, Brazil. Given the interest in Open Source software in Brazil, it may be a good venue for those using FOSS GIS related tools in fisheries, freshwater or marine related endeavours to present their work. Details available at: http://www.esl.co.jp/Sympo/4th/1st%20Announcement%20&%20Call%20for%20Papers.pdf Please pass this on to colleagues who may be interested. Cheers, Brent Wood From hulst at ARGOSS.NL Sat Jul 21 02:04:55 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Sat, 21 Jul 2007 11:04:55 +0200 Subject: Project a [0 360> dataset in [-180 180> domain Message-ID: Hello, I wondered if it is possible to get mapserv as far as showing a map from [-180 180> while to original dataset is [0 360>. My attempts only show data from [0 180>. That relates a bit to my next wish; can mapserver zoom cyclic? When I zoom in on 360, I want to see data from 320 to 360(-dx) and 0 to 40 degrees. Is this possible with current implementations? Regards, Sander From hulst at ARGOSS.NL Sat Jul 21 11:56:35 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Sat, 21 Jul 2007 20:56:35 +0200 Subject: Project a [0 360> dataset in [-180 180> domain In-Reply-To: <412220.44431.qm@web33212.mail.mud.yahoo.com> Message-ID: On Saturday 21 July 2007 14:26:27 Brent Wood wrote: > --- "A.Th.C. Hulst" wrote: > > Hello, > > > > I wondered if it is possible to get mapserv as far as showing a map from > > [-180 > > 180> while to original dataset is [0 360>. My attempts only show data > > from [0 180>. > > It will show data from -180 t0 o if you scroll left enough. > > There is no way to do this easily. I use a PostGIS table with two geometry > columns, one in each longitude space. Points are easy to convert, but lines > & polygons that cross 180 need to be joined/merged while those that cross 0 > need to be split. So it is not just a simple reprojection, but als includes > a merging or splitting of affected features crossing the 0/180 meridians. > > I also achieve the same result by cutting the wester hemisphere of data, > translate it by 360 degrees & paste it onto the 0-180 geometry column, so > the column goes from 0-360, 1 1/2 times around, which gives a reasonably > seamless map at the cost of some redundant data. > > I have found a few ways with PostGIS to work around this problem, but no > simple solutions. > > Raster data is also a problem, under Linux a symlink to tiles in the > eastern hemisphere with accomapnying world files seems to work OK, so there > is a -180 to 360 cover, without replicating images or tiles, just the extra > world files. > > > That relates a bit to my next wish; can mapserver zoom cyclic? When I > > zoom in > > > > on 360, I want to see data from 320 to 360(-dx) and 0 to 40 degrees. Is > > this possible with current implementations? > > As above, yes, if your dataset is -180 to 360. I was afraid that this was the answer ;) My hope was that I didn't need to fiddle with the data as I have a fresh dataset every 6 hours. Ah well.... Thanks. > > > Cheers, > > Brent Wood > > > Regards, > > Sander From bcosic at UCALGARY.CA Sat Jul 21 12:20:37 2007 From: bcosic at UCALGARY.CA (Boris Cosic) Date: Sat, 21 Jul 2007 13:20:37 -0600 Subject: Newbie Help Message-ID: Hello Everyone, I have just installed Mapguide Open Source and I've been playing with examples and successfully modified some code and everything is great. The issue comes with loading my own DWG and DWF files through web studio. I have read numerous white papers and documentation but for the life of me I can't figure out how to display the DWF file. Even the MGOS mentions the ability to load DWG files but even through Web Studio I can only see SDF and SHP as valid Data Types. I would prefer to do this without Mapguide Studio as there might be a batch of files and it would be nice if the server could just pick them up in the folder. Any help with direction on showing my DWF or DWG files in the dfwviewer.php would be great. Thanks Boris From j.l.h.hartmann at UVA.NL Sun Jul 22 09:33:26 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Sun, 22 Jul 2007 18:33:26 +0200 Subject: Mapserver sites with public map data in the US/Canada In-Reply-To: <476595.42312.qm@web33205.mail.mud.yahoo.com> Message-ID: Folks, For a German-Dutch funding proposal I am looking for Mapserver sites in the US and Canada that are based on maps which are not publicly available here in Europe, especially cadastral and large scale topographical maps. Preferebly these sites should be developed by small independent firms. A good example is Rich Greenwood's Teton County Map Server (http://www2.tetonwyo.org/mapserver/). I vaguely remember a housing server for New York, and a very large system for Portland City, but all pointers are welcome. We are trying to convince our local bigwigs that it can be profitable to make these data publicly available, both for government and for small to medium-sized firms. Those maps are completely monopolized by government and big business over here. Please send me personally any pointers you can think of, and I'll summarize them for the list. Thanks Jan Dr. J. Hartmann Department of Geography University of Amsterdam From friendvn2000 at YAHOO.COM Tue Jul 24 04:33:36 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Tue, 24 Jul 2007 06:33:36 -0500 Subject: Log file ??? Message-ID: I define log file in map file like this: WEB LOG "logs.txt" END and create a logs.txt file at the same directory of map file. But I get nothing response in this log file. What did I do wrong ? Thanks! From roybraam at B3PARTNERS.NL Mon Jul 23 05:16:26 2007 From: roybraam at B3PARTNERS.NL (Roy Braam) Date: Mon, 23 Jul 2007 14:16:26 +0200 Subject: Rotate truetype symbols Message-ID: List, I?ve got a question about rotating (with angle/angleitem) a truetype font symbol. I?ve created a layer that shows bridges etc. of roads. I?m using a font that has a ?bridge-symbol?. The direction of the nearest road in angles is stored in a attribute of the bridges-data. It works fine with pixmap symbols. When using truetype font symbols and the angle is 0 it also works fine. But when the angle is getting bigger the symbol deviates more from the real point. The symbol is rotated fine. I think this has to do with the point of rotation of the truetype symbol. In pixmap?s the point of rotation is the center that?s why it works fine. I?m using a truetype font symbol because I want the symbols fully transparent. When the pixmap symbol is rotated it isn?t transparent anymore. I thought this was a good solution?.. Can anyone help? My ?code? in the mapfile: LAYER ?. TYPE POINT TRANSPARENCY alpha CLASS NAME "bridge" STYLE #Used in older versions: ANGLEITEM ?nearest_road_direction? ANGLE [nearest_road_direction] COLOR 0 255 0 SYMBOL "bridge" SIZE 10 END STYLE COLOR 255 0 0 SYMBOL "point1" SIZE 10 END END END SYMBOL NAME "bridge" TYPE TRUETYPE FONT symbolfont FILLED TRUE CHARACTER "D" ANTIALIAS TRUE END SYMBOL NAME "point1" TYPE ellipse points 1 1 end FILLED true END So when the angle is bigger then 0 the symbol ?point1? and the center of the symbol ?bridge? is not shown on the same point. When angle equals 0 it is.The 'only' thing i want to do is rotate fully transparent symbols... Tia, Roy Braam B3partners BV -------------- next part -------------- An HTML attachment was scrubbed... URL: From veeraswamyd at YAHOO.CO.IN Sun Jul 22 22:35:11 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Sun, 22 Jul 2007 22:35:11 -0700 Subject: port Message-ID: hi all iam working with ms4w2.2.4 it is working with LISTEN 80 now i want to change it to LISTEN 8080 because simultaniously IIS is not working because it is also using port 80 so i want to change it to 8080 i have changed it to 8080 and restarted apache service but it is displaying error as "windows could not stsrt the apache ms4w web server on local computer.for more information,review the system event log.if this is a non-microsoft service vendor,and refer to service-specific error code 1." and apache is not starting.plz tell me this. -- View this message in context: http://www.nabble.com/port-tf4127615.html#a11738138 Sent from the Mapserver - User mailing list archive at Nabble.com. From mailtoasif at GMAIL.COM Mon Jul 23 14:07:44 2007 From: mailtoasif at GMAIL.COM (Asif Ahmed) Date: Mon, 23 Jul 2007 16:07:44 -0500 Subject: OVF Odbc connection identify erratic Message-ID: Hi, I am trying to implement dbox. I am displaying some points through ovf odbc connection to a sql server database. The points are showing up fine but identify/ getfeatureinfo seems to be returning only the first few rows in the database repeatedly no matter which point is clicked on. Has anybody encountered this problem before? I am using the latest map server and dbox. Any ideas? Thanks From mlinden at ZEELANDNET.NL Fri Jul 20 06:30:03 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Fri, 20 Jul 2007 15:30:03 +0200 Subject: WFS encoding problem Message-ID: For others to benefit from this discussion, I hereby post it to the Mapserver list, Daniel, special thanks for your response! I cannot find information about the gml_encoding parameter anywhere, and when I add it to my mapfile, it doesn't influence the encoding that is returned. This is a link to the mapfile that has "gml_encoding" set to "UTF-8" http://82.176.214.209/cgi-bin/mapserv.exe?map=/ms4w/apps/mappingworlds/service/wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=worldcities&maxfeatures=3&OUTPUTFORMAT=gml2 Can it be that it should be "wfs_encoding"? Should it be placed in the web metadata section of the MAP or of the Layer? Kind regards, Milo > > When I query my WFS for towns within the bounding box of for instance > Chili; > towns that are named with special characters in my mapinfo table like > CURIC? Are misinterpreted by the mapserver xml-generator: the output > gml is CURIC?/ms:City> > > Can you tell me how to fix this? I am using Mapserver 4.10.2 > Hi Milo, I think what you need to do is find out which encoding is used by your TAB file (you'll find that on the Charset line of the .tab file if you open it in a text editor) and then specify a "gml_encoding" metadata in the web section of your mapfile. The name you use for the encoding in the gml_encoding metadata may not be exactly the same as what you find in the .tab file's Charset line, you may have to find the encodig name that is suitable for use in a element. Unfortunately I can't find anything about this in the docs, but I do know that the option is available and has been there for a while. BTW, next time please use the mapserver-users list. Others on the list may have the answer to your questions or may benefit from seeing your questions/answers in the list archives. Daniel -- Daniel Morissette http://www.mapgears.com/ -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Steve.Lime at DNR.STATE.MN.US Mon Jul 23 09:13:24 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Mon, 23 Jul 2007 11:13:24 -0500 Subject: FOSS4G 2007 Early Bird Registration Ends in ONE WEEK Message-ID: 2007 Free and Open Source Software for Geospatial (FOSS4G) Conference September 24-27, Victoria, British Columbia http://www.foss4g2007.org/register/ Book now to get the early bird rates: conference registration before the deadline is just $395CAD; after July 27, registration is $565CAD. The early bird really does get the worm! For up-to-date information, registration and program details, please visit the conference website. http://www.foss4g2007.org/ EXHIBITOR AND SPONSORSHIP OPPORTUNITIES Early bird rates apply to exhibitors too! If you are planning to exhibit, reserve your booth now for a big savings! For information on exhibitor and sponsorship opportunities, see http://foss4g2007.org/ sponsors/ or contact Paul Ramsey, Conference Chair via email at pramsey at foss4g2007.org. We hope to see you in Victoria, Canada in September, in just two months! From veeraswamyd at YAHOO.CO.IN Mon Jul 23 22:36:40 2007 From: veeraswamyd at YAHOO.CO.IN (lakku) Date: Mon, 23 Jul 2007 22:36:40 -0700 Subject: LISTEN 80 Message-ID: hi all iam working with ms4w2.2.4 it is working with LISTEN 80 now i want to change it to LISTEN 8080 because simultaniously IIS is not working because it is also using port 80 so i want to change it to 8080 i have changed it to 8080 and restarted apache service but it is displaying error as "windows could not stsrt the apache ms4w web server on local computer.for more information,review the system event log.if this is a non-microsoft service vendor,and refer to service-specific error code 1." and apache is not starting.plz tell me this. -- View this message in context: http://www.nabble.com/LISTEN-80-tf4133941.html#a11757203 Sent from the Mapserver - User mailing list archive at Nabble.com. From j.l.h.hartmann at UVA.NL Sun Jul 22 09:33:26 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Sun, 22 Jul 2007 18:33:26 +0200 Subject: Mapserver sites with public map data in the US/Canada In-Reply-To: <476595.42312.qm@web33205.mail.mud.yahoo.com> Message-ID: Folks, For a German-Dutch funding proposal I am looking for Mapserver sites in the US and Canada that are based on maps which are not publicly available here in Europe, especially cadastral and large scale topographical maps. Preferebly these sites should be developed by small independent firms. A good example is Rich Greenwood's Teton County Map Server (http://www2.tetonwyo.org/mapserver/). I vaguely remember a housing server for New York, and a very large system for Portland City, but all pointers are welcome. We are trying to convince our local bigwigs that it can be profitable to make these data publicly available, both for government and for small to medium-sized firms. Those maps are completely monopolized by government and big business over here. Please send me personally any pointers you can think of, and I'll summarize them for the list. Thanks Jan Dr. J. Hartmann Department of Geography University of Amsterdam From friendvn2000 at YAHOO.COM Tue Jul 24 04:41:04 2007 From: friendvn2000 at YAHOO.COM (Jedi Knight) Date: Tue, 24 Jul 2007 06:41:04 -0500 Subject: All about query!!! Message-ID: An HTML attachment was scrubbed... URL: From dhober at GEOGRAPHIT.COM Mon Jul 23 13:47:58 2007 From: dhober at GEOGRAPHIT.COM (David Hober) Date: Mon, 23 Jul 2007 16:47:58 -0400 Subject: Mapscript query Message-ID: Greetings, In part of developing an application, I am trying to get it to perform a query on a region, given certain constraints. I've spent some time searching the MapServer forums and Google, and I still have not found an answer... I'm working with the C# mapscript library. It works as follows: A user sets up a filter for what they want returned in a search. Then they determine the region over which to search (currently I have it only searching over a point and a tolerance level defined). I pass the field to be filtered to the layer's filteritem property, and call the layer's setFilter method, and pass in the what it is the user wants to see. As an example, layerObj ms_layer = map.getLayerByName("county"); ms_layer.filteritem = "countyid" ms_layer.setFilter("[countyid] = 67"); I then perform a queryByPoint query on the layer, which returns a MS_FAILURE value. If I remove the call to ms_layer.filterItem, the query succeeds, but the results are not filtered. I've tried a variety of string combinations in the setFilter(...) method, including the following: [countyid] = 67 "[countyid] = 67" [countyid] = "67" ( [countyid] = 67 ) [countyid] == 67 "[countyid] == 67" ... and so on and so forth. Just as a reference point, here's my call to the query... Ms_layer.queryByPoint(map, queryPoint, mapscript.MS_MULTIPLE, tolerance); I'll welcome any insights or theories on this matter. Thanks! -- Dave H -------------- next part -------------- An HTML attachment was scrubbed... URL: From dmorissette at MAPGEARS.COM Tue Jul 24 08:31:30 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 24 Jul 2007 11:31:30 -0400 Subject: WFS encoding problem In-Reply-To: <46A0B8DB.1060405@zeelandnet.nl> Message-ID: Milo van der Linden wrote: > > I cannot find information about the gml_encoding parameter anywhere, and > when I add it to my mapfile, it doesn't influence the encoding that is > returned. > > This is a link to the mapfile that has "gml_encoding" set to "UTF-8" > > http://82.176.214.209/cgi-bin/mapserv.exe?map=/ms4w/apps/mappingworlds/service/wfs.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&TYPENAME=worldcities&maxfeatures=3&OUTPUTFORMAT=gml2 > Milo, The response of your server contains the following header: Which leads me to think that setting encoding has worked since the default encoding returned by MapServer should have been ISO-8859-1 if you don't explicitly set it to something else. > Can it be that it should be "wfs_encoding"? I think that's what the problem was. After checking the source code again, it seems that WFS GetFeature checks only for wfs_encoding and ows_encoding but doesn't try gml_encoding. Sorry for misleading you. :( > Should it be placed in the web metadata section of the MAP or of the Layer? > It has to be in the WEB metadata. Daniel -- Daniel Morissette http://www.mapgears.com/ From warmerdam at POBOX.COM Tue Jul 24 09:25:13 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Tue, 24 Jul 2007 12:25:13 -0400 Subject: OVF Odbc connection identify erratic In-Reply-To: Message-ID: Asif Ahmed wrote: > Hi, > > I am trying to implement dbox. > > I am displaying some points through ovf odbc connection to a sql server > database. The points are showing up fine but identify/ getfeatureinfo seems > to be returning only the first few rows in the database repeatedly no matter > which point is clicked on. > > Has anybody encountered this problem before? I am using the latest map > server and dbox. Asif, I imagine you are running into the classic "no unique identifier" problem. The two pass query mechanism used for identify/getfeatureinfo only works properly if features have a unique feature id. But some OGR drivers just set a feature id based on the order of returned records in a resultset. When a filter is applied the subset are still just numbered 1,2,3 even though they have different feature ids when no filter is applied. The fix is to ensure OGR can assign a persistent feature id to records. The OGR ODBC driver attempts to select a singular integer primary key as the feature id if one is noted. But some ODBC drivers don't provide this info properly. Also, if you are using an SQL result for your query instead of "plain table access" then this is defeated. You can force the OGR ODBC driver to use a particular column by setting the ODBC_OGR_FID configuration variable but this is a blunt tool for the job. The other approach is to add an columnname element in your OVF definition of the virtual layer. This tells the OVF driver to use a particular column for the fid. I'd suggest you do this. Note that MapServer queries through OVF/ODBC are somewhat fragile and the performance can suck since it ends up doing fetches by feature id which can be pretty slow. In MapServer 5.2 we hope to alter the query mechanism such that it will be one pass, resolving the fid requirement and performance issues. 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 | President OSGeo, http://osgeo.org From ihowat at APL.WASHINGTON.EDU Tue Jul 24 10:59:25 2007 From: ihowat at APL.WASHINGTON.EDU (Ian Howat) Date: Tue, 24 Jul 2007 11:59:25 -0600 Subject: Passing query results to the main CGI interface Message-ID: What's the easiest way to pass the results of a query back to the main CGI template (instead of to a separate query template)? I'm trying to set up an html field that shows the coordinates of the point last clicked on (without re-centering the image), as well as show some attribute information associated with that point. I'd like to have this display on my main interface page rather than open up a new query window. Thanks a lot, Ian From Josh.Hevenor at DPRA.COM Tue Jul 24 12:22:33 2007 From: Josh.Hevenor at DPRA.COM (Josh Hevenor) Date: Tue, 24 Jul 2007 14:22:33 -0500 Subject: Temporary folder and caching Message-ID: I wrote a batch file to clear out old images from mapservers temporary image folder and it got me thinking. Is this folder used just as a temporary location while mapserver constructs a response or is there any caching done using this folder? At first glance it doesn't look like there's any caching done. Mapserver 4.10 run through PHP on windows 2003. Thanks Josh Hevenor Application Developer ____________________________________________ 5230 South Service Road Burlington, Ontario L7L 5K2 Canada Phone: 905-333-4544 ext. 19 Fax: 905-333-0455 Cell: 905-320-7525 Email: josh.hevenor at dpra.com Internet: http://www.dpra.com Attention: Privileged/Confidential Information may be contained in this message. Disclosure to any person other than the named recipient is unauthorized. If you are not the intended recipient, please delete all copies of this information and kindly notify the sender by reply email. Opinions, conclusions and other information in this message that do not relate to the official business of DPRA shall be understood as neither given nor endorsed by it. DPRA and any of its subsidiaries reserve the right to monitor all e-mail communications through its networks. Thank you. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.jpg Type: image/jpeg Size: 3247 bytes Desc: image001.jpg URL: From szekerest at GMAIL.COM Tue Jul 24 13:25:26 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Tue, 24 Jul 2007 22:25:26 +0200 Subject: port In-Reply-To: <11738138.post@talk.nabble.com> Message-ID: Use "netstat -a" in a Command Prompt to make sure that there's no other 8080 port opened on your system with LISTENING state. Do you have a more specific error information in the Windows eventlog or the apache error.log? Best regards, Tamas 2007/7/23, lakku : > hi all > iam working with ms4w2.2.4 > it is working with LISTEN 80 > now i want to change it to LISTEN 8080 because simultaniously IIS is not > working because it is also using port 80 so i want to change it to 8080 > i have changed it to 8080 and restarted apache service but it is displaying > error as "windows could not stsrt the apache ms4w web server on local > computer.for more information,review the system event log.if this is a > non-microsoft service vendor,and refer to service-specific error code 1." > and apache is not starting.plz tell me this. > -- > View this message in context: http://www.nabble.com/port-tf4127615.html#a11738138 > Sent from the Mapserver - User mailing list archive at Nabble.com. > From karsten at TERRAGIS.NET Tue Jul 24 13:55:55 2007 From: karsten at TERRAGIS.NET (karsten vennemann) Date: Tue, 24 Jul 2007 13:55:55 -0700 Subject: use data field for building a combined / dynamic symbol? Message-ID: Hi all, I wanted to figure out if it is possible to use an attribute to build a "dynamic" symbol for a point layer. Let's say I create a triangle as a symbol definition and wanted to show a number as the attribute of that point inside the triangle on the map - just like a label but inside the symbol. The only way I found to do that would be to create an individual symbol definition for each number that exists in the attributes (each would be a small image for example). Is there any way that I could create a dynamic symbol (similar to a combination of the label and symbol)? Thanks Karsten Terra GIS LTD Seattle -------------- next part -------------- An HTML attachment was scrubbed... URL: From gregor at HOSTGIS.COM Tue Jul 24 14:16:50 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Tue, 24 Jul 2007 15:16:50 -0600 Subject: use data field for building a combined / dynamic symbol? In-Reply-To: <014501c7ce35$07c4e040$6501a8c0@snuggie> Message-ID: Hey, Karsten. Using pure Mapserver, you may be able to fudge something using a label and setting the label's position. If the label is centered, and the icon is big enough, and you tweak the label's font and size, it may look good enough for your needs. Other than that, I think you're out of luck. Mapserver uses predefined symbols and predefined classes. Using Mapscript, you get a lot of wiggle room as far as, for example, dynamically defining coordinates to define a new symbol on the fly. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From woodbri at SWOODBRIDGE.COM Tue Jul 24 14:38:09 2007 From: woodbri at SWOODBRIDGE.COM (Stephen Woodbridge) Date: Tue, 24 Jul 2007 17:38:09 -0400 Subject: AntiAlias dashed line Problem Message-ID: Hi all, I have a strange problem that I can't figure out. I have a symbol defined as: SYMBOL NAME 'dashed5' TYPE SIMPLE STYLE 5 5 END END And layers defined as below. Above 10,000,000 scale the layer works fine and display as expected. In the 4-10,000,000 scale layer the dashed line looks more like little arrows or a line with a + at one end. like: ---> ---> ---> or ---+ ---+ ---+ where the wide if the + or > is about 2. The only difference in the two layers is the WIDTH 1 vs WIDTH 2 Running: MapServer version 4.10.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=THREADS INPUT=TIFF INPUT=EPPL7 INPUT=JPEG INPUT=POSTGIS INPUT=SHAPEFILE Sorry no public IP on this server for a link. -Steve LAYER NAME "US_States" STATUS DEFAULT DATA "mdata/us/nt_states_polygon" TYPE POLYGON MINSCALE 10000100.0 CLASS NAME "States/Provinces" STYLE COLOR 242 239 233 END STYLE SYMBOL "dashed5" OUTLINECOLOR 153 153 153 WIDTH 1 ANTIALIAS TRUE END END END LAYER NAME "US_States" STATUS DEFAULT DATA "mdata/us/nt_states_polygon" TYPE POLYGON MAXSCALE 10000100.0 MINSCALE 4000100.0 CLASS NAME "States/Provinces" STYLE COLOR 242 239 233 END STYLE SYMBOL "dashed5" OUTLINECOLOR 153 153 153 WIDTH 2 ANTIALIAS TRUE END END END From szekerest at GMAIL.COM Tue Jul 24 15:30:40 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Wed, 25 Jul 2007 00:30:40 +0200 Subject: Mapscript query In-Reply-To: <248491BE875FBE40B765CC47E419144B0130AFF3@mosespa.ats.atsincorp.com> Message-ID: David, We have a working (drawquery.cs) sample application in the SVN trunk which does a similar job, by using the queryByAttributes though. http://trac.osgeo.org/mapserver/browser/trunk/mapserver/mapscript/csharp/examples/drawquery.cs You might try: drawquery sample.map "('[countyid]'='67')" sample.png I'm pretty sure that we are using a string comparison when evaluating the expressions. So you might have to make sure about the exact match between the actual field value and the constant have been used in the expression. The method, how the values of the numeric fields are converted the strings is somewhat data provider dependent. Best regards, Tamas 2007/7/23, David Hober : > > > > > Greetings, > > > > In part of developing an application, I am trying to get it to perform a > query on a region, given certain constraints. I've spent some time > searching the MapServer forums and Google, and I still have not found an > answer... > > > > I'm working with the C# mapscript library. > > > > It works as follows: > > > > A user sets up a filter for what they want returned in a search. Then they > determine the region over which to search (currently I have it only > searching over a point and a tolerance level defined). I pass the field to > be filtered to the layer's filteritem property, and call the layer's > setFilter method, and pass in the what it is the user wants to see. As an > example, > > > > layerObj ms_layer = map.getLayerByName("county"); > > ms_layer.filteritem = "countyid" > > ms_layer.setFilter("[countyid] = 67"); > > > > I then perform a queryByPoint query on the layer, which returns a MS_FAILURE > value. If I remove the call to ms_layer.filterItem, the query succeeds, but > the results are not filtered. I've tried a variety of string combinations > in the setFilter(?) method, including the following: > > > > [countyid] = 67 > > "[countyid] = 67" > > [countyid] = "67" > > ( [countyid] = 67 ) > > [countyid] == 67 > > "[countyid] == 67" > > > > ? and so on and so forth. > > > > Just as a reference point, here's my call to the query? > > > > Ms_layer.queryByPoint(map, queryPoint, mapscript.MS_MULTIPLE, tolerance); > > > > I'll welcome any insights or theories on this matter. > > > > Thanks! > > > > -- Dave H From richard.greenwood at GMAIL.COM Tue Jul 24 19:29:17 2007 From: richard.greenwood at GMAIL.COM (Richard Greenwood) Date: Tue, 24 Jul 2007 20:29:17 -0600 Subject: Passing query results to the main CGI interface In-Reply-To: <46A63DFD.1070005@apl.washington.edu> Message-ID: On 7/24/07, Ian Howat wrote: > What's the easiest way to pass the results of a query back to the main > CGI template (instead of to a separate query template)? I'm trying to > set up an html field that shows the coordinates of the point last > clicked on (without re-centering the image), as well as show some > attribute information associated with that point. I'd like to have this > display on my main interface page rather than open up a new query window. > Thanks a lot, > Ian > Just define your query template as what ever your "main CGI template" is. -- Richard Greenwood richard.greenwood at gmail.com www.greenwoodmap.com From mlinden at ZEELANDNET.NL Wed Jul 25 00:38:34 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Wed, 25 Jul 2007 09:38:34 +0200 Subject: MapInfo and UTF-8 Message-ID: Hello list, I have some problem with my Mapserver WFS server. In the mapfile there is a MapInfo tab that has special characters like ? and ?. MapInfo tabs are encoded in WindowsLatin1. I have set wfs_encoding is UTF-8 in the Map section of the Map File and encoding = ISO-8859-1 for the MapInfo tab. the GML output says like it should, but the attributes returned for this particular MapInfo table are meshed up because the special characters are not outputted correct. Is there a check in MapServer WFS that tries to match the tables encoding with the required GML encoding and converts characters where needed? Or are there other tricks? Kind regards, -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ben at REMOTEINFORMATION.COM.AU Wed Jul 25 01:33:17 2007 From: ben at REMOTEINFORMATION.COM.AU (Ben Madin) Date: Wed, 25 Jul 2007 16:33:17 +0800 Subject: php/mapscript can't set new_map_path Message-ID: G'day List, I can't get this to work, using $map=ms_newMapObj('',$mapserver_path); when I look in the $map object, I can get : [symbolsetfilename] => /ms4w/Apache/htdocs/report/mapserver/symbols/colour.sym [fontsetfilename] => /ms4w/Apache/htdocs/report/mapserver/fonts/fontset.txt [mappath] => [imagecolor] => ms_color_obj Object The first time I can get it to work by specifying the full path to the symbol and font files, the second time however I get : Warning: [MapServer Error]: loadSymbolSet(): Parsing error near ( ):(line 0) in C:\ms4w\Apache\htdocs\report\public\fragments\ms_public_base_map.inc on line 56 Warning: [MapServer Error]: msCalculateScale(): Invalid image width or height. in C:\ms4w\Apache\htdocs\report\public\fragments\ms_public_base_map.inc on line 56 Fatal error: Failed loading symbolset from c:/ms4w/Apache/htdocs/report/mapserver/symbols/colour.sym in C:\ms4w\Apache\htdocs\report\public\fragments\ms_public_base_map.inc on line 56 Help! cheers Ben From ben at REMOTEINFORMATION.COM.AU Wed Jul 25 02:14:32 2007 From: ben at REMOTEINFORMATION.COM.AU (Ben Madin) Date: Wed, 25 Jul 2007 17:14:32 +0800 Subject: php/mapscript can't set new_map_path (work around) Message-ID: G'day all, I have added a blank map file : $map=ms_newMapObj($mapserver_path.'blank.map'); that looks like : ## This is a temporary map placeholder MAP # Nothing is held here, but allows us to set the path. END which seems to work. cheers Ben From j.l.h.hartmann at UVA.NL Wed Jul 25 04:29:25 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Wed, 25 Jul 2007 13:29:25 +0200 Subject: [Fwd: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map data in the US/Canada] Message-ID: Folks, Ed McNierny, who of course is a prime example of a small firm doing big things with MapServer, sent me the following note. Can anyone from Canada give me any pointers to this policy change in Canada regarding royalties and licences op topographic maps? It's probably very important for our discussions over here in Europe Jan -------- Original Message -------- Subject: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map data in the US/Canada Date: Tue, 24 Jul 2007 14:30:10 -0400 From: Ed McNierney To: Jan Hartmann Jan - Just for completeness, I should explain that TopoZone uses three major data sets - topographic maps, aerial photos, and street maps - that are all produced by the U. S. Federal government as public domain data. We have long been interested in providing a similar topographic mapping service for Canada; as the Canadian government has recently changed its royalty/licensing policy for topographic maps, it is finally (8 years later) possible for us to do that. - Ed Ed McNierney TopoZone.com > From: Jan Hartmann > Date: Tue, 24 Jul 2007 19:54:56 +0200 > To: Ed McNierney > Subject: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map data in the > US/Canada > > Ed, how on earth could I forget you! Of course you are a magnificent > example of a small firm based on Open Source and public data. > > Thanks, > > Jan > > Ed McNierney wrote: >> Jan - >> >> I'm not completely certain of your description, but it sounds like TopoZone >> fits (www.topozone.com) and we've certainly got lots of data online. We >> serve about 500,000 maps and aerial photos per day; and there aren't many >> firms that can claim they are smaller than the two of us! >> >> - Ed >> >> Ed McNierney >> TopoZone.com >> >> >>> From: Jan Hartmann >>> Reply-To: Jan Hartmann >>> Date: Sun, 22 Jul 2007 18:33:26 +0200 >>> To: >>> Subject: [UMN_MAPSERVER-USERS] Mapserver sites with public map data in the >>> US/Canada >>> >>> Folks, >>> >>> For a German-Dutch funding proposal I am looking for Mapserver sites in >>> the US and Canada that are based on maps which are not publicly >>> available here in Europe, especially cadastral and large scale >>> topographical maps. Preferebly these sites should be developed by small >>> independent firms. A good example is Rich Greenwood's Teton County Map >>> Server (http://www2.tetonwyo.org/mapserver/). I vaguely remember a >>> housing server for New York, and a very large system for Portland City, >>> but all pointers are welcome. We are trying to convince our local >>> bigwigs that it can be profitable to make these data publicly available, >>> both for government and for small to medium-sized firms. Those maps are >>> completely monopolized by government and big business over here. >>> >>> Please send me personally any pointers you can think of, and I'll >>> summarize them for the list. >>> >>> Thanks >>> >>> Jan >>> >>> Dr. J. Hartmann >>> Department of Geography >>> University of Amsterdam >> >> From hulst at ARGOSS.NL Wed Jul 25 05:03:07 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Wed, 25 Jul 2007 14:03:07 +0200 Subject: PROCESSING "LUT=.... issue In-Reply-To: <46A0D5E9.8060508@pobox.com> Message-ID: Frank, On Friday 20 July 2007 17:34:01 Frank Warmerdam wrote: > It seems that this code change just ignores the implicit > 255:255 if there is any user provided lut points at all. > I'm not sure that this is advisable. I have changed the behaviour. Now it only ignores the 255:255 when the user specified a 255:x value. > > I'd suggest you file a specific bug against MapServer indicating > what you consider is the issue, and your proposed solution. Done. http://trac.osgeo.org/mapserver/ticket/2167 Best regards, Sander From hindemit at TISCALI.IT Wed Jul 25 05:27:36 2007 From: hindemit at TISCALI.IT (Antonio) Date: Wed, 25 Jul 2007 14:27:36 +0200 Subject: RASTER and real coordinates problem Message-ID: hi all, I've a raster image (600*400) of a harbour ... in the map file i MUST specify EXTENT 0.0 0.0 600.0 400.0 (correct ?) ... the real coordinates of the gps are between -9.10 41.20 -9.55 42.30 (for example) ... HOW can I calculate the real position of the boats on the map ? I'm tryin projection, but I'm not able to resolve ... documentation ? links ? etc ... tanks in advance ... -- #include int main(void){char c[]={10,65,110,116,111,110,105,111,32,98,97,114,98,111,110, 101,32,60,104,105,110,100,101,109,105,116,64,116,105,115,99,97,108,105,110,101, 116,46,105,116,62,10,10,0};printf("%s",c);return 0;} From fsozzi at INTERCAD.CH Wed Jul 25 05:25:15 2007 From: fsozzi at INTERCAD.CH (Francesco Sozzi) Date: Wed, 25 Jul 2007 14:25:15 +0200 Subject: transparent hatches Message-ID: Hi All, I have a polygon layer with overlapped geometries and with several classes. I use an hatch symbol into one class and I would like to set it transparent to see other polygons (of different classes) below. The transparence attribute works only at layer level and if I use it I still have other classes of the same layer hided by the hatched upper polygon. Is it possible to set transparency of an hatch symbol at symbol level or at class level? Regards Francesco -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at POBOX.COM Wed Jul 25 06:30:50 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Wed, 25 Jul 2007 09:30:50 -0400 Subject: MapInfo and UTF-8 In-Reply-To: <46A6FDFA.2010600@zeelandnet.nl> Message-ID: Milo van der Linden wrote: > Hello list, > > I have some problem with my Mapserver WFS server. In the mapfile there > is a MapInfo tab that has special characters like ? and ?. MapInfo tabs > are encoded in WindowsLatin1. > > I have set wfs_encoding is UTF-8 in the Map section of the Map File and > encoding = ISO-8859-1 for the MapInfo tab. > > the GML output says like it should, but the > attributes returned for this particular MapInfo table are meshed up > because the special characters are not outputted correct. > > Is there a check in MapServer WFS that tries to match the tables > encoding with the required GML encoding and converts characters where > needed? Milo, I'm not too sure whether MapServer tries to do character encoding changes. I gather it may in some circumstances. But OGR does not currently have any concept of the character set of a datasource. So OGR is certainly not able to indicate to mapserver what the input encoding is which I would guess means that no correct transliteration can be done. 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 | President OSGeo, http://osgeo.org From bartvde at OSGIS.NL Wed Jul 25 06:06:22 2007 From: bartvde at OSGIS.NL (Bart van den Eijnden (OSGIS)) Date: Wed, 25 Jul 2007 15:06:22 +0200 Subject: ANGLE FOLLOW Message-ID: Hi list, I am trying to use ANGLE FOLLOW in Mapserver 4.10.2 but I can't get the labels to have an offset, they are always right in the line segment (i.e. the center of the label is the line segment). Is this possible, and if so does anybody have an example to share? Thanks. Best regards, Bart -- Bart van den Eijnden OSGIS, Open Source GIS http://www.osgis.nl From nbest at LANWORTH.COM Wed Jul 25 07:09:42 2007 From: nbest at LANWORTH.COM (Neil Best) Date: Wed, 25 Jul 2007 09:09:42 -0500 Subject: floating point grass rasters and mapserver - a resume Message-ID: Can anyone comment on whether this information is still current? Are there any plans to accommodate GRASS rasters in Mapserver? Thanks for any info or tips. Neil On Sun, 16 Oct 2005 12:43:44 +0200, Jachym Cepicky wrote: >very well! > >I did it by hand till now (well I do not have so many raster in GRASS >and ... how often do one need to change the color table?) > >could you post this script on GRASS-Addons site? >(http://grass.gdf-hannover.de/twiki/bin/view/GRASS/GrassAddOns) > >J?chym > >On Sun, Oct 16, 2005 at 12:35:14PM +0200, Andrea Antonello wrote: >> Some time ago I was dealing with mapserver getting maps from a GRASS location. >> The maps are all floating point maps and as you (whoever interested) probably >> followed in a few mails, the result of most of my maps simply resulted in a >> single color layer (in my case it was yellow). >> Frank Warmerdam helped me to solve what was solvable and workaround what was >> "workaroundable". >> The following is an extract and resume of the mails exchange. >> Any reply and correction is appreciated. >> >> Alright, the problem was not only one, but a bunch concurring: >> 1) GRASS novalues are not supported and give problems >> >> Running gdalinfo -mm on the map, we find that part of the problem is that >> nodata values are being treated as "nan" (not a number). GDAL and mapserver >> do not know how to excluse "nan" nodata values from the min/max calculation >> so the autoscaling gets all screwed up. >> >> Here we can see it in the gdalinfo output: >> >> Band 1 Block=385x1 Type=Float64, ColorInterp=Palette >> Min=0.000 Max=229172.410 Computed Min/Max=nan,nan >> NoData Value=nan >> >> >> Therefore the min and max have to ge defined and supplied to the map file with >> the following: >> PROCESSING SCALE=min max >> >> 2) There is a problem with the creation of color ramps in the case of a big >> number of not homogeneous distributed values: >> >> >> Color Table (RGB with 100001 entries) >> 0: 0,0,0,0 >> 1: 255,255,0,255 >> 2: 255,255,0,255 >> 3: 255,255,0,255 >> ... >> >> >> This is why I had a yellow map. The first 256 values of the color table were >> used by MapServer for the after-scaling values. Effectively the first 256 >> entries of the color table are all shades of yellow. >> >> 3) MapServer does not support the GRASS color rules metadata >> >> >> Metadata: >> COLOR_TABLE_RULES_COUNT=5 >> COLOR_TABLE_RULE_RGB_0=1.000000e+00 4.583448e+04 255 255 0 0 255 0 >> COLOR_TABLE_RULE_RGB_1=4.583448e+04 9.166896e+04 0 255 0 0 255 255 >> COLOR_TABLE_RULE_RGB_2=9.166896e+04 1.375034e+05 0 255 255 0 0 255 >> COLOR_TABLE_RULE_RGB_3=1.375034e+05 1.833379e+05 0 0 255 255 0 255 >> COLOR_TABLE_RULE_RGB_4=1.833379e+05 2.291724e+05 255 0 255 255 0 0 >> >> >> The metadata contains the coloring rules that should be applied. However, >> mapserver does not currently know how to use this sort of color rule >> metadata. For now the only solution is to recreate classes that are value >> similar. One problem though is that MapServer classes don't allow applying a >> range of color to a range of values like GRASS (or QGIS). Applying own >> CLASSes in the LAYER makes mapserver ignore the color table. >> >> The CLASSes option has two main drawbacks: >> >> a) The CLASS does not allow color ranges. There is no big solution (only >> workarounds), if not to wait on the new range based class coloring that Bill >> Binko has been working on. An implementation of that is available in 4.6.x >> but it is under revision. >> >> b) If we decide to create a set of CLASS rules to get the map drawn "as if" it >> was interpolated, you will need to create a lot of rules, which gives big big >> performance problems in drawing the map. This can however be solved with a >> PROCESSING command. Here the explanation: >> The problem is that the class lookup is done once for each "bucket" in the >> lookup table and that by default there are 65536 buckets. It helps a lot to >> add the following line in the LAYER definition: >> >> PROCESSING "SCALE_BUCKETS=200" >> >> This basically alters the resolution of the lookup table but substantially >> accelerates things. >> >> >> >> After some testing on what would be the best to do for now, I'm now letting >> the following bash script snippet for automated creation of the raster part >> mapfile. It contains the solutions and workarounds reported in this document: >> >> # the path to the grass cellheader file >> absolutepath=$mapsetpath/cellhd/$i >> >> echo "LAYER" > rastertmpfile >> echo " NAME $i" >> rastertmpfile >> echo " TYPE RASTER" >> rastertmpfile >> echo " STATUS ON" >> rastertmpfile >> echo " DATA \"$absolutepath\"" >> rastertmpfile >> >> # extract the min and max >> minmax=`gdalinfo -mm $absolutepath | grep Min | awk -F "=" '{print $2, >> $3}' | awk '{print $1, $3}'` >> # extract the gdal computed min and max >> gdalrange=`gdalinfo -mm $absolutepath | grep "Computed Min" |awk -F >> "Computed Min/Max=" '{print $2}' | awk -F "," '{print $1}'` >> >> >> # if gdal has problems with colortables and novalues, it is not able to >> compute the range, >> # therefore we have to supply it and create a set of ad hoc colorrules >> if [ "$gdalrange" == "nan" ] >> then >> # minmax has the format "123 234", so just extract them >> min=`echo $minmax | awk '{print $1}' | awk -F "." '{print $1}'` >> max=`echo $minmax | awk '{print $2}' | awk -F "." '{print $1}'` >> >> # define a default colortable, rainbow of grass, but with "bin + 1" >> number of rules, >> # to get more colors and give the sensation to be interpolated >> bins=19 >> delta=$((($max-$min)/$bins)) >> >> if [ $delta -ne 0 ] >> then >> colors[1]="255 255 0" >> >> colors[2]="195 255 0" >> colors[3]="130 255 0" >> colors[4]="65 255 0" >> >> colors[5]="0 255 0" >> >> colors[6]="0 255 65" >> colors[7]="0 255 130" >> colors[8]="0 255 195" >> >> colors[9]="0 255 255" >> >> colors[10]="0 195 255" >> colors[11]="0 130 255" >> colors[12]="0 65 255" >> >> colors[13]="0 0 255" >> >> colors[14]="65 0 255" >> colors[15]="130 0 255" >> colors[16]="195 0 255" >> >> colors[17]="255 0 255" >> colors[18]="255 0 195" >> colors[19]="255 0 130" >> colors[20]="255 0 65" >> >> >> # add the processing commands >> echo " PROCESSING \"SCALE=$min $max\"" >> rastertmpfile >> echo " PROCESSING \"SCALE_BUCKETS=100\"" >> rastertmpfile >> >> >> # create the CLASSes, labeling them with the pixel value >> first=$min >> second=$(($min+$delta)) >> for j in `seq 1 $bins` >> do >> echo " CLASS " >> rastertmpfile >> echo " NAME \"$first\"" >> rastertmpfile >> echo " EXPRESSION ([pixel] >= $first and[pixel] < >> $second)" >> rastertmpfile >> echo " COLOR ${colors[$j]}" >> rastertmpfile >> echo " END" >> rastertmpfile >> first=$(($first+$delta)) >> second=$(($second+$delta)) >> done >> >> # add a last CLASSes, due to bash maths limitations >> echo " CLASS " >> rastertmpfile >> echo " NAME \"$max\"" >> rastertmpfile >> echo " EXPRESSION ([pixel] >= $first and[pixel] < $max)" >> >> rastertmpfile >> echo " COLOR ${colors[20]}" >> rastertmpfile >> echo " END" >> rastertmpfile >> fi >> fi >> >> >> >> Hope this helps someone, the script is not very stylistic, but at least it >> does the job for me. :) >> >> Ciao, >> Andrea >> >> >> >> >> -- >> ____________________________________________________________________________ >> HydroloGIS - Environmental Open Source Solutions >> www.hydrologis.com >> >> Andrea Antonello >> Environmental Engineer >> mobile: +393288497722 >> >> "Let it be as much a great honour to take as to give learning, >> if you want to be called wise." >> Skuggsja' - The King's mirror - 1240 Reykjavik >> ____________________________________________________________________________ > >-- >Jachym Cepicky >e-mail: jachym.cepicky at centrum.cz >URL: http://les-ejk.cz >GPG: http://les-ejk.cz/gnupg_public_key/ >----------------------------------------- >OFFICE: >Department of Geoinformation Technologies >LDF MZLU v Brn? >Zem?d?lsk? 3 >613 00 Brno >e-mail: xcepicky at node.mendelu.cz >URL: http://mapserver.mendelu.cz >Tel.: +420 545 134 514 From woodbri at SWOODBRIDGE.COM Wed Jul 25 07:17:50 2007 From: woodbri at SWOODBRIDGE.COM (Stephen Woodbridge) Date: Wed, 25 Jul 2007 10:17:50 -0400 Subject: ANGLE FOLLOW In-Reply-To: Message-ID: Bart van den Eijnden (OSGIS) wrote: > Hi list, > > I am trying to use ANGLE FOLLOW in Mapserver 4.10.2 but I can't get the > labels to have an offset, they are always right in the line segment (i.e. > the center of the label is the line segment). > > Is this possible, and if so does anybody have an example to share? Thanks. This was never implemented and it is non-trivial (and expensive) to compute the offset curve that would be need to place the character on. The offset would have to deal with adding and removing line segments in the offset. Think about this line: ---- \ / ------- ---------- The notch would need to be removed if you offset on the lowest side of the line otherwise you would create self intersection that would be bad for labeling. Variants on this are not uncommon. -Steve W From bartvde at OSGIS.NL Wed Jul 25 07:23:00 2007 From: bartvde at OSGIS.NL (Bart van den Eijnden (OSGIS)) Date: Wed, 25 Jul 2007 16:23:00 +0200 Subject: ANGLE FOLLOW Message-ID: So this is mostly useful for streets which are shown with very wide lines in which the labels fit, and not so much for rivers like I wanted to use it for? Best regards, Bart -- Bart van den Eijnden OSGIS, Open Source GIS http://www.osgis.nl --------- Oorspronkelijk bericht -------- Van: Stephen Woodbridge Naar: MAPSERVER-USERS at LISTS.UMN.EDU Onderwerp: Re: [UMN_MAPSERVER-USERS] ANGLE FOLLOW Datum: 25/07/07 12:21 > Bart van den Eijnden (OSGIS) wrote: > > Hi list, > > > > I am trying to use ANGLE FOLLOW in Mapserver 4.10.2 but I can't get the From nbest at LANWORTH.COM Wed Jul 25 07:25:40 2007 From: nbest at LANWORTH.COM (Neil Best) Date: Wed, 25 Jul 2007 09:25:40 -0500 Subject: floating point grass rasters and mapserver - a resume In-Reply-To: Message-ID: Also, is this work posted somewhere on the web as suggested? I did not find it in the GRASS wiki, but maybe I have overlooked it. Thanks again. Neil Best wrote: > Can anyone comment on whether this information is still current? Are there > any plans to accommodate GRASS rasters in Mapserver? Thanks for any info or > tips. > > Neil > > > On Sun, 16 Oct 2005 12:43:44 +0200, Jachym Cepicky > wrote: > >> very well! >> >> I did it by hand till now (well I do not have so many raster in GRASS >> and ... how often do one need to change the color table?) >> >> could you post this script on GRASS-Addons site? >> (http://grass.gdf-hannover.de/twiki/bin/view/GRASS/GrassAddOns) >> >> J?chym >> >> On Sun, Oct 16, 2005 at 12:35:14PM +0200, Andrea Antonello wrote: >>> Some time ago I was dealing with mapserver getting maps from a GRASS > location. >>> The maps are all floating point maps and as you (whoever interested) probably >>> followed in a few mails, the result of most of my maps simply resulted in a >>> single color layer (in my case it was yellow). >>> Frank Warmerdam helped me to solve what was solvable and workaround what was >>> "workaroundable". >>> The following is an extract and resume of the mails exchange. >>> Any reply and correction is appreciated. >>> >>> Alright, the problem was not only one, but a bunch concurring: >>> 1) GRASS novalues are not supported and give problems >>> >>> Running gdalinfo -mm on the map, we find that part of the problem is that >>> nodata values are being treated as "nan" (not a number). GDAL and mapserver >>> do not know how to excluse "nan" nodata values from the min/max calculation >>> so the autoscaling gets all screwed up. >>> >>> Here we can see it in the gdalinfo output: >>> >>> Band 1 Block=385x1 Type=Float64, ColorInterp=Palette >>> Min=0.000 Max=229172.410 Computed Min/Max=nan,nan >>> NoData Value=nan >>> >>> >>> Therefore the min and max have to ge defined and supplied to the map file > with >>> the following: >>> PROCESSING SCALE=min max >>> >>> 2) There is a problem with the creation of color ramps in the case of a big >>> number of not homogeneous distributed values: >>> >>> >>> Color Table (RGB with 100001 entries) >>> 0: 0,0,0,0 >>> 1: 255,255,0,255 >>> 2: 255,255,0,255 >>> 3: 255,255,0,255 >>> ... >>> >>> >>> This is why I had a yellow map. The first 256 values of the color table were >>> used by MapServer for the after-scaling values. Effectively the first 256 >>> entries of the color table are all shades of yellow. >>> >>> 3) MapServer does not support the GRASS color rules metadata >>> >>> >>> Metadata: >>> COLOR_TABLE_RULES_COUNT=5 >>> COLOR_TABLE_RULE_RGB_0=1.000000e+00 4.583448e+04 255 255 0 0 255 0 >>> COLOR_TABLE_RULE_RGB_1=4.583448e+04 9.166896e+04 0 255 0 0 255 255 >>> COLOR_TABLE_RULE_RGB_2=9.166896e+04 1.375034e+05 0 255 255 0 0 255 >>> COLOR_TABLE_RULE_RGB_3=1.375034e+05 1.833379e+05 0 0 255 255 0 255 >>> COLOR_TABLE_RULE_RGB_4=1.833379e+05 2.291724e+05 255 0 255 255 0 0 >>> >>> >>> The metadata contains the coloring rules that should be applied. However, >>> mapserver does not currently know how to use this sort of color rule >>> metadata. For now the only solution is to recreate classes that are value >>> similar. One problem though is that MapServer classes don't allow applying a >>> range of color to a range of values like GRASS (or QGIS). Applying own >>> CLASSes in the LAYER makes mapserver ignore the color table. >>> >>> The CLASSes option has two main drawbacks: >>> >>> a) The CLASS does not allow color ranges. There is no big solution (only >>> workarounds), if not to wait on the new range based class coloring that Bill >>> Binko has been working on. An implementation of that is available in 4.6.x >>> but it is under revision. >>> >>> b) If we decide to create a set of CLASS rules to get the map drawn "as > if" it >>> was interpolated, you will need to create a lot of rules, which gives big big >>> performance problems in drawing the map. This can however be solved with a >>> PROCESSING command. Here the explanation: >>> The problem is that the class lookup is done once for each "bucket" in the >>> lookup table and that by default there are 65536 buckets. It helps a lot to >>> add the following line in the LAYER definition: >>> >>> PROCESSING "SCALE_BUCKETS=200" >>> >>> This basically alters the resolution of the lookup table but substantially >>> accelerates things. >>> >>> >>> >>> After some testing on what would be the best to do for now, I'm now letting >>> the following bash script snippet for automated creation of the raster part >>> mapfile. It contains the solutions and workarounds reported in this document: >>> >>> # the path to the grass cellheader file >>> absolutepath=$mapsetpath/cellhd/$i >>> >>> echo "LAYER" > rastertmpfile >>> echo " NAME $i" >> rastertmpfile >>> echo " TYPE RASTER" >> rastertmpfile >>> echo " STATUS ON" >> rastertmpfile >>> echo " DATA \"$absolutepath\"" >> rastertmpfile >>> >>> # extract the min and max >>> minmax=`gdalinfo -mm $absolutepath | grep Min | awk -F "=" '{print $2, >>> $3}' | awk '{print $1, $3}'` >>> # extract the gdal computed min and max >>> gdalrange=`gdalinfo -mm $absolutepath | grep "Computed Min" |awk -F >>> "Computed Min/Max=" '{print $2}' | awk -F "," '{print $1}'` >>> >>> >>> # if gdal has problems with colortables and novalues, it is not able to >>> compute the range, >>> # therefore we have to supply it and create a set of ad hoc colorrules >>> if [ "$gdalrange" == "nan" ] >>> then >>> # minmax has the format "123 234", so just extract them >>> min=`echo $minmax | awk '{print $1}' | awk -F "." '{print $1}'` >>> max=`echo $minmax | awk '{print $2}' | awk -F "." '{print $1}'` >>> >>> # define a default colortable, rainbow of grass, but with "bin + 1" >>> number of rules, >>> # to get more colors and give the sensation to be interpolated >>> bins=19 >>> delta=$((($max-$min)/$bins)) >>> >>> if [ $delta -ne 0 ] >>> then >>> colors[1]="255 255 0" >>> >>> colors[2]="195 255 0" >>> colors[3]="130 255 0" >>> colors[4]="65 255 0" >>> >>> colors[5]="0 255 0" >>> >>> colors[6]="0 255 65" >>> colors[7]="0 255 130" >>> colors[8]="0 255 195" >>> >>> colors[9]="0 255 255" >>> >>> colors[10]="0 195 255" >>> colors[11]="0 130 255" >>> colors[12]="0 65 255" >>> >>> colors[13]="0 0 255" >>> >>> colors[14]="65 0 255" >>> colors[15]="130 0 255" >>> colors[16]="195 0 255" >>> >>> colors[17]="255 0 255" >>> colors[18]="255 0 195" >>> colors[19]="255 0 130" >>> colors[20]="255 0 65" >>> >>> >>> # add the processing commands >>> echo " PROCESSING \"SCALE=$min $max\"" >> rastertmpfile >>> echo " PROCESSING \"SCALE_BUCKETS=100\"" >> rastertmpfile >>> >>> >>> # create the CLASSes, labeling them with the pixel value >>> first=$min >>> second=$(($min+$delta)) >>> for j in `seq 1 $bins` >>> do >>> echo " CLASS " >> rastertmpfile >>> echo " NAME \"$first\"" >> rastertmpfile >>> echo " EXPRESSION ([pixel] >= $first and[pixel] < >>> $second)" >> rastertmpfile >>> echo " COLOR ${colors[$j]}" >> rastertmpfile >>> echo " END" >> rastertmpfile >>> first=$(($first+$delta)) >>> second=$(($second+$delta)) >>> done >>> >>> # add a last CLASSes, due to bash maths limitations >>> echo " CLASS " >> rastertmpfile >>> echo " NAME \"$max\"" >> rastertmpfile >>> echo " EXPRESSION ([pixel] >= $first and[pixel] < $max)" >> >>> rastertmpfile >>> echo " COLOR ${colors[20]}" >> rastertmpfile >>> echo " END" >> rastertmpfile >>> fi >>> fi >>> >>> >>> >>> Hope this helps someone, the script is not very stylistic, but at least it >>> does the job for me. :) >>> >>> Ciao, >>> Andrea >>> >>> >>> >>> >>> -- >>> ____________________________________________________________________________ >>> HydroloGIS - Environmental Open Source Solutions >>> www.hydrologis.com >>> >>> Andrea Antonello >>> Environmental Engineer >>> mobile: +393288497722 >>> >>> "Let it be as much a great honour to take as to give learning, >>> if you want to be called wise." >>> Skuggsja' - The King's mirror - 1240 Reykjavik >>> ____________________________________________________________________________ >> -- >> Jachym Cepicky >> e-mail: jachym.cepicky at centrum.cz >> URL: http://les-ejk.cz >> GPG: http://les-ejk.cz/gnupg_public_key/ >> ----------------------------------------- >> OFFICE: >> Department of Geoinformation Technologies >> LDF MZLU v Brn? >> Zem?d?lsk? 3 >> 613 00 Brno >> e-mail: xcepicky at node.mendelu.cz >> URL: http://mapserver.mendelu.cz >> Tel.: +420 545 134 514 From woodbri at SWOODBRIDGE.COM Wed Jul 25 07:28:42 2007 From: woodbri at SWOODBRIDGE.COM (Stephen Woodbridge) Date: Wed, 25 Jul 2007 10:28:42 -0400 Subject: ANGLE FOLLOW In-Reply-To: Message-ID: Bart van den Eijnden (OSGIS) wrote: > So this is mostly useful for streets which are shown with very wide lines in > which the labels fit, and not so much for rivers like I wanted to use it > for? I use it for rivers and streams like this: LAYER NAME "Rivers" STATUS DEFAULT DATA "rivers" TYPE LINE TILEINDEX "tgrindex" MAXSCALE 150100.0 LABELITEM "NAME" LABELMAXSCALE 50100.0 TRANSPARENCY ALPHA CLASS NAME "Rivers and Streams" STYLE COLOR 153 179 204 WIDTH 1 ANTIALIAS TRUE END LABEL ANGLE FOLLOW FONT "arial" TYPE TRUETYPE POSITION AUTO SIZE 7 BUFFER 4 COLOR 0 0 255 ANTIALIAS TRUE PARTIALS FALSE MINDISTANCE 250 MINFEATURESIZE 10 END END END From j.l.h.hartmann at UVA.NL Wed Jul 25 07:53:36 2007 From: j.l.h.hartmann at UVA.NL (Jan Hartmann) Date: Wed, 25 Jul 2007 16:53:36 +0200 Subject: [Fwd: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map data in the US/Canada] In-Reply-To: <46A73415.4090205@uva.nl> Message-ID: Found this link, which explains it all: http://www.freeourdata.org.uk/blog/?p=118 Jan Hartmann wrote: > Folks, > > Ed McNierny, who of course is a prime example of a small firm doing big > things with MapServer, sent me the following note. Can anyone from > Canada give me any pointers to this policy change in Canada regarding > royalties and licences op topographic maps? It's probably very important > for our discussions over here in Europe > > Jan > > -------- Original Message -------- > Subject: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map data > in the US/Canada > Date: Tue, 24 Jul 2007 14:30:10 -0400 > From: Ed McNierney > To: Jan Hartmann > > Jan - > > Just for completeness, I should explain that TopoZone uses three major data > sets - topographic maps, aerial photos, and street maps - that are all > produced by the U. S. Federal government as public domain data. We have > long been interested in providing a similar topographic mapping service for > Canada; as the Canadian government has recently changed its > royalty/licensing policy for topographic maps, it is finally (8 years > later) > possible for us to do that. > > - Ed > > Ed McNierney > TopoZone.com > > >> From: Jan Hartmann >> Date: Tue, 24 Jul 2007 19:54:56 +0200 >> To: Ed McNierney >> Subject: Re: [UMN_MAPSERVER-USERS] Mapserver sites with public map >> data in the >> US/Canada >> >> Ed, how on earth could I forget you! Of course you are a magnificent >> example of a small firm based on Open Source and public data. >> >> Thanks, >> >> Jan >> >> Ed McNierney wrote: >>> Jan - >>> >>> I'm not completely certain of your description, but it sounds like >>> TopoZone >>> fits (www.topozone.com) and we've certainly got lots of data online. We >>> serve about 500,000 maps and aerial photos per day; and there aren't >>> many >>> firms that can claim they are smaller than the two of us! >>> >>> - Ed >>> >>> Ed McNierney >>> TopoZone.com >>> >>> >>>> From: Jan Hartmann >>>> Reply-To: Jan Hartmann >>>> Date: Sun, 22 Jul 2007 18:33:26 +0200 >>>> To: >>>> Subject: [UMN_MAPSERVER-USERS] Mapserver sites with public map data >>>> in the >>>> US/Canada >>>> >>>> Folks, >>>> >>>> For a German-Dutch funding proposal I am looking for Mapserver sites in >>>> the US and Canada that are based on maps which are not publicly >>>> available here in Europe, especially cadastral and large scale >>>> topographical maps. Preferebly these sites should be developed by small >>>> independent firms. A good example is Rich Greenwood's Teton County Map >>>> Server (http://www2.tetonwyo.org/mapserver/). I vaguely remember a >>>> housing server for New York, and a very large system for Portland City, >>>> but all pointers are welcome. We are trying to convince our local >>>> bigwigs that it can be profitable to make these data publicly >>>> available, >>>> both for government and for small to medium-sized firms. Those maps are >>>> completely monopolized by government and big business over here. >>>> >>>> Please send me personally any pointers you can think of, and I'll >>>> summarize them for the list. >>>> >>>> Thanks >>>> >>>> Jan >>>> >>>> Dr. J. Hartmann >>>> Department of Geography >>>> University of Amsterdam >>> >>> > From jayzee.smith at GMAIL.COM Wed Jul 25 07:57:52 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Wed, 25 Jul 2007 10:57:52 -0400 Subject: catching errors?? Message-ID: guys, how'd i customize 'mapserv(): Web application error' and 'msDrawMap(): Image handling error'? in the first case only mapserver fails. in the second postgresql fails first then mapserver. anyway using cgi so catching error inside template isn't useful since template gets bypassed on error. what i'd really like is log error and display message from log. jzs From bfraser at GEOANALYTIC.COM Wed Jul 25 07:32:52 2007 From: bfraser at GEOANALYTIC.COM (Brent Fraser) Date: Wed, 25 Jul 2007 08:32:52 -0600 Subject: Mapserver sites with public map data Message-ID: Jan, The following message was sent to Canadian topographic data users. The data is available at http://geogratis.cgdi.gc.ca/geogratis/en/download/scanned.html. The scanned topo map dataset is known as CanMatrix. The Geomatics industry has been petitioning the Canadian federal government for years to: 1. remove the licensing restrictions on geographic data, and 2. make it available for free. And they finally did it. Brent Fraser GeoAnalytic Inc. Calgary, Alberta ----- Original Message ----- From: "Martin, Ann" To: "Martin, Ann" Sent: Tuesday, March 06, 2007 11:15 AM Subject: Request for Transition towards a no-fee, unrestricted access of Natural Resources Canada's Digital Topographic Data (DTD)/Transition vers un acc?s sans frais et sans restrictions aux donn?es topographiques num?riques (DTN) de Ressources naturelles Canada (le fran?ais suit) ________ In response to demands from users for no fee access to framework geographic data and the increasing technological shift in the marketplace, Natural Resources Canada (NRCan), is pleased to announce that starting April 1st 2007, the Earth Sciences Sector (ESS) will change the way its Digital Topographic Data (DTD) can be accessed. ESS will initiate a change from a cost recovery environment to an environment providing no fee access to its current DTD products. On April 1st, 2007, NRCan will start to make its existing DTD products available through the Geogratis Web portal. By combining the functionality from the current On-line Purchasing and Subscribers Web sites, the user will be provided with no fee access to DTD products. Under the new distribution policy, commercial licenses will no longer be required, as all users will obtain rights for unlimited use and royalty-free distribution of the data through a single unrestricted use license agreement. For subscribers, this means that beginning on April 1st, 2007, you will no longer have to pay for access rights or subscriptions for DTD products. Please note that your subscriber connection profile will remain active until April 1st, 2007, enabling you to download data as defined under the current agreement. For distributors, this means that beginning on April 1st, 2007, you will no longer have to pay royalty fees for the commercial use of DTD products. While this email serves as informal notification of our intent, official correspondence, accompanied by Letters of Mutual Consent which we request that you sign and return to NRCan, will be sent out in the next couple of days to formalize the termination of the existing contractual arrangements. We are grateful for your collaboration over the years and hope you will continue to support us in our efforts to make it easier to access, use and distribute Canada's digital topographic data. Please do not hesitate to contact me if you have any questions. ***** En r?ponse aux demandes des usagers pour avoir un acc?s sans frais aux donn?es g?ographiques cadres et compte tenu du changement technologique qui ne cesse de prendre de l'ampleur dans le march?, Ressources naturelles Canada (RNCan) est ravi d'annoncer qu'? compter du 1er avril 2007, le Secteur des sciences de la Terre (SST) changera la mani?re d'acc?der ? ses donn?es topographiques num?riques (DTN). Le SST modifiera son cadre de recouvrement des co?ts pour un cadre permettant d'acc?der sans frais ? ses produits actuels relatifs aux DTN. D?s le 1er avril 2007, RNCan offrira ses produits actuels relatifs aux DTN sur le portail en ligne de G?oGratis. L'acc?s sans frais aux produits relatifs aux DTN regroupera la fonctionnalit? des sites actuels Achat en ligne et Abonn?s. Dans le cadre de la nouvelle politique de distribution, il ne sera plus n?cessaire d'?tre titulaire d'une licence de commercialisation, puisque les usagers obtiendront, par l'entremise d'une seule licence d'utilisation sans restrictions, des droits illimit?s d'utilisation et de distribution sans redevances ? l'?gard de ces donn?es. Pour les abonn?s : Cela signifie qu'? compter du 1er avril 2007, il ne sera plus n?cessaire de payer pour avoir un acc?s ou un abonnement aux produits relatifs aux DTN. Veuillez prendre note que le profil d'abonn? avec lequel vous avez actuellement acc?s continuera d'?tre requis jusqu'au 1er avril 2007 pour que vous puissiez t?l?charger des donn?es de la mani?re pr?vue ? l'accord en vigueur. Pour les distributeurs : Cela signifie qu'? compter du 1er avril 2007, il ne sera plus n?cessaire de verser des redevances ? l'?gard de l'utilisation commerciale des produits relatifs aux DTN. Selon les conditions de la lettre de r?siliation par consentement mutuel, les redevances sont exigibles jusqu'au 31 d?cembre 2006. Ce courriel se veut un avis non officiel de notre intention. Cependant, une lettre officielle accompagn?e des lettres de r?siliation par consentement mutuel seront envoy?es dans les prochains jours afin de formaliser la r?siliation des conditions contractuelles en cours. Veuillez signer ces lettres et les retourner ? RNCan. Nous sommes heureux d'avoir pu compter sur votre collaboration au fil des ann?es, et nous esp?rons que nous pourrons continuer de compter sur votre appui pour poursuivre notre d?marche visant ? faciliter l'acc?s, l'utilisation et la distribution des donn?es topographiques num?riques du Canada. Pour toute question, n'h?sitez pas ? communiquer avec moi. Ann Martin Director / Directrice Data Dissemination Division / Direction de la diffusion des donn?es Data Management and Dissemination Branch / Direction de la gestion et de la diffusion des donn?es Earth Sciences Sector / Secteur des sciences de la Terre Natural Resources Canada / Ressources naturelles Canada Rm. 240, 601 Booth St. / 601, rue Booth, Pi?ce 240 Ottawa, (ON) K1A 0E8 Canada tel/t?l: 613-947-5849 fax / t?l?copieur (613) 947-5849 email / courriel: Ann.Martin at nrcan-rncan.gc.ca From jayzee.smith at GMAIL.COM Wed Jul 25 08:15:30 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Wed, 25 Jul 2007 11:15:30 -0400 Subject: catching errors?? In-Reply-To: Message-ID: for mapping since mapserver cgi is the last step before apache, it's fail-safe to catch errors with mapserver than say postgresql: application <=> apache <=> mapserver cgi <=> postgresql basically 'if response returned isn't image show custom text' kinda. jzs On 7/25/07, John Smith wrote: > guys, > how'd i customize 'mapserv(): Web application error' and 'msDrawMap(): > Image handling error'? in the first case only mapserver fails. in the > second postgresql fails first then mapserver. anyway using cgi so > catching error inside template isn't useful since template gets > bypassed on error. what i'd really like is log error and display > message from log. > jzs From jayzee.smith at GMAIL.COM Wed Jul 25 08:33:08 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Wed, 25 Jul 2007 11:33:08 -0400 Subject: catching errors?? In-Reply-To: Message-ID: sorry for frequent emails but didn't know there's ERROR is addition to EMPTY for cleaner error handling. ERROR catches what EMPTY doesn't. check this out http://ms.gis.umn.edu/docs/reference/mapfile/web . thanks anyways, jzs On 7/25/07, John Smith wrote: > for mapping since mapserver cgi is the last step before apache, it's > fail-safe to catch errors with mapserver than say postgresql: > application <=> apache <=> mapserver cgi <=> postgresql > > basically 'if response returned isn't image show custom text' kinda. > jzs > > On 7/25/07, John Smith wrote: > > guys, > > how'd i customize 'mapserv(): Web application error' and 'msDrawMap(): > > Image handling error'? in the first case only mapserver fails. in the > > second postgresql fails first then mapserver. anyway using cgi so > > catching error inside template isn't useful since template gets > > bypassed on error. what i'd really like is log error and display > > message from log. > > jzs From xwu2 at UTNET.UTOLEDO.EDU Wed Jul 25 10:56:15 2007 From: xwu2 at UTNET.UTOLEDO.EDU (Wu, Xiaochun) Date: Wed, 25 Jul 2007 13:56:15 -0400 Subject: How could I unsubscribe? Thank you Message-ID: Best regards, xiaochun -------------- next part -------------- An HTML attachment was scrubbed... URL: From mariette_hachey at HOTMAIL.COM Wed Jul 25 11:42:46 2007 From: mariette_hachey at HOTMAIL.COM (Mariette) Date: Wed, 25 Jul 2007 11:42:46 -0700 Subject: Download Raster(imagery) Message-ID: Is it possible to allow a user to download a raster(imagery) that is theextent of the map window? What can or can't be downloaded? Are there any demo sites out there that allow the user to download databased on the map window extent? Thanks -- View this message in context: http://www.nabble.com/Download-Raster%28imagery%29-tf4145620.html#a11792178 Sent from the Mapserver - User mailing list archive at Nabble.com. From gregor at HOSTGIS.COM Wed Jul 25 11:57:27 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Wed, 25 Jul 2007 12:57:27 -0600 Subject: Download Raster(imagery) In-Reply-To: <11792178.post@talk.nabble.com> Message-ID: > Is it possible to allow a user to download a raster(imagery) that is > theextent of the map window? What can or can't be downloaded? Are there any > demo sites out there that allow the user to download databased on the map > window extent? Oh, sure. The most basic way is to call mode=map like you're used to seeing, and just grab the resulting image. If you're using mapserv.js then just save the value of map.url and there's your image. If you mean geospatially referenced imagery, e.g. a GeoTIFF, then you want WCS (web coverage service). It's like WMS, except that the output is a geo-image instead of a plain image. Check the Mapserver documentation, the howtos, and read about setting up a WCS server and then testing it. You should find it easy to adapt the test URLs from the tutorial over to JavaScript or HTML to do what you want. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From rwburgholzer at DEQ.VIRGINIA.GOV Wed Jul 25 11:58:35 2007 From: rwburgholzer at DEQ.VIRGINIA.GOV (Burgholzer,Robert) Date: Wed, 25 Jul 2007 14:58:35 -0400 Subject: Download Raster(imagery) Message-ID: Essentially, this is what the user does every time you generate a map via mapserver, if I understand your desire correctly. If you are using PHP mapscript, an example will be easy to provide, such as: $image = $map->draw(); $image_url = $image->saveWebImage(MS_GIF,1,1,0); print("Click Here to Download Map Image"); HTH, r.b. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Mariette Sent: Wednesday, July 25, 2007 2:43 PM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: [UMN_MAPSERVER-USERS] Download Raster(imagery) Is it possible to allow a user to download a raster(imagery) that is theextent of the map window? What can or can't be downloaded? Are there any demo sites out there that allow the user to download databased on the map window extent? Thanks -- View this message in context: http://www.nabble.com/Download-Raster%28imagery%29-tf4145620.html#a11792 178 Sent from the Mapserver - User mailing list archive at Nabble.com. From ihowat at APL.WASHINGTON.EDU Wed Jul 25 12:05:26 2007 From: ihowat at APL.WASHINGTON.EDU (Ian Howat) Date: Wed, 25 Jul 2007 13:05:26 -0600 Subject: Map image wont load in query template? Message-ID: I'm trying to send the results of an attribute query to a form in my web template (i.e., the user clicks on a point on the map and the attributes of that point are displayed on the same page) but the map image won't load when the query is returned - ???? Is there something that keeps the map from displaying in query mode? Also the reference image doesnt display. Thanks, Ian -- Ian Howat Research Associate Applied Physics Lab, University of Washington & National Snow & Ice Data Center, University of Colorado From cplist at SECONDCREEK.ORG Wed Jul 25 12:17:32 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Wed, 25 Jul 2007 15:17:32 -0400 Subject: SOS om:result Message-ID: Hi, SOS experts. I see reference to 'results' in the SOS how-to, but I'm not clear on how to get an om:result block like I see on other SOS services. Something like I might see here http://tinyurl.com/2jvs28. I'm looking mainly at the om:result and om:resultDefinition blocks. Many thanks (as usual), Charlton From dmorissette at MAPGEARS.COM Wed Jul 25 13:27:26 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Wed, 25 Jul 2007 16:27:26 -0400 Subject: MapServer 5.0.0 release plan ... and release of beta1 Message-ID: MapServer Users, Here are some details about the upcoming MapServer 5.0 release... MapServer 5.0 release plan: --------------------------- We have had our v5.0 feature freeze on Monday of this week, which means that all new features for version 5.0 are now committed to the SVN repository, and for the next few weeks we are in beta mode (i.e. no new development, only fixing bugs). We plan to have one beta per week until the final release which is planned for the week of September 12, 2007. A summary of the main features/enhancements in v5.0 is included at the end of this email. MapServer 5.0.0-beta1 release: ------------------------------ Today we are also releasing MapServer 5.0.0-beta1. The source package and links to binaries are available at: http://mapserver.gis.umn.edu/download/beta Call for volunteers ------------------- We would like to invite experienced users to contribute to this release by testing the latest beta release and reporting any issue via Trac (see the "bugs" link on the MapServer website). Please drop us a note on mapserver-dev if you plan on helping with testing so that we have an idea of how many testers we have and can better coordinate the efforts. We have also setup a formal checklist to track which areas of the software have been tested for each beta. Please see http://mapserver.gis.umn.edu/development/release_plans/mapserver_5_0/mapserver_5_0_qa_checklist for more details. Highlight of MapServer 5.0 Features/Enhancements ================================================ Note: For more details on a specific item, please refer to the corresponding RFC document at http://mapserver.gis.umn.edu/development/rfc New features: ------------ - MS RFC 19: Added Style and Label attribute binding - MS RFC 21: Raster Color Correction via color lookup table - MS RFC 27: Added label priority - MS RFC 29: Added dynamic charting (pie and bar charts) - MS RFC 31: New mechanism to load/set objects via URL using mapfile syntax - MS RFC 32: Added support for map rendering using the AGG library for better output quality Long time issues resolved: ------------------------- - MS RFC 17: Use dynamic allocation for symbols, layers, classes and styles (got rid of the static limit on the number of instances of each in a map) - MS RFC 24: Improved memory management and garbage collection for MapScript - MS RFC 26: Terminology cleanup (layer transparency renamed to opacity, scale becomes scaledenom, symbol style becomes symbol pattern) - MS RFC 28: Enhanced the debug/logging mechanism to facilitate troubleshooting and tuning applications. Added support for multiple debug levels and more control on output location. ... and numerous fixes and enhancements not listed here... From jayzee.smith at GMAIL.COM Wed Jul 25 14:35:29 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Wed, 25 Jul 2007 17:35:29 -0400 Subject: mapserv(): Web application error. Query mode needs a point, imgxy and mapxy are not set?? Message-ID: guys, see if you can shed some light: i zoom in from page A (querying works) with the following cgi variables set in the url in order- mode, qlayer, map, imgext, minx, miny, maxx, maxy, imgxy, mapxy to page B (querying works) with the following variables in the url- mode, qlayer, map, imgext, minx, miny, maxx, maxy, imgxy, mapxy then back to page A using the browser back button with the following variables- mode, qlayer, map, imgext, minx, miny, maxx, maxy, imgxy, mapxy except now querying doesn't work and i face the dreaded 'mapserv(): Web application error. Query mode needs a point, imgxy and mapxy are not set'. but if i then refresh page A, querying works again?? running mapserver version 4.8.3. what gives?? http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0302/msg00638.html http://trac.osgeo.org/mapserver/ticket/304 http://trac.osgeo.org/mapserver/ticket/314 http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/mapserver-users.0405 variable order appears right and replacing mapext with map_extent doesn't help (see above). jzs From funkbucket at GMAIL.COM Wed Jul 25 14:42:38 2007 From: funkbucket at GMAIL.COM (Ben Tuttle) Date: Wed, 25 Jul 2007 15:42:38 -0600 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46A7B22E.7080204@mapgears.com> Message-ID: Does MS RFC 24 address bug #1975? Sounds like it, but I wanted to check. On 7/25/07, Daniel Morissette wrote: > MapServer Users, > > Here are some details about the upcoming MapServer 5.0 release... > > MapServer 5.0 release plan: > --------------------------- > > We have had our v5.0 feature freeze on Monday of this week, which means > that all new features for version 5.0 are now committed to the SVN > repository, and for the next few weeks we are in beta mode (i.e. no new > development, only fixing bugs). We plan to have one beta per week until > the final release which is planned for the week of September 12, 2007. > > A summary of the main features/enhancements in v5.0 is included at the > end of this email. > > > MapServer 5.0.0-beta1 release: > ------------------------------ > > Today we are also releasing MapServer 5.0.0-beta1. The source package > and links to binaries are available at: > http://mapserver.gis.umn.edu/download/beta > > > Call for volunteers > ------------------- > > We would like to invite experienced users to contribute to this release > by testing the latest beta release and reporting any issue via Trac (see > the "bugs" link on the MapServer website). Please drop us a note on > mapserver-dev if you plan on helping with testing so that we have an > idea of how many testers we have and can better coordinate the efforts. > > We have also setup a formal checklist to track which areas of the > software have been tested for each beta. Please see > http://mapserver.gis.umn.edu/development/release_plans/mapserver_5_0/mapserver_5_0_qa_checklist > for more details. > > > > Highlight of MapServer 5.0 Features/Enhancements > ================================================ > > Note: For more details on a specific item, please refer to the > corresponding RFC document at http://mapserver.gis.umn.edu/development/rfc > > New features: > ------------ > > - MS RFC 19: Added Style and Label attribute binding > > - MS RFC 21: Raster Color Correction via color lookup table > > - MS RFC 27: Added label priority > > - MS RFC 29: Added dynamic charting (pie and bar charts) > > - MS RFC 31: New mechanism to load/set objects via URL using mapfile syntax > > - MS RFC 32: Added support for map rendering using the AGG library for > better output quality > > > Long time issues resolved: > ------------------------- > > - MS RFC 17: Use dynamic allocation for symbols, layers, classes and styles > (got rid of the static limit on the number of instances of each in a map) > > - MS RFC 24: Improved memory management and garbage collection for MapScript > > - MS RFC 26: Terminology cleanup (layer transparency renamed to opacity, > scale becomes scaledenom, symbol style becomes symbol pattern) > > - MS RFC 28: Enhanced the debug/logging mechanism to facilitate > troubleshooting and tuning applications. Added support for multiple > debug levels and more control on output location. > > > ... and numerous fixes and enhancements not listed here... > From warmerdam at POBOX.COM Wed Jul 25 18:44:27 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Wed, 25 Jul 2007 21:44:27 -0400 Subject: PROCESSING "LUT=.... issue In-Reply-To: <200707251403.07656.hulst@argoss.nl> Message-ID: A.Th.C. Hulst wrote: > Frank, > > On Friday 20 July 2007 17:34:01 Frank Warmerdam wrote: >> It seems that this code change just ignores the implicit >> 255:255 if there is any user provided lut points at all. >> I'm not sure that this is advisable. > I have changed the behaviour. Now it only ignores the 255:255 when the user > specified a 255:x value. > >> I'd suggest you file a specific bug against MapServer indicating >> what you consider is the issue, and your proposed solution. > Done. http://trac.osgeo.org/mapserver/ticket/2167 Folks, I've applied Sander's excellent patch in trunk, and closed the ticket. This fix will appear in beta2 (and nightly snapshots of course). 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 | President OSGeo, http://osgeo.org From roybraam at B3PARTNERS.NL Thu Jul 26 00:12:31 2007 From: roybraam at B3PARTNERS.NL (Roy Braam) Date: Thu, 26 Jul 2007 09:12:31 +0200 Subject: rotate fully transparent symbols Message-ID: List, I?ve got a question about rotating (with angle/angleitem) a truetype font symbol. I?ve created a layer that shows bridges etc. of roads. I?m using a font that has a ?bridge-symbol?. The direction of the nearest road in angles is stored in a attribute of the bridges-data. It works fine with pixmap symbols. When using truetype font symbols and the angle is 0 it also works fine. But when the angle is getting bigger the symbol deviates more from the real point. The symbol is rotated fine. I think this has to do with the point of rotation of the truetype symbol. In pixmap?s the point of rotation is the center that?s why it works fine. I?m using a truetype font symbol because I want the symbols fully transparent. When the pixmap symbol is rotated it isn?t transparent anymore. I thought this was a good solution?.. Can anyone help? My ?code? in the mapfile: LAYER ?. TYPE POINT TRANSPARENCY alpha CLASS NAME "bridge" STYLE #Used in older versions: ANGLEITEM ?nearest_road_direction? ANGLE [nearest_road_direction] COLOR 0 255 0 SYMBOL "bridge" SIZE 10 END STYLE COLOR 255 0 0 SYMBOL "point1" SIZE 10 END END END SYMBOL NAME "bridge" TYPE TRUETYPE FONT symbolfont FILLED TRUE CHARACTER "D" ANTIALIAS TRUE END SYMBOL NAME "point1" TYPE ellipse points 1 1 end FILLED true END So when the angle is bigger then 0 the symbol ?point1? and the center of the symbol ?bridge? is not shown on the same point. When angle equals 0 it is.The 'only' thing i want to do is rotate fully transparent symbols at a point... Tia, Roy Braam B3partners BV Met vriendelijke groet, Roy Braam B3partners BV 030 214 2082 -------------- next part -------------- An HTML attachment was scrubbed... URL: From karsten at TERRAGIS.NET Thu Jul 26 00:13:33 2007 From: karsten at TERRAGIS.NET (karsten vennemann) Date: Thu, 26 Jul 2007 00:13:33 -0700 Subject: use data field for building a combined / dynamic symbol? In-Reply-To: <46A66C42.6020306@hostgis.com> Message-ID: Thanks Gregor, Setting the label to center above the symbol worked fine for me ... great. For reference here is how that looks in the map file STYLE SYMBOL "Square" SIZE 16 COLOR 115 223 255 OUTLINECOLOR 0 0 0 END LABEL TYPE TRUETYPE FONT "verdana" ANGLE AUTO PARTIALS FALSE POSITION CC SIZE 6 FORCE TRUE COLOR 0 0 0 OUTLINECOLOR 255 255 255 END Karsten -----Original Message----- From: Gregor Mosheh [mailto:gregor at hostgis.com] Sent: Tuesday, July 24, 2007 14:17 To: karsten vennemann Cc: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] use data field for building a combined / dynamic symbol? Hey, Karsten. Using pure Mapserver, you may be able to fudge something using a label and setting the label's position. If the label is centered, and the icon is big enough, and you tweak the label's font and size, it may look good enough for your needs. Other than that, I think you're out of luck. Mapserver uses predefined symbols and predefined classes. Using Mapscript, you get a lot of wiggle room as far as, for example, dynamically defining coordinates to define a new symbol on the fly. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From dmorissette at MAPGEARS.COM Thu Jul 26 07:03:56 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Thu, 26 Jul 2007 10:03:56 -0400 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <259e26270707251442q7421e815j5481c0c2c5481a5d@mail.gmail.com> Message-ID: Ben Tuttle wrote: > Does MS RFC 24 address bug #1975? Sounds like it, but I wanted to check. > I presume you are referring to comment #15 in that ticket? http://trac.osgeo.org/mapserver/ticket/1975#comment:15 RFC-24 may fix it, but I don't think PHP MapScript suffered of the same memory management issues as the other SWIG-based MapScript because it didn't allow the creation of standalone objects the same way as SWIG Mapscript did, so I doubt RFC-24 will have helped there. Note that as I wrote in comment 16 of that ticket, intermittent crashes are unlikely to be directly related to the main issue in that ticket which is the fact that loadParams() doesn't work properly in a PHP environment ... so a separate ticket would be required for the intermittent crashes with a testcase to reproduce if you find that it still happens with 5.0-beta1. Daniel -- Daniel Morissette http://www.mapgears.com/ From assefa at DMSOLUTIONS.CA Thu Jul 26 07:31:41 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Thu, 26 Jul 2007 10:31:41 -0400 Subject: SOS om:result In-Reply-To: <00b201c7cef0$73e8d4a0$650fa8c0@latitude> Message-ID: Charlton Purvis wrote: > Hi, SOS experts. I see reference to 'results' in the SOS how-to, but I'm > not clear on how to get an om:result block like I see on other SOS services. > Something like I might see here http://tinyurl.com/2jvs28. I'm looking > mainly at the om:result and om:resultDefinition blocks. > > Many thanks (as usual), > > Charlton > Doing a getObservation should return you an Obervation collection that includes om:result for each observation returned. The om:result is implemented to return a gml:feature member. -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From bthoen at GISNET.COM Thu Jul 26 07:41:37 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Thu, 26 Jul 2007 08:41:37 -0600 Subject: Implementing Scale-Dependent Styles in a WMS Server Message-ID: I'm starting to build a MapServer WMS server that will provide national street layers to my MapServer client but I have some questions about how to approach the problem of serving alternate layers designed for different scales and same layers with different styles depending on the scale. For example, I've got a US Interstates layer that has been thinned so that it is appropriate for scales smaller than 1:10,000,000, and I've got another one that I'd use at larger scales (but from 1:10,000,000 to 1:5,000,000 I want to use one style and for scales between 1:5,000,000 and 1:1,000,000 I want to use another style on this layer). Then I've got some MapInfo seamless road layers that have the highest detail that I'd use at the largest scales, but for these too, I have three different styles depending on the display scale. Can a MapServer WMS server support this sort of thing or should I load each layer as needed and style it in the WMS client MAP file? I know how to do the latter, but it would be much more convenient to make one call to a WMS and get all the appropriate layers rendered with the desired styles in one LAYER call in my client MAP files. I've read the how-tos for WMS client and server, and glanced at the article about SLD's (but haven't understood that very well yet) but so far I haven't seen this issue addressed specifically. Does anyone have any suggestions about how to do this, or can you point me to any documentation I should read? TIA, - Bill Thoen From gilles.bassiere at MAKINA-CORPUS.COM Thu Jul 26 07:10:52 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?ISO-8859-15?Q?Gilles_Bassi=E8re?=) Date: Thu, 26 Jul 2007 16:10:52 +0200 Subject: generateSLD returns an empty SLD Message-ID: Hi list I try to use the generateSLD method but can't get it to work. I have the following code (adapted from Mapserver how-to) : getAllLayerNames() as $layerName ) { $oLayer = $oMap->getLayerByName($layerName); // generate the sld for that layer $SLD = $oLayer->generateSLD() ; // return SLD to client echo $SLD ; } ?> I have several layers which are very simple and all look like this one : # LAYER golf ------------------------------------- LAYER NAME "golf" GROUP "background" CONNECTIONTYPE postgis CONNECTION "host=localhost dbname=test user=test password=xxx port=5432" DATA "wkb_geometry FROM golf" STATUS off TYPE polygon CLASS NAME "Golf courses" STYLE COLOR 203 216 195 ANTIALIAS true END END PROJECTION "init=epsg:4326" END METADATA "wms_title" "Golf courses" "wms_srs" "EPSG:4326" "wms_extent" "3.3 50.75 7.25 53.6" END END The PHP script above returns the following output : This output is a valid SLD, I agree... But I expected to find the parameters set up in the CLASS element, how should I proceed ? What is going wrong there ? -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From gregor at HOSTGIS.COM Thu Jul 26 07:53:15 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Thu, 26 Jul 2007 08:53:15 -0600 Subject: Implementing Scale-Dependent Styles in a WMS Server In-Reply-To: <46A8B2A1.70805@gisnet.com> Message-ID: Bill Thoen wrote: > For example, I've got a US Interstates layer that has been > thinned so that it is appropriate for scales smaller than 1:10,000,000, > and I've got another one that I'd use at larger scales (but from > 1:10,000,000 to 1:5,000,000 I want to use one style and for scales > between 1:5,000,000 and 1:1,000,000 I want to use another style on this > layer). How I'd do it, and I'd love to hear other methods/opinions... Set up multiple layers, and give them all the same GROUP. In case you're not familiar with it, a group defines a "virtual multi-layer layer" and the WMS client would get all of those layers together when it requests the one layer. Then, define your multiple layers to each use appropriate MINSCALE and MAXSCALE. e.g LAYER GROUP "roads" NAME "allstreets" MAXSCALE 100000 END LAYER GROUP "roads" NAME "countyroads" MINSCALE 100001 MAXSCALE 1999999 END LAYER GROUP "roads" NAME "highways" MINSCALE 2000000 END Ta-da, now the "roads layer" will automagically change with the scale. Hope that helps. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From gregor at HOSTGIS.COM Thu Jul 26 07:53:17 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Thu, 26 Jul 2007 08:53:17 -0600 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46A7B22E.7080204@mapgears.com> Message-ID: > - MS RFC 19: Added Style and Label attribute binding What does this mean exactly? > - MS RFC 29: Added dynamic charting (pie and bar charts) Hey neat. > - MS RFC 32: Added support for map rendering using the AGG library for > better output quality Oh yes! Mapserver is excellent, but the graphics could have used improvement. This is great news! > - MS RFC 17: Use dynamic allocation for symbols, layers, classes and styles > (got rid of the static limit on the number of instances of each in a map) Seriously? No more limit in map.h, a truly unlimited number of layers and symbols and so on? Boy, this makes my day! -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From Jim.Klassen at CI.STPAUL.MN.US Thu Jul 26 07:59:43 2007 From: Jim.Klassen at CI.STPAUL.MN.US (Jim Klassen) Date: Thu, 26 Jul 2007 09:59:43 -0500 Subject: Implementing Scale-Dependent Styles in a WMS Server Message-ID: If I understand your setup, you are in charge of two mapserver installs, one being a WMS server and another acting as a WMS client. I don't know what this will do to the getCapabilities response (and it doesn't matter if Mapserver is your only client), but you could in the WMS servers map file try adding a GROUP 'mygroup' statement to each of your layers, thus assigning each of the layers to the same group. Each of the layers can then be setup with the correct styles and min/max scales. Then try calling the WMS service and ask it for the 'mygroup' layer. We do something similar here internally with our aerial orthos, except we have one mapfile per logical layer and just set status=default in all of the layers in the mapfile so they will always be rendered, no matter which one the client chooses. (The min/max scales are setup so only one layer from the mapfile will be active at any given scale.) >>> Bill Thoen 07/26/07 9:41 AM >>> I'm starting to build a MapServer WMS server that will provide national street layers to my MapServer client but I have some questions about how to approach the problem of serving alternate layers designed for different scales and same layers with different styles depending on the scale. For example, I've got a US Interstates layer that has been thinned so that it is appropriate for scales smaller than 1:10,000,000, and I've got another one that I'd use at larger scales (but from 1:10,000,000 to 1:5,000,000 I want to use one style and for scales between 1:5,000,000 and 1:1,000,000 I want to use another style on this layer). Then I've got some MapInfo seamless road layers that have the highest detail that I'd use at the largest scales, but for these too, I have three different styles depending on the display scale. Can a MapServer WMS server support this sort of thing or should I load each layer as needed and style it in the WMS client MAP file? I know how to do the latter, but it would be much more convenient to make one call to a WMS and get all the appropriate layers rendered with the desired styles in one LAYER call in my client MAP files. I've read the how-tos for WMS client and server, and glanced at the article about SLD's (but haven't understood that very well yet) but so far I haven't seen this issue addressed specifically. Does anyone have any suggestions about how to do this, or can you point me to any documentation I should read? TIA, - Bill Thoen From assefa at DMSOLUTIONS.CA Thu Jul 26 08:22:37 2007 From: assefa at DMSOLUTIONS.CA (Yewondwossen Assefa) Date: Thu, 26 Jul 2007 11:22:37 -0400 Subject: generateSLD returns an empty SLD In-Reply-To: <46A8AB6C.1050108@makina-corpus.com> Message-ID: Is it possible that the layers status is OFF (seems like that looking at the layer definition)? It should be set to ON or DEFAULT Later, Gilles Bassi?re wrote: > Hi list > > I try to use the generateSLD method but can't get it to work. > > I have the following code (adapted from Mapserver how-to) : > > > // define variables > define("MAPFILE", "/home/gba/public_html/and/test.map"); > define("MODULE", "php_mapscript.so"); > > // load the mapscript module > if (!extension_loaded("MapScript")) dl(MODULE); > > // open map > $oMap = ms_newMapObj(MAPFILE); > > foreach ( $oMap->getAllLayerNames() as $layerName ) > { > $oLayer = $oMap->getLayerByName($layerName); > > // generate the sld for that layer > $SLD = $oLayer->generateSLD() ; > > // return SLD to client > echo $SLD ; > } > ?> > > I have several layers which are very simple and all look like this one : > > # LAYER golf ------------------------------------- > LAYER > NAME "golf" > GROUP "background" > CONNECTIONTYPE postgis > CONNECTION "host=localhost dbname=test user=test password=xxx > port=5432" > DATA "wkb_geometry FROM golf" > STATUS off > TYPE polygon > > CLASS > NAME "Golf courses" > STYLE > COLOR 203 216 195 > ANTIALIAS true > END > END > > PROJECTION > "init=epsg:4326" > END > > METADATA > "wms_title" "Golf courses" > "wms_srs" "EPSG:4326" > "wms_extent" "3.3 50.75 7.25 53.6" > END > END > > The PHP script above returns the following output : > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"> > > > This output is a valid SLD, I agree... But I expected to find the > parameters set up in the CLASS element, how should I proceed ? What is > going wrong there ? > -- ---------------------------------------------------------------- Assefa Yewondwossen Software Analyst Email: assefa at dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ---------------------------------------------------------------- From zhonghaiw at GMAIL.COM Thu Jul 26 08:25:31 2007 From: zhonghaiw at GMAIL.COM (Zhonghai Wang) Date: Thu, 26 Jul 2007 17:25:31 +0200 Subject: C# MapScript & GAC Message-ID: Hi Guys, I am now programming different windows applications with MapServer C# MapScript, to add reference to the mapscript_csharp.dll, sure that i can copy all the related DLLs into my projects, and all these work well. But it's not sort of elegant, i am trying now to generate an SNK file for the mapscript_csharp.dll and install it into GAC. Has anyone ever done anything like this and made it run? i got a problem with the AL.EXE command, because it needs a .netmodule file, i can not create it with the mapscript_csharp.dll. Since i use the binary MapServer version directly, i cannot add the strong name file per attribute. what I am trying to do are: 1. sn.exe -- > get the strong name file; 2. al.exe -- > link the .netmodule with the strong name file, get a DLL output; 3. GACUtil /i -- > install it into the GAC. 4. Add a reference to the DLL in my projects. any ideas are welcome. Cheers Zhonghai -------------- next part -------------- An HTML attachment was scrubbed... URL: From szekerest at GMAIL.COM Thu Jul 26 09:29:39 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Thu, 26 Jul 2007 18:29:39 +0200 Subject: C# MapScript & GAC In-Reply-To: <2534c4120707260825h2cbab1cboee2176ac3d869c6d@mail.gmail.com> Message-ID: Zhonghai, I'm afraid you'll have to do some kind of compilation in any case. By using the al.exe you might have to compile mapscript as a 'raw' module with the /t:module csc option. FYI: Currently I have an open ticket for the support of the signed assemblies targeting the 5.0 release. http://trac.osgeo.org/mapserver/ticket/2112 I'm planning to fix this in some days for the time of the beta2 (Wed Aug. 1, 2007) so the ms4w package for the beta2 will possibly contain this option. Best regards, Tamas 2007/7/26, Zhonghai Wang : > Hi Guys, > > I am now programming different windows applications with MapServer C# > MapScript, to add reference to the mapscript_csharp.dll, sure that i can > copy all the related DLLs into my projects, and all these work well. But > it's not sort of elegant, i am trying now to generate an SNK file for the > mapscript_csharp.dll and install it into GAC. Has anyone ever done anything > like this and made it run? > > i got a problem with the AL.EXE command, because it needs a .netmodule file, > i can not create it with the mapscript_csharp.dll. Since i use the binary > MapServer version directly, i cannot add the strong name file per attribute. > > what I am trying to do are: > 1. sn.exe -- > get the strong name file; > 2. al.exe -- > link the .netmodule with the strong name file, get a DLL > output; > 3. GACUtil /i -- > install it into the GAC. > 4. Add a reference to the DLL in my projects. > > any ideas are welcome. > > Cheers > > Zhonghai From Josh.Hevenor at DPRA.COM Thu Jul 26 09:29:27 2007 From: Josh.Hevenor at DPRA.COM (Josh Hevenor) Date: Thu, 26 Jul 2007 11:29:27 -0500 Subject: SQLServer 2005 via ovf Message-ID: I'm trying to connect to a SQLServer 2005 table through OVF with little success... My OVF file ODBC:usr/pwd at ourdb,table_name table_name wkbPoint Our mapfile just has a background (province) polygon layer and this point layer. When I use shp2img there is no error reported but my points aren't on the image. shp2img -m geoportal.map -o testing.png msDrawMap(): Layer 0 (Province), 0.172s msDrawMap(): Layer 1 (Major Roads), 0.046s msDrawMap(): Layer 2 (our_layer), 7.157s // the ovf layer msDrawMap(): Drawing Label Cache, 0.000s msDrawMap() total time: 7.375s I can use mapserv.exe to draw a map when the ovf layer is turned off. When I attempt to connect through mapserver (mapscript, php) I get the following error [MapServer Error]: msOGRFileOpen(): Open failed for OGR connection `..\..\common\data\ovf\our_layer.ovf'. Unable to initialize ODBC connection to DSN for usr/pwd at ourdb,table_name, [Microsoft][SQL Native Client]Named Pipes Provider: Could not open a connection to SQL Server [1326]. When I use the 'Sql Server' odbc driver in the connection I get the following for line 3 instead of the Named Pipes stuff [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied. I'm using PHP 5.2.3 and MapServer version 4.10.2 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF OUTPUT=SVG SUPPORTS=PROJ 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 DEBUG=MSDEBUG Any suggestions are much appreciated, Josh Hevenor Application Developer ____________________________________________ 5230 South Service Road Burlington, Ontario L7L 5K2 Canada Phone: 905-333-4544 ext. 19 Fax: 905-333-0455 Cell: 905-320-7525 Email: josh.hevenor at dpra.com Internet: http://www.dpra.com Attention: Privileged/Confidential Information may be contained in this message. Disclosure to any person other than the named recipient is unauthorized. If you are not the intended recipient, please delete all copies of this information and kindly notify the sender by reply email. Opinions, conclusions and other information in this message that do not relate to the official business of DPRA shall be understood as neither given nor endorsed by it. DPRA and any of its subsidiaries reserve the right to monitor all e-mail communications through its networks. Thank you. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.jpg Type: image/jpeg Size: 3247 bytes Desc: image001.jpg URL: From warmerdam at POBOX.COM Thu Jul 26 09:51:53 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Thu, 26 Jul 2007 12:51:53 -0400 Subject: SQLServer 2005 via ovf In-Reply-To: <49B9846C39F25A4FA901064970861610B7B5BC@mhk-ex1.ad.dpra.com> Message-ID: Josh Hevenor wrote: > I?m trying to connect to a SQLServer 2005 table through OVF with little > success? > > > > My OVF file > > > > > > > > ODBC:usr/pwd at ourdb,table_name > > table_name > > wkbPoint > > x="LONGITUDE" y="LATITUDE"/> > > > > > > > > Our mapfile just has a background (province) polygon layer and this > point layer. When I use shp2img there is no error reported but my points > aren?t on the image. > > > > shp2img -m geoportal.map -o testing.png > > msDrawMap(): Layer 0 (Province), 0.172s > > msDrawMap(): Layer 1 (Major Roads), 0.046s > > msDrawMap(): Layer 2 (our_layer), 7.157s // the ovf layer > > msDrawMap(): Drawing Label Cache, 0.000s > > msDrawMap() total time: 7.375s > > > > I can use mapserv.exe to draw a map when the ovf layer is turned off. > When I attempt to connect through mapserver (mapscript, php) I get the > following error > > > > [MapServer Error]: msOGRFileOpen(): Open failed for OGR > connection `..\..\common\data\ovf\our_layer.ovf'. > > Unable to initialize ODBC connection to DSN for usr/pwd at ourdb,table_name, > > [Microsoft][SQL Native Client]Named Pipes Provider: Could not open a > connection to SQL Server [1326]. > > > > When I use the ?Sql Server? odbc driver in the connection I get the > following for line 3 instead of the Named Pipes stuff > > > > [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does > not exist or access denied. Josh, This seems like permissions problems. I don't quite "get" the permissions model under windows, but I'd suggest: 1) make sure your DSN is a system dsn, not a user dsn. 2) Investigate what you need to do to let your web user have permission to use the DSN. BTW, 7 seconds to render the points layer with shp2img is pretty terrible. Are you sure you want this to work? There are some mechanisms to have the spatial query passed down to SQL Server to be evaluated against the table. This might improve performance substantially. Contact me off list if you can't find enough info in the OVF howto on mapserver.gis.umn.edu or in the OGR VRT driver docs. 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 | President OSGeo, http://osgeo.org From cplist at SECONDCREEK.ORG Thu Jul 26 10:00:39 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Thu, 26 Jul 2007 13:00:39 -0400 Subject: SOS om:result In-Reply-To: <46A8B04D.8020308@dmsolutions.ca> Message-ID: Thanks, Assefa. > Doing a getObservation should return you an Obervation collection that > includes om:result for each observation returned. The om:result is > implemented to return a gml:feature member. Here is a live SOS query that returns 1 row (that's all it should return). http://preview.tinyurl.com/2a2x7h The part I was looking for on the above result set would be similar to the om:result from the original URL I sent earlier from another service. Basically, it's the block w/ value,value,value. I'm sorry if I'm missing your point -- that's very likely! Charlton From bthoen at GISNET.COM Thu Jul 26 12:51:52 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Thu, 26 Jul 2007 13:51:52 -0600 Subject: How to Fix Ratty Line Rendering in WMS? Message-ID: First, a thank you to Gregor Mosheh for his response to my earlier question about producing scale-dependent layers from a WMS server. The 'GROUP' method works well! But now my problem is that linework from my WMS looks pretty ratty compared to using the same data in vector form. Is there any fix for this? How can I produce smooth road lines? - Bill Thoen From gregor at HOSTGIS.COM Thu Jul 26 13:03:33 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Thu, 26 Jul 2007 14:03:33 -0600 Subject: How to Fix Ratty Line Rendering in WMS? In-Reply-To: <46A8FB58.4020908@gisnet.com> Message-ID: Bill Thoen wrote: > But now my problem is that linework from my WMS looks pretty ratty > compared to using the same data in vector form. Is there any fix for > this? How can I produce smooth road lines? Are you using transparency? I find that antialiasing and transparency just don't work well together; the antialiasing gets turned transparent, which makes it look awful. I'd love to hear advice on this topic, as I have similar issues with fonts and symbols looking crummy under transparency. If it's not transparency, how about your image format? Are you using JPEG? JPEG is nice stuff, but you've probably seen JPEGs that get all crummy if someone tried to compress too hard. Try setting the OUTPUTFORMAT options to turn up the JPEG quality to 100. Anything beyond that, we'd probably need to know a thing or two about your image format, maybe see an example of it, ... -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From doug at GIS-SOLVED.COM Thu Jul 26 13:53:20 2007 From: doug at GIS-SOLVED.COM (SUBSCRIBE MAPSERVER-USERS DougC) Date: Thu, 26 Jul 2007 15:53:20 -0500 Subject: GeoRaster Oracle support Message-ID: Hi all I am new to the world of Mapserver and am trying to see if MapServer supports the sdo georaster datatype in Oracle 10gR2 database. Will it do it? I cant see anything in gdalinfo or the mapfile structure that says I could access this datatype but would like confirmation. Many thanks Doug From even.rouault at MINES-PARIS.ORG Thu Jul 26 15:25:40 2007 From: even.rouault at MINES-PARIS.ORG (Even Rouault) Date: Fri, 27 Jul 2007 00:25:40 +0200 Subject: Ticket #2181: [PATCH] Fix handling of NODATA values (for DTED files) Message-ID: [I've just copied/pasted the content of ticket #2181, as it might interest other users too] Currently, when doing WCS on DTED files (whose NODATA value is -32767), ?you may experience problems when using INTERPOLATION=AVERAGE or ?INTERPOLATION=BILINEAR. That's because the NODATA value is not recognized ?as such and the resampling algorithms are using -32767 as a normal value, ?leading to 'fun' values like -16145 when computing averages. My proposal ?is to force the noData value as offsite.red when the source is a one band ?image. ?The following addition in msResampleGDALToMap fixes this : ?{{{ ? ? ?if (srcImage->format->bands == 1) ? ? ?{ ? ? ? ?void* hBand1 = GDALGetRasterBand( hDS, 1 ); ? ? ? ?noData = msGetGDALNoDataValue( layer, hBand1, &bGotNoData ); ? ? ? ?if (bGotNoData) ? ? ? ?{ ? ? ? ? ?layer->offsite.red = noData; ? ? ? ?} ? ? ?} ?}}} ?But, this fix is not really sufficient to address the correct handling of ?DTED files. In aeraunatical applications using DTED files, the meaning of ?the NODATA value is really 'unknown', 'there's maybe a big mountain here ?but no data collected'. So, you often prefer the propagation of the ?uncertainty of the source to the result, rather than a clever ?interpolation that may be dangerous for the final user. So, if for some ?processing of an application, you need to resample a DTED Level 2 file to ?a lower resolution, like near the resolution of a DTED1 file, you want ?-32767 to be the result of the resampling as soon as one of source grid ?elements is -32767. ?With the small patch above, those source grid elements are just ignored ?for the computation.[[BR]] ?So, I've introduced a new PROCESSING directive ('STRICT_NODATA=YES') that ?enforces the propagation of the noData value. Of course, when using ?STRICT_NODATA=yes, you should also set 'LOAD_FULL_RES_IMAGE=YES' to be ?sure that all the source grid elements will be read. And of course, the ?default resampling method, NEAREST, doesn't make much sense... Debug ?warnings are emitted when those 2 conditions are not met. ?PS : I've a longer patch that adds another INTERPOLATION method, 'MAXIMUM' ?useful for aeronautical applications too (safety altitude computations for ?example). As its name suggests, it takes the maximum value of the source ?grid elements (except a noData value ;-)). As it depends of this current ?patch, I've thought that I should delay its posting. ?PS2 : It doesn't include the small patch I've previously sent for the ?reprojection/tileindex issue (http://trac.osgeo.org/mapserver/ticket/2180) From szekerest at GMAIL.COM Thu Jul 26 16:24:31 2007 From: szekerest at GMAIL.COM (Tamas Szekeres) Date: Fri, 27 Jul 2007 01:24:31 +0200 Subject: C# MapScript & GAC In-Reply-To: <2534c4120707261233k51f38704id71ce1f13207b5da@mail.gmail.com> Message-ID: The SVN trunk have been modified so that the mapscript_csharp.dll is signed with a strong name. The following files have also been added: mapscript.snk -- Contains the key pair used config/AssemblyInfo.cs -- Contains the reference to the key file Note1: The key pair can be recreated manually using 'nmake -f makefile.vc sign' (if needed) Note2: As of these changes the applications having reference to the mapscript_csharp.dll should be recompiled when a new version of the .dll is deployed. Note3: to add the dll into the GAC we can use: 'gacutil -i mapscript_csharp.dll' Best regards, Tamas 2007/7/26, Zhonghai Wang : > Hey Tamas, > > that's fantastic! I've thought about recompiling of the > mapscript_csharp.dll, but before i recompile it myself, i just need advice > from you guys. thanks for your information. > > Use ClickOnce deployment for applications with MapServer will be surely > perfect. I am looking forward to making a test with it. > > If there's anything i can help, please let me know. Be honest, you've done a > lot for C# mapscript. Thank you, dude! > > Zhonghai > > > On 7/26/07, Tamas Szekeres wrote: > > Zhonghai, > > > > I'm afraid you'll have to do some kind of compilation in any case. By > > using the al.exe you might have to compile mapscript as a 'raw' module > > with the /t:module csc option. > > > > FYI: Currently I have an open ticket for the support of the signed > > assemblies targeting the 5.0 release. > > > > http://trac.osgeo.org/mapserver/ticket/2112 > > > > I'm planning to fix this in some days for the time of the beta2 (Wed > > Aug. 1, 2007) so the ms4w package for the beta2 will possibly contain > > this option. > > > > Best regards, > > > > Tamas > > > > > > > > 2007/7/26, Zhonghai Wang : > > > Hi Guys, > > > > > > I am now programming different windows applications with MapServer C# > > > MapScript, to add reference to the mapscript_csharp.dll, sure that i can > > > copy all the related DLLs into my projects, and all these work well. But > > > it's not sort of elegant, i am trying now to generate an SNK file for > the > > > mapscript_csharp.dll and install it into GAC. Has anyone ever done > anything > > > like this and made it run? > > > > > > i got a problem with the AL.EXE command, because it needs a .netmodule > file, > > > i can not create it with the mapscript_csharp.dll. Since i use the > binary > > > MapServer version directly, i cannot add the strong name file per > attribute. > > > > > > what I am trying to do are: > > > 1. sn.exe -- > get the strong name file; > > > 2. al.exe -- > link the .netmodule with the strong name file, get a DLL > > > output; > > > 3. GACUtil /i -- > install it into the GAC. > > > 4. Add a reference to the DLL in my projects. > > > > > > any ideas are welcome. > > > > > > Cheers > > > > > > Zhonghai > > > > From jmpmcmanus at YAHOO.COM Thu Jul 26 20:08:09 2007 From: jmpmcmanus at YAHOO.COM (James McManus McManus) Date: Thu, 26 Jul 2007 20:08:09 -0700 Subject: mapserver-5.0.0-beta1 with agg on x86_64 Message-ID: I am attempting to install mapserver-5.0.0-beta1, with agg support, on a x86_64 machine, runing fedora core 7. I first installed agg using the fedora Package Manager. It put the libraries in /usr/lib64 and headers in /usr/include/agg2. When I configure a specify --with-agg=/usr, however, the following error message occurs: checking if AGG support requested... configure: error: "could not find agg_rendering_buffer.h or libagg.a in /usr." I double checked and these files exist. I then downloaded and installed agg-2.5 in /usr/local/agg. I was able to configure mapserver, with this build of aag, but when I attempted to make I got the following error messages: g++ -g -O2 -fPIC -Wall -DENABLE_STDERR_DEBUG -DNEED_NONBLOCKING_STDERR -DHAVE_VSNPRINTF -DNEED_STRLCAT -DUSE_EPPL -DUSE_PROJ -DUSE_WMS_SVR -DUSE_WMS_LYR -DUSE_WFS_LYR -DUSE_WCS_SVR -DUSE_SOS_SVR -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS -DUSE_AGG -DUSE_PDF -DUSE_OGR -DUSE_GDAL -DUSE_GEOS -DUSE_ICONV -DUSE_POSTGIS -DUSE_THREAD -I/usr/include -I/usr/local/agg/include/agg2 -I/usr/include -I/usr/include/gdal/ -I/usr/include -I/usr/include -I/usr/include/libxml2 -c -o mapagg.o mapagg.cpp mapagg.cpp: In function ???void msImageInitAGG(imageObj*, colorObj*)???: mapagg.cpp:144: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? mapagg.cpp: In function ???void imagePolyline(imageObj*, shapeObj*, colorObj*, int, int, int, int, int*)???: mapagg.cpp:263: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? mapagg.cpp: In function ???void imageFilledPolygon2(imageObj*, shapeObj*, colorObj*, int, int)???: mapagg.cpp:338: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? mapagg.cpp: In function ???void imageFilledPolygon(imageObj*, shapeObj*, colorObj*, int, int)???: mapagg.cpp:387: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? mapagg.cpp: In function ???void msDrawMarkerSymbolAGGEllipse(symbolObj*, double, double, char, styleObj*, int, int, gdImage*, pointObj*)???: mapagg.cpp:541: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? mapagg.cpp:542: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? mapagg.cpp:546: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? mapagg.cpp: In function ???void msDrawMarkerSymbolAGGVector(symbolObj*, double, double, char, styleObj*, int, int, gdImage*, pointObj*, imageObj*)???: mapagg.cpp:635: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? mapagg.cpp: In function ???void msPieSliceAGG(imageObj*, styleObj*, double, double, double, double, double)???: mapagg.cpp:928: error: cast from ???void*??? to ???int??? loses precision mapagg.cpp: In function ???void msFilledRectangleAGG(imageObj*, styleObj*, double, double, double, double)???: mapagg.cpp:995: error: cast from ???void*??? to ???int??? loses precision mapagg.cpp: At global scope: mapagg.cpp:333: warning: ???void imageFilledPolygon2(imageObj*, shapeObj*, colorObj*, int, int)??? defined but not used mapagg.cpp:1040: warning: ???nmsTransformShapeAGG??? defined but not used make: *** [mapagg.o] Error 1 Jim -------------- next part -------------- An HTML attachment was scrubbed... URL: From mgleahy at GOLDEN.NET Thu Jul 26 23:19:09 2007 From: mgleahy at GOLDEN.NET (Mike Leahy) Date: Fri, 27 Jul 2007 01:19:09 -0500 Subject: mapserver-5.0.0-beta1 with agg on x86_64 Message-ID: Jim, I just compiled on F7-x86_64. I think maybe you need to add '--libdir=/usr/lib64' to your compile options. Mike On Thu, 26 Jul 2007 20:08:09 -0700, James McManus McManus wrote: >I am attempting to install mapserver-5.0.0-beta1, with agg support, on a x86_64 machine, runing fedora core 7. I first installed agg using the fedora Package Manager. It put the libraries in /usr/lib64 and headers in /usr/include/agg2. When I configure a specify --with-agg=/usr, however, the following error message occurs: > >checking if AGG support requested... configure: error: "could not find agg_rendering_buffer.h or libagg.a in /usr." > >I double checked and these files exist. > >I then downloaded and installed agg-2.5 in /usr/local/agg. I was able to configure mapserver, with this build of aag, but when I attempted to make I got the following error messages: > >g++ -g -O2 -fPIC -Wall -DENABLE_STDERR_DEBUG -DNEED_NONBLOCKING_STDERR -DHAVE_VSNPRINTF -DNEED_STRLCAT -DUSE_EPPL -DUSE_PROJ -DUSE_WMS_SVR -DUSE_WMS_LYR -DUSE_WFS_LYR -DUSE_WCS_SVR -DUSE_SOS_SVR -DUSE_GD_GIF -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS -DUSE_AGG -DUSE_PDF -DUSE_OGR -DUSE_GDAL -DUSE_GEOS -DUSE_ICONV -DUSE_POSTGIS -DUSE_THREAD -I/usr/include -I/usr/local/agg/include/agg2 -I/usr/include -I/usr/include/gdal/ -I/usr/include -I/usr/include -I/usr/include/libxml2 -c -o mapagg.o mapagg.cpp >mapagg.cpp: In function ???void msImageInitAGG(imageObj*, colorObj*)???: >mapagg.cpp:144: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? >mapagg.cpp: In function ???void imagePolyline(imageObj*, shapeObj*, colorObj*, int, int, int, int, int*)???: >mapagg.cpp:263: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? >mapagg.cpp: In function ???void imageFilledPolygon2(imageObj*, shapeObj*, colorObj*, int, int)???: >mapagg.cpp:338: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? >mapagg.cpp: In function ???void imageFilledPolygon(imageObj*, shapeObj*, colorObj*, int, int)???: >mapagg.cpp:387: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? >mapagg.cpp: In function ???void msDrawMarkerSymbolAGGEllipse(symbolObj*, double, double, char, styleObj*, int, int, gdImage*, pointObj*)???: >mapagg.cpp:541: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? >mapagg.cpp:542: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? >mapagg.cpp:546: warning: passing ???double??? for argument 7 to ???void gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)??? >mapagg.cpp: In function ???void msDrawMarkerSymbolAGGVector(symbolObj*, double, double, char, styleObj*, int, int, gdImage*, pointObj*, imageObj*)???: >mapagg.cpp:635: warning: format ???%08x??? expects type ???unsigned int???, but argument 3 has type ???void*??? >mapagg.cpp: In function ???void msPieSliceAGG(imageObj*, styleObj*, double, double, double, double, double)???: >mapagg.cpp:928: error: cast from ???void*??? to ???int??? loses precision >mapagg.cpp: In function ???void msFilledRectangleAGG(imageObj*, styleObj*, double, double, double, double)???: >mapagg.cpp:995: error: cast from ???void*??? to ???int??? loses precision >mapagg.cpp: At global scope: >mapagg.cpp:333: warning: ???void imageFilledPolygon2(imageObj*, shapeObj*, colorObj*, int, int)??? defined but not used >mapagg.cpp:1040: warning: ???nmsTransformShapeAGG??? defined but not used >make: *** [mapagg.o] Error 1 > >Jim > > > From thomas.bonfort at GMAIL.COM Thu Jul 26 23:51:07 2007 From: thomas.bonfort at GMAIL.COM (thomas bonfort) Date: Fri, 27 Jul 2007 08:51:07 +0200 Subject: mapserver-5.0.0-beta1 with agg on x86_64 In-Reply-To: <311195.58004.qm@web35712.mail.mud.yahoo.com> Message-ID: don't know why this is coming out as an error ... it's an old debugging message that should have been removed... you can safely remove the two occurences of this code if ( pRowCache == NULL ) { fprintf ( pLogFile, "imageFilledPolygon pRowCache == NULL, extra is %08x\n", (int)image->imageextra ); return; } in mapagg.cpp thomas On 7/27/07, James McManus McManus wrote: > > I am attempting to install mapserver-5.0.0-beta1, with agg support, on a > x86_64 machine, runing fedora core 7. I first installed agg using the fedora > Package Manager. It put the libraries in /usr/lib64 and headers in > /usr/include/agg2. When I configure a specify --with-agg=/usr, however, the > following error message occurs: > > checking if AGG support requested... configure: error: "could not find > agg_rendering_buffer.h or libagg.a in /usr." > > I double checked and these files exist. > > I then downloaded and installed agg-2.5 in /usr/local/agg. I was able to > configure mapserver, with this build of aag, but when I attempted to make I > got the following error messages: > > g++ -g -O2 -fPIC -Wall -DENABLE_STDERR_DEBUG -DNEED_NONBLOCKING_STDERR > -DHAVE_VSNPRINTF -DNEED_STRLCAT -DUSE_EPPL -DUSE_PROJ -DUSE_WMS_SVR > -DUSE_WMS_LYR -DUSE_WFS_LYR -DUSE_WCS_SVR -DUSE_SOS_SVR -DUSE_GD_GIF > -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_FT -DGD_HAS_FTEX_XSHOW > -DGD_HAS_GDIMAGEGIFPTR -DGD_HAS_GETBITMAPFONTS -DUSE_AGG -DUSE_PDF > -DUSE_OGR -DUSE_GDAL -DUSE_GEOS -DUSE_ICONV -DUSE_POSTGIS -DUSE_THREAD > -I/usr/include -I/usr/local/agg/include/agg2 -I/usr/include > -I/usr/include/gdal/ -I/usr/include -I/usr/include > -I/usr/include/libxml2 -c -o mapagg.o mapagg.cpp > mapagg.cpp: In function 'void msImageInitAGG(imageObj*, colorObj*)': > mapagg.cpp:144: warning: format '%08x' expects type 'unsigned int', but > argument 3 has type 'void*' > mapagg.cpp: In function 'void imagePolyline(imageObj*, shapeObj*, > colorObj*, int, int, int, int, int*)': > mapagg.cpp:263: warning: format '%08x' expects type 'unsigned int', but > argument 3 has type 'void*' > mapagg.cpp: In function 'void imageFilledPolygon2(imageObj*, shapeObj*, > colorObj*, int, int)': > mapagg.cpp:338: warning: format '%08x' expects type 'unsigned int', but > argument 3 has type 'void*' > mapagg.cpp: In function 'void imageFilledPolygon(imageObj*, shapeObj*, > colorObj*, int, int)': > mapagg.cpp:387: warning: format '%08x' expects type 'unsigned int', but > argument 3 has type 'void*' > mapagg.cpp: In function 'void msDrawMarkerSymbolAGGEllipse(symbolObj*, > double, double, char, styleObj*, int, int, gdImage*, pointObj*)': > mapagg.cpp:541: warning: passing 'double' for argument 7 to 'void > gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)' > mapagg.cpp:542: warning: passing 'double' for argument 7 to 'void > gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)' > mapagg.cpp:546: warning: passing 'double' for argument 7 to 'void > gdImageFilledArc(gdImage*, int, int, int, int, int, int, int, int)' > mapagg.cpp: In function 'void msDrawMarkerSymbolAGGVector(symbolObj*, > double, double, char, styleObj*, int, int, gdImage*, pointObj*, imageObj*)': > mapagg.cpp:635: warning: format '%08x' expects type 'unsigned int', but > argument 3 has type 'void*' > mapagg.cpp: In function 'void msPieSliceAGG(imageObj*, styleObj*, double, > double, double, double, double)': > mapagg.cpp:928: error: cast from 'void*' to 'int' loses precision > mapagg.cpp: In function 'void msFilledRectangleAGG(imageObj*, styleObj*, > double, double, double, double)': > mapagg.cpp:995: error: cast from 'void*' to 'int' loses precision > mapagg.cpp: At global scope: > mapagg.cpp:333: warning: 'void imageFilledPolygon2(imageObj*, shapeObj*, > colorObj*, int, int)' defined but not used > mapagg.cpp:1040: warning: 'nmsTransformShapeAGG' defined but not used > make: *** [mapagg.o] Error 1 > > Jim > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gilles.bassiere at MAKINA-CORPUS.COM Fri Jul 27 06:09:22 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?ISO-8859-15?Q?Gilles_Bassi=E8re?=) Date: Fri, 27 Jul 2007 15:09:22 +0200 Subject: Polygon outline width Message-ID: Hi there, I wonder whether it's possible to have no outline for a polygon. My first attempt was to set the WIDTH property of the STYLE element to 0 in my MapFile but I got an error from MapServer, it seems to be an invalid value. As I might need to display the same data through GeoServer, I decided to move all style information to a SLD. I wrote the following SLD : water Water bodies #99b3cc #0000FF 0.0 My map is rendered without any error but there is still an outline. I tried to set opacity to 0.0 but it's not supported by MapServer. I can set the same color for stroke and fill but having a 1px outline means that a very thin river is rendered with, at least, a 2 pixels width and this is not really nice when viewing the map at higher scales... If I remove the Stroke element Mapserver seems to set automatically a 1px outline using the fill color. Does anyone know a workaround to get rid of polygon outlines ? -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From yjacolin at FREE.FR Fri Jul 27 06:21:08 2007 From: yjacolin at FREE.FR (Jacolin Yves) Date: Fri, 27 Jul 2007 15:21:08 +0200 Subject: Polygon outline width In-Reply-To: <46A9EE82.2030308@makina-corpus.com> Message-ID: Le Friday 27 July 2007 15:09:22 Gilles Bassi?re, vous avez ?crit?: > Hi there, >[..] > > Does anyone know a workaround to get rid of polygon outlines ? Hi Gilles, You can use OUTLINECOLOR -1 -1 -1 for invisible layer. Y. -- Yves Jacolin --- http://softlibre.gloobe.org From flavio at TYDAC.CH Fri Jul 27 06:37:29 2007 From: flavio at TYDAC.CH (Flavio Hendry) Date: Fri, 27 Jul 2007 15:37:29 +0200 Subject: Polygon outline width In-Reply-To: <46A9EE82.2030308@makina-corpus.com> Message-ID: Hi Gilles just set the OUTLINECOLOR to -1 0 0. Mit freundlichem Gruss / Best Regards Flavio Hendry ---------------------------------------------------------------- TYDAC Web-Site: http://www.tydac.ch TYDAC MapServer: http://www.mapserver.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 ---------------------------------------------------------------- -----Original Message----- From: Gilles Bassi?re To: MAPSERVER-USERS at LISTS.UMN.EDU Date: Fri, 27 Jul 2007 15:09:22 +0200 Subject: [UMN_MAPSERVER-USERS] Polygon outline width > Hi there, > > I wonder whether it's possible to have no outline for a polygon. > My first attempt was to set the WIDTH property of the STYLE element > to 0 > in my MapFile but I got an error from MapServer, it seems to be an > invalid value. > As I might need to display the same data through GeoServer, I decided > to > move all style information to a SLD. I wrote the following SLD : > > > version="1.0.0" > xmlns="http://www.opengis.net/sld" > xmlns:gml="http://www.opengis.net/gml" > xmlns:ogc="http://www.opengis.net/ogc" > xmlns:xlink="http://www.w3.org/1999/xlink" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.opengis.net/sld > http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" > > > > > water > > > > Water bodies > > > #99b3cc > > > name="stroke">#0000FF > name="stroke-width">0.0 > > > > > > > > > My map is rendered without any error but there is still an outline. I > tried to set opacity to 0.0 but it's not supported by MapServer. I > can > set the same color for stroke and fill but having a 1px outline means > that a very thin river is rendered with, at least, a 2 pixels width > and > this is not really nice when viewing the map at higher scales... > If I remove the Stroke element Mapserver seems to set automatically a > 1px outline using the fill color. > > Does anyone know a workaround to get rid of polygon outlines ? > > -- > Gilles Bassiere > MAKINA CORPUS > 30 rue des Jeuneurs > FR-75011 PARIS > http://www.makina-corpus.com From fsozzi at INTERCAD.CH Fri Jul 27 07:31:27 2007 From: fsozzi at INTERCAD.CH (Francesco Sozzi) Date: Fri, 27 Jul 2007 16:31:27 +0200 Subject: GeoRaster Oracle support Message-ID: Hi Doug, Mapserver does not support Georasters at the moment. But I havely used big rasters directly from files with very good performances. Regards Francesco ----- Original Message ----- From: "SUBSCRIBE MAPSERVER-USERS DougC" To: Sent: Thursday, July 26, 2007 10:53 PM Subject: [UMN_MAPSERVER-USERS] GeoRaster Oracle support Hi all I am new to the world of Mapserver and am trying to see if MapServer supports the sdo georaster datatype in Oracle 10gR2 database. Will it do it? I cant see anything in gdalinfo or the mapfile structure that says I could access this datatype but would like confirmation. Many thanks Doug __________ Informazione NOD32 2424 (20070726) __________ Questo messaggio ? stato controllato dal Sistema Antivirus NOD32 http://www.nod32.it From piero.cavalieri at GMAIL.COM Fri Jul 27 09:29:35 2007 From: piero.cavalieri at GMAIL.COM (Piero Cavalieri) Date: Fri, 27 Jul 2007 16:29:35 +0000 Subject: SQLServer 2005 via ovf In-Reply-To: <49B9846C39F25A4FA901064970861610B7B5BC@mhk-ex1.ad.dpra.com> Message-ID: Bho, I have a connection like this: CONNECTIONTYPE OGR CONNECTION " ODBC:xxx/xxx at gisdevSql2005 top025sc SELECT * FROM top025sc WHERE TOP_CL = 'T110' or TOP_CL = 'T115' " And a System DSN and it's working. Here is different: ODBC:xxx/xxx at gisdevSql2005 Where gisdevSql2005 is the DSN, And u have: ODBC:usr/pwd at ourdb,table_name Which is different syntax. Try as my syntax, maybe it works. Cheers Piero 2007/7/26, Josh Hevenor : > > I'm trying to connect to a SQLServer 2005 table through OVF with little > success? > > > > My OVF file > > > > > > > > ODBC:usr/pwd at ourdb,table_name > > table_name > > wkbPoint > > x="LONGITUDE" y="LATITUDE"/> > > > > > > > > Our mapfile just has a background (province) polygon layer and this point > layer. When I use shp2img there is no error reported but my points aren't on > the image. > > > > shp2img -m geoportal.map -o testing.png > > msDrawMap(): Layer 0 (Province), 0.172s > > msDrawMap(): Layer 1 (Major Roads), 0.046s > > msDrawMap(): Layer 2 (our_layer), 7.157s // the ovf layer > > msDrawMap(): Drawing Label Cache, 0.000s > > msDrawMap() total time: 7.375s > > > > I can use mapserv.exe to draw a map when the ovf layer is turned off. When > I attempt to connect through mapserver (mapscript, php) I get the following > error > > > > [MapServer Error]: msOGRFileOpen(): Open failed for OGR > connection `..\..\common\data\ovf\our_layer.ovf'. > > Unable to initialize ODBC connection to DSN for usr/pwd at ourdb,table_name, > > [Microsoft][SQL Native Client]Named Pipes Provider: Could not open a > connection to SQL Server [1326]. > > > > When I use the 'Sql Server' odbc driver in the connection I get the > following for line 3 instead of the Named Pipes stuff > > > > [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does > not exist or access denied. > > > > I'm using PHP 5.2.3 and MapServer version 4.10.2 > > > > OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF OUTPUT=SWF > OUTPUT=SVG SUPPORTS=PROJ 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 > DEBUG=MSDEBUG > > > > Any suggestions are much appreciated, > > > > Josh Hevenor > Application Developer > ____________________________________________ > 5230 South Service Road > Burlington, Ontario > L7L 5K2 Canada > Phone: 905-333-4544 ext. 19 > Fax: 905-333-0455 > Cell: 905-320-7525* > **Email: josh.hevenor at dpra.com** > *Internet: http://www.dpra.com* > * > > > > > > > *Attention:** > *Privileged/Confidential Information may be contained in this message. > Disclosure to any person other than the named recipient is unauthorized. If > you are not the intended recipient, please delete all copies of this > information and kindly notify the sender by reply email. Opinions, > conclusions and other information in this message that do not relate to the > official business of DPRA shall be understood as neither given nor endorsed > by it. DPRA and any of its subsidiaries reserve the right to monitor all > e-mail communications through its networks. Thank you. > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image001.jpg Type: image/jpeg Size: 3247 bytes Desc: not available URL: From Piero.Cavalieri at HEIDI.IT Fri Jul 27 09:26:12 2007 From: Piero.Cavalieri at HEIDI.IT (Piero Cavalieri) Date: Fri, 27 Jul 2007 18:26:12 +0200 Subject: R: [UMN_MAPSERVER-USERS] SQLServer 2005 via ovf In-Reply-To: A<46A8D129.5000404@pobox.com> Message-ID: Bho, I have a connection like this: CONNECTIONTYPE OGR CONNECTION "ODBC:xxx/xxx at gisdevSql2005 top025sc SELECT * FROM top025sc WHERE TOP_CL = 'T110' or TOP_CL = 'T115' " And a System DSN and it's working. Here is different: ODBC:xxx/xxx at gisdevSql2005 Where gisdevSql2005 is the DSN, And u have: ODBC:usr/pwd at ourdb,table_name Which is different syntax. Try as my syntax, maybe it works. Cheers Piero -----Messaggio originale----- Da: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] Per conto di Frank Warmerdam Inviato: gioved? 26 luglio 2007 18.52 A: MAPSERVER-USERS at LISTS.UMN.EDU Oggetto: Re: [UMN_MAPSERVER-USERS] SQLServer 2005 via ovf Josh Hevenor wrote: > I'm trying to connect to a SQLServer 2005 table through OVF with little > success... > > > > My OVF file > > > > > > > > ODBC:usr/pwd at ourdb,table_name > > table_name > > wkbPoint > > x="LONGITUDE" y="LATITUDE"/> > > > > > > > > Our mapfile just has a background (province) polygon layer and this > point layer. When I use shp2img there is no error reported but my points > aren't on the image. > > > > shp2img -m geoportal.map -o testing.png > > msDrawMap(): Layer 0 (Province), 0.172s > > msDrawMap(): Layer 1 (Major Roads), 0.046s > > msDrawMap(): Layer 2 (our_layer), 7.157s // the ovf layer > > msDrawMap(): Drawing Label Cache, 0.000s > > msDrawMap() total time: 7.375s > > > > I can use mapserv.exe to draw a map when the ovf layer is turned off. > When I attempt to connect through mapserver (mapscript, php) I get the > following error > > > > [MapServer Error]: msOGRFileOpen(): Open failed for OGR > connection `..\..\common\data\ovf\our_layer.ovf'. > > Unable to initialize ODBC connection to DSN for usr/pwd at ourdb,table_name, > > [Microsoft][SQL Native Client]Named Pipes Provider: Could not open a > connection to SQL Server [1326]. > > > > When I use the 'Sql Server' odbc driver in the connection I get the > following for line 3 instead of the Named Pipes stuff > > > > [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does > not exist or access denied. Josh, This seems like permissions problems. I don't quite "get" the permissions model under windows, but I'd suggest: 1) make sure your DSN is a system dsn, not a user dsn. 2) Investigate what you need to do to let your web user have permission to use the DSN. BTW, 7 seconds to render the points layer with shp2img is pretty terrible. Are you sure you want this to work? There are some mechanisms to have the spatial query passed down to SQL Server to be evaluated against the table. This might improve performance substantially. Contact me off list if you can't find enough info in the OVF howto on mapserver.gis.umn.edu or in the OGR VRT driver docs. 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 | President OSGeo, http://osgeo.org From bthoen at GISNET.COM Fri Jul 27 10:29:28 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 27 Jul 2007 11:29:28 -0600 Subject: How to Fix Ratty Line Rendering in WMS? - Redux In-Reply-To: <46A8FE15.9080808@hostgis.com> Message-ID: I've now posted some images showing the problem at http://www.gisnet.com/wms_examples/. To summarize the problem, I've set up a MapServer WMS Server that's got road data in native MapInfo format with a coordinate system based on Lat/Long (EPSG:4269). When I display it in a MapServer client map using the same projection EPSG:4269, the line work looks nice and clean. However, if I try to use a different projection in my client like EPSG:2163 (Lambert), the lines are pretty shabby looking. I'm not using transparency or antialiasing (I couldn't get that to work in the WMS anyway). The WMS produces png images, and my OUTPUTFORMAT directive in my WMS' MAP file :looks like: OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE RGB EXTENSION "png" END My MapServer installation details: MapServer version 4.10.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=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE Does anyone know what's causing the lines to come out so ratty in the 2163 projection or how to fix it? - Bill Thoen Gregor Mosheh wrote: > Bill Thoen wrote: >> But now my problem is that linework from my WMS looks pretty ratty >> compared to using the same data in vector form. Is there any fix for >> this? How can I produce smooth road lines? > > Are you using transparency? I find that antialiasing and transparency > just don't work well together; the antialiasing gets turned > transparent, which makes it look awful. I'd love to hear advice on > this topic, as I have similar issues with fonts and symbols looking > crummy under transparency. > > If it's not transparency, how about your image format? Are you using > JPEG? JPEG is nice stuff, but you've probably seen JPEGs that get all > crummy if someone tried to compress too hard. Try setting the > OUTPUTFORMAT options to turn up the JPEG quality to 100. > > Anything beyond that, we'd probably need to know a thing or two about > your image format, maybe see an example of it, ... > From dmorissette at MAPGEARS.COM Fri Jul 27 10:37:41 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Fri, 27 Jul 2007 13:37:41 -0400 Subject: How to Fix Ratty Line Rendering in WMS? - Redux In-Reply-To: <46AA2B78.3060102@gisnet.com> Message-ID: Bill Thoen wrote: > I've now posted some images showing the problem at > http://www.gisnet.com/wms_examples/. > > To summarize the problem, I've set up a MapServer WMS Server that's got > road data in native MapInfo format with a coordinate system based on > Lat/Long (EPSG:4269). When I display it in a MapServer client map using > the same projection EPSG:4269, the line work looks nice and clean. > However, if I try to use a different projection in my client like > EPSG:2163 (Lambert), the lines are pretty shabby looking. > Did you list EPSG:2163 in the wms_srs metadata of the CONNECTIONTYPE WMS layer in you client mapfile? The "wms_srs" metadata in a client WMS connection layer definition is used to list all the projections (SRS) supported by the remote server. It's a space-separated list, e.g. LAYER ... METADATA "wms_srs" "EPSGL4326 EPSG:4269 EPSG:2163" ... END ... END If the requested SRS is not found in this list then MapServer concludes that the remote server doesn't support that projection and then it uses the layer's default SRS for its GetMap call to the remote server and then reprojects the resulting image on the fly. This is probably what's happening here and explains the shabby looking lines. Daniel -- Daniel Morissette http://www.mapgears.com/ From bthoen at GISNET.COM Fri Jul 27 11:00:16 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 27 Jul 2007 12:00:16 -0600 Subject: How to Fix Ratty Line Rendering in WMS? - Redux In-Reply-To: <46AA2D65.20201@mapgears.com> Message-ID: I hadn't done that, but when I did, I got an error printed on the map: "Invalid SRS given. SRS must be valid for all requested layers" I also have EPSG:2163 listed as one of the option in the WEB METADATA of my WMS MAP file. Do I need to add it somewhere in my WMS layers definitions too? Daniel Morissette wrote: > Bill Thoen wrote: >> I've now posted some images showing the problem at >> http://www.gisnet.com/wms_examples/. >> >> To summarize the problem, I've set up a MapServer WMS Server that's >> got road data in native MapInfo format with a coordinate system based >> on Lat/Long (EPSG:4269). When I display it in a MapServer client map >> using the same projection EPSG:4269, the line work looks nice and >> clean. However, if I try to use a different projection in my client >> like EPSG:2163 (Lambert), the lines are pretty shabby looking. >> > > Did you list EPSG:2163 in the wms_srs metadata of the CONNECTIONTYPE > WMS layer in you client mapfile? > > The "wms_srs" metadata in a client WMS connection layer definition is > used to list all the projections (SRS) supported by the remote server. > It's a space-separated list, e.g. > > LAYER > ... > METADATA > "wms_srs" "EPSGL4326 EPSG:4269 EPSG:2163" > ... > END > ... > END > > If the requested SRS is not found in this list then MapServer > concludes that the remote server doesn't support that projection and > then it uses the layer's default SRS for its GetMap call to the remote > server and then reprojects the resulting image on the fly. > > This is probably what's happening here and explains the shabby looking > lines. > > Daniel From bthoen at GISNET.COM Fri Jul 27 11:03:17 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 27 Jul 2007 12:03:17 -0600 Subject: How to Fix Ratty Line Rendering in WMS? - Redux In-Reply-To: <46AA32B0.8010209@gisnet.com> Message-ID: Bill Thoen wrote: > I hadn't done that, but when I did, I got an error printed on the map: > "Invalid SRS given. SRS must be valid for all requested layers" > > I also have EPSG:2163 listed as one of the option in the WEB METADATA > of my WMS MAP file. Do I need to add it somewhere in my WMS layers > definitions too? I got it now. It also has to be listed in the WMS layers metadata section. From bassotti at YAHOO.COM Fri Jul 27 11:04:37 2007 From: bassotti at YAHOO.COM (Guido Bassotti) Date: Fri, 27 Jul 2007 11:04:37 -0700 Subject: URL Map Download Message-ID: Dear mapserver users, I would like to know, if it is posible to download a full map file using a URL query in a mapserver I want to download a mapserv generated map at the maximum size and resolution possible This way, the users could choose the layers they want and download an entire map that they could plot. Any help is very much appreciated Regards Guido --------------------------------- Luggage? GPS? Comic books? Check out fitting gifts for grads at Yahoo! Search. -------------- next part -------------- An HTML attachment was scrubbed... URL: From Jukka.Rahkonen at MMMTIKE.FI Fri Jul 27 11:36:04 2007 From: Jukka.Rahkonen at MMMTIKE.FI (Rahkonen Jukka) Date: Fri, 27 Jul 2007 21:36:04 +0300 Subject: URL Map Download Message-ID: Hi, Perhaps setting geotiff OUTPUTFORMAT in mapfile and using Mapserver cgi might do about what you want? An excerpt from mapfile documentation about defining geotiff output: OUTPUTFORMAT NAME GTiff DRIVER "GDAL/GTiff" MIMETYPE "image/tiff" IMAGEMODE RGB EXTENSION "tif" END Then your user should send in some way the request using option &OUTPUTFORMAT=GTiff. Also the application should take suitable values from the user interface for MAPEXT and MAPSIZE values. -Jukka Rahkonen- -----Original Message----- From: UMN MapServer Users List on behalf of Guido Bassotti Sent: Fri 27.7.2007 21:04 To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: [UMN_MAPSERVER-USERS] URL Map Download Dear mapserver users, I would like to know, if it is posible to download a full map file using a URL query in a mapserver I want to download a mapserv generated map at the maximum size and resolution possible This way, the users could choose the layers they want and download an entire map that they could plot. Any help is very much appreciated Regards Guido --------------------------------- Luggage? GPS? Comic books? Check out fitting gifts for grads at Yahoo! Search. From dmorissette at MAPGEARS.COM Fri Jul 27 12:15:10 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Fri, 27 Jul 2007 15:15:10 -0400 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46A8B55D.4000009@hostgis.com> Message-ID: Gregor Mosheh wrote: >> - MS RFC 19: Added Style and Label attribute binding > > What does this mean exactly? > Excerpt from the MIGRATION_GUIDE.TXT, now online at: http://mapserver.gis.umn.edu/development/release_plans/mapserver_5_0/migration_guide_410_50/ ---------------------------------------- Attribute Bindings: In an effort to stem the tide of keyword overload and add functionality MapServer 5.0 supports a new method of binding feature attributes to STYLE and LABEL properties. In the past keywords like ANGLEITEM or LABELSIZEITEM were used, now you denote the attribute in the context of the property being bound. For example, to bind an attribute to a label size you'd do: LABEL ... SIZE [mySizeItem] END The []'s denote a binding (as with logical expressions). The following keywords are no longer supported and their presence will throw an error: Layer: LABELANGLEITEM, LABELSIZEITEM Style: ANGLEITEM, SIZEITEM The following properties can accept bindings: Style: angle, color, outlinecolor, size, symbol Label: angle, color, outlinecolor, size, font, priority Colors may be given as a hex value (e.g. #FFFFFF) or an RGB triplet (e.g. 255 255 255). ---------------------------------------- Daniel -- Daniel Morissette http://www.mapgears.com/ From gregor at HOSTGIS.COM Fri Jul 27 12:19:33 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Fri, 27 Jul 2007 13:19:33 -0600 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46AA443E.2060501@mapgears.com> Message-ID: Daniel Morissette wrote: > Gregor Mosheh wrote: >>> - MS RFC 19: Added Style and Label attribute binding Ah, it means that we replaced labelitem and the like with a smoother syntax, e.g. LABEL [name] Very very nice! -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From efujioka at DUKE.EDU Fri Jul 27 14:40:51 2007 From: efujioka at DUKE.EDU (Ei Fujioka) Date: Fri, 27 Jul 2007 17:40:51 -0400 Subject: Antarctica disappears with Mercator projection Message-ID: Hello experts, I'm developing an online mapper where you can change the projection. http://seamap.env.duke.edu/prod/mapservice/onlinemap/oms_main_v2.phtml The default projection is the geographic WGS84. You can change this by switching to [OPTIONS] tab and hit [Projection] button. In the popup window, if you choose "World Mercator", Antarctica disappears. I tried to change latitude values in EXTENT (e.g. -90, -85, etc.) but didn't make difference. Any idea why this happens and how to work around? It's an ESRI's shapefile and Antarctica is projected properly in Mercator with ArcGIS. The excerpt from mapfile below. MAP NAME "OBIS MAP" UNITS DD IMAGETYPE png EXTENT -180 -83.6236 180 83.6236 PROJECTION "init=epsg:4326" END LAYER NAME "Continents" STATUS DEFAULT DATA "countries" TYPE POLYGON TRANSPARENCY 0 PROJECTION "init=epsg:4326" END CLASS NAME "Countries" COLOR 204 204 204 OUTLINECOLOR 153 153 153 END METADATA "wms_abstract" "Countries" "TITLE" "Countries" "wms_title" "Countries" END END END Thanks, Ei -- ====================== Ei Fujioka Research Associate Duke University (919) 613-8021 efujioka at duke.edu ====================== From bthoen at GISNET.COM Fri Jul 27 15:26:09 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Fri, 27 Jul 2007 16:26:09 -0600 Subject: The Scale Template Variable Message-ID: Is the [scale] template variable the denominator in a standard ratio scale? E.g. when it says 250000, that means the map is displayed at a 1:250K scale? From samhiatt at GMAIL.COM Fri Jul 27 16:59:51 2007 From: samhiatt at GMAIL.COM (Samuel Hiatt) Date: Fri, 27 Jul 2007 16:59:51 -0700 Subject: Coloring 32bit floating point rasters In-Reply-To: <1b181a320707271658o223b48o1a4e346ec439effc@mail.gmail.com> Message-ID: Hi all! I am trying to serve up several floating point 32-bit rasters and I am curious to know the best way to render these images in color. I've read that it is possible to use a LUT to define the colors of a pseudo-color image, but only for byte data (256 colors). Has anyone already tackled this problem of displaying these float32 rasters? What do y'all think is the best way to do it? Thanks! Sam -------------- next part -------------- An HTML attachment was scrubbed... URL: From warmerdam at POBOX.COM Sat Jul 28 07:15:24 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Sat, 28 Jul 2007 10:15:24 -0400 Subject: Coloring 32bit floating point rasters In-Reply-To: <1b181a320707271659v4416fddax6df96b7994a3d7e7@mail.gmail.com> Message-ID: Samuel Hiatt wrote: > Hi all! > > I am trying to serve up several floating point 32-bit rasters and I am > curious to know the best way to render these images in color. I've read > that it is possible to use a LUT to define the colors of a pseudo-color > image, but only for byte data (256 colors). > > Has anyone already tackled this problem of displaying these float32 > rasters? What do y'all think is the best way to do it? Sam, I was going to suggested using the RFC 6 colorrange mechanism, but on reflection, I'm pretty sure I never implemented it for raster data. The "normal" approach is just to use quite a few classes - one per color. It's hard to have enough classes to give really continuous color, but you can do a bunch of graduations and assign each range a nice name (or numeric value range in text) to appear in the legend. 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 | President OSGeo, http://osgeo.org From bthoen at GISNET.COM Sat Jul 28 14:38:38 2007 From: bthoen at GISNET.COM (Bill Thoen) Date: Sat, 28 Jul 2007 15:38:38 -0600 Subject: Problem Opening MapInfo Table Message-ID: Does anyone know if there are issues opening a MapInfo seamlesss table of views? I've got a seamless table of roads in several states that's refusing to draw in a map widnow. The roads tables are standard MapInfo views, and they are collected together into a seamless table. Other seamless table of normal tables do work, but not this one. I just want to make sure this format isn't too weird for MapServer's OGR CONNECTIONTYPEs. - Bill Thoen From interfacemirror at GMAIL.COM Sat Jul 28 23:06:14 2007 From: interfacemirror at GMAIL.COM (Jandost Khoso) Date: Sun, 29 Jul 2007 10:06:14 +0400 Subject: Map Server performance Message-ID: Hi, Can anybody guide me how can i increase performance of Map Server? Actually i have a huge map data in PostGre database when i zoom-in into map Map Server speed is very good but as i zoom-out performance drops drastically. Is there anyway to increase performance? Many thanks in advance. Kindest Regards, -------------- next part -------------- An HTML attachment was scrubbed... URL: From micha at ARAVA.CO.IL Sun Jul 29 06:23:01 2007 From: micha at ARAVA.CO.IL (Micha Silver) Date: Sun, 29 Jul 2007 08:23:01 -0500 Subject: linked tables and spatial queries Message-ID: On Thu, 28 Jun 2007 18:50:47 -0700, Dylan Beaudette wrote: > >I was in need of this type of functionality, and found it through two methods: > >1. define a query template in your mapfile, and have it redirect the user to a >PHP page which can do related DB lookups and presentation. You can pass along >mapserver query results on the URL. > >2. use something like ka-map and adjust how the query system displays the >results in the left-hand side panel. I modified the query functions such that >all searching and presentation was done via postgres+PHP. > >let me know if you need the details. > Hi Dylan: I'm working on a new site (displaying water quality for farmers around our region). I've got the mapserver / *.map file set up OK. I've installed ka-map for it's well designed interface. And the layers display as I expect. But I'm stuck with getting the results from spatial queries... My layers are in postgis, and as per your previous post on the list, I've split all the layers into two GROUPs, with one group of layers all set as "queryable" "true" in the mapfile. I've also got a simple html file as a template for each layer to show the data. Each html template file looks something like: Well name: [name]

  • Drill Depth = [drill_dept]
  • Aquifer = [aquifer_name]
  • Elevation = [elevation] where each item in [] is a column in the postgis table. When I use the query button in the ka-map interface, what I get back (in the left panel) is : Layer Name: Wells results: 1 So it looks like the querying is working in general, just not retrieving the columns of data. Can you give me any pointers? I'd be glad to try to rewrite the map_query.php stuff in ka-map if necessary, but what should that script do exactly? The option to just write a query template in php is tempting but ka-map seems to be ignoring that TEMPLATE file. Excuse the long post. Any tips will be most appreciated. Regards, Micha >cheers, > >dylan > > >-- >Dylan Beaudette >Soils and Biogeochemistry Graduate Group >University of California at Davis >530.754.7341 From gregor at HOSTGIS.COM Sun Jul 29 10:56:54 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Sun, 29 Jul 2007 11:56:54 -0600 Subject: Map Server performance In-Reply-To: Message-ID: Jandost Khoso wrote: > Can anybody guide me how can i increase performance of Map Server? This is a really common question, yet it's not in the FAQ. So I've added it: http://mapserver.gis.umn.edu/docs/faq/performance It'll be linked into the main FAQ page when they've reviewed it. If anyone has additional input or changes to it, feel free to jump in and edit, or add comments. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From volpicelli at OATO.INAF.IT Sun Jul 29 11:44:32 2007 From: volpicelli at OATO.INAF.IT (Antonio) Date: Sun, 29 Jul 2007 20:44:32 +0200 Subject: Map Server performance In-Reply-To: <46ACD4E6.8010105@hostgis.com> Message-ID: Hi Gregor, I am interesting about MapServer performance too. I tried to follow your link, I made the registration too but I am not able to see any document. Ciao Antonio Gregor Mosheh wrote: > Jandost Khoso wrote: > > Can anybody guide me how can i increase performance of Map Server? > > This is a really common question, yet it's not in the FAQ. > So I've added it: > http://mapserver.gis.umn.edu/docs/faq/performance > > It'll be linked into the main FAQ page when they've reviewed it. If > anyone has additional input or changes to it, feel free to jump in and > edit, or add comments. > -- /-------------------------------------------------------\ PLEASE WARNING: E-mail is CHANGED volpicelli at oato.inaf.it /-------------------------------------------------------\ From woklist at KYNGCHAOS.COM Sun Jul 29 12:46:23 2007 From: woklist at KYNGCHAOS.COM (William Kyngesburye) Date: Sun, 29 Jul 2007 14:46:23 -0500 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46A7B22E.7080204@mapgears.com> Message-ID: OSX binaries ready on my site. I'll try to keep up to date on the betas. For now I did only the framework build (aka dynamic libraries). If problems are found that are definitely caused by this and I can't fix them, I'll make the normal static lib build. I don't have much time for run tests, but I'll see if I can tackle what's on the checklist over the coming weeks. I wanted to at least add a couple Mac notes to the checklist, even after logging in I didn't see an edit link for the page. lack of permissions? OSX notes: SDE - not available for OSX (or maybe note which platforms it is only available for) OCI - only available for PPC OSX On Jul 25, 2007, at 3:27 PM, Daniel Morissette wrote: > MapServer 5.0.0-beta1 release: > ------------------------------ > > Today we are also releasing MapServer 5.0.0-beta1. The source > package and links to binaries are available at: > http://mapserver.gis.umn.edu/download/beta > ----- William Kyngesburye http://www.kyngchaos.com/ Earth: "Mostly harmless" - revised entry in the HitchHiker's Guide to the Galaxy From pcreso at PCRESO.COM Sun Jul 29 20:00:30 2007 From: pcreso at PCRESO.COM (Brent Wood) Date: Sun, 29 Jul 2007 20:00:30 -0700 Subject: NY Times article on amateurs making maps on the internet Message-ID: This article from NY Times on amateur web mapping introduces some of the things being done with free & FOSS spatial data management & web mapping tools. http://www.nytimes.com/2007/07/27/technology/27maps.html A fast growing area of FOSS tools where NZ is well behind many other countries. Cheers, Brent Wood From correosig at GMAIL.COM Sun Jul 29 23:14:36 2007 From: correosig at GMAIL.COM (Ruben Pardo) Date: Mon, 30 Jul 2007 08:14:36 +0200 Subject: Authentication Message-ID: Hi everybody, We want to protect a number of layers to non-authenticate users. We have an apache tomcat on an external server that generate request to our apache+mapserver server. We cannot use mapscript. I want to ask how people use to protect layers served by mapserver? is there any mechanism inside mapserver for this? thanks very much. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gregor at HOSTGIS.COM Sun Jul 29 23:30:08 2007 From: gregor at HOSTGIS.COM (Gregor Mosheh) Date: Mon, 30 Jul 2007 00:30:08 -0600 Subject: Authentication In-Reply-To: <736d33ec0707292314i37cb2404rea15653f7184dec0@mail.gmail.com> Message-ID: Ruben Pardo wrote: > We want to protect a number of layers to non-authenticate users. > I want to ask how people use to protect layers served by mapserver? is > there any mechanism inside mapserver for this? There sure isn't. Authentication has to be done at some other layer, typically the webserver layer. If Tomcat is generating the requests, then that'd be the best place to do the authentication. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From correosig at GMAIL.COM Mon Jul 30 00:59:36 2007 From: correosig at GMAIL.COM (Ruben Pardo) Date: Mon, 30 Jul 2007 09:59:36 +0200 Subject: Authentication In-Reply-To: <46AD8570.7090303@hostgis.com> Message-ID: but if the request is generated in other layer, people can ask with a browser to the mapserver changing the name of the layer on the WMS, We have a WMS accesible with some layer to everybody and other to authenticate users. we are thinking on using a remoteWMS like deegree (with WASS) with mapserver, a single sign-on or something on apache (mod_auth or similiar). but we want to know how people use to implement this issue. Thanks. 2007/7/30, Gregor Mosheh : > > Ruben Pardo wrote: > > We want to protect a number of layers to non-authenticate users. > > I want to ask how people use to protect layers served by mapserver? is > > there any mechanism inside mapserver for this? > > There sure isn't. Authentication has to be done at some other layer, > typically the webserver layer. If Tomcat is generating the requests, > then that'd be the best place to do the authentication. > > -- > Gregor Mosheh / Greg Allensworth > System Administrator, HostGIS cartographic development & hosting services > http://www.HostGIS.com/ > > "Remember that no one cares if you can back up, > only if you can restore." - AMANDA > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hulst at ARGOSS.NL Mon Jul 30 00:57:53 2007 From: hulst at ARGOSS.NL (A.Th.C. Hulst) Date: Mon, 30 Jul 2007 09:57:53 +0200 Subject: Coloring 32bit floating point rasters In-Reply-To: <46AB4F7C.2020305@pobox.com> Message-ID: On Saturday 28 July 2007 16:15:24 Frank Warmerdam wrote: > Samuel Hiatt wrote: > > Hi all! > > > > I am trying to serve up several floating point 32-bit rasters and I am > > curious to know the best way to render these images in color. I've read > > that it is possible to use a LUT to define the colors of a pseudo-color > > image, but only for byte data (256 colors). > > > > Has anyone already tackled this problem of displaying these float32 > > rasters? What do y'all think is the best way to do it? I've displayed floating point data with the latest SVN version using the LUT directive. That works pretty well. LAYER NAME "Hs" DATA "netCDF:/var/www/mapserver/data/windwave/ww3_output.nc:sign_wave_height" PROCESSING "SCALE=0.1,10" PROCESSING "SCALE_BUCKETS=200" PROCESSING "BANDS=1,1,1" PROCESSING "LUT_1=96:0,157:255,221:255,255:240" PROCESSING "LUT_2=29:0,93:255,157:255,221:0,255:0" PROCESSING "LUT_3=1:255,93:255,157:0,255:0" TYPE RASTER STATUS ON OFFSITE 0 0 0 TEMPLATE "rquery.html" END Cheers, Sander From Jukka.Rahkonen at MMMTIKE.FI Mon Jul 30 01:48:53 2007 From: Jukka.Rahkonen at MMMTIKE.FI (Rahkonen Jukka) Date: Mon, 30 Jul 2007 11:48:53 +0300 Subject: Authentication Message-ID: Hi, Perhaps you could make a separate WMS-service for each user group you have? With Mapserver it is easy because you only need to create a new mapfile and then control which mapfile the current user can access. This should at least prevent fiddling with layer names. We are using proxy approach which creates a facede server on a local port after successful login and we are rather satisfied with that. System is self made but it is in principle close to OWS-proxy by deegree, of Web security service by 52nort.org. -Jukka Rahkonen- ________________________________ L?hett?j?: UMN MapServer Users List puolesta: Ruben Pardo L?hetetty: ma 30.7.2007 10:59 Vastaanottaja: MAPSERVER-USERS at LISTS.UMN.EDU Aihe: Re: [UMN_MAPSERVER-USERS] Authentication but if the request is generated in other layer, people can ask with a browser to the mapserver changing the name of the layer on the WMS, We have a WMS accesible with some layer to everybody and other to authenticate users. we are thinking on using a remoteWMS like deegree (with WASS) with mapserver, a single sign-on or something on apache (mod_auth or similiar). but we want to know how people use to implement this issue. Thanks. 2007/7/30, Gregor Mosheh : Ruben Pardo wrote: > We want to protect a number of layers to non-authenticate users. > I want to ask how people use to protect layers served by mapserver? is > there any mechanism inside mapserver for this? There sure isn't. Authentication has to be done at some other layer, typically the webserver layer. If Tomcat is generating the requests, then that'd be the best place to do the authentication. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From correosig at GMAIL.COM Mon Jul 30 02:04:26 2007 From: correosig at GMAIL.COM (Ruben Pardo) Date: Mon, 30 Jul 2007 11:04:26 +0200 Subject: Authentication In-Reply-To: Message-ID: Our problem is that we dinamically have to create user group authorization with different layers, in that case we have to create a mapfile dinamically with the layers and configure the control access (with apache authorization?) of the user. The proxy approach is one of the option that we are considering, thanks. 2007/7/30, Rahkonen Jukka : > > Hi, > > Perhaps you could make a separate WMS-service for each user group you > have? With Mapserver it is easy because you only need to create a new > mapfile and then control which mapfile the current user can access. This > should at least prevent fiddling with layer names. > > We are using proxy approach which creates a facede server on a local port > after successful login and we are rather satisfied with that. System is self > made but it is in principle close to OWS-proxy by deegree, of Web security > service by 52nort.org. > > -Jukka Rahkonen- > > > ________________________________ > > L?hett?j?: UMN MapServer Users List puolesta: Ruben Pardo > L?hetetty: ma 30.7.2007 10:59 > Vastaanottaja: MAPSERVER-USERS at LISTS.UMN.EDU > Aihe: Re: [UMN_MAPSERVER-USERS] Authentication > > > but if the request is generated in other layer, people can ask with a > browser to the mapserver changing the name of the layer on the WMS, > We have a WMS accesible with some layer to everybody and other to > authenticate users. > we are thinking on using a remoteWMS like deegree (with WASS) with > mapserver, a single sign-on or something on apache (mod_auth or similiar). > but we want to know how people use to implement this issue. > > Thanks. > > > 2007/7/30, Gregor Mosheh : > > Ruben Pardo wrote: > > We want to protect a number of layers to non-authenticate users. > > I want to ask how people use to protect layers served by > mapserver? is > > there any mechanism inside mapserver for this? > > There sure isn't. Authentication has to be done at some other > layer, > typically the webserver layer. If Tomcat is generating the > requests, > then that'd be the best place to do the authentication. > > -- > Gregor Mosheh / Greg Allensworth > System Administrator, HostGIS cartographic development & hosting > services > http://www.HostGIS.com/ > > "Remember that no one cares if you can back up, > only if you can restore." - AMANDA > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gilles.bassiere at MAKINA-CORPUS.COM Mon Jul 30 02:58:00 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?ISO-8859-15?Q?Gilles_Bassi=E8re?=) Date: Mon, 30 Jul 2007 11:58:00 +0200 Subject: Polygon outline width In-Reply-To: Message-ID: Hi Flavio Thanks for your help. Unfortunately, it has no effect on my map. I tried to set this value for OUTLINE in the CLASS element, then in the STYLE element but rivers still appear very thick on my map when the scale in large... Actually, the same map is produced with OUTLINE -1 0 0 or without. =( As explained in the FAQ, I tried to set up a circle symbol but it seems to work only for true lines, not for polygon outlines. Any other idea ? Gilles > Hi Gilles > > just set the OUTLINECOLOR to -1 0 0. > > Mit freundlichem Gruss / Best Regards > Flavio Hendry > > ---------------------------------------------------------------- > TYDAC Web-Site: http://www.tydac.ch > TYDAC MapServer: http://www.mapserver.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 > ---------------------------------------------------------------- > > > -----Original Message----- > From: Gilles Bassi?re > To: MAPSERVER-USERS at LISTS.UMN.EDU > Date: Fri, 27 Jul 2007 15:09:22 +0200 > Subject: [UMN_MAPSERVER-USERS] Polygon outline width > > >> Hi there, >> >> I wonder whether it's possible to have no outline for a polygon. >> My first attempt was to set the WIDTH property of the STYLE element >> to 0 >> in my MapFile but I got an error from MapServer, it seems to be an >> invalid value. >> As I might need to display the same data through GeoServer, I decided >> to >> move all style information to a SLD. I wrote the following SLD : >> >> >> > version="1.0.0" >> xmlns="http://www.opengis.net/sld" >> xmlns:gml="http://www.opengis.net/gml" >> xmlns:ogc="http://www.opengis.net/ogc" >> xmlns:xlink="http://www.w3.org/1999/xlink" >> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >> xsi:schemaLocation="http://www.opengis.net/sld >> http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" >> > >> >> >> water >> >> >> >> Water bodies >> >> >> #99b3cc >> >> >> > name="stroke">#0000FF >> > name="stroke-width">0.0 >> >> >> >> >> >> >> >> >> My map is rendered without any error but there is still an outline. I >> tried to set opacity to 0.0 but it's not supported by MapServer. I >> can >> set the same color for stroke and fill but having a 1px outline means >> that a very thin river is rendered with, at least, a 2 pixels width >> and >> this is not really nice when viewing the map at higher scales... >> If I remove the Stroke element Mapserver seems to set automatically a >> 1px outline using the fill color. >> >> Does anyone know a workaround to get rid of polygon outlines ? >> >> -- >> Gilles Bassiere >> MAKINA CORPUS >> 30 rue des Jeuneurs >> FR-75011 PARIS >> http://www.makina-corpus.com >> -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From gilles.bassiere at MAKINA-CORPUS.COM Mon Jul 30 03:11:50 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?ISO-8859-15?Q?Gilles_Bassi=E8re?=) Date: Mon, 30 Jul 2007 12:11:50 +0200 Subject: Polygon outline width In-Reply-To: <46ADB628.2080901@makina-corpus.com> Message-ID: Gilles Bassi?re wrote: > Hi Flavio > > Thanks for your help. Unfortunately, it has no effect on my map. I > tried to set this value for OUTLINE in the CLASS element, then in the > STYLE element but rivers still appear very thick on my map when the > scale in large... Actually, the same map is produced with OUTLINE -1 0 > 0 or without. =( Oops, I meant OUTLINECOLOR of course... Yves, I also tried the -1 -1 -1 value but I can't see any change on my map =( > As explained in the FAQ, I tried to set up a circle symbol but it > seems to work only for true lines, not for polygon outlines. > > Any other idea ? > > Gilles >> Hi Gilles >> >> just set the OUTLINECOLOR to -1 0 0. >> >> Mit freundlichem Gruss / Best Regards >> Flavio Hendry >> >> ---------------------------------------------------------------- >> TYDAC Web-Site: http://www.tydac.ch >> TYDAC MapServer: http://www.mapserver.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 >> ---------------------------------------------------------------- >> >> >> -----Original Message----- >> From: Gilles Bassi?re >> To: MAPSERVER-USERS at LISTS.UMN.EDU >> Date: Fri, 27 Jul 2007 15:09:22 +0200 >> Subject: [UMN_MAPSERVER-USERS] Polygon outline width >> >> >>> Hi there, >>> >>> I wonder whether it's possible to have no outline for a polygon. >>> My first attempt was to set the WIDTH property of the STYLE element >>> to 0 in my MapFile but I got an error from MapServer, it seems to be >>> an invalid value. >>> As I might need to display the same data through GeoServer, I decided >>> to move all style information to a SLD. I wrote the following SLD : >>> >>> >>> >> version="1.0.0" >>> xmlns="http://www.opengis.net/sld" >>> xmlns:gml="http://www.opengis.net/gml" >>> xmlns:ogc="http://www.opengis.net/ogc" >>> xmlns:xlink="http://www.w3.org/1999/xlink" >>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >>> xsi:schemaLocation="http://www.opengis.net/sld >>> http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" >>> > >>> >>> >>> water >>> >>> >>> >>> Water bodies >>> >>> >>> #99b3cc >>> >>> >>> >> name="stroke">#0000FF >>> >> name="stroke-width">0.0 >>> >>> >>> >>> >>> >>> >>> >>> >>> My map is rendered without any error but there is still an outline. I >>> tried to set opacity to 0.0 but it's not supported by MapServer. I >>> can set the same color for stroke and fill but having a 1px outline >>> means >>> that a very thin river is rendered with, at least, a 2 pixels width >>> and this is not really nice when viewing the map at higher scales... >>> If I remove the Stroke element Mapserver seems to set automatically a >>> 1px outline using the fill color. >>> >>> Does anyone know a workaround to get rid of polygon outlines ? >>> >>> -- >>> Gilles Bassiere >>> MAKINA CORPUS >>> 30 rue des Jeuneurs >>> FR-75011 PARIS >>> http://www.makina-corpus.com >>> -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From eltalpdopat at GMAIL.COM Mon Jul 30 04:54:15 2007 From: eltalpdopat at GMAIL.COM (giska) Date: Mon, 30 Jul 2007 04:54:15 -0700 Subject: Problem with two point layers... Message-ID: Hi to everyone, i'm working in a project with Mapserver and I have a problem with two points layer. When I open the page, they show perfectly with their labels but when i zoom in a extension when all the elements of a layer aren't in, directly Mapserver don't show any element of the layer. I am also working with poligons and lines layers and i don't have any problem with them. The 'Status' is DEFAULT in all of the layers and the projetion is the same in all layers: ED50 UTM Zone 30N. What could the problem be? Thank you in advance. -- View this message in context: http://www.nabble.com/Problem-with-two-point-layers...-tf4169641.html#a11862296 Sent from the Mapserver - User mailing list archive at Nabble.com. From eltalpdopat at GMAIL.COM Mon Jul 30 04:58:41 2007 From: eltalpdopat at GMAIL.COM (giska) Date: Mon, 30 Jul 2007 04:58:41 -0700 Subject: points disappearing when zooming in In-Reply-To: <18287.145.50.39.8.1155130142.squirrel@webmail.xs4all.nl> Message-ID: I think i have the same problem...Did you solve it? Bart van den Eijnden (OSGIS) wrote: > > Hi list, > > I have a strange problem. > > Say at a scale of 1:200000 a whole lot of points are displayed. Then I > zoom in at the cloud of points, to a scale of say 1:20000, and no points > are displayed anymore. > > The layer has no MINSCALE or MAXSCALE settings, also the CLASSES have > none. > > How can this be? Any thoughts? > > For reference, the layer definition: > > LAYER > METADATA > "WMS_LAYER_GROUP" "/WEGGEG" > "WFS_MAXFEATURES" "50" > "OWS_TITLE" "Portalen" > "OWS_ABSTRACT" "Portalen punt" > "WMS_METADATAURL_TYPE" "TC211" > "WMS_METADATAURL_FORMAT" "text/xml" > "WMS_METADATAURL_HREF" > "http://test.intranet.rijkswaterstaat.nl/apps/geoservices/metadata/basispakket/AAA86" > "GML_INCLUDE_ITEMS" "all" > "GML_GEOMETRIES" "geometry" > "GML_GEOMETRY_TYPE" "multipoint" > "OWS_EXTENT" "10000 305000 280000 619000" > END > PROJECTION > "init=epsg:28992" > END > NAME "AAA86" > DATA "weggeg/geogegevens/shapefile/weggeg_wegvakniveau/portalen" > STATUS ON > TYPE POINT > UNITS METERS > SIZEUNITS PIXELS > TOLERANCE 5 > TOLERANCEUNITS PIXELS > TEMPLATE "blank.html" > DUMP TRUE > CLASSITEM "OMSCHR" > CLASS > NAME "staal (losstaande stalen constructie)" > EXPRESSION "staal (losstaande stalen constructie)" > STYLE > SYMBOL "square" > COLOR 225 225 225 > SIZE 6 > END > STYLE > SYMBOL "square" > COLOR 0 92 230 > SIZE 4 > END > END > CLASS > NAME "viaduct (aan de zijkant van een viaduct)" > EXPRESSION "viaduct (aan de zijkant van een viaduct)" > STYLE > SYMBOL "square" > COLOR 225 225 225 > SIZE 6 > END > STYLE > SYMBOL "square" > COLOR 168 112 0 > SIZE 4 > END > END > END > > Best regards, > Bart > > -- View this message in context: http://www.nabble.com/points-disappearing-when-zooming-in-tf2078791.html#a11862403 Sent from the Mapserver - User mailing list archive at Nabble.com. From mlinden at ZEELANDNET.NL Mon Jul 30 05:26:22 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Mon, 30 Jul 2007 14:26:22 +0200 Subject: Cannot zoom in any further In-Reply-To: <11862403.post@talk.nabble.com> Message-ID: Hello list, I have a mapfile that spans the entire world, holds 2 attached WMS layers and 3 postGIS layers. The mapfile extend is set to -180 -90 180 90 My postGIS layers contain tiny little elements ordered in projects of approx. 1 km x 1 km in size. I use CartoWeb3 as my client. When I start zooming in, I reach a certain level where the image refuses to go into more detail. I can keep clicking my Cartoweb zoom in button, and I see the image refreshing, but it doesn't change scale or content. Is this a zoom in limit set by the fact that I use global extends? Or is there no such limit in Mapserver and do I have to look in more detail into my Cartoweb3 configuration? From bartvde at OSGIS.NL Mon Jul 30 05:53:51 2007 From: bartvde at OSGIS.NL (Bart van den Eijnden (OSGIS)) Date: Mon, 30 Jul 2007 14:53:51 +0200 Subject: Cannot zoom in any further Message-ID: Hi Milo, I know of no such limit in Mapserver, so I expect this to be on the Cartoweb side. Best regards, Bart -- Bart van den Eijnden OSGIS, Open Source GIS http://www.osgis.nl --------- Oorspronkelijk bericht -------- Van: Milo van der Linden Naar: MAPSERVER-USERS at LISTS.UMN.EDU Onderwerp: [UMN_MAPSERVER-USERS] Cannot zoom in any further Datum: 30/07/07 10:27 > Hello list, > > > I have a mapfile that spans the entire world, holds 2 attached WMS > layers and 3 postGIS layers. The mapfile extend is set to -180 -90 180 90 > My postGIS layers contain tiny little elements ordered in projects of > approx. 1 km x 1 km in size. > > I use CartoWeb3 as my client. > > When I start zooming in, I reach a certain level where the image refuses > to go into more detail. I can keep clicking my Cartoweb zoom in button, > and I see the image refreshing, but it doesn't change scale or content. From gilles.bassiere at MAKINA-CORPUS.COM Mon Jul 30 05:57:42 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?ISO-8859-15?Q?Gilles_Bassi=E8re?=) Date: Mon, 30 Jul 2007 14:57:42 +0200 Subject: Polygon outline width In-Reply-To: Message-ID: Here is my mapfile. The complete Mapfile has 8 other layers but I removed them in order to make it easy to read, anyway all layers have the same properties (only the color change). I also tried to set the OUTLINECOLOR property at the CLASS level and to use the value -1 0 0 but the outline is still not transparent. # WGS 84 (epsg:4326) MAP NAME "Test" IMAGETYPE "png" EXTENT 3.3 50.75 7.25 53.6 IMAGECOLOR 255 255 255 FONTSET "/home/gba/public_html/fonts.txt" SYMBOLSET "/home/gba/public_html/symbols.sym" UNITS dd PROJECTION "init=epsg:4326" END WEB IMAGEPATH "/home/gba/public_html/img/" IMAGEURL "/img/" METADATA "wms_title" "Road map" "wms_onlineresource" "http://localhost/~gba/cgi-bin/test.cgi?" "wms_srs" "epsg:4326" END END # Legend LEGEND KEYSIZE 10 5 LABEL TYPE bitmap SIZE medium COLOR 0 0 0 PARTIALS false END STATUS on END # Scale bar SCALEBAR IMAGECOLOR 255 255 255 LABEL COLOR 0 0 0 SIZE tiny END STYLE 1 SIZE 50 2 COLOR 0 0 0 UNITS meters INTERVALS 2 STATUS on END OUTPUTFORMAT NAME "png" DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE "rgba" EXTENSION "png" FORMATOPTION "transparent=on" FORMATOPTION "interlace=on" END ########################################################################## # Start of LAYER Definitions --------------------------------------------- ########################################################################## # LAYER 9 : water ------------------------------------- LAYER NAME "water" GROUP "background" CONNECTIONTYPE postgis CONNECTION "host=localhost dbname=test user=test password=xxxxx port=5432" DATA "wkb_geometry FROM water" STATUS on TYPE polygon TRANSPARENCY alpha PROJECTION "init=epsg:4326" END CLASS STYLE COLOR 153 179 204 OUTLINECOLOR -1 -1 -1 ANTIALIAS true END END METADATA "wms_title" "Water bodies" "wms_srs" "EPSG:4326" "wms_extent" "3.3 50.75 7.25 53.6" END END END # test URL (GetMap) : http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&request=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=600&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 > Hi Gilles > > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely should work. > > Mit freundlichem Gruss / Best Regards > Flavio Hendry > > ---------------------------------------------------------------- > TYDAC Web-Site: http://www.tydac.ch > TYDAC MapServer: http://www.mapserver.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 > ---------------------------------------------------------------- > > > -----Original Message----- > From: Gilles Bassi?re > To: Flavio Hendry > Cc: MAPSERVER-USERS at LISTS.UMN.EDU > Date: Mon, 30 Jul 2007 11:58:00 +0200 > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width > > >> Hi Flavio >> >> Thanks for your help. Unfortunately, it has no effect on my map. I >> tried >> to set this value for OUTLINE in the CLASS element, then in the STYLE >> element but rivers still appear very thick on my map when the scale >> in >> large... Actually, the same map is produced with OUTLINE -1 0 0 or >> without. =( >> >> As explained in the FAQ, I tried to set up a circle symbol but it >> seems >> to work only for true lines, not for polygon outlines. >> >> Any other idea ? >> >> Gilles >> >>> Hi Gilles >>> >>> just set the OUTLINECOLOR to -1 0 0. >>> >>> Mit freundlichem Gruss / Best Regards >>> Flavio Hendry >>> >>> ---------------------------------------------------------------- >>> TYDAC Web-Site: http://www.tydac.ch >>> TYDAC MapServer: http://www.mapserver.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 >>> ---------------------------------------------------------------- >>> >>> >>> -----Original Message----- >>> From: Gilles Bassi?re >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width >>> >>> >>> >>>> Hi there, >>>> >>>> I wonder whether it's possible to have no outline for a polygon. >>>> My first attempt was to set the WIDTH property of the STYLE >>>> >> element >> >>>> to 0 >>>> in my MapFile but I got an error from MapServer, it seems to be an >>>> invalid value. >>>> As I might need to display the same data through GeoServer, I >>>> >> decided >> >>>> to >>>> move all style information to a SLD. I wrote the following SLD : >>>> >>>> >>>> >>> version="1.0.0" >>>> xmlns="http://www.opengis.net/sld" >>>> xmlns:gml="http://www.opengis.net/gml" >>>> xmlns:ogc="http://www.opengis.net/ogc" >>>> xmlns:xlink="http://www.w3.org/1999/xlink" >>>> >>>> >> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >> >>>> xsi:schemaLocation="http://www.opengis.net/sld >>>> http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" >>>> > >>>> >>>> >>>> water >>>> >>>> >>>> >>>> Water bodies >>>> >>>> >>>> >>> >> name="fill">#99b3cc >> >>>> >>>> >>>> >>> name="stroke">#0000FF >>>> >>> name="stroke-width">0.0 >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> My map is rendered without any error but there is still an >>>> >> outline. I >> >>>> tried to set opacity to 0.0 but it's not supported by MapServer. I >>>> can >>>> set the same color for stroke and fill but having a 1px outline >>>> >> means >> >>>> that a very thin river is rendered with, at least, a 2 pixels >>>> >> width >> >>>> and >>>> this is not really nice when viewing the map at higher scales... >>>> If I remove the Stroke element Mapserver seems to set >>>> >> automatically a >> >>>> 1px outline using the fill color. >>>> >>>> Does anyone know a workaround to get rid of polygon outlines ? >>>> >>>> -- >>>> Gilles Bassiere >>>> MAKINA CORPUS >>>> 30 rue des Jeuneurs >>>> FR-75011 PARIS >>>> http://www.makina-corpus.com >>>> >>>> >> -- >> Gilles Bassiere >> MAKINA CORPUS >> 30 rue des Jeuneurs >> FR-75011 PARIS >> http://www.makina-corpus.com >> > > > -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From bartvde at OSGIS.NL Mon Jul 30 06:01:08 2007 From: bartvde at OSGIS.NL (Bart van den Eijnden (OSGIS)) Date: Mon, 30 Jul 2007 15:01:08 +0200 Subject: Polygon outline width Message-ID: Try and leave out the OUTLINECOLOR altogether. Best regards, Bart -- Bart van den Eijnden OSGIS, Open Source GIS http://www.osgis.nl --------- Oorspronkelijk bericht -------- Van: Gilles Bassi???re Naar: MAPSERVER-USERS at LISTS.UMN.EDU Onderwerp: Re: [UMN_MAPSERVER-USERS] Polygon outline width Datum: 30/07/07 10:58 > Here is my mapfile. The complete Mapfile has 8 other layers but I > removed them in order to make it easy to read, anyway all layers have > the same properties (only the color change). > I also tried to set the OUTLINECOLOR property at the CLASS level and to > use the value -1 0 0 but the outline is still not transparent. > > # WGS 84 (epsg:4326) > MAP > NAME "Test" > IMAGETYPE "png" > EXTENT 3.3 50.75 7.25 53.6 > IMAGECOLOR 255 255 255 > FONTSET "/home/gba/public_html/fonts.txt" > SYMBOLSET "/home/gba/public_html/symbols.sym" > UNITS dd > > PROJECTION > "init=epsg:4326" > END > > WEB > IMAGEPATH "/home/gba/public_html/img/" > IMAGEURL "/img/" > METADATA > "wms_title" "Road map" > "wms_onlineresource" "http://localhost/~gba/cgi-bin/test.cgi?" > "wms_srs" "epsg:4326" > END > END > > # Legend > LEGEND > KEYSIZE 10 5 > LABEL > TYPE bitmap > SIZE medium > COLOR 0 0 0 > PARTIALS false > END > STATUS on > END > > # Scale bar > SCALEBAR > IMAGECOLOR 255 255 255 > LABEL > COLOR 0 0 0 > SIZE tiny > END > STYLE 1 > SIZE 50 2 > COLOR 0 0 0 > UNITS meters > INTERVALS 2 > STATUS on > END > > OUTPUTFORMAT > NAME "png" > DRIVER "GD/PNG" > MIMETYPE "image/png" > IMAGEMODE "rgba" > EXTENSION "png" > FORMATOPTION "transparent=on" > FORMATOPTION "interlace=on" > END > > > ########################################################################## > # Start of LAYER Definitions > --------------------------------------------- > > ########################################################################## > > # LAYER 9 : water ------------------------------------- > LAYER > NAME "water" > GROUP "background" > CONNECTIONTYPE postgis > CONNECTION "host=localhost dbname=test user=test > password=xxxxx port=5432" > DATA "wkb_geometry FROM water" > STATUS on > TYPE polygon > TRANSPARENCY alpha > > PROJECTION > "init=epsg:4326" > END > > CLASS > STYLE > COLOR 153 179 204 > OUTLINECOLOR -1 -1 -1 > ANTIALIAS true > END > END > > METADATA > "wms_title" "Water bodies" > "wms_srs" "EPSG:4326" > "wms_extent" "3.3 50.75 7.25 53.6" > END > END > END > > # test URL (GetMap) : > http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&request=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=600&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 > > Hi Gilles > > > > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely should work. > > > > Mit freundlichem Gruss / Best Regards > > Flavio Hendry > > > > ---------------------------------------------------------------- > > TYDAC Web-Site: http://www.tydac.ch > > TYDAC MapServer: http://www.mapserver.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 > > ---------------------------------------------------------------- > > > > > > -----Original Message----- > > From: Gilles Bassi???re <gilles.bassiere at makina-corpus.com> > > To: Flavio Hendry <flavio at tydac.ch> > > Cc: MAPSERVER-USERS at LISTS.UMN.EDU > > Date: Mon, 30 Jul 2007 11:58:00 +0200 > > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width > > > > > >> Hi Flavio > >> > >> Thanks for your help. Unfortunately, it has no effect on my map. I > >> tried > >> to set this value for OUTLINE in the CLASS element, then in the STYLE > >> element but rivers still appear very thick on my map when the scale > >> in > >> large... Actually, the same map is produced with OUTLINE -1 0 0 or > >> without. =( > >> > >> As explained in the FAQ, I tried to set up a circle symbol but it > >> seems > >> to work only for true lines, not for polygon outlines. > >> > >> Any other idea ? > >> > >> Gilles > >> > >>> Hi Gilles > >>> > >>> just set the OUTLINECOLOR to -1 0 0. > >>> > >>> Mit freundlichem Gruss / Best Regards > >>> Flavio Hendry > >>> > >>> ---------------------------------------------------------------- > >>> TYDAC Web-Site: http://www.tydac.ch > >>> TYDAC MapServer: http://www.mapserver.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 > >>> ---------------------------------------------------------------- > >>> > >>> > >>> -----Original Message----- > >>> From: Gilles Bassi???re <gilles.bassiere at MAKINA-CORPUS.COM> > >>> To: MAPSERVER-USERS at LISTS.UMN.EDU > >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 > >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width > >>> > >>> > >>> > >>>> Hi there, > >>>> > >>>> I wonder whether it's possible to have no outline for a polygon. From David.Fawcett at STATE.MN.US Mon Jul 30 06:00:51 2007 From: David.Fawcett at STATE.MN.US (Fawcett, David) Date: Mon, 30 Jul 2007 08:00:51 -0500 Subject: Map Server performance In-Reply-To: A<46ACD4E6.8010105@hostgis.com> Message-ID: Gregor, About a year ago, there were a few threads on the list related to performance optimization. I think that most people agreed that there was some good content in the list archives, but nothing in the documentation. I agreed to create a skeletal HowTo and invited others to help flesh it out. You can find it at: http://mapserver.gis.umn.edu/docs/howto/mapfiletuning (I was secretly hoping that Ed would write his raster optimization dissertation there for the last time, so he would just have to point people there instead of re-writing it quarterly to answer list questions .... ; / ) I think that it would be beneficial to combine or cross-reference the two articles. It would also be great if others would add their own knowledge. David. -----Original Message----- From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On Behalf Of Gregor Mosheh Sent: Sunday, July 29, 2007 12:57 PM To: MAPSERVER-USERS at LISTS.UMN.EDU Subject: Re: [UMN_MAPSERVER-USERS] Map Server performance Jandost Khoso wrote: > Can anybody guide me how can i increase performance of Map Server? This is a really common question, yet it's not in the FAQ. So I've added it: http://mapserver.gis.umn.edu/docs/faq/performance It'll be linked into the main FAQ page when they've reviewed it. If anyone has additional input or changes to it, feel free to jump in and edit, or add comments. -- Gregor Mosheh / Greg Allensworth System Administrator, HostGIS cartographic development & hosting services http://www.HostGIS.com/ "Remember that no one cares if you can back up, only if you can restore." - AMANDA From warmerdam at POBOX.COM Mon Jul 30 06:12:35 2007 From: warmerdam at POBOX.COM (Frank Warmerdam) Date: Mon, 30 Jul 2007 09:12:35 -0400 Subject: Cannot zoom in any further In-Reply-To: <46ADD8EE.2010706@zeelandnet.nl> Message-ID: Milo van der Linden wrote: > Hello list, > > > I have a mapfile that spans the entire world, holds 2 attached WMS > layers and 3 postGIS layers. The mapfile extend is set to -180 -90 180 90 > My postGIS layers contain tiny little elements ordered in projects of > approx. 1 km x 1 km in size. > > I use CartoWeb3 as my client. > > When I start zooming in, I reach a certain level where the image refuses > to go into more detail. I can keep clicking my Cartoweb zoom in button, > and I see the image refreshing, but it doesn't change scale or content. > > Is this a zoom in limit set by the fact that I use global extends? Milo, I don't think it relates to global extents. I don't know a lot about Cartoweb, but this sounds like behavior that would be caused by having MAXSCALE set in the WEB section of your mapfile. 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 | President OSGeo, http://osgeo.org From yjacolin at FREE.FR Mon Jul 30 06:30:49 2007 From: yjacolin at FREE.FR (Jacolin Yves) Date: Mon, 30 Jul 2007 15:30:49 +0200 Subject: Cannot zoom in any further In-Reply-To: <46ADE3C3.9090108@pobox.com> Message-ID: Le Monday 30 July 2007 15:12:35 Frank Warmerdam, vous avez ?crit?: > Milo van der Linden wrote: > > Hello list, > > > > > > I have a mapfile that spans the entire world, holds 2 attached WMS > > layers and 3 postGIS layers. The mapfile extend is set to -180 -90 180 90 > > My postGIS layers contain tiny little elements ordered in projects of > > approx. 1 km x 1 km in size. > > > > I use CartoWeb3 as my client. > > > > When I start zooming in, I reach a certain level where the image refuses > > to go into more detail. I can keep clicking my Cartoweb zoom in button, > > and I see the image refreshing, but it doesn't change scale or content. > > > > Is this a zoom in limit set by the fact that I use global extends? > > Milo, > > I don't think it relates to global extents. I don't know a lot about > Cartoweb, but this sounds like behavior that would be caused by having > MAXSCALE set in the WEB section of your mapfile. > > Best regards, Hi, Cartoweb define a limit for the zoom in, check your client.ini file and others (I have not any cartoweb project on my server, so I can not check myself, but this parameter exists). Regards, Y. -- Yves Jacolin --- http://softlibre.gloobe.org From eltalpdopat at GMAIL.COM Mon Jul 30 07:28:31 2007 From: eltalpdopat at GMAIL.COM (giska) Date: Mon, 30 Jul 2007 07:28:31 -0700 Subject: Problem with two point layers... In-Reply-To: <11862296.post@talk.nabble.com> Message-ID: SOLVED!! The question is that the two points layers were in 3D. The solution was to transform these layers to 2d. Thanks to the people who tried to solve it! giska wrote: > > Hi to everyone, > > i'm working in a project with Mapserver and I have a problem with two > points layer. > When I open the page, they show perfectly with their labels but when i > zoom in a extension when all the elements of a layer aren't in, directly > Mapserver don't show any element of the layer. > I am also working with poligons and lines layers and i don't have any > problem with them. The 'Status' is DEFAULT in all of the layers and the > projetion is the same in all layers: ED50 UTM Zone 30N. > > What could the problem be? Thank you in advance. > -- View this message in context: http://www.nabble.com/Problem-with-two-point-layers...-tf4169641.html#a11864785 Sent from the Mapserver - User mailing list archive at Nabble.com. From Tom.Kralidis at EC.GC.CA Mon Jul 30 08:12:45 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Mon, 30 Jul 2007 11:12:45 -0400 Subject: SOS om:result In-Reply-To: A<001001c7cfa6$7ef98130$650fa8c0@latitude> Message-ID: > > Thanks, Assefa. > > > Doing a getObservation should return you an Obervation > collection that > > includes om:result for each observation returned. The om:result is > > implemented to return a gml:feature member. > > Here is a live SOS query that returns 1 row (that's all it > should return). > http://preview.tinyurl.com/2a2x7h > > The part I was looking for on the above result set would be > similar to the om:result from the original URL I sent earlier > from another service. > Basically, it's the block w/ value,value,value. > Charlton: I'm not getting any results back. Are there any records in the database/file? ..Tom From cplist at SECONDCREEK.ORG Mon Jul 30 08:21:39 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Mon, 30 Jul 2007 11:21:39 -0400 Subject: SOS om:result In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F67@ecburexch1.ontario.int.ec.gc.ca> Message-ID: > > Here is a live SOS query that returns 1 row (that's all it > > should return). > > http://preview.tinyurl.com/2a2x7h > > > > The part I was looking for on the above result set would be > > similar to the om:result from the original URL I sent earlier > > from another service. > > Basically, it's the block w/ value,value,value. > > > > Charlton: I'm not getting any results back. Are there any records in > the database/file? Grr. Sorry about that. We're back up now. From Tom.Kralidis at EC.GC.CA Mon Jul 30 08:37:33 2007 From: Tom.Kralidis at EC.GC.CA (Kralidis,Tom [Burlington]) Date: Mon, 30 Jul 2007 11:37:33 -0400 Subject: SOS om:result In-Reply-To: <011a01c7d2bd$545f4490$650fa8c0@latitude> Message-ID: > > > > Here is a live SOS query that returns 1 row (that's all it should > > > return). > > > http://preview.tinyurl.com/2a2x7h > > > > > > The part I was looking for on the above result set would > be similar > > > to the om:result from the original URL I sent earlier > from another > > > service. > > > Basically, it's the block w/ value,value,value. > > > > > > > Charlton: I'm not getting any results back. Are there any > records in > > the database/file? > > Grr. Sorry about that. We're back up now. > (Summarizing off-list exchange). MapServer doesn't support result values being returned as a DataBlock (DataBlock example: http://vast.uah.edu:8080/ows5-dev/weather?request=GetObservation&version =0.0.31&offering=WEATHER_DATA&time=2004-04-01T05:00:00Z/2004-04-01T06:00 :00Z&format=application/com-xml), just a simple/flat OM result. ..Tom From cplist at SECONDCREEK.ORG Mon Jul 30 08:55:59 2007 From: cplist at SECONDCREEK.ORG (Charlton Purvis) Date: Mon, 30 Jul 2007 11:55:59 -0400 Subject: SOS om:result In-Reply-To: <2DC5CCA14756424BBBEE8B4B2E4A682F277F6B@ecburexch1.ontario.int.ec.gc.ca> Message-ID: > MapServer doesn't support result values being returned as a DataBlock > (DataBlock example: OK. Thanks for the help, Tom. Charlton From gilles.bassiere at MAKINA-CORPUS.COM Mon Jul 30 09:08:40 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?UTF-8?B?R2lsbGVzIEJhc3Npw6hyZQ==?=) Date: Mon, 30 Jul 2007 18:08:40 +0200 Subject: Polygon outline width In-Reply-To: <556569dd8ce63de004c6c1e4c077a3bd@145.50.39.11> Message-ID: Hi Bart I don't get you. I tried with the OUTLINECOLOR property set to a valid color, to -1 0 0 and without any OUTLINECOLOR property, is that what you mean ? Let me describe my results : 1) COLOR set to 153 179 204, OUTLINECOLOR is set to 0 0 0 => My shape appear in blue with a 1 pixel black border. 2) COLOR set to 153 179 204, OUTLINECOLOR is not set (default value) => My shape appear in blue, there is no black border but polygon is as thick as the previous one. I assume that Mapserver draw a 1 pixel border using the filling color. 3) COLOR set to 153 179 204, OUTLINECOLOR is set to -1 0 0 (or to -1 -1 -1) => The result is the same as case no 2. Attached are some map excerpts illustrating these 3 cases. If I understand, the value -1 0 0 is a way to say to Mapserver: "Draw this transparent", right ? So, every pixel that appear black in the first case shouldn't appear in blue in the 3rd case, isn't it ? As you can see on the third map (case3.png), it's not. :( Flavio, thanks for checking my mapfile. I tried with and without antialias and it looks better with it. I don't know how to check whether my polygons are valid (closed polygon), could you give me a way to check that ? Regards Bart van den Eijnden (OSGIS) wrote: > Try and leave out the OUTLINECOLOR altogether. > > Best regards, > Bart > > -- > Bart van den Eijnden > OSGIS, Open Source GIS > http://www.osgis.nl > > > --------- Oorspronkelijk bericht -------- > Van: Gilles Bassi???re > Naar: MAPSERVER-USERS at LISTS.UMN.EDU > Onderwerp: Re: [UMN_MAPSERVER-USERS] Polygon outline width > Datum: 30/07/07 10:58 > > >> Here is my mapfile. The complete Mapfile has 8 other layers but I >> removed them in order to make it easy to read, anyway all layers have >> the same properties (only the color change). >> I also tried to set the OUTLINECOLOR property at the CLASS level and to >> use the value -1 0 0 but the outline is still not transparent. >> >> # WGS 84 (epsg:4326) >> MAP >> NAME "Test" >> IMAGETYPE "png" >> EXTENT 3.3 50.75 7.25 53.6 >> IMAGECOLOR 255 255 255 >> FONTSET "/home/gba/public_html/fonts.txt" >> SYMBOLSET "/home/gba/public_html/symbols.sym" >> UNITS dd >> >> PROJECTION >> "init=epsg:4326" >> END >> >> WEB >> IMAGEPATH "/home/gba/public_html/img/" >> IMAGEURL "/img/" >> METADATA >> "wms_title" "Road map" >> "wms_onlineresource" >> > "http://localhost/~gba/cgi-bin/test.cgi?" > >> "wms_srs" "epsg:4326" >> END >> END >> >> # Legend >> LEGEND >> KEYSIZE 10 5 >> LABEL >> TYPE bitmap >> SIZE medium >> COLOR 0 0 0 >> PARTIALS false >> END >> STATUS on >> END >> >> # Scale bar >> SCALEBAR >> IMAGECOLOR 255 255 255 >> LABEL >> COLOR 0 0 0 >> SIZE tiny >> END >> STYLE 1 >> SIZE 50 2 >> COLOR 0 0 0 >> UNITS meters >> INTERVALS 2 >> STATUS on >> END >> >> OUTPUTFORMAT >> NAME "png" >> DRIVER "GD/PNG" >> MIMETYPE "image/png" >> IMAGEMODE "rgba" >> EXTENSION "png" >> FORMATOPTION "transparent=on" >> FORMATOPTION "interlace=on" >> END >> >> >> ########################################################################## >> # Start of LAYER Definitions >> --------------------------------------------- >> >> ########################################################################## >> >> # LAYER 9 : water ------------------------------------- >> LAYER >> NAME "water" >> GROUP "background" >> CONNECTIONTYPE postgis >> CONNECTION "host=localhost dbname=test user=test >> password=xxxxx port=5432" >> DATA "wkb_geometry FROM water" >> STATUS on >> TYPE polygon >> TRANSPARENCY alpha >> >> PROJECTION >> "init=epsg:4326" >> END >> >> CLASS >> STYLE >> COLOR 153 179 204 >> OUTLINECOLOR -1 -1 -1 >> ANTIALIAS true >> END >> END >> >> METADATA >> "wms_title" "Water bodies" >> "wms_srs" "EPSG:4326" >> "wms_extent" "3.3 50.75 7.25 53.6" >> END >> END >> END >> >> # test URL (GetMap) : >> >> > http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&request=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=600&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 > >> > Hi Gilles >> > >> > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely should >> > work. > >> > >> > Mit freundlichem Gruss / Best Regards >> > Flavio Hendry >> > >> > ---------------------------------------------------------------- >> > TYDAC Web-Site: http://www.tydac.ch >> > TYDAC MapServer: http://www.mapserver.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 >> > ---------------------------------------------------------------- >> > >> > >> > -----Original Message----- >> > From: Gilles Bassi???re <gilles.bassiere at makina-corpus.com> >> > To: Flavio Hendry <flavio at tydac.ch> >> > Cc: MAPSERVER-USERS at LISTS.UMN.EDU >> > Date: Mon, 30 Jul 2007 11:58:00 +0200 >> > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width >> > >> > >> >> Hi Flavio >> >> >> >> Thanks for your help. Unfortunately, it has no effect on my map. >> > I > >> >> tried >> >> to set this value for OUTLINE in the CLASS element, then in the >> > STYLE > >> >> element but rivers still appear very thick on my map when the >> > scale > >> >> in >> >> large... Actually, the same map is produced with OUTLINE -1 0 0 >> > or > >> >> without. =( >> >> >> >> As explained in the FAQ, I tried to set up a circle symbol but it >> >> seems >> >> to work only for true lines, not for polygon outlines. >> >> >> >> Any other idea ? >> >> >> >> Gilles >> >> >> >>> Hi Gilles >> >>> >> >>> just set the OUTLINECOLOR to -1 0 0. >> >>> >> >>> Mit freundlichem Gruss / Best Regards >> >>> Flavio Hendry >> >>> >> >>> >> > ---------------------------------------------------------------- > >> >>> TYDAC Web-Site: http://www.tydac.ch >> >>> TYDAC MapServer: http://www.mapserver.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 > >> >>> >> > ---------------------------------------------------------------- > >> >>> >> >>> >> >>> -----Original Message----- >> >>> From: Gilles Bassi???re >> > <gilles.bassiere at MAKINA-CORPUS.COM> > >> >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >> >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 >> >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width >> >>> >> >>> >> >>> >> >>>> Hi there, >> >>>> >> >>>> I wonder whether it's possible to have no outline for a >> > polygon. > -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com -------------- next part -------------- A non-text attachment was scrubbed... Name: case1.png Type: image/png Size: 18661 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: case2.png Type: image/png Size: 15368 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: case3.png Type: image/png Size: 15368 bytes Desc: not available URL: From jayzee.smith at GMAIL.COM Mon Jul 30 12:10:00 2007 From: jayzee.smith at GMAIL.COM (John Smith) Date: Mon, 30 Jul 2007 15:10:00 -0400 Subject: mapserv(): Web application error. Query mode needs a point, imgxy and mapxy are not set?? In-Reply-To: Message-ID: quick note: forward works fine without refresh. jzs On 7/25/07, John Smith wrote: > guys, > see if you can shed some light: > > i zoom in from page A (querying works) with the following cgi > variables set in the url in order- mode, qlayer, map, imgext, minx, > miny, maxx, maxy, imgxy, mapxy > > to page B (querying works) with the following variables in the url- > mode, qlayer, map, imgext, minx, miny, maxx, maxy, imgxy, mapxy > > then back to page A using the browser back button with the following > variables- mode, qlayer, map, imgext, minx, miny, maxx, maxy, imgxy, > mapxy > except now querying doesn't work and i face the dreaded 'mapserv(): > Web application error. Query mode needs a point, imgxy and mapxy are > not set'. but if i then refresh page A, querying works again?? > > running mapserver version 4.8.3. what gives?? > > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/0302/msg00638.html > http://trac.osgeo.org/mapserver/ticket/304 > http://trac.osgeo.org/mapserver/ticket/314 > http://mapserver.gis.umn.edu/data2/wilma/mapserver-users/mapserver-users.0405 > variable order appears right and replacing mapext with map_extent > doesn't help (see above). > > jzs From Steve.Lime at DNR.STATE.MN.US Mon Jul 30 12:14:18 2007 From: Steve.Lime at DNR.STATE.MN.US (Steve Lime) Date: Mon, 30 Jul 2007 14:14:18 -0500 Subject: MapServer 5.0.0 release plan ... and release of beta1 In-Reply-To: <46AA4545.1070305@hostgis.com> Message-ID: Not quite, there are still a couple ...ITEM parameters that still exist because they don't function like the bindings in the RFC do. Most notably CLASSITEM, LABELITEM, TILEITEM and FILTERITEM still remain and behave as before. The reason being that they don't map directly to other parameters. For example, SIZEITEM maps to the SIZE property. What does CLASSITEM map to? It doesn't, so it still remains. The LABELITEM kinda maps to the classObj TEXT property but I thought it would be less disruptive to leave that one in tact. Steve >>> On 7/27/2007 at 2:19 PM, in message <46AA4545.1070305 at hostgis.com>, Gregor Mosheh wrote: > Daniel Morissette wrote: >> Gregor Mosheh wrote: >>>> - MS RFC 19: Added Style and Label attribute binding > > Ah, it means that we replaced labelitem and the like with a smoother > syntax, e.g. LABEL [name] > > Very very nice! From Jukka.Rahkonen at MMMTIKE.FI Tue Jul 31 00:06:15 2007 From: Jukka.Rahkonen at MMMTIKE.FI (Rahkonen Jukka) Date: Tue, 31 Jul 2007 10:06:15 +0300 Subject: Polygon outline width Message-ID: Hi, The question might be actually in how the polygons and outlines actually are rendered. Gilles seems to suppose that polygon in first rendered with COLOR and after that outline is rendered outside the polygon with OUTLINECOLOR, resulting to a shape that widened from the original by the line width. But perhaps Mapserver is rendering the outline just inside (effectively, above) the coloured polygon that is on the bottom, or maybe half and half? I suppose that would lead to similar results in cases 2) and 3). Who knows? -Jukka Rahkonen- ________________________________ L?hett?j?: UMN MapServer Users List puolesta: Gilles Bassi?re L?hetetty: ma 30.7.2007 19:08 Vastaanottaja: MAPSERVER-USERS at LISTS.UMN.EDU Aihe: Re: [UMN_MAPSERVER-USERS] Polygon outline width Hi Bart I don't get you. I tried with the OUTLINECOLOR property set to a valid color, to -1 0 0 and without any OUTLINECOLOR property, is that what you mean ? Let me describe my results : 1) COLOR set to 153 179 204, OUTLINECOLOR is set to 0 0 0 => My shape appear in blue with a 1 pixel black border. 2) COLOR set to 153 179 204, OUTLINECOLOR is not set (default value) => My shape appear in blue, there is no black border but polygon is as thick as the previous one. I assume that Mapserver draw a 1 pixel border using the filling color. 3) COLOR set to 153 179 204, OUTLINECOLOR is set to -1 0 0 (or to -1 -1 -1) => The result is the same as case no 2. Attached are some map excerpts illustrating these 3 cases. If I understand, the value -1 0 0 is a way to say to Mapserver: "Draw this transparent", right ? So, every pixel that appear black in the first case shouldn't appear in blue in the 3rd case, isn't it ? As you can see on the third map (case3.png), it's not. :( Flavio, thanks for checking my mapfile. I tried with and without antialias and it looks better with it. I don't know how to check whether my polygons are valid (closed polygon), could you give me a way to check that ? Regards Bart van den Eijnden (OSGIS) wrote: > Try and leave out the OUTLINECOLOR altogether. > > Best regards, > Bart > > -- > Bart van den Eijnden > OSGIS, Open Source GIS > http://www.osgis.nl > > > --------- Oorspronkelijk bericht -------- > Van: Gilles Bassi???re > Naar: MAPSERVER-USERS at LISTS.UMN.EDU > Onderwerp: Re: [UMN_MAPSERVER-USERS] Polygon outline width > Datum: 30/07/07 10:58 > > >> Here is my mapfile. The complete Mapfile has 8 other layers but I >> removed them in order to make it easy to read, anyway all layers have >> the same properties (only the color change). >> I also tried to set the OUTLINECOLOR property at the CLASS level and to >> use the value -1 0 0 but the outline is still not transparent. >> >> # WGS 84 (epsg:4326) >> MAP >> NAME "Test" >> IMAGETYPE "png" >> EXTENT 3.3 50.75 7.25 53.6 >> IMAGECOLOR 255 255 255 >> FONTSET "/home/gba/public_html/fonts.txt" >> SYMBOLSET "/home/gba/public_html/symbols.sym" >> UNITS dd >> >> PROJECTION >> "init=epsg:4326" >> END >> >> WEB >> IMAGEPATH "/home/gba/public_html/img/" >> IMAGEURL "/img/" >> METADATA >> "wms_title" "Road map" >> "wms_onlineresource" >> > "http://localhost/~gba/cgi-bin/test.cgi?" > >> "wms_srs" "epsg:4326" >> END >> END >> >> # Legend >> LEGEND >> KEYSIZE 10 5 >> LABEL >> TYPE bitmap >> SIZE medium >> COLOR 0 0 0 >> PARTIALS false >> END >> STATUS on >> END >> >> # Scale bar >> SCALEBAR >> IMAGECOLOR 255 255 255 >> LABEL >> COLOR 0 0 0 >> SIZE tiny >> END >> STYLE 1 >> SIZE 50 2 >> COLOR 0 0 0 >> UNITS meters >> INTERVALS 2 >> STATUS on >> END >> >> OUTPUTFORMAT >> NAME "png" >> DRIVER "GD/PNG" >> MIMETYPE "image/png" >> IMAGEMODE "rgba" >> EXTENSION "png" >> FORMATOPTION "transparent=on" >> FORMATOPTION "interlace=on" >> END >> >> >> ########################################################################## >> # Start of LAYER Definitions >> --------------------------------------------- >> >> ########################################################################## >> >> # LAYER 9 : water ------------------------------------- >> LAYER >> NAME "water" >> GROUP "background" >> CONNECTIONTYPE postgis >> CONNECTION "host=localhost dbname=test user=test >> password=xxxxx port=5432" >> DATA "wkb_geometry FROM water" >> STATUS on >> TYPE polygon >> TRANSPARENCY alpha >> >> PROJECTION >> "init=epsg:4326" >> END >> >> CLASS >> STYLE >> COLOR 153 179 204 >> OUTLINECOLOR -1 -1 -1 >> ANTIALIAS true >> END >> END >> >> METADATA >> "wms_title" "Water bodies" >> "wms_srs" "EPSG:4326" >> "wms_extent" "3.3 50.75 7.25 53.6" >> END >> END >> END >> >> # test URL (GetMap) : >> >> > http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&request=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=600&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 > >> > Hi Gilles >> > >> > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely should >> > work. > >> > >> > Mit freundlichem Gruss / Best Regards >> > Flavio Hendry >> > >> > ---------------------------------------------------------------- >> > TYDAC Web-Site: http://www.tydac.ch >> > TYDAC MapServer: http://www.mapserver.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 >> > ---------------------------------------------------------------- >> > >> > >> > -----Original Message----- >> > From: Gilles Bassi???re <gilles.bassiere at makina-corpus.com> >> > To: Flavio Hendry <flavio at tydac.ch> >> > Cc: MAPSERVER-USERS at LISTS.UMN.EDU >> > Date: Mon, 30 Jul 2007 11:58:00 +0200 >> > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width >> > >> > >> >> Hi Flavio >> >> >> >> Thanks for your help. Unfortunately, it has no effect on my map. >> > I > >> >> tried >> >> to set this value for OUTLINE in the CLASS element, then in the >> > STYLE > >> >> element but rivers still appear very thick on my map when the >> > scale > >> >> in >> >> large... Actually, the same map is produced with OUTLINE -1 0 0 >> > or > >> >> without. =( >> >> >> >> As explained in the FAQ, I tried to set up a circle symbol but it >> >> seems >> >> to work only for true lines, not for polygon outlines. >> >> >> >> Any other idea ? >> >> >> >> Gilles >> >> >> >>> Hi Gilles >> >>> >> >>> just set the OUTLINECOLOR to -1 0 0. >> >>> >> >>> Mit freundlichem Gruss / Best Regards >> >>> Flavio Hendry >> >>> >> >>> >> > ---------------------------------------------------------------- > >> >>> TYDAC Web-Site: http://www.tydac.ch >> >>> TYDAC MapServer: http://www.mapserver.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 > >> >>> >> > ---------------------------------------------------------------- > >> >>> >> >>> >> >>> -----Original Message----- >> >>> From: Gilles Bassi???re >> > <gilles.bassiere at MAKINA-CORPUS.COM> > >> >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >> >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 >> >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width >> >>> >> >>> >> >>> >> >>>> Hi there, >> >>>> >> >>>> I wonder whether it's possible to have no outline for a >> > polygon. > -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From roybraam at B3PARTNERS.NL Tue Jul 31 00:32:47 2007 From: roybraam at B3PARTNERS.NL (Roy Braam) Date: Tue, 31 Jul 2007 09:32:47 +0200 Subject: Rotate transparent symbols Message-ID: List, Does anyone know how to show rotated symbols (font's or images) transparent in a point layer? If i rotate fonts the location isn't correct any more and if i rotate images they aren't transparent any more. Tia, Roy Braam B3partners BV -------------- next part -------------- An HTML attachment was scrubbed... URL: From flavio at TYDAC.CH Tue Jul 31 00:45:01 2007 From: flavio at TYDAC.CH (Flavio Hendry) Date: Tue, 31 Jul 2007 09:45:01 +0200 Subject: Polygon outline width In-Reply-To: Message-ID: Hi Jukka half/half would be normal and logic to me ... Mit freundlichem Gruss / Best Regards Flavio Hendry ---------------------------------------------------------------- TYDAC Web-Site: http://www.tydac.ch TYDAC MapServer: http://www.mapserver.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 ---------------------------------------------------------------- -----Original Message----- From: Rahkonen Jukka To: MAPSERVER-USERS at LISTS.UMN.EDU Date: Tue, 31 Jul 2007 10:06:15 +0300 Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width > Hi, > > The question might be actually in how the polygons and outlines > actually are rendered. Gilles seems to suppose that polygon in first > rendered with COLOR and after that outline is rendered outside the > polygon with OUTLINECOLOR, resulting to a shape that widened from the > original by the line width. But perhaps Mapserver is rendering the > outline just inside (effectively, above) the coloured polygon that is > on the bottom, or maybe half and half? I suppose that would lead to > similar results in cases 2) and 3). Who knows? > > -Jukka Rahkonen- > > ________________________________ > > L?hett?j?: UMN MapServer Users List puolesta: Gilles Bassi?re > L?hetetty: ma 30.7.2007 19:08 > Vastaanottaja: MAPSERVER-USERS at LISTS.UMN.EDU > Aihe: Re: [UMN_MAPSERVER-USERS] Polygon outline width > > > > Hi Bart > > I don't get you. I tried with the OUTLINECOLOR property set to a > valid > color, to -1 0 0 and without any OUTLINECOLOR property, is that what > you > mean ? > > Let me describe my results : > > 1) COLOR set to 153 179 204, OUTLINECOLOR is set to 0 0 0 > => My shape appear in blue with a 1 pixel black border. > > 2) COLOR set to 153 179 204, OUTLINECOLOR is not set (default value) > => My shape appear in blue, there is no black border but polygon is > as > thick as the previous one. I assume that Mapserver draw a 1 pixel > border > using the filling color. > > 3) COLOR set to 153 179 204, OUTLINECOLOR is set to -1 0 0 (or to -1 > -1 -1) > => The result is the same as case no 2. > > Attached are some map excerpts illustrating these 3 cases. > > If I understand, the value -1 0 0 is a way to say to Mapserver: "Draw > this transparent", right ? So, every pixel that appear black in the > first case shouldn't appear in blue in the 3rd case, isn't it ? As > you > can see on the third map (case3.png), it's not. :( > > Flavio, thanks for checking my mapfile. I tried with and without > antialias and it looks better with it. I don't know how to check > whether > my polygons are valid (closed polygon), could you give me a way to > check > that ? > > Regards > > > > Bart van den Eijnden (OSGIS) wrote: > > Try and leave out the OUTLINECOLOR altogether. > > > > Best regards, > > Bart > > > > -- > > Bart van den Eijnden > > OSGIS, Open Source GIS > > http://www.osgis.nl > > > > > > --------- Oorspronkelijk bericht -------- > > Van: Gilles Bassi???re > > Naar: MAPSERVER-USERS at LISTS.UMN.EDU > > Onderwerp: Re: [UMN_MAPSERVER-USERS] Polygon outline width > > Datum: 30/07/07 10:58 > > > > > >> Here is my mapfile. The complete Mapfile has 8 other layers but I > >> removed them in order to make it easy to read, anyway all layers > have > >> the same properties (only the color change). > >> I also tried to set the OUTLINECOLOR property at the CLASS level > and to > >> use the value -1 0 0 but the outline is still not transparent. > >> > >> # WGS 84 (epsg:4326) > >> MAP > >> NAME "Test" > >> IMAGETYPE "png" > >> EXTENT 3.3 50.75 7.25 53.6 > >> IMAGECOLOR 255 255 255 > >> FONTSET "/home/gba/public_html/fonts.txt" > >> SYMBOLSET > "/home/gba/public_html/symbols.sym" > >> UNITS dd > >> > >> PROJECTION > >> "init=epsg:4326" > >> END > >> > >> WEB > >> IMAGEPATH "/home/gba/public_html/img/" > >> IMAGEURL "/img/" > >> METADATA > >> "wms_title" "Road map" > >> "wms_onlineresource" > >> > > "http://localhost/~gba/cgi-bin/test.cgi?" > > > > >> "wms_srs" "epsg:4326" > >> END > >> END > >> > >> # Legend > >> LEGEND > >> KEYSIZE 10 5 > >> LABEL > >> TYPE bitmap > >> SIZE medium > >> COLOR 0 0 0 > >> PARTIALS false > >> END > >> STATUS on > >> END > >> > >> # Scale bar > >> SCALEBAR > >> IMAGECOLOR 255 255 255 > >> LABEL > >> COLOR 0 0 0 > >> SIZE tiny > >> END > >> STYLE 1 > >> SIZE 50 2 > >> COLOR 0 0 0 > >> UNITS meters > >> INTERVALS 2 > >> STATUS on > >> END > >> > >> OUTPUTFORMAT > >> NAME "png" > >> DRIVER "GD/PNG" > >> MIMETYPE "image/png" > >> IMAGEMODE "rgba" > >> EXTENSION "png" > >> FORMATOPTION "transparent=on" > >> FORMATOPTION "interlace=on" > >> END > >> > >> > >> > ##################################################################### > ##### > >> # Start of LAYER Definitions > >> --------------------------------------------- > >> > >> > ##################################################################### > ##### > >> > >> # LAYER 9 : water ------------------------------------- > >> LAYER > >> NAME "water" > >> GROUP "background" > >> CONNECTIONTYPE postgis > >> CONNECTION "host=localhost dbname=test user=test > >> password=xxxxx port=5432" > >> DATA "wkb_geometry FROM water" > >> STATUS on > >> TYPE polygon > >> TRANSPARENCY alpha > >> > >> PROJECTION > >> "init=epsg:4326" > >> END > >> > >> CLASS > >> STYLE > >> COLOR 153 179 204 > >> OUTLINECOLOR -1 -1 -1 > >> ANTIALIAS true > >> END > >> END > >> > >> METADATA > >> "wms_title" "Water bodies" > >> "wms_srs" "EPSG:4326" > >> "wms_extent" "3.3 50.75 7.25 53.6" > >> END > >> END > >> END > >> > >> # test URL (GetMap) : > >> > >> > > > http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&requ > est=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=6 > 00&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 > > > >> > Hi Gilles > >> > > >> > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely > should > >> > > work. > > > >> > > >> > Mit freundlichem Gruss / Best Regards > >> > Flavio Hendry > >> > > >> > > ---------------------------------------------------------------- > >> > TYDAC Web-Site: http://www.tydac.ch > >> > TYDAC MapServer: http://www.mapserver.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 > >> > > ---------------------------------------------------------------- > >> > > >> > > >> > -----Original Message----- > >> > From: Gilles Bassi???re > <gilles.bassiere at makina-corpus.com> > >> > To: Flavio Hendry <flavio at tydac.ch> > >> > Cc: MAPSERVER-USERS at LISTS.UMN.EDU > >> > Date: Mon, 30 Jul 2007 11:58:00 +0200 > >> > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width > >> > > >> > > >> >> Hi Flavio > >> >> > >> >> Thanks for your help. Unfortunately, it has no effect on > my map. > >> > > I > > > >> >> tried > >> >> to set this value for OUTLINE in the CLASS element, then > in the > >> > > STYLE > > > >> >> element but rivers still appear very thick on my map when > the > >> > > scale > > > >> >> in > >> >> large... Actually, the same map is produced with OUTLINE > -1 0 0 > >> > > or > > > >> >> without. =( > >> >> > >> >> As explained in the FAQ, I tried to set up a circle > symbol but it > >> >> seems > >> >> to work only for true lines, not for polygon outlines. > >> >> > >> >> Any other idea ? > >> >> > >> >> Gilles > >> >> > >> >>> Hi Gilles > >> >>> > >> >>> just set the OUTLINECOLOR to -1 0 0. > >> >>> > >> >>> Mit freundlichem Gruss / Best Regards > >> >>> Flavio Hendry > >> >>> > >> >>> > >> > > ---------------------------------------------------------------- > > > >> >>> TYDAC Web-Site: http://www.tydac.ch > > >> >>> TYDAC MapServer: http://www.mapserver.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 > > > >> >>> > >> > > ---------------------------------------------------------------- > > > >> >>> > >> >>> > >> >>> -----Original Message----- > >> >>> From: Gilles Bassi???re > >> > > <gilles.bassiere at MAKINA-CORPUS.COM> > > > >> >>> To: MAPSERVER-USERS at LISTS.UMN.EDU > >> >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 > >> >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width > >> >>> > >> >>> > >> >>> > >> >>>> Hi there, > >> >>>> > >> >>>> I wonder whether it's possible to have no outline > for a > >> > > polygon. > > > > > -- > Gilles Bassiere > MAKINA CORPUS > 30 rue des Jeuneurs > FR-75011 PARIS > http://www.makina-corpus.com From anhtin at GMAIL.COM Tue Jul 31 02:47:04 2007 From: anhtin at GMAIL.COM (anhtin) Date: Tue, 31 Jul 2007 02:47:04 -0700 Subject: create circle mapserver Message-ID: hi all i have question I have layer ticket LAYER #ProvinceLable NAME "17" CONNECTIONTYPE postgis CONNECTION "host=10.0.0.9 dbname=demo user=postgres password=123456 port=5432" DATA "the_geom FROM ticket" STATUS ON TYPE ANNOTATION LABELMINSCALE 500000 LABELITEM "gid" CLASSITEM "name" CLASS #EXPRESSION /./ #COLOR -1 -1 -1 LABEL ANGLE AUTO COLOR 0 0 0 # FONT "Arial" FONT "vnarial" # OUTLINECOLOR 255 255 255 # SHADOWSIZE 1 1 TYPE truetype SIZE 9 POSITION CC PARTIALS FALSE BUFFER 2 END # end of label END # end of States class object END # end of layer END it show lable for me, And now i want create circle with coordinate in layer ticket how can i do it note: i create point demo and it ok MAP NAME MAP_POINTS SIZE 600 300 EXTENT -180 -90 180 90 TRANSPARENT ON SYMBOL NAME "circle" TYPE ELLIPSE FILLED TRUE POINTS 1 1 END END LAYER NAME custom_points1 TYPE POINT STATUS ON #TRANSPARENT ON #TRANSPARENCY 5 FEATURE # Inline feature definition POINTS -51 54 END TEXT "My Place" END CLASS COLOR 0 0 0 OUTLINECOLOR 255 255 255 SYMBOL "circle" SIZE 10 LABEL POSITION AUTO COLOR 250 0 0 OUTLINECOLOR 255 255 255 END END END END -- View this message in context: http://www.nabble.com/create-circle-mapserver-tf4191965.html#a11921170 Sent from the Mapserver - User mailing list archive at Nabble.com. From anhtin at GMAIL.COM Tue Jul 31 02:57:49 2007 From: anhtin at GMAIL.COM (anhtin) Date: Tue, 31 Jul 2007 02:57:49 -0700 Subject: create circle mapserver Message-ID: hi all i have question I have layer ticket LAYER #ProvinceLable NAME "17" CONNECTIONTYPE postgis CONNECTION "host=10.0.0.9 dbname=demo user=postgres password=123456 port=5432" DATA "the_geom FROM ticket" STATUS ON TYPE ANNOTATION LABELMINSCALE 500000 LABELITEM "gid" CLASSITEM "name" CLASS #EXPRESSION /./ #COLOR -1 -1 -1 LABEL ANGLE AUTO COLOR 0 0 0 # FONT "Arial" FONT "vnarial" # OUTLINECOLOR 255 255 255 # SHADOWSIZE 1 1 TYPE truetype SIZE 9 POSITION CC PARTIALS FALSE BUFFER 2 END # end of label END # end of States class object END # end of layer END it show lable for me, And now i want create circle with coordinate in layer ticket how can i do it note: i create point demo and it ok MAP NAME MAP_POINTS SIZE 600 300 EXTENT -180 -90 180 90 TRANSPARENT ON SYMBOL NAME "circle" TYPE ELLIPSE FILLED TRUE POINTS 1 1 END END LAYER NAME custom_points1 TYPE POINT STATUS ON #TRANSPARENT ON #TRANSPARENCY 5 FEATURE # Inline feature definition POINTS -51 54 END TEXT "My Place" END CLASS COLOR 0 0 0 OUTLINECOLOR 255 255 255 SYMBOL "circle" SIZE 10 LABEL POSITION AUTO COLOR 250 0 0 OUTLINECOLOR 255 255 255 END END END END -- View this message in context: http://www.nabble.com/create-circle-mapserver-tf4191977.html#a11921216 Sent from the Mapserver - User mailing list archive at Nabble.com. From eltalpdopat at GMAIL.COM Tue Jul 31 03:51:00 2007 From: eltalpdopat at GMAIL.COM (giska) Date: Tue, 31 Jul 2007 03:51:00 -0700 Subject: About the background color of the icon of the Legend Message-ID: I'm working with Mapserver and i'm using a template to show the legend... And I need to know if is it possible to change the background color of the icon of the Legend ([leg_icon])? Thank you in advance. -- View this message in context: http://www.nabble.com/About-the-background-color-of-the-icon-of-the-Legend-tf4192288.html#a11921948 Sent from the Mapserver - User mailing list archive at Nabble.com. From mlinden at ZEELANDNET.NL Tue Jul 31 07:01:38 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Tue, 31 Jul 2007 16:01:38 +0200 Subject: Mapscript issue with towgs84 parameter Message-ID: Hello list, I am using php mapscript to convert coordinates from one coordsys to another. the project function takes ms_newprojectionobj as input for the from and to coordsys. The string with which I construct the ms_newprojectionobj contains a towgs84 parameter that takes comma seperated values. My gut tells me that this is causing a shift in the via ogr2ogr converted shapefiles and my X/Y values converted with php_mapscript from MSSQL. Can any one tell me if this ms_newprojectionobj can be constructed like the way it is in ogr2ogr? with + instead of , as seperator? -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From nico at LANGHIRANO.IT Tue Jul 31 07:03:28 2007 From: nico at LANGHIRANO.IT (Nico Alberti) Date: Tue, 31 Jul 2007 16:03:28 +0200 Subject: MG Studio 2008 and MG 1.1.0 "Incompatible version". Am I the only one. Message-ID: Seems I am the only one that gets the infamous message "The Studio Version is Incompatible with the site version" after having upgraded my MG Studio to version 2008. Not surprisingly the dll provided for MG 2007 does not work with the new version. Have I missed something? It's is not a big issue, as I can roll back to MG 2007 and wait for MG 1.2.0 final to tune up my site, however if someone can give me a hint, I would greatly appreciate it. -- Ciao Nico From nico at LANGHIRANO.IT Tue Jul 31 07:07:50 2007 From: nico at LANGHIRANO.IT (Nico Alberti) Date: Tue, 31 Jul 2007 16:07:50 +0200 Subject: MG Studio 2008 and MG 1.1.0 "Incompatible version". Am I the only one. In-Reply-To: Message-ID: 2007/7/31, Nico Alberti : > Seems I am the only one that gets the infamous message "The Studio Sorry. Wrong mailing list. (embarassing...) -- Ciao Nico From gilles.bassiere at MAKINA-CORPUS.COM Tue Jul 31 07:27:27 2007 From: gilles.bassiere at MAKINA-CORPUS.COM (=?UTF-8?B?R2lsbGVzIEJhc3Npw6hyZQ==?=) Date: Tue, 31 Jul 2007 16:27:27 +0200 Subject: Polygon outline width In-Reply-To: Message-ID: Hi Jukka, Interesting point of view! I still think that outline are drawn outside polygons. I tried uDig to view my data. In this application, I can easily switch my outline on and off (that is, set width to 0px). The thickness of mapserver polygons is equivalent to those drawn in uDig with a 1px outline. Without this outline, the smaller river are almost invisible in uDig at large scale. Since mapserver doesn't support an outline width lesser than 1px, I assume that it's just not possible to completely "turn off" outlines. I still wonder why the OUTLINECOLOR -1 -1 -1 didn't work on my computer. I also try to change IMAGECOLOR settings but it's still the same crappy rendering. Anyway, I finally gave up and created a second CLASS in order to draw only bigger rivers when the scale is large. It's not as nice as uDig rendering but it's still readable. Thanks ! Gilles Rahkonen Jukka wrote: > Hi, > > The question might be actually in how the polygons and outlines actually are rendered. Gilles seems to suppose that polygon in first rendered with COLOR and after that outline is rendered outside the polygon with OUTLINECOLOR, resulting to a shape that widened from the original by the line width. But perhaps Mapserver is rendering the outline just inside (effectively, above) the coloured polygon that is on the bottom, or maybe half and half? I suppose that would lead to similar results in cases 2) and 3). Who knows? > > -Jukka Rahkonen- > > ________________________________ > > L?hett?j?: UMN MapServer Users List puolesta: Gilles Bassi?re > L?hetetty: ma 30.7.2007 19:08 > Vastaanottaja: MAPSERVER-USERS at LISTS.UMN.EDU > Aihe: Re: [UMN_MAPSERVER-USERS] Polygon outline width > > > > Hi Bart > > I don't get you. I tried with the OUTLINECOLOR property set to a valid > color, to -1 0 0 and without any OUTLINECOLOR property, is that what you > mean ? > > Let me describe my results : > > 1) COLOR set to 153 179 204, OUTLINECOLOR is set to 0 0 0 > => My shape appear in blue with a 1 pixel black border. > > 2) COLOR set to 153 179 204, OUTLINECOLOR is not set (default value) > => My shape appear in blue, there is no black border but polygon is as > thick as the previous one. I assume that Mapserver draw a 1 pixel border > using the filling color. > > 3) COLOR set to 153 179 204, OUTLINECOLOR is set to -1 0 0 (or to -1 -1 -1) > => The result is the same as case no 2. > > Attached are some map excerpts illustrating these 3 cases. > > If I understand, the value -1 0 0 is a way to say to Mapserver: "Draw > this transparent", right ? So, every pixel that appear black in the > first case shouldn't appear in blue in the 3rd case, isn't it ? As you > can see on the third map (case3.png), it's not. :( > > Flavio, thanks for checking my mapfile. I tried with and without > antialias and it looks better with it. I don't know how to check whether > my polygons are valid (closed polygon), could you give me a way to check > that ? > > Regards > > > > Bart van den Eijnden (OSGIS) wrote: > >> Try and leave out the OUTLINECOLOR altogether. >> >> Best regards, >> Bart >> >> -- >> Bart van den Eijnden >> OSGIS, Open Source GIS >> http://www.osgis.nl >> >> >> --------- Oorspronkelijk bericht -------- >> Van: Gilles Bassi???re >> Naar: MAPSERVER-USERS at LISTS.UMN.EDU >> Onderwerp: Re: [UMN_MAPSERVER-USERS] Polygon outline width >> Datum: 30/07/07 10:58 >> >> >> >>> Here is my mapfile. The complete Mapfile has 8 other layers but I >>> removed them in order to make it easy to read, anyway all layers have >>> the same properties (only the color change). >>> I also tried to set the OUTLINECOLOR property at the CLASS level and to >>> use the value -1 0 0 but the outline is still not transparent. >>> >>> # WGS 84 (epsg:4326) >>> MAP >>> NAME "Test" >>> IMAGETYPE "png" >>> EXTENT 3.3 50.75 7.25 53.6 >>> IMAGECOLOR 255 255 255 >>> FONTSET "/home/gba/public_html/fonts.txt" >>> SYMBOLSET "/home/gba/public_html/symbols.sym" >>> UNITS dd >>> >>> PROJECTION >>> "init=epsg:4326" >>> END >>> >>> WEB >>> IMAGEPATH "/home/gba/public_html/img/" >>> IMAGEURL "/img/" >>> METADATA >>> "wms_title" "Road map" >>> "wms_onlineresource" >>> >>> >> "http://localhost/~gba/cgi-bin/test.cgi?" >> >> >>> "wms_srs" "epsg:4326" >>> END >>> END >>> >>> # Legend >>> LEGEND >>> KEYSIZE 10 5 >>> LABEL >>> TYPE bitmap >>> SIZE medium >>> COLOR 0 0 0 >>> PARTIALS false >>> END >>> STATUS on >>> END >>> >>> # Scale bar >>> SCALEBAR >>> IMAGECOLOR 255 255 255 >>> LABEL >>> COLOR 0 0 0 >>> SIZE tiny >>> END >>> STYLE 1 >>> SIZE 50 2 >>> COLOR 0 0 0 >>> UNITS meters >>> INTERVALS 2 >>> STATUS on >>> END >>> >>> OUTPUTFORMAT >>> NAME "png" >>> DRIVER "GD/PNG" >>> MIMETYPE "image/png" >>> IMAGEMODE "rgba" >>> EXTENSION "png" >>> FORMATOPTION "transparent=on" >>> FORMATOPTION "interlace=on" >>> END >>> >>> >>> ########################################################################## >>> # Start of LAYER Definitions >>> --------------------------------------------- >>> >>> ########################################################################## >>> >>> # LAYER 9 : water ------------------------------------- >>> LAYER >>> NAME "water" >>> GROUP "background" >>> CONNECTIONTYPE postgis >>> CONNECTION "host=localhost dbname=test user=test >>> password=xxxxx port=5432" >>> DATA "wkb_geometry FROM water" >>> STATUS on >>> TYPE polygon >>> TRANSPARENCY alpha >>> >>> PROJECTION >>> "init=epsg:4326" >>> END >>> >>> CLASS >>> STYLE >>> COLOR 153 179 204 >>> OUTLINECOLOR -1 -1 -1 >>> ANTIALIAS true >>> END >>> END >>> >>> METADATA >>> "wms_title" "Water bodies" >>> "wms_srs" "EPSG:4326" >>> "wms_extent" "3.3 50.75 7.25 53.6" >>> END >>> END >>> END >>> >>> # test URL (GetMap) : >>> >>> >>> >> http://localhost/~gba/cgi-bin/test.cgi?service=wms&version=1.1.1&request=getmap&layers=background&styles=&srs=epsg:4326&width=800&height=600&format=image/png&bbox=3.358400,50.750400,7.227600,53.555000 >> >> >>> > Hi Gilles >>> > >>> > How does sour map-file look? OUTLINECOLOR -1 0 0 definitely should >>> >>> >> work. >> >> >>> > >>> > Mit freundlichem Gruss / Best Regards >>> > Flavio Hendry >>> > >>> > ---------------------------------------------------------------- >>> > TYDAC Web-Site: http://www.tydac.ch >>> > TYDAC MapServer: http://www.mapserver.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 >>> > ---------------------------------------------------------------- >>> > >>> > >>> > -----Original Message----- >>> > From: Gilles Bassi???re <gilles.bassiere at makina-corpus.com> >>> > To: Flavio Hendry <flavio at tydac.ch> >>> > Cc: MAPSERVER-USERS at LISTS.UMN.EDU >>> > Date: Mon, 30 Jul 2007 11:58:00 +0200 >>> > Subject: Re: [UMN_MAPSERVER-USERS] Polygon outline width >>> > >>> > >>> >> Hi Flavio >>> >> >>> >> Thanks for your help. Unfortunately, it has no effect on my map. >>> >>> >> I >> >> >>> >> tried >>> >> to set this value for OUTLINE in the CLASS element, then in the >>> >>> >> STYLE >> >> >>> >> element but rivers still appear very thick on my map when the >>> >>> >> scale >> >> >>> >> in >>> >> large... Actually, the same map is produced with OUTLINE -1 0 0 >>> >>> >> or >> >> >>> >> without. =( >>> >> >>> >> As explained in the FAQ, I tried to set up a circle symbol but it >>> >> seems >>> >> to work only for true lines, not for polygon outlines. >>> >> >>> >> Any other idea ? >>> >> >>> >> Gilles >>> >> >>> >>> Hi Gilles >>> >>> >>> >>> just set the OUTLINECOLOR to -1 0 0. >>> >>> >>> >>> Mit freundlichem Gruss / Best Regards >>> >>> Flavio Hendry >>> >>> >>> >>> >>> >>> >> ---------------------------------------------------------------- >> >> >>> >>> TYDAC Web-Site: http://www.tydac.ch >>> >>> TYDAC MapServer: http://www.mapserver.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 >> >> >>> >>> >>> >>> >> ---------------------------------------------------------------- >> >> >>> >>> >>> >>> >>> >>> -----Original Message----- >>> >>> From: Gilles Bassi???re >>> >>> >> <gilles.bassiere at MAKINA-CORPUS.COM> >> >> >>> >>> To: MAPSERVER-USERS at LISTS.UMN.EDU >>> >>> Date: Fri, 27 Jul 2007 15:09:22 +0200 >>> >>> Subject: [UMN_MAPSERVER-USERS] Polygon outline width >>> >>> >>> >>> >>> >>> >>> >>>> Hi there, >>> >>>> >>> >>>> I wonder whether it's possible to have no outline for a >>> >>> >> polygon. >> >> > > > -- > Gilles Bassiere > MAKINA CORPUS > 30 rue des Jeuneurs > FR-75011 PARIS > http://www.makina-corpus.com > > > > -- Gilles Bassiere MAKINA CORPUS 30 rue des Jeuneurs FR-75011 PARIS http://www.makina-corpus.com From micha at ARAVA.CO.IL Tue Jul 31 07:04:41 2007 From: micha at ARAVA.CO.IL (Micha Silver) Date: Tue, 31 Jul 2007 17:04:41 +0300 Subject: linked tables and spatial queries In-Reply-To: <200707301703.16669.dylan.beaudette@gmail.com> Message-ID: Dylan Beaudette wrote: > On Sunday 29 July 2007 06:23, you wrote: > >> On Thu, 28 Jun 2007 18:50:47 -0700, Dylan Beaudette >> >> wrote: >> >>> I was in need of this type of functionality, and found it through two >>> methods: >>> >>> 1. define a query template in your mapfile, and have it redirect the user >>> to a PHP page which can do related DB lookups and presentation. You can >>> pass along mapserver query results on the URL. >>> >>> 2. use something like ka-map and adjust how the query system displays the >>> results in the left-hand side panel. I modified the query functions such >>> that all searching and presentation was done via postgres+PHP. >>> >>> let me know if you need the details. >>> >> Hi Dylan: >> > > Hi! Glad to hear that you have made some progress. > > >> I'm working on a new site (displaying water quality for farmers around our >> > ...{clipped]... > > >> When I use the query button in the ka-map interface, what I get back (in >> the left panel) is : >> >> Layer Name: >> Wells >> results: 1 >> > > Right -- I had the same thing happen... details below. > > >> So it looks like the querying is working in general, just not retrieving >> the columns of data. Can you give me any pointers? I'd be glad to try to >> rewrite the map_query.php stuff in ka-map if necessary, but what should >> that script do exactly? The option to just write a query template in php is >> tempting but ka-map seems to be ignoring that TEMPLATE file. >> > > Since I am using the kaExplorer interface, the files you might be interested > in are in the folder tools/kaExplorer, specifically startUp.js . However, the > query system uses the file map_query_float.php > > I made my own version of this file, essentially removing much of what kamap > does by default : > > right after the lines: > //print common header to the floating query results box: > // echo "Query Results:
    "; > > ... put your stuff here. spatial queries (or attribute) are simple to write in > postgis- so I just made some functions which query tables based on either a > coordinate pair -- which this PHP function has access to ($coords) -- or a > bounding box, pass them to postgis, and return an associative array as the > result. loop through the result printing an HTML table -- there is an example > in the code -- and there you have it! > > Good luck, > > Dylan > > Thanks for the reply. That's what I was looking for. BTW, after some more fiddling, here's what I've found regarding ka-map's built in querying system: 1- You must enter "queryable" "true" (obviously) in the METADATA section of each LAYER that you want to query. This point is mentioned in the ka-map wiki : http://ka-map.ominiverdi.org/wiki/index.php/Query 2- You must have all queryable layers in their own GROUP. This I learned from your post: http://lists.maptools.org/pipermail/ka-map-users/2006-October/002298.html 3- I got query results ONLY when I added a "fields" line in the METADATA section as so: "fields" "name:Name,drill_dept:Depth,elevation:Elevation,aquifer_na:Aquifer" It's in the format: "fields" "column_1:alias_1,column_2:alias_2" Then the aliases happily appear in ka-map's left hand result window, with data values underneath. And one additional important piece of information that I gleaned from an obscure post somewhere: My DATA points to a view in postgresql. The view is a join of the geom table and the data table. (I'd assume many people work this way.) In order for the query to work when pointing to a postgresql view, you MUST have a column in the view named 'oid' with unique values. AND the view should be entered into the geometry_columns table in postgis. It took me a while to collect all these bits and pieces, so I'm trying to post this to mapserver-users also. My first question never made it to the list; hope this gets thru to possibly aid others. Warm regards, Micha -- Micha Silver Arava Development Co +972-8-6592270 From mlinden at ZEELANDNET.NL Tue Jul 31 08:56:52 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Tue, 31 Jul 2007 17:56:52 +0200 Subject: PHP mapscript Message-ID: Ok, let me format it differently; the next string fails to construct the projection that I need. Probably because towgs84= contains to much , seperators for the projection object to process. Please tell me what I can do to make this work! $projRDpma = ms_newprojectionobj("proj=sterea,lat_0=52.15616055555555,lon_0=5.38763888888889,k=0.999908,x_0=155000,y_0=463000,ellps=bessel,units=m,towgs84=565.2369,50.0087,465.658,-0.406857330322398,0.350732676542563,-1.87 03473836068,4.0812,no_defs"); Milo van der Linden
    SomaFM From dmorissette at MAPGEARS.COM Tue Jul 31 09:59:48 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 31 Jul 2007 12:59:48 -0400 Subject: PHP mapscript In-Reply-To: <33875.213.201.130.58.1185897412.squirrel@secure.zeelandnet.nl> Message-ID: Milo van der Linden wrote: > Ok, let me format it differently; > the next string fails to construct the projection that I need. Probably > because towgs84= contains to much , seperators for the projection object > to process. Please tell me what I can do to make this work! > > $projRDpma = > ms_newprojectionobj("proj=sterea,lat_0=52.15616055555555,lon_0=5.38763888888889,k=0.999908,x_0=155000,y_0=463000,ellps=bessel,units=m,towgs84=565.2369,50.0087,465.658,-0.406857330322398,0.350732676542563,-1.87 > 03473836068,4.0812,no_defs"); > The proj definition above gives me the following error: msProcessProjection(): unknown projection id After a quick check, I suspect you probably need to use proj=stere instead of proj=sterea as the projection name ... and then the "+" form of projection definition works (the comma-delimited version screws up the towgs params as you had expected). setProjection($proj_string); echo $map->getProjection(); ?> Daniel -- Daniel Morissette http://www.mapgears.com/ From mlinden at ZEELANDNET.NL Tue Jul 31 11:30:54 2007 From: mlinden at ZEELANDNET.NL (Milo van der Linden) Date: Tue, 31 Jul 2007 20:30:54 +0200 Subject: PHP mapscript In-Reply-To: <46AF6A84.7050500@mapgears.com> Message-ID: (Milo Jumps up and Dances!) Daniel, Fabulous! That did the trick, had I known from the start I could feed it the + delimited string, it would have saved me a lot of pain! Gratefully yours! (Milo takes a bow) Daniel Morissette schreef: > Milo van der Linden wrote: >> Ok, let me format it differently; >> the next string fails to construct the projection that I need. Probably >> because towgs84= contains to much , seperators for the projection object >> to process. Please tell me what I can do to make this work! >> >> $projRDpma = >> ms_newprojectionobj("proj=sterea,lat_0=52.15616055555555,lon_0=5.38763888888889,k=0.999908,x_0=155000,y_0=463000,ellps=bessel,units=m,towgs84=565.2369,50.0087,465.658,-0.406857330322398,0.350732676542563,-1.87 >> >> 03473836068,4.0812,no_defs"); >> > > The proj definition above gives me the following error: > > msProcessProjection(): unknown projection id > > After a quick check, I suspect you probably need to use proj=stere > instead of proj=sterea as the projection name ... and then the "+" > form of projection definition works (the comma-delimited version > screws up the towgs params as you had expected). > > > $proj_string = "+proj=stere +lat_0=52.15616055555555 > +lon_0=5.38763888888889 +k=0.999908 +x_0=155000 +y_0=463000 > +ellps=bessel +units=m > +towgs84=565.2369,50.0087,465.658,-0.406857330322398,0.350732676542563,-1.8703473836068,4.0812 > +no_defs"; > > // Use mapObj.getProjection() to verify that the projection is parsed > properly > $map = ms_newmapobj(""); > $map->setProjection($proj_string); > echo $map->getProjection(); > > ?> > > Daniel -- Milo van der Linden mlinden at zeelandnet.nl milovanderlinden at gmail.com milo at 3dsite.nl http://www.3dsite.nl De informatie in dit bericht reflecteerd mijn persoonlijke mening en niet die van een bedrijf of instantie. Aan de informatie kunnen geen rechten worden ontleend. Indien dit bericht onderdeel is van een forum, mailing-list of community dan gelden automatisch de bijbehorende voorwaarden. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dhober at GEOGRAPHIT.COM Tue Jul 31 12:05:51 2007 From: dhober at GEOGRAPHIT.COM (David Hober) Date: Tue, 31 Jul 2007 15:05:51 -0400 Subject: Zoom To Scale Message-ID: Greetings, I'm having some trouble trying to achieve a zoom to scale effect in a mapping program. I'm using mapscript's c# library, version 4.10. I tried setting the map object's scale property, but that had no effect, so I'm trying to achieve it now by resetting the extent of the map. The method that does the calculation receives a fractional scale value (say, 50000). I calculate the center point in map units, but I just can't figure out how to scale the extent to achieve the user-provided scale value. I'm open for any suggestions / ideas. -- Dave -------------- next part -------------- An HTML attachment was scrubbed... URL: From srph124 at YAHOO.COM Tue Jul 31 12:10:49 2007 From: srph124 at YAHOO.COM (s r) Date: Tue, 31 Jul 2007 12:10:49 -0700 Subject: Fwd: Some Question about MapServer features Message-ID: Note: forwarded message attached. --------------------------------- Yahoo! oneSearch: Finally, mobile search that gives answers, not web links. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- An embedded message was scrubbed... From: s r Subject: Fwd: Some Question about MapServer features Date: Mon, 30 Jul 2007 03:01:57 -0700 (PDT) Size: 3357 URL: From dmorissette at MAPGEARS.COM Tue Jul 31 14:18:33 2007 From: dmorissette at MAPGEARS.COM (Daniel Morissette) Date: Tue, 31 Jul 2007 17:18:33 -0400 Subject: Problem Opening MapInfo Table In-Reply-To: <20070728213838.GA23357@www.gisnet.com> Message-ID: Bill Thoen wrote: > Does anyone know if there are issues opening a MapInfo seamlesss table of > views? I've got a seamless table of roads in several states that's refusing > to draw in a map widnow. The roads tables are standard MapInfo views, and > they are collected together into a seamless table. Other seamless table of > normal tables do work, but not this one. I just want to make sure this > format isn't too weird for MapServer's OGR CONNECTIONTYPEs. > You got it, the problem is that the MITAB driver in OGR doesn't support seamless tables of views. It only supports seamless tables of "normal" tables. Daniel -- Daniel Morissette http://www.mapgears.com/ From anhtin at GMAIL.COM Tue Jul 31 19:13:41 2007 From: anhtin at GMAIL.COM (anhtin) Date: Tue, 31 Jul 2007 19:13:41 -0700 Subject: how can resize buffer point Message-ID: hi all how could i resize buffer point by mapserver?? -- View this message in context: http://www.nabble.com/how-can-resize-buffer-point-tf4197537.html#a11938410 Sent from the Mapserver - User mailing list archive at Nabble.com. From jmpmcmanus at YAHOO.COM Tue Jul 31 19:16:44 2007 From: jmpmcmanus at YAHOO.COM (James McManus McManus) Date: Tue, 31 Jul 2007 19:16:44 -0700 Subject: mapscript.mapObj(map_path+map_file) Message-ID: In the past I was able to run python mapscripts, but recently I have been getting a strange error when running scripts: [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] Traceback (most recent call last): [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] File "/var/www/cgi-bin/check.py", line 8, in [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] map = mapscript.mapObj(map_path+map_file) [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] File "/usr/lib64/python2.5/site-packages/mapscript.py", line 1219, in __init__ [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] this = _mapscript.new_mapObj(*args) [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] _mapscript.MapServerError: msInitGDALOutputFormat(): General error message. No GDAL driver named `GTiff' available. [Tue Jul 31 21:45:58 2007] [error] [client 71.241.222.127] Premature end of script headers: check.py ----------------------------------------------------------------------------------------------------------------------- check.py is a very simple test script: #!/usr/bin/python import mapscript, string map_path = "/var/www/html/mapserver/" map_file = "third.map" input = open(map_path+map_file, 'r') infile = input.readlines() map = mapscript.mapObj(map_path+map_file) print "Content-type: text/html" print print "" print "
    Python Mapscript Hello World
    " print "" print string.lower(infile[1]) print infile[1] print map.extent print "" print "" I am able to run this same script from my shell prompt, without getting an error. I am also able to run this script, from my server, if I comment out: map = mapscript.mapObj(map_path+map_file), and print map.extent The error only occurs when I try to use mapscript.mapObj in a script being accessed through my server. Strange!!! Jim -------------- next part -------------- An HTML attachment was scrubbed... URL: