Re: [mapserver-users] Customized layer for Mapserver/Kamap
Hi, In your mapfile you define the layers and the colors. See example below. If you have an SRID (projection) for the layer use it. You can see what it is by selecting this sql in pgadmin: select srid(the_geom) from cities) . Use the number you get here in the mapserver layer definition and in the projection definition as well. If you loaded the cities with shp2pgsql then you should automatically have a gid field on the cities table. And your cities table should have a population field the type of which should be some kind of number. LAYER METADATA wms_title Cities layer END NAME cities TRANSPARENCY 100 CONNECTIONTYPE postgis CONNECTION host=??? user=??? dbname=??? password='???' DATA the_geom from cities using srid=??? USING UNIQUE gid TYPE POLYGON CLASS NAME Small cities EXPRESSION ( [population] 5) COLOR 0 255 0 END CLASS NAME Medium cities EXPRESSION ([population] 5 AND [population] 150 ) COLOR 255 255 0 END CLASS NAME Big cities EXPRESSION ([population] 150 ) COLOR 255 0 0 END END Hope this helps, Florin ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Customized layer for Mapserver/Kamap
Hi, Kamap was designed to only take Mapserver input, yes. Mapserver will take most formats. You can have data in shapefiles, in a database, a raster image, or in a text file. Do you have polygons for the cities or do you want to just draw a circle at their lat/long ? On Mon, May 12, 2008 at 4:20 PM, Emilio Ponce [EMAIL PROTECTED] wrote: Hi everyone, I'm working with mapserver using ka-map. Now I'm trying to create a new layer over the others using alphanumeric data, and I was wondering what's the best method. My idea is to represent this data with a colour gradient. For example if the data are like this: City Population --- Barcelona 400 Madrid 700 I want to represent the Barcelona area with a light red colour, and Madrid with a darker red. Someone told me that the only input to Ka-map is mapserver, and mapserver uses GDAL/OGR library for this kind of tasks... so what is the best kind of input format using this library? And in order to represent the data with the colour gradient, where I have to link the alphanumeric data (e.g 400) with the colour (e.g. dark red)? Thank you very much guys! ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] ArcGIS Image Server
The 9.3 version of ArcGIS will be able to serve Image Server services as WMS. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Re: flash swf output
The reason to have names for the buttons is so that the loader swf can reference them with Action Script and change their color, position, etc... This could be done even without having names, because at runtime the Flash player assigns to each movie clip a name if it does not have one. These are called 'instance1', 'instance2', 'instance3' etc... These can be referenced by Action Script. Unfortunately, the buttons in the SWF output from MapServer can't be referenced by ActionScript at all. Neither with the 'instance1' syntax, nor with the new 'button212', 'button213', etc names that are assigned to the buttons with this fix. I am not sure why this is. I've created a few Ming movies to test this. Make a simple movie in MING with two buttons. Don't give them names. Then create a Flash movie with two buttons named thebtn, and one called loadming, a blank movie on the stage called swfContainer, and this actionscript which will load ming_output.swf. var mcLoader:MovieClipLoader = new MovieClipLoader(); thebtn.onRelease = function() { for (var mcname in swfContainer) { trace(mcname); if (mcname == instance2) { _root.swfContainer[mcname]._x += 10; } } }; loadming.onRelease = function(){ mcLoader.loadClip(ming_output.swf, swfContainer); } If you load any Ming swf with this script, you'll be able to move 10 pixels to the right anything in that swf called instance2. If you load a MapServer swf you won't be able to do this. All of the buttons in the swf will move 10 pixels to the right because _root.swfContainer.instance1 returns a reference to the parent _root.swfContainer . I'm trying to look at the mapswf.c code to see why this might be happening, but its over 3000 lines, so it will be a while, unless anybody has some ideas. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] compiling on windows
Hi Frank, I forgot the rest C:\projects\regex-0.12\regex.c(4079) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4110) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4123) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4293) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3771) : warning C4101: 'destination' : unreferenced local variable C:\projects\regex-0.12\regex.c(3918) : warning C4101: 'destination' : unreferenced local variable C:\projects\regex-0.12\regex.c(3971) : warning C4101: 'destination' : unreferenced local variable C:\projects\regex-0.12\regex.c(4110) : warning C4101: 'destination' : unreferenced local variable C:\projects\regex-0.12\regex.c(4123) : warning C4101: 'destination' : unreferenced local variable C:\projects\regex-0.12\regex.c(4876) : warning C4996: 'errcode' was declared deprecated C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE\crtdefs.h(506) : see declaration of 'errcode' Message: 'This name was supported during some Whidbey pre-releases. Instead, use the standard name errno_t.' C:\projects\regex-0.12\regex.c(4876) : error C2081: 'preg' : name in formal parameter list illegal C:\projects\regex-0.12\regex.c(4876) : error C2081: 'errbuf' : name in formal parameter list illegal C:\projects\regex-0.12\regex.c(4876) : error C2081: 'errbuf_size' : name in formal parameter list illegal C:\projects\regex-0.12\regex.c(4877) : error C2055: expected formal parameter list, not a type list C:\projects\regex-0.12\regex.c(4877) : error C2082: redefinition of formal parameter 'errcode' C:\projects\regex-0.12\regex.c(4885) : warning C4996: 'errcode' was declared deprecated C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE\crtdefs.h(506) : see declaration of 'errcode' Message: 'This name was supported during some Whidbey pre-releases. Instead, use the standard name errno_t.' C:\projects\regex-0.12\regex.c(4885) : error C2059: syntax error : 'type' C:\projects\regex-0.12\regex.c(4893) : error C2275: 'errcode' : illegal use of this type as an expression C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE\crtdefs.h(506) : see declaration of 'errcode' C:\projects\regex-0.12\regex.c(4910) : warning C4996: 'strcpy' was declared deprecated Message: 'This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_DEPRE CATE. See online help for details.' NMAKE : fatal error U1077: 'C:\Program Files\Microsoft Visual Studio 8\VC\BIN\cl.EXE' : return code '0x2' Stop. On Mon, Apr 7, 2008 at 2:03 PM, Frank Warmerdam [EMAIL PROTECTED] wrote: Florin A. wrote: Hello, I'm trying to compile MapServer on Windows Server 2003. I followed all the instructions on http://mapserver.gis.umn.edu/docs/howto/win32_compiling and I'm stuck with regex errors. The errors are the same as this post http://www.mail-archive.com/[EMAIL PROTECTED]/msg15996.html I'm compiling with nmake from Microsoft Visual Studio 8 I also tried compiling with the buildkit from http://download.osgeo.org/buildkit/ and got the same errors. regex.c C:\projects\regex-0.12\regex.c(768) : warning C4018: '' : signed/unsigned mismatch ... C:\projects\regex-0.12\regex.c(1953) : warning C4018: '' : signed/unsigned mismatch I tried the correction mentioned for the regex.c file: //extern void printchar (); void printchar( int i ) {} This made no difference. I also tried with the win32 regex distribution from http://people.delphiforums.com/gjc/gnu_regex.exe and again, exactly the same errors. Has anybody else encountered this regex error? Shouldn't nmake work with no problems on the buildkit ? Florin, The above are just warnings. I would encourage you to just ignore them and proceed. Best regards, -- ---+-- I set the clouds in motion - turn up | Frank Warmerdam, [EMAIL PROTECTED] light and sound - activate the windows | http://pobox.com/~warmerdamhttp://pobox.com/%7Ewarmerdam and watch the world go round - Rush| President OSGeo, http://osgeo.org ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] compiling on windows
Hi Tamas, I added MSVC_VER=1400 I call nmake like this: C:\projects\mapserver-5.0.2nmake /f Makefile.vc MSVC_VER=1400 The errors are the same as before: C:\projects\mapserver-5.0.2nmake /f Makefile.vc MSVC_VER=1400 Microsoft (R) Program Maintenance Utility Version 8.00.50727.42 Copyright (C) Microsoft Corporation. All rights reserved. cl /nologo /Ox /MD /W3 /DDEBUG /EHsc /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE -IC:/projects/gdwin32 -Ic:\projects\map server-5.0.2\..\jpeg-6b -IC:\projects\proj-4.4.9/src -IC:\projects\regex-0.12 -Ic:\projects\mapserver-5.0.2\..\zlib-1.2.3 -DHAVE_STRING_H -DREGEX_MALLOC -DNEED_STRCASECMP -DNEED_STRNCASECMP -DNEED_STRLCAT-DUSE_PROJ -DUSE_PROJ_API_H -DUSE_JPEG -DUSE_GD_PNG -DUSE_GD_JPEG -DUSE_GD_WBMP -DUSE_GD_GIF -DGD_HAS_GDIMAGEGIFPTR -DUSE_GD_FT -DGD_HAS_GETBITMAPFONT -DGD_HAS_FTEX_XSHOW -DUSE_WMS_SVR -DUSE _THREAD-DIGNORE_MISSING_DATA -DENABLE_STDERR_DEBUG -DUSE_GD_ANTIALIAS -DUSE_ZLIB-DWIN32 -D_WIN32 /c C:\projects\r egex-0.12\regex.c /FoC:\projects\regex-0.12\regex.obj regex.c C:\projects\regex-0.12\regex.c(768) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(774) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1123) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1189) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1204) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1297) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1322) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1336) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1346) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1358) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1364) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1372) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1608) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1638) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1683) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1698) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1726) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1813) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1926) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1932) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1937) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1941) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1945) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1949) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1953) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1957) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(1975) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(2023) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(2027) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(2042) : warning C4013: 'free' undefined; assuming extern returning int C:\projects\regex-0.12\regex.c(2236) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(2784) : warning C4013: 'abort' undefined; assuming extern returning int C:\projects\regex-0.12\regex.c(2834) : warning C4047: '=' : 'regoff_t *' differs in levels of indirection from 'int' C:\projects\regex-0.12\regex.c(3313) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3403) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3427) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3480) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3496) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3760) : warning C4018: '' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3771) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3918) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(3971) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4079) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4110) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4123) : warning C4018: '=' : signed/unsigned mismatch C:\projects\regex-0.12\regex.c(4293) : warning C4018: '='
Re: [mapserver-users] compiling on windows
The message was complaining about the 'errcode' variable in regex.c I changed regex.c code at lines 4876, 4877, 4885, 4886, 4893 and replaced all occurences of 'errcode' in the regerror function with 'errcode2'. Then mapserver compiled :) ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] flash swf output
Hello, I have a couple of suggestions for the SWF output which would really help with making more interesting applications: -THE most important: name the objects in the swf so they can be accessed by ActionScript -define the rollover, rollout, press and release actions in one prototype in the root. this will not break any existing applications and will reduce file size a bit. -allow the user to set the amount by which the resolution can be reduced. how much is lost with FULL_RESOLUTION=FALSE ? -line thickness for vector lines I'd like to help work on some of these things, but I need some guidance. Maybe a google summer of code thing? I am a student Also, the page at http://www2.dmsolutions.ca/mapserver/dl/FlashMapserverUserDoc.html should be updated to indicate that the new version of XAMPP contains a compiled version of Ming 0.4 for Windows. Florin ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users