[mapserver-users] Is there still a 2GB size limit on shapefiles?

2013-05-08 Thread Roger André
Pretty sure I just hit this
http://trac.osgeo.org/mapserver/ticket/3514 problem
in my 6.0.3 local stack.  I haven't tested it in the current release, but
does anyone know for sure that a shapefile with any component larger than
2GB works in 6.2?

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Is there still a 2GB size limit on shapefiles?

2013-05-08 Thread Roger André
Very interesting to know this. Thank you all for the feedback.

I did use the OGR connector and it worked fine, but I assumed the native
reader was faster.
On May 8, 2013 9:53 PM, Stephen Woodbridge wood...@swoodbridge.com
wrote:

 In general the shapefile spec is owned by ERSI and unless they change the
 spec you will have a problem. Last I knew, there are pointers/offsets
 inside the shapefile that are only 32bits wide per the spec. it is because
 of these that you are limited to 2GB.

 At some point I thought Frank W or someone was working on a version of
 shapelib that could support greater than 2GB, but only programs that used
 that version would be able to read/write these larger files. I have not
 heard anything on that front in a while so I don't know if that was just
 talk, or code ever materialized.

 -Steve W

 On 5/9/2013 12:32 AM, Rahkonen Jukka wrote:

 Hi,

 I am not sure either if reading 2GB shapefiles works with the native
 shp reader on all platforms, but as the ticket says, you should be
 able to use OGR connection in the mapfile even with your current
 version. If you use OGR you can also split the shapefile into pieces
 and read them through the ogr tileindex system which may be faster
 sometimes.

 -Jukka Rahkonen-

 __**__ Andrea Peri wrote:

  If it don't work you should evalute the option to use spatialite.
 It work well with dataset greater than 2GB . I use it with
 mapserver 6.3dev and gdal 1.10.




 2013/5/9 Roger André 
 ran...@gmail.commailto:randr**e...@gmail.comran...@gmail.com
 
 Pretty sure I just hit
 thishttp://trac.osgeo.org/**mapserver/ticket/3514http://trac.osgeo.org/mapserver/ticket/3514
 problem in my 6.0.3
 local stack.  I haven't tested it in the current release, but does
 anyone know for sure that a shapefile with any component larger than
 2GB works in 6.2?

 Roger

 __**_ mapserver-users
 mailing list
 mapserver-users@lists.osgeo.**org mapserver-users@lists.osgeo.org
 mailto:mapserver-users@**lists.osgeo.orgmapserver-users@lists.osgeo.org
 


  
 http://lists.osgeo.org/**mailman/listinfo/mapserver-**usershttp://lists.osgeo.org/mailman/listinfo/mapserver-users





 -- - Andrea Peri . . . . . . . . . qwerty àèìòù
 - __**_
 mapserver-users mailing list 
 mapserver-users@lists.osgeo.**orgmapserver-users@lists.osgeo.org
 http://lists.osgeo.org/**mailman/listinfo/mapserver-**usershttp://lists.osgeo.org/mailman/listinfo/mapserver-users


 __**_
 mapserver-users mailing list
 mapserver-users@lists.osgeo.**org mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/**mailman/listinfo/mapserver-**usershttp://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Location of geometriespdf page in new website

2010-05-22 Thread Roger André
Can someone point me to the new location of this page?

-
http://mapserver.gis.umn.edu/community/conferences/MUM3/workshop/python/geometriespdf

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] compilation error

2010-05-13 Thread Roger André
Try installing the following ogdi packages with apt-get:

libogdi3.2 - Open Geographic Datastore Interface Library -- library
libogdi3.2-dev - Open Geographic Datastore Interface Library -- development
ogdi-bin - Open Geographic Datastore Interface Library -- utilities

No idea if that will do the trick though.  I've never seen that particular
error before.

Roger
--

On Wed, May 12, 2010 at 11:36 AM, pablo lopez plabl...@gmail.com wrote:

 Hi List, Im building mapserver 5.6.3 on a ubuntu box. The config script I'm
 using is:
 ./configure --prefix=/usr \
 --with-ogr=/usr/bin/gdal-config \
 --with-gdal=/usr/bin/gdal-config \
 --with-httpd=/usr/sbin/apache2 \
 --with-wfsclient \
 --with-fribidi \
 --with-wmsclient \
 --with-wfs \
 --with-pdf \
 --enable-debug \
 --with-curl-config=/usr/bin/curl-config \
 --with-proj=/usr \
 --with-tiff \
 --with-gd \
 --with-jpeg \
 --with-png=/usr/lib \
 --with-freetype=/usr/lib \
 --with-threads \
 --with-wcs \
 --with-postgis=/usr/bin/pg_config \
 --with-geos=/usr/bin/geos-config \
 --with-libiconv=/usr/lib \
 --with-php=/usr/include/php5 \
 --with-agg


  The config output is:

 MapServer is now configured for

  -- Compiler Info -
   C compiler:gcc -g  -fPIC -Wall
   C++ compiler:  g++ -g  -fPIC -Wall
   Debug: -g
   Generic NINT:

  -- Renderer Settings -
   OpenGL support:
   zlib support:  -DUSE_ZLIB
   png support:
   palette rgba png support:
   jpeg support:
   iconv support: -DUSE_ICONV
   AGG support:   -DUSE_AGG
   Cairo (SVG,PDF) support:
   Ming(flash) support:
   PDFLib support:-DUSE_PDF

  -- Support Libraries -
   Proj.4 support:-DUSE_PROJ
   Libxml2 support:   -DUSE_LIBXML2
   FriBidi support:
   Curl support:  -DUSE_CURL
   FastCGI support:
   Threading support: -DUSE_THREAD
   GEOS support:  -DUSE_GEOS -DGEOS_HAS_SIMPLIFY

  -- Data Format Drivers ---
   native tiff support:   -DUSE_TIFF
   PostGIS support:   -DUSE_POSTGIS
   EPPL7 support: -DUSE_EPPL
   ArcSDE support:
   OGR support:   -DUSE_OGR
   GDAL support:  -DUSE_GDAL
   Oracle Spatial support:

  -- OGC Services --
   WMS Server:-DUSE_WMS_SVR
   WMS Client:-DUSE_WMS_LYR
   WFS Server:-DUSE_WFS_SVR
   WFS Client:-DUSE_WMS_LYR
   WCS Server:-DUSE_WCS_SVR
   SOS Server:

  -- MapScript -
   PHP MapScript: yes


 Now, when i run make, it ends up with the following error:

 shp2img.c:33: warning: ‘cvsid_aw’ defined but not used
 g++ -g  -fPIC -Wall -DHAVE_VSNPRINTF -DNEED_STRLCAT
 -DNEED_STRRSTR-DUSE_WMS_LYR -DUSE_WFS_LYR  -DUSE_LIBXML2 -DUSE_CURL
 -DUSE_WCS_SVR -DUSE_WFS_SVR -DUSE_WMS_SVR-DUSE_POSTGIS -DUSE_TIFF
 -DUSE_GDAL -DUSE_OGR -DUSE_GEOS -DGEOS_HAS_SIMPLIFY  -DUSE_THREAD -DUSE_PROJ
 -DUSE_EPPL  -DUSE_AGG   -DUSE_PDF  -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_ICONV -DUSE_ZLIB -I/usr/include
 -I/usr/include/freetype2-I/usr/include -I/usr/include/gdal
 -I/usr/include/postgresql -I/usr/include-I/usr/include/libxml2
 shp2img.o  -L. -lmapserver -lgd -L/usr/lib64 -lgd -ljpeg -L/usr/lib
 -lfreetype -L/usr/lib -lpng -lz -lXpm -lX11 -lpdf -ltiff -ljpeg
 -L/usr/lib -lfreetype -L/usr/lib -lpng -lz -lXpm -lX11  -L/usr/lib64 -lproj
 -ljpeg -L/usr/lib -lpng  -L/usr/lib -lgdal1.6.0 -L/usr/lib -lgeos_c
 -I/usr/include -lsqlite3 -lodbc -lodbcinst -L/usr/lib -lexpat -L/usr/lib
 -lxerces-c -lpthread -ljasper -lhdf5 -lmfhdf -ldf -logdi -lgif -ljpeg -lpng
 -lnetcdf -lpq -L/usr/lib -lpq -lz -lpthread -lm -lrt -ldl -lcurl
 -Wl,-Bsymbolic-functions -rdynamic -L/usr/lib/mysql -lmysqlclient
 -L/usr/lib -lpq -lpgport -lxslt -lxml2 -lpam -lssl -lcrypto -lkrb5 -lcom_err
 -lgssapi_krb5 -lz -lreadline -lcrypt -ldl -lm   -lcurl  -L/usr/lib -lgeos_c
 -lpthread -L -lc  -lz -lxml2  -lm -lstdc++-o shp2img
 /usr/bin/ld: cannot find -logdi
 collect2: ld returned 1 exit status
 make: *** [shp2img] Error 1


 I'm lost here, any help is appreciated
 Thanks
 Pablo

 ___
 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

Re: [mapserver-users] WCS 1.0 vs 1.1 image shifted

2010-05-02 Thread Roger André
Hi Ben,

I think it's a bug, at least based on the conversation that took place last
year with Steve Lime regarding this -
http://www.mail-archive.com/mapserver-users@lists.osgeo.org/msg06123.html

I'm not sure what the current state is of this though.

Roger
--

On Fri, Apr 30, 2010 at 1:18 PM, Ben Tuttle benjamin.tut...@gmail.comwrote:

 I am trying to understand the results I am getting from WCS requests
 to MapServer.
 If I make the same request changing only the WCS version the images I
 get back are shifted by 1 pixel in the x and y directions. A request
 for VERSION=1.1.0 gives me the image I expect while VERSION=1.0.0
 gives me back an image shifted by 1 pixel in the x and y directions to
 the North and West.
 The underlying data and mapfile are the same in both cases. So I am
 not sure if this is perhaps a MapServer bug or if perhaps I am reading
 the WCS spec incorrectly and this is actually the intended result (I
 hope it's not). Can anyone help me out?

 Request Examples:

 http://map.ngdc.noaa.gov/cgi-bin/mapserver/test_image_ms_wcs100_avgvis42_23_47_28.tif?map=../../../nfs/gisdata/mapserver/gcv4/index.maprequest=GetCoverageservice=WCSCOVERAGE=F162008_v4_avg_viscrs=EPSG:4326VERSION=1.0.0format=geotiffresx=0.008333resy=0.008333bbox=42,23,47,28


 http://map.ngdc.noaa.gov/cgi-bin/mapserver/test_image_ms_wcs110_avgvis42_23_47_28.tif?map=../../../nfs/gisdata/mapserver/gcv4/index.maprequest=GetCoverageservice=WCSCOVERAGE=F162008_v4_avg_viscrs=EPSG:4326VERSION=1.1.0format=geotiffresx=0.008333resy=0.008333bbox=42,23,47,28


 System Details:
 MapServer version 5.6.3 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
 OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV
 SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER
 SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER
 SUPPORTS=THREADS SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS
 INPUT=ORACLESPATIAL INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE

 Red Hat Enterprise Linux Server release 5.5 (Tikanga)

 --
 Cheers, Ben Tuttle
 ___
 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] Need help testing WMS segfault

2010-01-30 Thread Roger André
Done.  Opened Ticket #3280.

Thanks for the help.
--



On Fri, Jan 29, 2010 at 5:37 PM, Paul Ramsey pram...@opengeo.org wrote:

 Right here:
 http://www.osgeo.org/osgeo_userid

 On 2010-01-29, at 5:09 PM, Roger André wrote:

 It appears I need an OsGeo login with TICKET_CREATE privileges.  How do I
 get one of those?
 --

 On Fri, Jan 29, 2010 at 5:04 PM, Roger André ran...@gmail.com wrote:

 sigh  I'm an idiot.  Total size is much smaller.
 72Kagg_wms_segfault.tar.gz

 Paul, you'll appreciate this.  The file is much smaller when you do this:

 $ ogr2ogr parcel_clip.shp PG:host=localhost dbname=foo \
-sql SELECT
  parcel_id,
  import_exp,
  external_i,
  ST_Intersection('SRID=4326;POLYGON((-122.339256836
 47.6576914062,

 -122.331763672 47.6576914062,

 -122.331763672 47.6651845703,

-122.339256836 47.6651845703,

 -122.339256836 47.6576914062))', the_geom)
   FROM parcel
   WHERE 'SRID=4326;POLYGON((-122.339256836 47.6576914062,
-122.331763672
 47.6576914062,
-122.331763672
 47.6651845703,
-122.339256836
 47.6651845703,
-122.339256836
 47.6576914062))'
the_geom \
-nlt POLYGON

 instead of just:

 $ ogr2ogr parcel_clip.shp PG:host=localhost dbname=foo \
-sql SELECT
  parcel_id,
  import_exp,
  external_i,
  ST_Intersection('SRID=4326;POLYGON((-122.339256836
 47.6576914062,

 -122.331763672 47.6576914062,

 -122.331763672 47.6651845703,

-122.339256836 47.6651845703,

 -122.339256836 47.6576914062))', the_geom)
   FROM parcel
-nlt POLYGON

 I'll file the bug now.

 Roger
 --




 On Fri, Jan 29, 2010 at 4:42 PM, Paul Ramsey pram...@opengeo.org wrote:

 File bug in trac

 http://trac.osgeo.org/mapserver

 With a 5mb attachement, you might need to separately upload it somewhere
 and post a URL, not sure what the attachment max size is for osgeo trac.

 P

 On 2010-01-29, at 4:40 PM, Roger André wrote:

 Alright, I've clipped the data sets down to areas just slightly larger
 than the WMS bbox, cleaned up the map file, and replicated the WMS to make
 sure that it still breaks.  The tgz file that contains the mapfile and 2
 shapefiles is just under 5 MB.  Where should I file the bug, and can I
 attach the data to the bug?

 Thanks,

 Roger
 --



 On Fri, Jan 29, 2010 at 2:57 PM, Roger André ran...@gmail.com wrote:

 Hi Paul,

 Ok.  I'll see if I can replicate the problem with a single data layer,
 and will then package everything together so another developer can run it.

 Thanks,

 Roger
 --


 On Fri, Jan 29, 2010 at 2:16 PM, Paul Ramsey pram...@opengeo.orgwrote:

 Lovely, Another AGG bug. Well the next thing is to package up your
 environment so a developer can duplicate the problem on their rig. Figure
 out which layer it is, so you only have to pack that data up. Since the
 issue is arising in AGG, flag the ticket to the AGG module. When you pack 
 up
 your map file, remember to also pack up or strip out things like 
 templates,
 font libraries, symbol libraries, etc. Ideally, copy the whole mess to a 
 new
 path on your system ensure it does in fact run independently of the rest 
 of
 your installation.

 Best,

 Paul

 On 2010-01-29, at 2:11 PM, Roger André wrote:

 Hi Paul,

 Thanks for the advice. (Chris Schmidt suggested I do the same thing in
 IRC yesterday, and I forgot to try it.)

 Below are the results of gdb.  It's fun to run, but uhm... not
 something I'm readily able to decipher (yet).

 $ gdb /usr/lib/cgi-bin/mapserv
 GNU gdb (GDB) 7.0-ubuntu
 Copyright (C) 2009 Free Software Foundation, Inc.
 License GPLv3+: GNU GPL version 3 or later 
 http://gnu.org/licenses/gpl.html
 This is free software: you are free to change and redistribute it.
 There is NO WARRANTY, to the extent permitted by law.  Type show
 copying
 and show warranty for details.
 This GDB was configured as i486-linux-gnu.
 For bug reporting instructions, please see:
 http://www.gnu.org/software/gdb/bugs/...
 Reading symbols from /usr/lib/cgi-bin/mapserv...done.
 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 Starting program: /usr/lib/cgi-bin/mapserv
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 [Thread debugging using libthread_db enabled]

 Program received signal SIGSEGV, Segmentation fault.
 0x0740bbf2

Re: [mapserver-users] New to mapserver; question about USGS DRG/GeoTIFF files

2010-01-29 Thread Roger André
Hi Jon,

You don't appear to have any projection info in your map file.  Since you
have UNITS dd in it, I assume you want to display the map in lat/lon
WGS84?  If so, your MAP file needs an entry that looks like this:

  PROJECTION
init=epsg:4326
  END

and your usgs LAYER (the name should be quoted btw) should have the UTM
projection defined in it, like this:

LAYER
  NAME usgs
  PROJECTION  init=epsg:26719 END

Best of luck,

Roger
--




On Fri, Jan 29, 2010 at 4:38 AM, Jon Miner cp_...@yahoo.com wrote:




 Hi -

 I'm new to Mapserver, and so far impressed by it's capabilities.  I've
 installed the FGS package via
 fgs-mapserver_basic_5.6.0-fgs_9.5-linux-i386.bin and played with their demo
 program.

 I'm having a problem with a USGS DRG file that is encoded as a GeoTIFF
 file.  It doesn't display on the webpage, and I'm not sure where to start
 debugging this.  I've checked the file with gdalinfo:

 Driver: GTiff/GeoTIFF
 Files: o43071a4.tif
 Size is 5388, 6854
 Coordinate System is:
 PROJCS[NAD27 / UTM zone 19N,
GEOGCS[NAD27,
DATUM[North_American_Datum_1927,
SPHEROID[Clarke 1866,6378206.4,294.9786982138982,
AUTHORITY[EPSG,7008]],
AUTHORITY[EPSG,6267]],
PRIMEM[Greenwich,0],
UNIT[degree,0.0174532925199433],
AUTHORITY[EPSG,4267]],
PROJECTION[Transverse_Mercator],
PARAMETER[latitude_of_origin,0],
PARAMETER[central_meridian,-69],
PARAMETER[scale_factor,0.9996],
PARAMETER[false_easting,50],
PARAMETER[false_northing,0],
UNIT[metre,1,
AUTHORITY[EPSG,9001]],
AUTHORITY[EPSG,26719]]
 Origin = (295125.99949388772,4778305.84265616444)
 Pixel Size = (2.4384000,-2.4384000)
 Metadata:
  AREA_OR_POINT=Area
  TIFFTAG_IMAGEDESCRIPTION=USGS GeoTIFF DRG 1:24000 Quad of Manchester
 North. Product:522644
  TIFFTAG_SOFTWARE=USGS CD Archiver program tif2usgsdrg v.1.0
  TIFFTAG_DATETIME=1997:01:10 07:16:28
  TIFFTAG_XRESOLUTION=72
  TIFFTAG_YRESOLUTION=72
  TIFFTAG_RESOLUTIONUNIT=2 (pixels/inch)
 Image Structure Metadata:
  COMPRESSION=PACKBITS
  INTERLEAVE=BAND
 Corner Coordinates:
 Upper Left  (  295125.999, 4778305.843) ( 71d31'7.66W, 43d 7'54.16N)
 Lower Left  (  295125.999, 4761593.049) ( 71d30'45.52W, 42d58'52.88N)
 Upper Right (  308264.099, 4778305.843) ( 71d21'26.67W, 43d 8'6.54N)
 Lower Right (  308264.099, 4761593.049) ( 71d21'5.95W, 42d59'5.20N)
 Center  (  301695.049, 4769949.446) ( 71d26'6.44W, 43d 3'29.80N)
 Band 1 Block=5388x1 Type=Byte, ColorInterp=Palette
  Color Table (RGB with 256 entries)
0: 0,0,0,255
1: 255,255,255,255
2: 0,151,164,255
3: 203,0,23,255
4: 131,66,37,255
5: 201,234,157,255
6: 137,51,128,255
7: 255,234,0,255
8: 167,226,226,255
9: 255,184,184,255
   10: 218,179,214,255
   11: 209,209,209,255
   12: 207,164,142,255
 (etc...)

 And my map file looks like this:

 MAP
 NAME DEMO
 STATUS ON
 SIZE 400 300
 SYMBOLSET ../etc/symbols.sym
 EXTENT -72 42 -71 44
 UNITS dd
 SCALEDENOM 24000
 SHAPEPATH ../data
 IMAGECOLOR 255 255 255
 FONTSET ../etc/fonts.txt
 CONFIG MS_ERRORFILE /tmp/ms_error.txt
 #
 # Start of web interface definition
 #
 WEB
  MINSCALEDENOM 24000
  MAXSCALEDENOM 24000
 #
 # On Windows systems, /tmp and /opt/fgs/tmp/ms_tmp/ should be created at
 the root
 # of the drive where the .MAP file resides.
 #
  IMAGEPATH /opt/fgs/tmp/ms_tmp/
  IMAGEURL /ms_tmp/
  LOG /tmp/gmap.log
 END

 LAYER
  NAME usgs
  METADATA
DESCRIPTION USGS GeoTIFF
  END
  TYPE RASTER
  STATUS ON
  DATA o43071a4.tif
 END

 END # Map File



 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Need help testing WMS segfault

2010-01-29 Thread Roger André
Hi All,

I'm experiencing some strange behavior that I would appreciate some help
testing.  My MapServer 5.6 instance is segfaulting in response to certain
WMS requests it is receiving from TileCache.  Below is one of the specific
requests:

http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703

I'd appreciate it if someone who has a layer that covers Seattle would try
the bbox extents listed above and report back if it causes an error for
them.

FYI - When I set this bbox as the EXTENTS in my MAP, and the SIZE to 256
256, Mapserver delivers the image without any problem.

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Need help testing WMS segfault

2010-01-29 Thread Roger André
Hi Paul,

Thanks for the advice. (Chris Schmidt suggested I do the same thing in IRC
yesterday, and I forgot to try it.)

Below are the results of gdb.  It's fun to run, but uhm... not something I'm
readily able to decipher (yet).

$ gdb /usr/lib/cgi-bin/mapserv
GNU gdb (GDB) 7.0-ubuntu
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html

This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type show copying
and show warranty for details.
This GDB was configured as i486-linux-gnu.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/...
Reading symbols from /usr/lib/cgi-bin/mapserv...done.
(gdb) run
QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
Starting program: /usr/lib/cgi-bin/mapserv
QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
[Thread debugging using libthread_db enabled]

Program received signal SIGSEGV, Segmentation fault.
0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
(gdb) bt
#0  0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
#1  0x0740d868 in malloc () from /lib/tls/i686/cmov/libc.so.6
#2  0x006abbb7 in operator new(unsigned int) () from /usr/lib/libstdc++.so.6
#3  0x006abced in operator new[](unsigned int) () from
/usr/lib/libstdc++.so.6
#4  0x080dbdd5 in void
mapserver::render_scanlinesmapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
, mapserver::scanline_u8,
mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
mapserver::order_bgra, mapserv_row_ptr_cacheint, int  
(mapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
, mapserver::scanline_u8,
mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
mapserver::order_bgra, mapserv_row_ptr_cacheint, int  ) ()
#5  0x080ba7ac in T.1744 ()
#6  0x080bdbda in msDrawShadeSymbolAGG ()
#7  0x0813b3d2 in msDrawShadeSymbol ()
#8  0x0809ff17 in msDrawShape ()
#9  0x080a2cfe in msDrawVectorLayer ()
#10 0x080a343d in msDrawLayer ()
#11 0x080a4fd7 in msDrawMap ()
#12 0x08157d82 in msWMSGetMap ()
#13 0x0815cf36 in msWMSDispatch ()
#14 0x080e9924 in msOWSDispatch ()
#15 0x08056583 in main ()
(gdb)

Roger
--

On Fri, Jan 29, 2010 at 1:38 PM, Paul Ramsey pram...@opengeo.org wrote:

 Roger,

 It looks like you're on Linux, so pull a stacktrace, it's fun!

 gdb /path/to/mapserv

 ... lots of info ...

 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703

 then when you hit to segfault, do

 (gdb) bt

 bt stands for backtrace

 now you'll have a lot more useful information about what went wrong,

 Yours,

 Paul

 On Fri, Jan 29, 2010 at 1:27 PM, Roger André ran...@gmail.com wrote:
  Hi All,
 
  I'm experiencing some strange behavior that I would appreciate some help
  testing.  My MapServer 5.6 instance is segfaulting in response to certain
  WMS requests it is receiving from TileCache.  Below is one of the
 specific
  requests:
 
 
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 
  I'd appreciate it if someone who has a layer that covers Seattle would
 try
  the bbox extents listed above and report back if it causes an error for
  them.
 
  FYI - When I set this bbox as the EXTENTS in my MAP, and the SIZE to 256
  256, Mapserver delivers the image without any problem.
 
  Thanks,
 
  Roger
 
  ___
  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] Need help testing WMS segfault

2010-01-29 Thread Roger André
Hi Paul,

Ok.  I'll see if I can replicate the problem with a single data layer, and
will then package everything together so another developer can run it.

Thanks,

Roger
--

On Fri, Jan 29, 2010 at 2:16 PM, Paul Ramsey pram...@opengeo.org wrote:

 Lovely, Another AGG bug. Well the next thing is to package up your
 environment so a developer can duplicate the problem on their rig. Figure
 out which layer it is, so you only have to pack that data up. Since the
 issue is arising in AGG, flag the ticket to the AGG module. When you pack up
 your map file, remember to also pack up or strip out things like templates,
 font libraries, symbol libraries, etc. Ideally, copy the whole mess to a new
 path on your system ensure it does in fact run independently of the rest of
 your installation.

 Best,

 Paul

 On 2010-01-29, at 2:11 PM, Roger André wrote:

 Hi Paul,

 Thanks for the advice. (Chris Schmidt suggested I do the same thing in IRC
 yesterday, and I forgot to try it.)

 Below are the results of gdb.  It's fun to run, but uhm... not something
 I'm readily able to decipher (yet).

 $ gdb /usr/lib/cgi-bin/mapserv
 GNU gdb (GDB) 7.0-ubuntu
 Copyright (C) 2009 Free Software Foundation, Inc.
 License GPLv3+: GNU GPL version 3 or later 
 http://gnu.org/licenses/gpl.html
 This is free software: you are free to change and redistribute it.
 There is NO WARRANTY, to the extent permitted by law.  Type show copying
 and show warranty for details.
 This GDB was configured as i486-linux-gnu.
 For bug reporting instructions, please see:
 http://www.gnu.org/software/gdb/bugs/...
 Reading symbols from /usr/lib/cgi-bin/mapserv...done.
 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 Starting program: /usr/lib/cgi-bin/mapserv
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 [Thread debugging using libthread_db enabled]

 Program received signal SIGSEGV, Segmentation fault.
 0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 (gdb) bt
 #0  0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 #1  0x0740d868 in malloc () from /lib/tls/i686/cmov/libc.so.6
 #2  0x006abbb7 in operator new(unsigned int) () from
 /usr/lib/libstdc++.so.6
 #3  0x006abced in operator new[](unsigned int) () from
 /usr/lib/libstdc++.so.6
 #4  0x080dbdd5 in void
 mapserver::render_scanlinesmapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
 , mapserver::scanline_u8,
 mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
 mapserver::order_bgra, mapserv_row_ptr_cacheint, int  
 (mapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
 , mapserver::scanline_u8,
 mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
 mapserver::order_bgra, mapserv_row_ptr_cacheint, int  ) ()
 #5  0x080ba7ac in T.1744 ()
 #6  0x080bdbda in msDrawShadeSymbolAGG ()
 #7  0x0813b3d2 in msDrawShadeSymbol ()
 #8  0x0809ff17 in msDrawShape ()
 #9  0x080a2cfe in msDrawVectorLayer ()
 #10 0x080a343d in msDrawLayer ()
 #11 0x080a4fd7 in msDrawMap ()
 #12 0x08157d82 in msWMSGetMap ()
 #13 0x0815cf36 in msWMSDispatch ()
 #14 0x080e9924 in msOWSDispatch ()
 #15 0x08056583 in main ()
 (gdb)

 Roger
 --

 On Fri, Jan 29, 2010 at 1:38 PM, Paul Ramsey pram...@opengeo.org wrote:

 Roger,

 It looks like you're on Linux, so pull a stacktrace, it's fun!

 gdb /path/to/mapserv

 ... lots of info ...

 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703

 then when you hit to segfault, do

 (gdb) bt

 bt stands for backtrace

 now you'll have a lot more useful information about what went wrong,

 Yours,

 Paul

 On Fri, Jan 29, 2010 at 1:27 PM, Roger André ran...@gmail.com wrote:
  Hi All,
 
  I'm experiencing some strange behavior that I would appreciate some help
  testing.  My MapServer 5.6 instance is segfaulting in response to
 certain
  WMS requests it is receiving from TileCache.  Below is one of the
 specific
  requests:
 
 
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 
  I'd appreciate it if someone who has a layer that covers Seattle would
 try
  the bbox extents listed above and report back if it causes an error for
  them.
 
  FYI - When I set this bbox

Re: [mapserver-users] Need help testing WMS segfault

2010-01-29 Thread Roger André
Alright, I've clipped the data sets down to areas just slightly larger than
the WMS bbox, cleaned up the map file, and replicated the WMS to make sure
that it still breaks.  The tgz file that contains the mapfile and 2
shapefiles is just under 5 MB.  Where should I file the bug, and can I
attach the data to the bug?

Thanks,

Roger
--



On Fri, Jan 29, 2010 at 2:57 PM, Roger André ran...@gmail.com wrote:

 Hi Paul,

 Ok.  I'll see if I can replicate the problem with a single data layer, and
 will then package everything together so another developer can run it.

 Thanks,

 Roger
 --


 On Fri, Jan 29, 2010 at 2:16 PM, Paul Ramsey pram...@opengeo.org wrote:

 Lovely, Another AGG bug. Well the next thing is to package up your
 environment so a developer can duplicate the problem on their rig. Figure
 out which layer it is, so you only have to pack that data up. Since the
 issue is arising in AGG, flag the ticket to the AGG module. When you pack up
 your map file, remember to also pack up or strip out things like templates,
 font libraries, symbol libraries, etc. Ideally, copy the whole mess to a new
 path on your system ensure it does in fact run independently of the rest of
 your installation.

 Best,

 Paul

 On 2010-01-29, at 2:11 PM, Roger André wrote:

 Hi Paul,

 Thanks for the advice. (Chris Schmidt suggested I do the same thing in IRC
 yesterday, and I forgot to try it.)

 Below are the results of gdb.  It's fun to run, but uhm... not something
 I'm readily able to decipher (yet).

 $ gdb /usr/lib/cgi-bin/mapserv
 GNU gdb (GDB) 7.0-ubuntu
 Copyright (C) 2009 Free Software Foundation, Inc.
 License GPLv3+: GNU GPL version 3 or later 
 http://gnu.org/licenses/gpl.html
 This is free software: you are free to change and redistribute it.
 There is NO WARRANTY, to the extent permitted by law.  Type show copying
 and show warranty for details.
 This GDB was configured as i486-linux-gnu.
 For bug reporting instructions, please see:
 http://www.gnu.org/software/gdb/bugs/...
 Reading symbols from /usr/lib/cgi-bin/mapserv...done.
 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 Starting program: /usr/lib/cgi-bin/mapserv
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 [Thread debugging using libthread_db enabled]

 Program received signal SIGSEGV, Segmentation fault.
 0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 (gdb) bt
 #0  0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 #1  0x0740d868 in malloc () from /lib/tls/i686/cmov/libc.so.6
 #2  0x006abbb7 in operator new(unsigned int) () from
 /usr/lib/libstdc++.so.6
 #3  0x006abced in operator new[](unsigned int) () from
 /usr/lib/libstdc++.so.6
 #4  0x080dbdd5 in void
 mapserver::render_scanlinesmapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
 , mapserver::scanline_u8,
 mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
 mapserver::order_bgra, mapserv_row_ptr_cacheint, int  
 (mapserver::rasterizer_scanline_aamapserver::rasterizer_sl_clipmapserver::ras_conv_int
 , mapserver::scanline_u8,
 mapserver::renderer_scanline_aa_solidmapserver::renderer_basemapserver::pixfmt_alpha_blend_rgbamapserver::blender_rgba_premapserver::rgba8,
 mapserver::order_bgra, mapserv_row_ptr_cacheint, int  ) ()
 #5  0x080ba7ac in T.1744 ()
 #6  0x080bdbda in msDrawShadeSymbolAGG ()
 #7  0x0813b3d2 in msDrawShadeSymbol ()
 #8  0x0809ff17 in msDrawShape ()
 #9  0x080a2cfe in msDrawVectorLayer ()
 #10 0x080a343d in msDrawLayer ()
 #11 0x080a4fd7 in msDrawMap ()
 #12 0x08157d82 in msWMSGetMap ()
 #13 0x0815cf36 in msWMSDispatch ()
 #14 0x080e9924 in msOWSDispatch ()
 #15 0x08056583 in main ()
 (gdb)

 Roger
 --

 On Fri, Jan 29, 2010 at 1:38 PM, Paul Ramsey pram...@opengeo.org wrote:

 Roger,

 It looks like you're on Linux, so pull a stacktrace, it's fun!

 gdb /path/to/mapserv

 ... lots of info ...

 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703

 then when you hit to segfault, do

 (gdb) bt

 bt stands for backtrace

 now you'll have a lot more useful information about what went wrong,

 Yours,

 Paul

 On Fri, Jan 29, 2010 at 1:27 PM, Roger André ran...@gmail.com wrote:
  Hi All,
 
  I'm experiencing some strange behavior that I would appreciate some
 help
  testing.  My MapServer 5.6 instance is segfaulting in response to
 certain
  WMS requests it is receiving from TileCache.  Below is one of the
 specific
  requests:
 
 
 http

Re: [mapserver-users] Need help testing WMS segfault

2010-01-29 Thread Roger André
sigh  I'm an idiot.  Total size is much smaller.
72Kagg_wms_segfault.tar.gz

Paul, you'll appreciate this.  The file is much smaller when you do this:

$ ogr2ogr parcel_clip.shp PG:host=localhost dbname=foo \
   -sql SELECT
 parcel_id,
 import_exp,
 external_i,
 ST_Intersection('SRID=4326;POLYGON((-122.339256836
47.6576914062,

-122.331763672 47.6576914062,

-122.331763672 47.6651845703,

 -122.339256836 47.6651845703,

-122.339256836 47.6576914062))', the_geom)
  FROM parcel
  WHERE 'SRID=4326;POLYGON((-122.339256836 47.6576914062,
   -122.331763672
47.6576914062,
   -122.331763672
47.6651845703,
   -122.339256836
47.6651845703,
   -122.339256836
47.6576914062))'
   the_geom \
   -nlt POLYGON

instead of just:

$ ogr2ogr parcel_clip.shp PG:host=localhost dbname=foo \
   -sql SELECT
 parcel_id,
 import_exp,
 external_i,
 ST_Intersection('SRID=4326;POLYGON((-122.339256836
47.6576914062,

-122.331763672 47.6576914062,

-122.331763672 47.6651845703,

 -122.339256836 47.6651845703,

-122.339256836 47.6576914062))', the_geom)
  FROM parcel
   -nlt POLYGON

I'll file the bug now.

Roger
--



On Fri, Jan 29, 2010 at 4:42 PM, Paul Ramsey pram...@opengeo.org wrote:

 File bug in trac

 http://trac.osgeo.org/mapserver

 With a 5mb attachement, you might need to separately upload it somewhere
 and post a URL, not sure what the attachment max size is for osgeo trac.

 P

 On 2010-01-29, at 4:40 PM, Roger André wrote:

 Alright, I've clipped the data sets down to areas just slightly larger than
 the WMS bbox, cleaned up the map file, and replicated the WMS to make sure
 that it still breaks.  The tgz file that contains the mapfile and 2
 shapefiles is just under 5 MB.  Where should I file the bug, and can I
 attach the data to the bug?

 Thanks,

 Roger
 --



 On Fri, Jan 29, 2010 at 2:57 PM, Roger André ran...@gmail.com wrote:

 Hi Paul,

 Ok.  I'll see if I can replicate the problem with a single data layer, and
 will then package everything together so another developer can run it.

 Thanks,

 Roger
 --


 On Fri, Jan 29, 2010 at 2:16 PM, Paul Ramsey pram...@opengeo.org wrote:

 Lovely, Another AGG bug. Well the next thing is to package up your
 environment so a developer can duplicate the problem on their rig. Figure
 out which layer it is, so you only have to pack that data up. Since the
 issue is arising in AGG, flag the ticket to the AGG module. When you pack up
 your map file, remember to also pack up or strip out things like templates,
 font libraries, symbol libraries, etc. Ideally, copy the whole mess to a new
 path on your system ensure it does in fact run independently of the rest of
 your installation.

 Best,

 Paul

 On 2010-01-29, at 2:11 PM, Roger André wrote:

 Hi Paul,

 Thanks for the advice. (Chris Schmidt suggested I do the same thing in
 IRC yesterday, and I forgot to try it.)

 Below are the results of gdb.  It's fun to run, but uhm... not something
 I'm readily able to decipher (yet).

 $ gdb /usr/lib/cgi-bin/mapserv
 GNU gdb (GDB) 7.0-ubuntu
 Copyright (C) 2009 Free Software Foundation, Inc.
 License GPLv3+: GNU GPL version 3 or later 
 http://gnu.org/licenses/gpl.html
 This is free software: you are free to change and redistribute it.
 There is NO WARRANTY, to the extent permitted by law.  Type show
 copying
 and show warranty for details.
 This GDB was configured as i486-linux-gnu.
 For bug reporting instructions, please see:
 http://www.gnu.org/software/gdb/bugs/...
 Reading symbols from /usr/lib/cgi-bin/mapserv...done.
 (gdb) run
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 Starting program: /usr/lib/cgi-bin/mapserv
 QUERY_STRING=map=/var/www/mapfiles/seattle.maplayers=roadsstyles=service=WMSwidth=256format=image/pngrequest=GetMapheight=256srs=EPSG:4326version=1.1.1bbox=-122.338256836,47.6586914062,-122.332763672,47.6641845703
 [Thread debugging using libthread_db enabled]

 Program received signal SIGSEGV, Segmentation fault.
 0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 (gdb) bt
 #0  0x0740bbf2 in ?? () from /lib/tls/i686/cmov/libc.so.6
 #1  0x0740d868 in malloc () from /lib/tls/i686/cmov/libc.so.6
 #2  0x006abbb7 in operator new(unsigned int) () from
 /usr/lib/libstdc++.so.6
 #3  0x006abced in operator new[](unsigned int) () from
 /usr/lib/libstdc++.so.6
 #4  0x080dbdd5 in void
 mapserver::render_scanlinesmapserver::rasterizer_scanline_aamapserver

[mapserver-users] Python mapscript throwing PostGIS support is not available error

2010-01-28 Thread Roger André
Hi All,

I'm getting kinda stumped by this error.  I'm running MapServer-5.6.0,
Python 2.6, postgresql-8.4.2, and postgis-1.4.1 on an Ubuntu 9.10 box.  I've
compiled mapserver with PostGIS support...

$ /usr/lib/cgi-bin/mapserv -v
MapServer version 5.6.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER
SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS
SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL
INPUT=SHAPEFILE

and I'm able to make a regular old mode=map request via cgi to a layer
that is coming from PostGIS.  However, when I try to access the same layer
via Python mapscript, I get the following error:

_mapscript.MapServerError: msDrawMap(): Image handling error. Failed to draw
layer named 'roadsPG'.
msPostGISLayerOpen(): General error message. PostGIS support is not
available.

I had omitted to include Postgis support in my MapServer build initially,
but did a make clean and rebuilt it.  I also re-ran the Python mapscript
install afterwards.  Is there something else I need to do to clean out the
old mapscript module?  I'm no distutils expert, so any help would be
appreciated.

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Python mapscript throwing PostGIS support is not available error

2010-01-28 Thread Roger André
Well, I've fixed this, but I had to remove the entire build dir and
recompile.  I'm guessing that when ./configure is run the first time, it
creates some sort of mapscript file used later by distutils when Python
mapscript is built.  I can't prove it, and I don't have the time to keep
re-testing, but it appears that neither running make clean, or recompiling
makes a difference once that file is present.
--

On Thu, Jan 28, 2010 at 10:18 AM, Roger André ran...@gmail.com wrote:

 Hi All,

 I'm getting kinda stumped by this error.  I'm running MapServer-5.6.0,
 Python 2.6, postgresql-8.4.2, and postgis-1.4.1 on an Ubuntu 9.10 box.  I've
 compiled mapserver with PostGIS support...

 $ /usr/lib/cgi-bin/mapserv -v
 MapServer version 5.6.0 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
 OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=ICONV
 SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER
 SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=FASTCGI SUPPORTS=THREADS
 SUPPORTS=GEOS INPUT=TIFF INPUT=EPPL7 INPUT=POSTGIS INPUT=OGR INPUT=GDAL
 INPUT=SHAPEFILE

 and I'm able to make a regular old mode=map request via cgi to a layer
 that is coming from PostGIS.  However, when I try to access the same layer
 via Python mapscript, I get the following error:

 _mapscript.MapServerError: msDrawMap(): Image handling error. Failed to
 draw layer named 'roadsPG'.
 msPostGISLayerOpen(): General error message. PostGIS support is not
 available.

 I had omitted to include Postgis support in my MapServer build initially,
 but did a make clean and rebuilt it.  I also re-ran the Python mapscript
 install afterwards.  Is there something else I need to do to clean out the
 old mapscript module?  I'm no distutils expert, so any help would be
 appreciated.

 Thanks,

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Which mapscript function to use?

2010-01-18 Thread Roger André
Hi all,

I'm trying to pass a python mapscript image object directly into GDAL, and
can't seem to hit on the correct mapscript object to feed it with.

- Passing a valid WMS url directly into GDAL works fine, like this.

url = 
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/sav0656/basemap.maplayers=Ditchesstyles=service=WMSwidth=1056format=image%2Fpngrequest=GetMapheight=1056srs=EPSG%3A900913version=1.1.1bbox=19411336.2028%2C19411336.2028%2C60738697.1524%2C60738697.1524

gdal.Open(url)

- However, none of these mapscript objects can seem to be read in a similar
way:

  mapobject = mapscript.mapObj('basemap.map')
  imageobject = mapobject.draw()
  f = StringIO()
  imageobject.write(f)
  gdal.Open(f)

TypeError: in method 'Open', argument 1 of type 'char const *'

- or:

  mapobject = mapscript.mapObj('basemap.map')
  imageobject = mapobject.draw()
  buffer = imageobject.getBytes()
  gdal.Open(buffer)

(Creates a 'NoneType' object without any attributes or methods)


So I'm guessing that the image object that's written as the result of the
WMS request is somehow different from the objects written by
imageObj.write() and imageObj.getBytes().  Any ideas on how to mimic this?

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Fwd: World Wind and Map Server

2009-11-09 Thread Roger André
Does anyone in the MapServer Dev. community want to respond to this?  I
*think* the implication here is that a vanilla MapServer GetCapabilities
request is not conforming to spec.

Roger
--

-- Forwarded message --
From: Tom Gaskins t...@tomgaskins.com
Date: Sun, Nov 8, 2009 at 9:21 PM
Subject: Re: World Wind and Map Server
To: Roger André ran...@gmail.com
Cc: David Collins paul.coll...@nasa.gov


Roger, Thanks for clarifying, but I think I may still be confused. WMS
defines two primary requests, GetCapabilities and GetMap. The first one
requests the metadata associated with the server and each of the layers it
serves. The second requests a map, always in the form of a raster. Reading
your most recent mail, it seems you're expecting the GetCapabilities request
to return a particular map. Is this correct? I'm also confused because the
request you show that you'd like to specify to the demo's layer manager
doesn't meet the definition of a valid WMS end point, which should be simply
a host address and not contain a query string (elements after the question
mark). The query string is exclusively for WMS parameters, which the WWJ
demo fills in when sending the request. I've included the relevant text from
the WMS spec below.

I can understand that mapserver may have its own request protocol, but the
demo you're using is meant to work with only conforming WMS servers. It's
certainly possible for WWJ to visualize data from servers using other
protocols, and many applications do that. We'd be more than happy to help
you determine the best way to interact with mapserver. The demo you're
trying to use, though, isn't intended to to that.

Thanks,
Tom

*6.3.3 HTTP GET*
A Web Map Service shall support the GET method of the HTTP protocol (IETF
RFC 2616).
An Online Resource URL intended for HTTP GET requests is in fact only a URL
prefix to which additional parameters are appended in order to construct a
valid Operation request. A URL prefix is defined in accordance with IETF RFC
2396 as a string including, in order, the scheme (http or https),
Internet Protocol hostname or numeric address, optional port number, path,
mandatory question mark '?', and optional string comprising one or more
server-specific parameters ending in an ampersand ''. The prefix defines
the network address to which request messages are to be sent for a
particular operation on a particular server. Each operation may have a
different prefix. Each prefix is entirely at the discretion of the service
provider.
This International Standard defines how to construct a query part that is
appended to the URL prefix in order to form a complete request message.
Every WMS operation has several mandatory or optional request parameters.
Each parameter has a defined name. Each parameter may have one or more legal
values, which are either defined by this International Standard or are
selected by the client based on service metadata. To formulate the query
part of the URL, a client shall append the mandatory request parameters, and
any desired optional parameters, as name/value pairs in the form
name=value (parameter name, equals sign, parameter value, ampersand). The
'' is a separator between name/value pairs, and is therefore optional after
the last pair in the request string.
When the HTTP GET method is used, the client-constructed query part is
appended to the URL prefix defined by the server, and the resulting complete
URL is invoked as defined by HTTP (IETF RFC 2616).
Table 2 summarizes the components of an operation request URL when HTTP GET
is used.
*Table 2 — Structure of WMS request using HTTP GET*
*6.3.4 HTTP POST*
A Web Map Service may support the POST method of the HTTP protocol (IETF
RFC 2616).
An Online Resource URL intended for HTTP POST requests is a complete URL
(not merely a prefix as in the HTTP GET case) that is valid according to
IETF RFC 2396 to which clients transmit request parameters in the body of
the POST message. A WMS shall not require additional parameters to be
appended to the URL in order to construct a valid target for the operation
request. When POST is used, the request message is formulated as an XML
document.
*URL Component*
*Description*
http://host[:port]/path[?{name[=value]}]http://host%5B%3Aport%5D/path%5B?%7Bname%5B=value%5D%7D%5D
URL prefix of service operation. [ ] denotes 0 or 1 occurrence of an
optional part; {} denotes 0 or more occurrences.
name=value
One or more standard request parameter name/value pairs as defined for each
operation by this International Standard.
On Nov 8, 2009, at 12:29 PM, Roger André wrote:

Hi Tom,

Problem is pretty simple to describe actually.  One of the executives at my
company found this page, http://worldwind.arc.nasa.gov/java/demos/, and
decided to try out the WMS Layer manager example,
WMSLayerManager.jnlphttp://worldwind.arc.nasa.gov/java/demos/WMSLayerManager.jnlp.
He liked the various layers that were available, and asked me if it would be
possible to view some

[mapserver-users] Fwd: World Wind and Map Server

2009-11-09 Thread Roger André
-- Forwarded message --
From: Tom Gaskins t...@tomgaskins.com
Date: Mon, Nov 9, 2009 at 9:52 AM
Subject: Re: World Wind and Map Server
To: Roger André ran...@gmail.com
Cc: David Collins paul.coll...@nasa.gov


Thanks Roger. On looking at this again this morning, the WMS spec does say
that a server-specific query string may be part of the server prefix,
although we've not encountered that before. It still sounds to me, however,
that a map is expected to be returned from a GetCapabilities request.
Nevertheless, we'll modify the relevant WWJ code to recognize the case of an
existing query string in the server URL. That seems to be all you need to
get past the problem
Thanks,
Tom


On Nov 9, 2009, at 9:34 AM, Roger André wrote:

HI Tom,

I've forwarded your response to the MapServer list, as the implication is
that MapServer may not be confirming to WMS spec in the structure of its
GetCapabilities request.  I can understand your confusion about the map
mentioned in my message.  This map has nothng to do with a GetMap
request.  MapServer uses the concept of a map document to define a
specific project.  These map documents contain all of the specifications and
parameters to define the capabilities and/or appearance a specific MapServer
WMS, WFS, WCS, etc. layer.

Anyhow, thanks for the info,

Roger
-- 

On Sun, Nov 8, 2009 at 9:21 PM, Tom Gaskins t...@tomgaskins.com wrote:

 Roger, Thanks for clarifying, but I think I may still be confused. WMS
 defines two primary requests, GetCapabilities and GetMap. The first one
 requests the metadata associated with the server and each of the layers it
 serves. The second requests a map, always in the form of a raster. Reading
 your most recent mail, it seems you're expecting the GetCapabilities request
 to return a particular map. Is this correct? I'm also confused because the
 request you show that you'd like to specify to the demo's layer manager
 doesn't meet the definition of a valid WMS end point, which should be simply
 a host address and not contain a query string (elements after the question
 mark). The query string is exclusively for WMS parameters, which the WWJ
 demo fills in when sending the request. I've included the relevant text from
 the WMS spec below.

 I can understand that mapserver may have its own request protocol, but the
 demo you're using is meant to work with only conforming WMS servers. It's
 certainly possible for WWJ to visualize data from servers using other
 protocols, and many applications do that. We'd be more than happy to help
 you determine the best way to interact with mapserver. The demo you're
 trying to use, though, isn't intended to to that.

 Thanks,
 Tom

 *6.3.3 HTTP GET*
 A Web Map Service shall support the GET method of the HTTP protocol (IETF
 RFC 2616).
 An Online Resource URL intended for HTTP GET requests is in fact only a URL
 prefix to which additional parameters are appended in order to construct a
 valid Operation request. A URL prefix is defined in accordance with IETF RFC
 2396 as a string including, in order, the scheme (http or https),
 Internet Protocol hostname or numeric address, optional port number, path,
 mandatory question mark '?', and optional string comprising one or more
 server-specific parameters ending in an ampersand ''. The prefix defines
 the network address to which request messages are to be sent for a
 particular operation on a particular server. Each operation may have a
 different prefix. Each prefix is entirely at the discretion of the service
 provider.
 This International Standard defines how to construct a query part that is
 appended to the URL prefix in order to form a complete request message.
 Every WMS operation has several mandatory or optional request parameters.
 Each parameter has a defined name. Each parameter may have one or more legal
 values, which are either defined by this International Standard or are
 selected by the client based on service metadata. To formulate the query
 part of the URL, a client shall append the mandatory request parameters, and
 any desired optional parameters, as name/value pairs in the form
 name=value (parameter name, equals sign, parameter value, ampersand). The
 '' is a separator between name/value pairs, and is therefore optional after
 the last pair in the request string.
 When the HTTP GET method is used, the client-constructed query part is
 appended to the URL prefix defined by the server, and the resulting complete
 URL is invoked as defined by HTTP (IETF RFC 2616).
 Table 2 summarizes the components of an operation request URL when HTTP GET
 is used.
 *Table 2 — Structure of WMS request using HTTP GET*
 *6.3.4 HTTP POST*
 A Web Map Service may support the POST method of the HTTP protocol (IETF
 RFC 2616).
 An Online Resource URL intended for HTTP POST requests is a complete URL
 (not merely a prefix as in the HTTP GET case) that is valid according to
 IETF RFC 2396 to which clients transmit request parameters in the body

Re: [mapserver-users] mapserver vs mapscript: agg + transparency + quantize not working

2009-11-05 Thread Roger André
Hi Tiemens,

Not sure if this helps, but in some of the testing I did with Python
mapscript, I specified the following in my code:

map.selectOutputFormat(AGGPNG24)

That seemed to do the trick for me.  The script is inline below, in case it
might help give context.

Roger
--
#! /usr/bin/python

# mimic the Mapnik 'hello world' at
# http://trac.mapnik.org/wiki/GettingStarted
# based on example in Web Mapping Illustrated

import mapscript

# create a base mapfile
map = mapscript.mapObj()
map.selectOutputFormat(AGGPNG24)
map.name = CustomMap
map.setSize(1000, 500)
#map.setExtent(-180.0, -90.0, 180.0, 90.0)
map.setExtent(-22, -36, 60, 38)
map.imagecolor.setRGB(70,130,180)
map.units = mapscript.MS_DD

# set Web image params
map.web.imagepath = /var/www/tmp/
map.web.imageurl = /tmp

# create layer object
layer = mapscript.layerObj(map)
layer.name = countries
#layer.type = mapscript.MS_LAYER_LINE
layer.type = mapscript.MS_LAYER_POLYGON
layer.status = mapscript.MS_DEFAULT
layer.data = /home/randre/gis_data/unep/unep_coastlines.shp
layer.template = template.html

# create a class
class1 = mapscript.classObj(layer)
class1.name = Countries

# create a style
style = mapscript.styleObj(class1)
style.outlinecolor.setRGB(125,125,125)
style.width = 1
style.color.setRGB(240,240,240)
#style.antialias = mapscript.MS_TRUE

# write the map object into a map file
#map.save(custom.map)

# write out an image using these params
mapimage = map.draw()
mapimage.save(ms_world.png)
--
On Thu, Nov 5, 2009 at 9:04 AM, Tiemens, Gerben
gerben.tiem...@grontmij.nlwrote:

   I am busy writing a application with mapscript in C#.

 Currently I am facing the earlier mentioned problems of agg + transparent
 images + quantization.

 Is the new MS4W compiled with the quantization options?

 The image background is now Black. The labels are dissapearing.

 It should be an image wich is completly transparent with some colored lines
 and some black labels.

 Setting the imagecolor will not help me.

 Images without quantization options on, are perfect and beautiful png's.



 What I am using now is this:

 MS4W 3.0 Beta 7   which contains Mapserver 5.4.2



 C# mapscript



 Mapfile is completely written in C#, so all default options apply.

 I saved this mapfile from my mapobj



 --

 MAP

 EXTENT 104952 495303 105452 495803

 IMAGECOLOR 255 255 255

 IMAGETYPE gif

 SIZE 2000 2000

 STATUS ON

 UNITS METERS

 NAME MS

 OUTPUTFORMAT

 NAME PNG_mapscript

 MIMETYPE image/png; mode=24bit

 DRIVER AGG/PNG

 EXTENSION PNG

 IMAGEMODE RGBA

 TRANSPARENT TRUE

 FORMATOPTION QUANTIZE_FORCE=on

 FORMATOPTION QUANTIZE_DITHER=off

 FORMATOPTION QUANTIZE_COLORS=256

 END

 SYMBOL

 NAME circle

 TYPE ELLIPSE

 FILLED TRUE

 POINTS

 1 1

 END

 END

 --

 *snip*

 --

 END



 



 In addition to above: further testing revealed that the transparent color
 is always black.



 So if I set

 imagecolor 99 99 99

 transparent = true

 And outputformat to:

 OUTPUTFORMAT

 NAME PNG_mapscript

 MIMETYPE image/png

 DRIVER GD/PNG

 EXTENSION PNG

 IMAGEMODE RGBA

 TRANSPARENT TRUE

 FORMATOPTION QUANTIZE_FORCE=on

 FORMATOPTION QUANTIZE_COLORS=256

 FORMATOPTION QUANTIZE_NEW=on

 END

 The image appears grey.

 The black labels with white backgroundcolor and black shadowcolor in
 original image are mapped to: white background with gray outline characters
 and transparent filling and the shadow is grayoutlined with transparent
 filling. Probably the antialiasing generates the grey outline, the black
 filling is converted to transparent.

 Something is going wrong.



 If I set output format to:

 OUTPUTFORMAT

 NAME PNG_mapscript

 MIMETYPE image/png; mode=24bit

 DRIVER AGG/PNG

 EXTENSION PNG

 IMAGEMODE RGBA

 TRANSPARENT TRUE

 FORMATOPTION QUANTIZE_FORCE=on

 FORMATOPTION QUANTIZE_DITHER=off

 FORMATOPTION QUANTIZE_COLORS=256

 END

 The same applies for the text/labels, but background of the image is now
 black in all circumstances (no matter what color of imagecolor setting.



 ---



 Further research drills down to where the problem may occur:

 If i test my saved mapfile from mapscript into the
 apache/cgi-bin/mapserv.exe

 The image is coming out as it should be.

 Transparent background, features like it should be, and text also as it
 should be.,  but if I use the draw() method from mapscript, it comes out
 crippled.





 Am i doing something wrong in mapscript? Are there configurations that I
 may miss in mapscript that are default in mapserv.exe?

 I also do'nt know if this is a problem of Mapserver or MS4W, therefore
 crossposting it.

 Greetings


 Gerben


  Please read our E-mail Disclaimer at: Emaildisclaimer.Grontmij.com 

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users




ms_test.py
Description: application/python

[mapserver-users] Fwd: Need some ideas for mosaic'ing raster data that spans the dateline

2009-10-21 Thread Roger André
cross-posting to MapServer list.

Roger


-- Forwarded message --
From: Roger André ran...@gmail.com
Date: Mon, Oct 19, 2009 at 3:16 PM
Subject: Need some ideas for mosaic'ing raster data that spans the dateline
To: gdal-dev gdal-...@lists.osgeo.org


I need to create a colored raster that shows data intensity over
Russia.  My data is in 2 pieces, one on each side of the dateline, and
in WGS84 projection.  What I would like to do is create a shifted
lat/lon projection, such that when both pieces are stuck together, all
of russia can be represented.  I'm pretty sure I can get everything to
line up correctly in GIMP to create a mosaic, but I'm drawing a blank
as to how I can define the shifted projection.  I'd like to use the
projection in Mapserver afterwards for display too.

Can someone send me a thumbnail sketch of how to do this, preferrably
with some proj parameters, please?

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Status of TMS minidriver in gdal_wms

2009-08-19 Thread Roger André
I was able to get this to work using the patch checked in from the Toronto
code sprint. However, I still have questions.  I would like to take
advantage of the fact that I already have pre-rendered tiles in my
TileCache, but it seems that MapServer is still having to render all of the
requests that I'm making through the WMS service.  How can I use my
pre-existing TileCache tiles as the data source?  Do I need to match the
projection that they are created in when I make the request?  Do I need to
set resolution levels in the GDAL_WMS file?  I followed the syntax in the
OSM GDAL_WMS sample to make the requests work.

Thanks,

Roger
--

On Wed, Aug 19, 2009 at 3:18 PM, Roger André ran...@gmail.com wrote:

 Hi All,

 I'd like to use GDAL to access tiles that have been generated by
 TileCache.  It appears this should be possible in GDAL 1.7 via the TMS
 service.  I *think* the example at
 http://www.gdal.org/frmt_wms_openstreetmap_tms.xml shows this.

 I'd appreciate it if someone could clarify whether my expectations are
 reasonable regarding this, and whether this functionality can be enabled in
 a pre-1.7 version of GDAL.

 Thanks,

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Documentation for serving large rasterimagesusing tile cache.

2009-07-01 Thread Roger André
Hi Asif,

I don't know of any specific applications or methods to stress test
MapServer.  However, I would think that you could use some web-based tools
such as Selenium (possibly) to exercise a web-based setup, or write a
test-script which does the same.  Sean Gillies has an excellent set of unit
tests written to exercise Python Mapscript.  You can view them here -
http://kentuckykarst.org/mapserver/mapscript/python/tests/cases/.  It might
be possible to adapt some of these to suit your needs, but I would think
that a utility which exercises your installation in the same way a user does
would be better.

There is a good, generic description of how to approach load testing of web
applications here - http://msdn.microsoft.com/en-us/library/bb924374.aspx.

Best of luck,

Roger
--



On Tue, Jun 30, 2009 at 10:15 PM, Asif Memon mme...@sdsc.edu wrote:

 Hello,

 We have started using Map Server to serve large size images. Now we want to
 do a performance/stress test on Map Server. Do you have any documentation
 that explains the performance/stress test on a Map Server? If not, could you
 please suggest what shall I do?

 Sincerely,
 Asif Memon


 -Original Message-
 From: Bob Basques [mailto:bob.basq...@ci.stpaul.mn.us]
 Sent: Monday, November 10, 2008 1:27 PM
 To: ran...@gmail.com; Asif Memon
 Cc: mapserver-users@lists.osgeo.org
 Subject: RE: [mapserver-users] Documentation for serving large
 rasterimagesusing tile cache.

 Asif,

 While it may be a bit of overhead to implement just for testing, the
 GeoMoose client would definitely help with your performance testing.  If
 you combine it with FireBug/FireFox, you should be able to extract all
 the performance information you need (from the client end).

 From the server side, you can run the MapServer requests on the
 commandline.  In my experience though, the web side of the equation is
 usually the bottleneck for most performance issues.

 bobb



  Asif Memon mme...@sdsc.edu 11/10/08 3:21 PM 
 Thanks Roger,



 I have tiled a large mosaic(2 GB) by using the GDAL utility(gdal_convert
 TILED=YES). I want to test the performance for querying the mosaic
 with the zoom functionality. Do I need to write a client or is there
 anything readily available with which I can check the performance?



 Sincerely,

 Asif Memon





 From: Roger André [mailto:ran...@gmail.com]
 Sent: Monday, November 10, 2008 9:35 AM
 To: Asif Memon
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Documentation for serving large raster
 images using tile cache.



 Hi Asif,

 My apologies.  I saw your message Friday evening but forgot about it
 over the weekend in the course of reinstalling my Linux OS.  If time is
 of the essence, posting your question to the entire list should ensure a
 speedier response.

 Regarding your questions:

 1) I am not aware of any applications that will act as viewers for
 Mapserver operating in map mode.  They may exist, but I'm not familiar
 with them.  I tend to use Mapserver in only one of two ways at the
 moment; in map mode to generate static maps, in wms mode with a
 connection to it via OpenLayers (or TileCache).

 2) Regarding the path to your mapfile, I believe there are several
 solutions that you can try if your goal is to shorten the URL string.
 They are well-explained here -

 http://mapserver.gis.umn.edu/docs/howto/wms_server/#more-about-the-online-resource-url
 .
  As far as why the 1st URL doesn't actually work, it's because the path
 should be relative to the mapserv.exe location in cgi-bin, not to
 htdocs.  So try this instead:

 -

 http://localhost:9090/cgi-bin/mapserv.exe?map=../htdocs/mapdemo/itasca_demo.mapmode=map
 
 http://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.mapmode=map
 


 Roger
 --

 On Mon, Nov 10, 2008 at 1:58 AM, Asif Memon mme...@sdsc.edu wrote:

 Hi All,



 I have couple of question, could you please take a look at it :



 1)  Do you know any Map Server Client that allows viewing the image
 service (created on the Minnesota Map Server) if I give the URL listed
 below:

 http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.mapmode=map
 



 2)  I am using Windows XP on my PC. When I give the URL in this
 format -

 http://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.mapmode=map
 ,
 it doesn't work. But if I give it in format -
 http://localhost:9090/cgi-bin/mapserv.exe?map=C
 :\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.mapmode=map
 
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.mapmode=map
 
 , it works. The problem in giving the URL is this format is I have to
 put the complete path starting with C: drive and if I have to run it
 on the server, I cannot give it like that.



 Could you please help me with both the above issues? Thanks!



 Sincerely,

 Asif Memon





 From: Roger André [mailto:ran...@gmail.com]
 Sent: Tuesday, October

Re: [mapserver-users] Precache

2009-05-21 Thread Roger André
Ahh, ok.  I'm not sure in what fashion you are using TileCache, but my
experience has been with using it to create tiles to display in Google
Maps.  Google Maps uses the projection which is EPSG:900913.  I
believe there are other codes for it, but that is the one I use.

All of my source data for the MapServer projects I make are in
EPSG:4326.  So there are 3 things I need to do in order to make the
Tilecache output tiles align correctly in Gmaps.

1. I set both the mapfile and the layer projections to EPSG:4326.
MAP
  NAME  'v2_80m_global'
  PROJECTION
init=epsg:4326
  END

  LAYER
NAME 'imagery'
PROJECTION
  init=epsg:4326
END
snip...

2. I explicity allow for a wms request to be made for the layer in
EPSG:900913 by setting the following in my MapServer LAYER:
METADATA
  wms_srs EPSG:4326 EPSG:900913
snip...

3. I define my TileCache layer so that it requests images from
Mapserver in EPSG:900913.
[v2_20m_global]
type=MapServerLayer
mapfile=/var/www/mapfiles/v2_20m_global/v2_20m_global.map
metaTile=true
metaSize=2,2
metaBuffer=0,500
layers=imagery
spherical_mercator=true
srs=EPSG:900913

That's what works for me.

Roger
--

On Thu, May 21, 2009 at 5:24 AM, Chad Clabaugh cclaba...@centwire.com wrote:
 Thank you Roger, for your response.  I have done that but I do not
 understand how tilecache works.  The images that are returned from mapserver
 line up perfectly. But the images returned from tilecache do not align very
 well (they're distorted).  If tilecache is simply caching the returned
 images then I do not understand where this distortion comes from.  Any
 thoughts?

 Thanks!

 -Original Message-
 From: Roger André [mailto:ran...@gmail.com]
 Sent: Wednesday, May 20, 2009 11:46 PM
 To: Chad Clabaugh
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Precache

 Your request is somewhat lacking in detail, but assuming that your
 goal is a simple one, here is one way to accomplish this.

 1. Create a MapServer project that displays your shapefile in whatever
 style you choose.
 2. Setup a TileCache instance that points to your MapServer project.
 3. Run the tilecache_seed.py script to pre-generate tiles.

 Roger
 --

 On Wed, May 20, 2009 at 12:16 PM, Chad Clabaugh cclaba...@centwire.com
 wrote:
 How can I precache tile images from shapefiles?



 Thanks



 Chad Clabaugh

 Technical Support, Engineering

 Office: 260.760.6398

 Mobile: 260.466.8861



 ___
 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] Precache

2009-05-20 Thread Roger André
Your request is somewhat lacking in detail, but assuming that your
goal is a simple one, here is one way to accomplish this.

1. Create a MapServer project that displays your shapefile in whatever
style you choose.
2. Setup a TileCache instance that points to your MapServer project.
3. Run the tilecache_seed.py script to pre-generate tiles.

Roger
--

On Wed, May 20, 2009 at 12:16 PM, Chad Clabaugh cclaba...@centwire.com wrote:
 How can I precache tile images from shapefiles?



 Thanks



 Chad Clabaugh

 Technical Support, Engineering

 Office: 260.760.6398

 Mobile: 260.466.8861



 ___
 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] Development environment

2009-04-30 Thread Roger André
vi and gcc?

Roger
--

On Wed, Apr 29, 2009 at 2:07 AM, Iratxe Lejarreta iratxe.lejarr...@axios.es
 wrote:

  Hi,

 Could anybody tell me which is the recomended enviroment to develop in C++
 language?

 Thanks!

 --

 Iratxe Lejarreta

 www.axios.es

 ___
 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] Dem classification

2009-04-21 Thread Roger André
Or you could do it without GRASS, using a script like this.

Roger
--

On Tue, Apr 21, 2009 at 7:41 AM, Dylan Beaudette
dylan.beaude...@gmail.comwrote:

 Hi,

 Here is a start:
 http://grass.osgeo.org/wiki/Main_Page

 the main idea:

 # make a new mapset/location
 # import dem:
 r.in.gdal

 # convert to classes
 r.reclass

 # fix colors:
 r.colors

 # export image:
 r.out.tiff or d.out.file

 Cheers,
 Dylan

 On Tue, Apr 21, 2009 at 6:33 AM, leonidas leonidas_lia...@yahoo.gr
 wrote:
 
  Any tutorial how to implement that with grass gis?
 
  Dylan Beaudette-2 wrote:
 
  You could always apply the elevation classification in a standard GIS
  like GRASS, and then save the color-mapped image and use that instead
  of the original DEM.
 
  Cheers,
 
  Dylan
 
 
 
  --
  View this message in context:
 http://n2.nabble.com/Dem-classification-tp2662869p2670014.html
  Sent from the Mapserver - User mailing list archive at Nabble.com.
 
  ___
  mapserver-users mailing list
  mapserver-users@lists.osgeo.org
  http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

#! /usr/bin/env python

# Create a colored image based on LUT in MakeColor function

# Author: Roger Andre, October 2008

# Usage: discreet_gray2color.py infile outfile

from osgeo import gdal
import sys
import numpy
import os.path
gdal.TermProgress = gdal.TermProgress_nocb

src_file = sys.argv[1]
dst_file = sys.argv[2]
out_bands = 3

def MakeColor(z_value):
  '''LUT for color ramp. Keys are pixel values, hash values are RGB triplets.'''
  color_dict = {
0:[102,0,255],
   25:[20,82,255],
   50:[0,194,224],
   75:[0,255,122],
  100:[41,255,0],
  125:[204,255,0],
  150:[245,194,0],
  175:[224,118,0],
  200:[168,46,0],
  225:[105,0,0],
  250:[64,0,0],
  255:[0,0,0]}

  key_list = color_dict.keys()
  key_list.sort()
  while len(key_list)  0:
last_val = key_list[-1]
if z_value = last_val:
  return color_dict[last_val]
else:
  key_list.remove(last_val)

# Print some info
print Creating %s % (dst_file)

# Open source file
src_ds = gdal.Open( src_file )
src_band = src_ds.GetRasterBand(1)

# create destination file
dst_driver = gdal.GetDriverByName('GTiff')
dst_ds = dst_driver.Create(dst_file, src_ds.RasterXSize, src_ds.RasterYSize, out_bands, gdal.GDT_Byte) 

# create output bands
band1 = numpy.zeros([src_ds.RasterYSize, src_ds.RasterXSize])
band2 = numpy.zeros([src_ds.RasterYSize, src_ds.RasterXSize])
band3 = numpy.zeros([src_ds.RasterYSize, src_ds.RasterXSize])

# set the projection and georeferencing info
dst_ds.SetProjection( src_ds.GetProjection() )
dst_ds.SetGeoTransform( src_ds.GetGeoTransform() )

# read the source file
gdal.TermProgress( 0.0 )
for iY in range(src_ds.RasterYSize):
  src_data = src_band.ReadAsArray(0,iY,src_ds.RasterXSize,1)
  col_values = src_data[0] # array of z_values, one per row in source data
  for iX in range(src_ds.RasterXSize):
z_value = col_values[iX]
# print z_value # uncomment to see what value breaks color ramp
[R,G,B] = MakeColor(z_value)
band1[iY][iX] = R
band2[iY][iX] = G
band3[iY][iX] = B
  gdal.TermProgress( (iY+1.0) / src_ds.RasterYSize )

# write each band out
dst_ds.GetRasterBand(1).WriteArray(band1)
dst_ds.GetRasterBand(2).WriteArray(band2)
dst_ds.GetRasterBand(3).WriteArray(band3)

dst_ds = None
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Elevation-like map

2009-04-14 Thread Roger André
What information does your shapefile contain, elevation points? If so, and
if they are regularly spaced, you can probably use the GMT utility xyz2grd,
http://gmt.soest.hawaii.edu/gmt/doc/gmt/html/man/xyz2grd.html.  Otherwise
you will need to interpolate the points into a regular grid, and my only
experience doing this is with ArcGIS's Spatial Analyst.  I would imagine
GRASS has similar capability though.  I'd be curious to hear other
suggestions as well.

Roger
--

On Tue, Apr 14, 2009 at 7:01 AM, Nelson Correia nelson...@hotmail.comwrote:


 Hi,

 Thanks for the quick answers.

 Do you know how can I convert a shapefile to a suitable format for those
 apps (either rel.py or DEM utilities)? I've searched the documentation, but
 I didn't find that info.

 Thanks,

 Nelson Correia

  Date: Mon, 13 Apr 2009 15:39:44 -0400
  From: jmcke...@gatewaygeomatics.com
  To: mapserver-users@lists.osgeo.org
  Subject: Re: [mapserver-users] Elevation-like map

 
 
  
   - Step 2: Create a hillshade layer. (I use rel.py with gdal to do this,

   but you can do it with something else.)
  
 
  A handy toolset is the DEM Utilities
  (http://www.perrygeo.net/wordpress/?p=7), which, if you're a Windows
  user, are available in MS4W.
 
  -jeff
 
 
 
  --
  Jeff McKenna
  FOSS4G Consulting and Training Services
  http://www.gatewaygeomatics.com/
 
 
 
 
  ___
  mapserver-users mailing list
  mapserver-users@lists.osgeo.org
  http://lists.osgeo.org/mailman/listinfo/mapserver-users

 --
 Get news, entertainment and everything you care about at Live.com. Check
 it out! http://www.live.com/getstarted.aspx

 ___
 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] Elevation-like map

2009-04-13 Thread Roger André
Sure, you can do this with Mapserver.  The difficulty lies more in
pre-processing the data, than in having Mapserver display it.

- Step 1: Get some elevation data.

- Step 2: Create a hillshade layer. (I use rel.py with gdal to do this, but
you can do it with something else.)

- Step 3: Create a hypsometric tint layer of your elevation data.  (Note:
You can use Mapserver styles to directly read the DEM and style the
elevation zones.)

- Step 4: Combine the 2 layers with some transparency and you can get
something that looks like these -
http://lagerratrobe.blogspot.com/2008/10/continuous-vs-discreet-color-elevation.html
.

Contact me off-list if you want more info.

Roger
--



On Mon, Apr 13, 2009 at 10:51 AM, Nelson Correia nelson...@hotmail.comwrote:

  Hi,

 Anyone knows how to make an elevation-like map, like the terrain mode in
 Google Maps.

 Does MapServer allow to do something like that?

 I have the level curves data of the area that I want to represent, is
 that enough?

 Thanks in advance,

 Nelson Correia

 --
 What can you do with the new Windows Live? Find 
 outhttp://www.microsoft.com/windows/windowslive/default.aspx

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] MapServer using GDAL_WMS to access TileCache layer

2009-03-23 Thread Roger André
Hi All,

I've created a TileCache layer that's being used to overlay tiles in a
Google Maps page.  That's working just fine, but I would also like to
access this layer via a MapServer WMS call as well.  I have tried to
setup a GDAL_WMS file that can read the TileCache layer, but am
getting IReadBlock failed errors when I try to run gdal_translate on
it, or try to view the layer in a MapServer map.

Below are the pertinent details of my configuration.

TileCache layer:
---
[20m_global]
type=MapServerLayer
mapfile=/var/www/mapfiles/20m_global/20m_global.map
#url=http://10.10.40.152/cgi-bin/mapserv?map=/var/www/mapfiles/20m_global/20m_global.map
metaTile=true
metaSize=2,2
metaBuffer=0,500
layers=imagery
spherical_mercator=true
srs=EPSG:900913

GDAL_WMS xml file:
--
GDAL_WMS
Service name=TileService
!--ServerUrlhttp://tile.openstreetmap.org/${z}/${x}/${y}.png/ServerUrl--
ServerUrlhttp://10.10.10.143/cgi-bin/tilecache-2.04/tilecache.cgi/1.0.0/v2_80m_global/{Z}/{X}/{Y}.png/ServerUrl
/Service
DataWindow
UpperLeftX-20037508.34/UpperLeftX
UpperLeftY20037508.34/UpperLeftY
LowerRightX20037508.34/LowerRightX
LowerRightY-20037508.34/LowerRightY
TileLevel11/TileLevel
TileCountX1/TileCountX
TileCountY1/TileCountY
YOrigintop/YOrigin
/DataWindow
ProjectionEPSG:900913/Projection
BlockSizeX256/BlockSizeX
BlockSizeY256/BlockSizeY
BandsCount3/BandsCount
Cache/
/GDAL_WMS

gdalinfo output:
-
$ gdalinfo tilecache.xml
Driver: WMS/OGC Web Map Service
Files: tilecache.xml
Size is 524288, 524288
Coordinate System is:
PROJCS[Google Maps Global Mercator,
GEOGCS[WGS 84,
DATUM[WGS_1984,
SPHEROID[WGS 84,6378137,298.257223563,
AUTHORITY[EPSG,7030]],
AUTHORITY[EPSG,6326]],
PRIMEM[Greenwich,0,
AUTHORITY[EPSG,8901]],
UNIT[degree,0.01745329251994328,
AUTHORITY[EPSG,9122]],
AUTHORITY[EPSG,4326]],
PROJECTION[Mercator_2SP],
PARAMETER[standard_parallel_1,0],
PARAMETER[latitude_of_origin,0],
PARAMETER[central_meridian,0],
PARAMETER[false_easting,0],
PARAMETER[false_northing,0],
UNIT[Meter,1],
EXTENSION[PROJ4,+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0
+lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgri...@null +wktext
+no_defs],
AUTHORITY[EPSG,900913]]
Origin = (-20037508.33999850988,20037508.33999850988)
Pixel Size = (76.437028274536132,-76.437028274536132)
Corner Coordinates:
Upper Left  (-20037508.340,20037508.340) (180d 0'0.00W, 85d 3'4.06N)
Lower Left  (-20037508.340,-20037508.340) (180d 0'0.00W, 85d 3'4.06S)
Upper Right (20037508.340,20037508.340) (180d 0'0.00E, 85d 3'4.06N)
Lower Right (20037508.340,-20037508.340) (180d 0'0.00E, 85d 3'4.06S)
Center  (   0.000,   0.000) (  0d 0'0.01E,  0d 0'0.00S)
Band 1 Block=256x256 Type=Byte, ColorInterp=Undefined
  Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
256x256
Band 2 Block=256x256 Type=Byte, ColorInterp=Undefined
  Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
256x256
Band 3 Block=256x256 Type=Byte, ColorInterp=Undefined
  Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
256x256

gdal_translate error:

$ gdal_translate -outsize 1% 1% tilecache.xml test.tif
Input file size is 524288, 524288
0ERROR 4: `/vsimem/wms/0x8503470/wmsresult.dat' not recognised as a
supported file format.

ERROR 1: GDALWMS: Unable to open downloaded block.
ERROR 1: GDALWMS: ReadBlockFromFile failed.
ERROR 1: IReadBlock failed at X offset 0, Y offset 0
ERROR 4: `/vsimem/wms/0x809dc08/wmsresult.dat' not recognised as a
supported file format.

ERROR 1: GDALWMS: Unable to open downloaded block.
ERROR 1: GDALWMS: ReadBlockFromFile failed.
ERROR 1: IReadBlock failed at X offset 0, Y offset 0

MapServer error:
---
msDrawMap(): Image handling error. Failed to draw layer named
'imagery'. IReadBlock failed at X offset 1442, Y offset 607: Unable to
access file. GDALRasterIO() failed: drawGDAL()

If you see anything that jumps out at you as being incorrect, I'd love
to hear from you.

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: [gdal-dev] MapServer using GDAL_WMS to access TileCache layer

2009-03-23 Thread Roger André
Hi Even,

Thanks for the info.  I have updated my GDAL_WMS file to now show:

ServerUrlhttp://10.10.10.143/cgi-bin/tilecache-2.04/tilecache.cgi/1.0.0/v2_80m_global/${z}/${x}/${y}.png/ServerUrl


Still doesn't work though.


gdal_translate -outsize 1% 1% tilecache.xml test.tif
Input file size is 524288, 524288
0ERROR 4: `/vsimem/wms/0x8503480/wmsresult.dat' not recognised as a
supported file format.

ERROR 1: GDALWMS: Unable to open downloaded block.
ERROR 1: GDALWMS: ReadBlockFromFile failed.
ERROR 1: IReadBlock failed at X offset 0, Y offset 0
ERROR 4: `/vsimem/wms/0x809dc28/wmsresult.dat' not recognised as a
supported file format.

ERROR 1: GDALWMS: Unable to open downloaded block.
ERROR 1: GDALWMS: ReadBlockFromFile failed.
ERROR 1: IReadBlock failed at X offset 0, Y offset 0


On Mon, Mar 23, 2009 at 1:35 PM, Even Rouault
even.roua...@mines-paris.org wrote:
 Roger,

 your GDAL_WMS xml file is not correct. The format of the URL you use is not
 consistant with the one expected by the TileService service. You've used
 the example of TMS service (which really new in GDAL 1.7.0dev SVN only) but
 the correct format would be exactly what you have commented out (${x} in
 lowercase, and not {X}).

 Best regards,
 Even

 Le Monday 23 March 2009 21:18:16 Roger André, vous avez écrit :
 Hi All,

 I've created a TileCache layer that's being used to overlay tiles in a
 Google Maps page.  That's working just fine, but I would also like to
 access this layer via a MapServer WMS call as well.  I have tried to
 setup a GDAL_WMS file that can read the TileCache layer, but am
 getting IReadBlock failed errors when I try to run gdal_translate on
 it, or try to view the layer in a MapServer map.

 Below are the pertinent details of my configuration.

 TileCache layer:
 ---
 [20m_global]
 type=MapServerLayer
 mapfile=/var/www/mapfiles/20m_global/20m_global.map
 #url=http://10.10.40.152/cgi-bin/mapserv?map=/var/www/mapfiles/20m_global/2
0m_global.map metaTile=true
 metaSize=2,2
 metaBuffer=0,500
 layers=imagery
 spherical_mercator=true
 srs=EPSG:900913

 GDAL_WMS xml file:
 --
 GDAL_WMS
 Service name=TileService
 !--ServerUrlhttp://tile.openstreetmap.org/${z}/${x}/${y}.png/ServerUrl
--
 ServerUrlhttp://10.10.10.143/cgi-bin/tilecache-2.04/tilecache.cgi/1.0.0/v
2_80m_global/{Z}/{X}/{Y}.png/ServerUrl /Service
 DataWindow
 UpperLeftX-20037508.34/UpperLeftX
 UpperLeftY20037508.34/UpperLeftY
 LowerRightX20037508.34/LowerRightX
 LowerRightY-20037508.34/LowerRightY
 TileLevel11/TileLevel
 TileCountX1/TileCountX
 TileCountY1/TileCountY
 YOrigintop/YOrigin
 /DataWindow
 ProjectionEPSG:900913/Projection
 BlockSizeX256/BlockSizeX
 BlockSizeY256/BlockSizeY
 BandsCount3/BandsCount
 Cache/
 /GDAL_WMS

 gdalinfo output:
 -
 $ gdalinfo tilecache.xml
 Driver: WMS/OGC Web Map Service
 Files: tilecache.xml
 Size is 524288, 524288
 Coordinate System is:
 PROJCS[Google Maps Global Mercator,
     GEOGCS[WGS 84,
         DATUM[WGS_1984,
             SPHEROID[WGS 84,6378137,298.257223563,
                 AUTHORITY[EPSG,7030]],
             AUTHORITY[EPSG,6326]],
         PRIMEM[Greenwich,0,
             AUTHORITY[EPSG,8901]],
         UNIT[degree,0.01745329251994328,
             AUTHORITY[EPSG,9122]],
         AUTHORITY[EPSG,4326]],
     PROJECTION[Mercator_2SP],
     PARAMETER[standard_parallel_1,0],
     PARAMETER[latitude_of_origin,0],
     PARAMETER[central_meridian,0],
     PARAMETER[false_easting,0],
     PARAMETER[false_northing,0],
     UNIT[Meter,1],
     EXTENSION[PROJ4,+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0
 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgri...@null +wktext
 +no_defs],
     AUTHORITY[EPSG,900913]]
 Origin = (-20037508.33999850988,20037508.33999850988)
 Pixel Size = (76.437028274536132,-76.437028274536132)
 Corner Coordinates:
 Upper Left  (-20037508.340,20037508.340) (180d 0'0.00W, 85d 3'4.06N)
 Lower Left  (-20037508.340,-20037508.340) (180d 0'0.00W, 85d 3'4.06S)
 Upper Right (20037508.340,20037508.340) (180d 0'0.00E, 85d 3'4.06N)
 Lower Right (20037508.340,-20037508.340) (180d 0'0.00E, 85d 3'4.06S)
 Center      (   0.000,   0.000) (  0d 0'0.01E,  0d 0'0.00S)
 Band 1 Block=256x256 Type=Byte, ColorInterp=Undefined
   Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
 256x256
 Band 2 Block=256x256 Type=Byte, ColorInterp=Undefined
   Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
 256x256
 Band 3 Block=256x256 Type=Byte, ColorInterp=Undefined
   Overviews: 262144x262144, 131072x131072, 65536x65536, 32768x32768,
 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024, 512x512,
 256x256

 gdal_translate error:
 
 $ gdal_translate -outsize 1% 1% tilecache.xml test.tif
 Input file size is 524288, 524288
 0ERROR 4: `/vsimem/wms/0x8503470

Re: [mapserver-users] Mapserver WCS - how to return native pixel resolution data?

2009-03-19 Thread Roger André
Hi Alexander,

Thanks for the response.  Yes, I am using a GetCoverage request that
looks like this:

http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
SERVICE=wcs
VERSION=1.0.0
REQUEST=GetCoverage
COVERAGE=elev
CRS=EPSG:4326
BBOX=125,50,130,55
WIDTH=600
HEIGHT=600
FORMAT=image/grid

The source is a single-band image, and the data is correctly returned
as either a single-band GeoTIFF, or an ASCII Grid, depending on which
FORMAT I specify in the WCS string.

What I would like to do is eliminate the WIDTH and HEIGHT parameters
from the request, and just return whatever is available in the BBOX
area.  When I remove them from the request, I get an error that says I
either need HEIGHT and WIDTH, or RESX and RESY.  When I restructure
the command to include RESX and RESY (see below), I get an Out of
memory error.

http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
SERVICE=wcs
VERSION=1.0.0
REQUEST=GetCoverage
COVERAGE=elev
CRS=EPSG:4326
BBOX=125,50,130,55
FORMAT=image/grid
RESX=.033RESY=-.033

I believe I should be able to use the pixel dimensions that are
reported back to me in a DescribeCoverage request, which show them to
be:

gml:offsetVector0.033 0/gml:offsetVector
gml:offsetVector0 -0.033/gml:offsetVector

Thanks for the help,

Roger
--

On Wed, Mar 18, 2009 at 6:51 PM, Alexander Petkov green...@gmail.com wrote:
 On 3/18/09, Roger André ran...@gmail.com wrote:
 Hi All,

  I have a question which I'm not sure relates to the structure of a WCS
  request, or the setup of my WCS server.  I have a tileset of SRTM
  tiles that I would like to query by geographic region via WCS.  I have
  basic functionality working, but I can't figure out how to make a
  request via BBOX that only returns the actual pixels that are present
  in the source data.  Is this possible?  I would think that as long as
  I specified the matching SRS, I should be able to, but I've gotten
  stuck.

 Are you using a WCS getcoverage request to get the data? Is the source
 file a 1 band image? Is the returned data contaiining 3 bands? A
 little more information will be of help to give a good answer.

 You are working in the right direction by configuring your WCS to
 serve the actual data.

 In my case, I have 1 band palletted images, and with a getcoverage
 request  for a bounding box I got the values, but as a grayscale
 image. With some help from another user I managed to add the colormap
 info from the class directives in my map file.

 The following output format is what worked to add a pallette to the
 returned image:
 OUTPUTFORMAT
   NAME GTIFF
   MIMETYPE image/tiff
   DRIVER GDAL/GTiff
   EXTENSION tif
   IMAGEMODE PC256
   TRANSPARENT TRUE
   FORMATOPTION COMPRESS=DEFLATE
   FORMATOPTION ZLEVEL=9
  END

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver WCS - how to return native pixel resolution data?

2009-03-19 Thread Roger André
Sorry for the spam, I think I found the answer.  Both RESX and RESY
need to be positive values.  Using that, I am able to get back data
that matches the original data.

Thanks,

Roger
--

On Thu, Mar 19, 2009 at 11:36 AM, Roger André ran...@gmail.com wrote:
 Hi Alexander,

 Thanks for the response.  Yes, I am using a GetCoverage request that
 looks like this:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 WIDTH=600
 HEIGHT=600
 FORMAT=image/grid

 The source is a single-band image, and the data is correctly returned
 as either a single-band GeoTIFF, or an ASCII Grid, depending on which
 FORMAT I specify in the WCS string.

 What I would like to do is eliminate the WIDTH and HEIGHT parameters
 from the request, and just return whatever is available in the BBOX
 area.  When I remove them from the request, I get an error that says I
 either need HEIGHT and WIDTH, or RESX and RESY.  When I restructure
 the command to include RESX and RESY (see below), I get an Out of
 memory error.

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 FORMAT=image/grid
 RESX=.033RESY=-.033

 I believe I should be able to use the pixel dimensions that are
 reported back to me in a DescribeCoverage request, which show them to
 be:

 gml:offsetVector0.033 0/gml:offsetVector
 gml:offsetVector0 -0.033/gml:offsetVector

 Thanks for the help,

 Roger
 --

 On Wed, Mar 18, 2009 at 6:51 PM, Alexander Petkov green...@gmail.com wrote:
 On 3/18/09, Roger André ran...@gmail.com wrote:
 Hi All,

  I have a question which I'm not sure relates to the structure of a WCS
  request, or the setup of my WCS server.  I have a tileset of SRTM
  tiles that I would like to query by geographic region via WCS.  I have
  basic functionality working, but I can't figure out how to make a
  request via BBOX that only returns the actual pixels that are present
  in the source data.  Is this possible?  I would think that as long as
  I specified the matching SRS, I should be able to, but I've gotten
  stuck.

 Are you using a WCS getcoverage request to get the data? Is the source
 file a 1 band image? Is the returned data contaiining 3 bands? A
 little more information will be of help to give a good answer.

 You are working in the right direction by configuring your WCS to
 serve the actual data.

 In my case, I have 1 band palletted images, and with a getcoverage
 request  for a bounding box I got the values, but as a grayscale
 image. With some help from another user I managed to add the colormap
 info from the class directives in my map file.

 The following output format is what worked to add a pallette to the
 returned image:
 OUTPUTFORMAT
   NAME GTIFF
   MIMETYPE image/tiff
   DRIVER GDAL/GTiff
   EXTENSION tif
   IMAGEMODE PC256
   TRANSPARENT TRUE
   FORMATOPTION COMPRESS=DEFLATE
   FORMATOPTION ZLEVEL=9
  END


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver WCS - how to return native pixel resolution data?

2009-03-19 Thread Roger André
Sure thing.  Here are the OUTPUTFORMAT declarations I have:

OUTPUTFORMAT
  NAME GEOTIFF_FLOAT
  DRIVER 'GDAL/GTiff'
  MIMETYPE 'image/tiff'
  IMAGEMODE FLOAT32
  EXTENSION 'tif'
END

OUTPUTFORMAT
  NAME ASCII_GRID
  DRIVER 'GDAL/AAIGrid'
  MIMETYPE 'image/grid'
  IMAGEMODE FLOAT32
  EXTENSION 'asc'
END

I'll have to check my output data more closely to see if the 1/2 pixel
offset exists.  I've only looked at it in a cursory way so far.  The
version of MapServer I'm using is 5.2.0
--

On Thu, Mar 19, 2009 at 12:14 PM, Alexander Petkov green...@gmail.com wrote:
 On Thu, Mar 19, 2009 at 12:48 PM, Roger André ran...@gmail.com wrote:
 Sorry for the spam, I think I found the answer.  Both RESX and RESY
 need to be positive values.  Using that, I am able to get back data
 that matches the original data.

 Thanks,

 Roger
 --

 On Thu, Mar 19, 2009 at 11:36 AM, Roger André ran...@gmail.com wrote:
 Hi Alexander,

 Thanks for the response.  Yes, I am using a GetCoverage request that
 looks like this:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 WIDTH=600
 HEIGHT=600
 FORMAT=image/grid

 The source is a single-band image, and the data is correctly returned
 as either a single-band GeoTIFF, or an ASCII Grid, depending on which
 FORMAT I specify in the WCS string.

 What I would like to do is eliminate the WIDTH and HEIGHT parameters
 from the request, and just return whatever is available in the BBOX
 area.  When I remove them from the request, I get an error that says I
 either need HEIGHT and WIDTH, or RESX and RESY.  When I restructure
 the command to include RESX and RESY (see below), I get an Out of
 memory error.

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 FORMAT=image/grid
 RESX=.033RESY=-.033

 I believe I should be able to use the pixel dimensions that are
 reported back to me in a DescribeCoverage request, which show them to
 be:

 gml:offsetVector0.033 0/gml:offsetVector
 gml:offsetVector0 -0.033/gml:offsetVector

 Thanks for the help,

 Roger

 Hi Roger:

 Glad to know that you got the problem solved. Do you mind sharing your
 OUTPUTFORMAT configurations in your mapfile if you have them
 configured, particularly for the ASCII grid format.

 Also, are you using a mapserver release older than any of the 5.4
 betas? I am using 5.2.1 and I see the result of the GetCoverage
 request being offset by a half pixel (the pixel size of my data). Bug
 reports indicate that this offset will be fixed for the 5.4 release.


 Thanks in advance,
 Alex

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver WCS - how to return native pixel resolution data?

2009-03-19 Thread Roger André
You're right, 1/2 pixel offset is definitely present. What a pain.
Any idea when the 5.4 stable release is expected?  I see that a beta
release is available currently.
--

On Thu, Mar 19, 2009 at 1:55 PM, Roger André ran...@gmail.com wrote:
 Sure thing.  Here are the OUTPUTFORMAT declarations I have:

 OUTPUTFORMAT
  NAME GEOTIFF_FLOAT
  DRIVER 'GDAL/GTiff'
  MIMETYPE 'image/tiff'
  IMAGEMODE FLOAT32
  EXTENSION 'tif'
 END

 OUTPUTFORMAT
  NAME ASCII_GRID
  DRIVER 'GDAL/AAIGrid'
  MIMETYPE 'image/grid'
  IMAGEMODE FLOAT32
  EXTENSION 'asc'
 END

 I'll have to check my output data more closely to see if the 1/2 pixel
 offset exists.  I've only looked at it in a cursory way so far.  The
 version of MapServer I'm using is 5.2.0
 --

 On Thu, Mar 19, 2009 at 12:14 PM, Alexander Petkov green...@gmail.com wrote:
 On Thu, Mar 19, 2009 at 12:48 PM, Roger André ran...@gmail.com wrote:
 Sorry for the spam, I think I found the answer.  Both RESX and RESY
 need to be positive values.  Using that, I am able to get back data
 that matches the original data.

 Thanks,

 Roger
 --

 On Thu, Mar 19, 2009 at 11:36 AM, Roger André ran...@gmail.com wrote:
 Hi Alexander,

 Thanks for the response.  Yes, I am using a GetCoverage request that
 looks like this:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 WIDTH=600
 HEIGHT=600
 FORMAT=image/grid

 The source is a single-band image, and the data is correctly returned
 as either a single-band GeoTIFF, or an ASCII Grid, depending on which
 FORMAT I specify in the WCS string.

 What I would like to do is eliminate the WIDTH and HEIGHT parameters
 from the request, and just return whatever is available in the BBOX
 area.  When I remove them from the request, I get an error that says I
 either need HEIGHT and WIDTH, or RESX and RESY.  When I restructure
 the command to include RESX and RESY (see below), I get an Out of
 memory error.

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 FORMAT=image/grid
 RESX=.033RESY=-.033

 I believe I should be able to use the pixel dimensions that are
 reported back to me in a DescribeCoverage request, which show them to
 be:

 gml:offsetVector0.033 0/gml:offsetVector
 gml:offsetVector0 -0.033/gml:offsetVector

 Thanks for the help,

 Roger

 Hi Roger:

 Glad to know that you got the problem solved. Do you mind sharing your
 OUTPUTFORMAT configurations in your mapfile if you have them
 configured, particularly for the ASCII grid format.

 Also, are you using a mapserver release older than any of the 5.4
 betas? I am using 5.2.1 and I see the result of the GetCoverage
 request being offset by a half pixel (the pixel size of my data). Bug
 reports indicate that this offset will be fixed for the 5.4 release.


 Thanks in advance,
 Alex


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Custom XML output via WCS, maybe via gdal VRT?

2009-03-19 Thread Roger André
Hi All,

I'm curious if it's possible to get XML output from a WCS request?  It
seems that I can get the server to output any gdal-supported format,
but I don't think GML or XML is one of them.  I currently have ASCII
grid output coming out, but I would like to display the data values
directly in the browser.

Anyone tried this?

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver WCS - how to return native pixel resolution data?

2009-03-19 Thread Roger André
Hi Steve,

You're right.  Version 1.0.0 requests don't show a 1/2 pixel offset
when overlaid on a static data image, version 1.1.0 does.  However,
once they're overlaid, I do see a difference in data values.  I'm
going to have to figure that one out next.

Roger
--

On Thu, Mar 19, 2009 at 3:04 PM, Steve Lime steve.l...@dnr.state.mn.us wrote:
 Are you seeing the issue with both WCS 1.0 and WCS 1.1? I could have
 sworn I fixed WCS 1.0 back at the 5.0 but
 perhaps the merge of the WCS 1.1 support broke that. There is code in
 mapwcs.c to account for the differences in
 various pixel models (MapServer, WCS 1.0 and WCS 1.1).

 Steve

 On 3/19/2009 at 3:59 PM, in message
 9c2015090903191359y4c54cb4dne65f87645d79...@mail.gmail.com, Roger
 André
 ran...@gmail.com wrote:
 You're right, 1/2 pixel offset is definitely present. What a pain.
 Any idea when the 5.4 stable release is expected?  I see that a beta
 release is available currently.
 --

 On Thu, Mar 19, 2009 at 1:55 PM, Roger André ran...@gmail.com
 wrote:
 Sure thing.  Here are the OUTPUTFORMAT declarations I have:

 OUTPUTFORMAT
  NAME GEOTIFF_FLOAT
  DRIVER 'GDAL/GTiff'
  MIMETYPE 'image/tiff'
  IMAGEMODE FLOAT32
  EXTENSION 'tif'
 END

 OUTPUTFORMAT
  NAME ASCII_GRID
  DRIVER 'GDAL/AAIGrid'
  MIMETYPE 'image/grid'
  IMAGEMODE FLOAT32
  EXTENSION 'asc'
 END

 I'll have to check my output data more closely to see if the 1/2
 pixel
 offset exists.  I've only looked at it in a cursory way so far.
 The
 version of MapServer I'm using is 5.2.0
 --

 On Thu, Mar 19, 2009 at 12:14 PM, Alexander Petkov
 green...@gmail.com wrote:
 On Thu, Mar 19, 2009 at 12:48 PM, Roger André ran...@gmail.com
 wrote:
 Sorry for the spam, I think I found the answer.  Both RESX and
 RESY
 need to be positive values.  Using that, I am able to get back
 data
 that matches the original data.

 Thanks,

 Roger
 --

 On Thu, Mar 19, 2009 at 11:36 AM, Roger André ran...@gmail.com
 wrote:
 Hi Alexander,

 Thanks for the response.  Yes, I am using a GetCoverage request
 that
 looks like this:


 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map

 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 WIDTH=600
 HEIGHT=600
 FORMAT=image/grid

 The source is a single-band image, and the data is correctly
 returned
 as either a single-band GeoTIFF, or an ASCII Grid, depending on
 which
 FORMAT I specify in the WCS string.

 What I would like to do is eliminate the WIDTH and HEIGHT
 parameters
 from the request, and just return whatever is available in the
 BBOX
 area.  When I remove them from the request, I get an error that
 says I
 either need HEIGHT and WIDTH, or RESX and RESY.  When I
 restructure
 the command to include RESX and RESY (see below), I get an Out
 of
 memory error.


 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map

 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 COVERAGE=elev
 CRS=EPSG:4326
 BBOX=125,50,130,55
 FORMAT=image/grid
 RESX=.033RESY=-.033

 I believe I should be able to use the pixel dimensions that are
 reported back to me in a DescribeCoverage request, which show
 them to
 be:

 gml:offsetVector0.033 0/gml:offsetVector
 gml:offsetVector0 -0.033/gml:offsetVector

 Thanks for the help,

 Roger

 Hi Roger:

 Glad to know that you got the problem solved. Do you mind sharing
 your
 OUTPUTFORMAT configurations in your mapfile if you have them
 configured, particularly for the ASCII grid format.

 Also, are you using a mapserver release older than any of the 5.4
 betas? I am using 5.2.1 and I see the result of the GetCoverage
 request being offset by a half pixel (the pixel size of my data).
 Bug
 reports indicate that this offset will be fixed for the 5.4
 release.


 Thanks in advance,
 Alex


 ___
 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] WMS Google Layer !

2009-03-12 Thread Roger André
Would it not be simpler for you to add the WMS layer to Google Maps
instead?  There are several javascript solutions for doing this, and
the performance seems to be quite good.
--



On Mon, Mar 9, 2009 at 11:13 AM, Julien-Samuel Lacroix
jlacr...@mapgears.com wrote:
 Hi,

 Someone correct me if I'm wrong.
 Google Maps licence doesn't allow you to use it outside the Google Maps API.
 So you are not allowed to use it as a WMS server in MapServer. You have to
 use an application that use the API like OpenLayers.

 Julien

 Paul james wrote:

 Hello guys...
 I´m trying to add a Google Maps WMS layer on mapserver... Without sucess
 ...
 If someone could help me on that, It will be great !

 Thanks...


 

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

 --
 Julien-Samuel Lacroix
 Mapgears
 http://www.mapgears.com/
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] WMS Google Layer !

2009-03-12 Thread Roger André
Here's one.  It's based on code that John Deck at Berkeley developed.
His original code can be found here -
http://chignik.berkeley.edu/google/wmstest236.html.  I've modified it
to suit my needs.  I've included my modified .js, as well as a gmap
html page that shows how to use it.

Good luck.
--

On Thu, Mar 12, 2009 at 9:17 AM, John Ruffing jruff...@lizardtech.com wrote:
 I like that idea..  Where are these JavaScript solutions located?

 John


 -Original Message-
 From: mapserver-users-boun...@lists.osgeo.org 
 [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Roger André
 Sent: Thursday, March 12, 2009 9:16 AM
 To: Julien-Samuel Lacroix
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] WMS Google Layer !

 Would it not be simpler for you to add the WMS layer to Google Maps instead?  
 There are several javascript solutions for doing this, and the performance 
 seems to be quite good.
 --



 On Mon, Mar 9, 2009 at 11:13 AM, Julien-Samuel Lacroix 
 jlacr...@mapgears.com wrote:
 Hi,

 Someone correct me if I'm wrong.
 Google Maps licence doesn't allow you to use it outside the Google Maps API.
 So you are not allowed to use it as a WMS server in MapServer. You
 have to use an application that use the API like OpenLayers.

 Julien

 Paul james wrote:

 Hello guys...
 I´m trying to add a Google Maps WMS layer on mapserver... Without
 sucess ...
 If someone could help me on that, It will be great !

 Thanks...


 -
 ---

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

 --
 Julien-Samuel Lacroix
 Mapgears
 http://www.mapgears.com/
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

Title: Google Map and WMS Layer Integration Test



  
  
  
  



wms_randre.js
Description: JavaScript source
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Problems mapping regions that span Dateline

2009-03-06 Thread Roger André
Hi Brent,

Thanks for your reply.  Converting to a 0 - 360 longitude span seems
like it would work, but as part of my map contains imagery data, I
think it would probably be best if I could define a new projection in
my epsg file that contained the required parameters.  Is that
possible?  I have implemented the DateLine wrap in OpenLayers, and it
works well there.  Unfortunately, I also need to generate some map
images dynamically via mapscript, and this is where I have the most
problems.

Thanks again,

Roger
--

On Thu, Mar 5, 2009 at 1:54 PM, Brent Wood pcr...@yahoo.com wrote:


 Welcome to my world...


 The simplest way is, if you can, convert your longitutes to a 0-360 instead 
 of +-180 space. If you use PostGIS the shift_longitude function works, Proj.4 
 can also be told which space to use for western hemisphere longitudes and 
 generate longs in the 0-360 space.

 Alternatively, if you stick to +-180, you can use OpenLayers at the client 
 end, as this has a switch available to work across 180.


 HTH,

  Brent Wood


 --- On Fri, 3/6/09, Roger André ran...@gmail.com wrote:

 From: Roger André ran...@gmail.com
 Subject: [mapserver-users] Problems mapping regions that span Dateline
 To: mapserver-users@lists.osgeo.org mapserver-users@lists.osgeo.org
 Date: Friday, March 6, 2009, 8:30 AM
 Hi All,

 I'm having some problems mapping some regions of the
 world that span
 the Dateline.  I have several examples of this, but using
 one, the UN
 subregion defined as being South Pacific, as an
 example illustrates
 the problem nicely.  This region has the following extents:

 Corner Coordinates:
 Upper Left  (-180.000,  28.233)
 Lower Left  (-180.000, -29.067)
 Upper Right ( 180.000,  28.233)
 Lower Right ( 180.000, -29.067)

 The map that is generated using these extents with EPSG
 4326 spans the
 entire globe, and I'd like to find a way to show the
 are in a more
 concise fashion.  I have the same problem with New Zealand,
 and with
 the full extents of the USA.

 Hoping for some suggestions.

 Thanks,

 Roger
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Problems mapping regions that span Dateline

2009-03-05 Thread Roger André
Hi All,

I'm having some problems mapping some regions of the world that span
the Dateline.  I have several examples of this, but using one, the UN
subregion defined as being South Pacific, as an example illustrates
the problem nicely.  This region has the following extents:

Corner Coordinates:
Upper Left  (-180.000,  28.233)
Lower Left  (-180.000, -29.067)
Upper Right ( 180.000,  28.233)
Lower Right ( 180.000, -29.067)

The map that is generated using these extents with EPSG 4326 spans the
entire globe, and I'd like to find a way to show the are in a more
concise fashion.  I have the same problem with New Zealand, and with
the full extents of the USA.

Hoping for some suggestions.

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Image Quality - Image Preprocessing

2009-03-04 Thread Roger André
Hi Travis,

From a purely subjective standpoint, I feel that the bilinear
resampling method works the best with aerial photo data.  You can test
this using gdalwarp:

gdalwarp -ts x_size y_size -r resampling_method infile outfile

But before you resample all your data, you might try adding the
following processing directive to your imagery layer:

PROCESSING RESAMPLE=BILINEAR

You might find that this improves things enough.

Roger
--

On Wed, Mar 4, 2009 at 6:54 AM, Travis Kirstine
traviskirst...@gmail.com wrote:
 We are running mapserver connected to a tilecache delivering high
 resolution orthophoto to a google maps.  The problem I am having is
 that we preprocess all our imagery using reduced resolutions at higher
 scales and full resolution at lower scales.  In the past we have used
 gdal_merge with - ps 10 10  to merge tile into larger overalls and
 downsampling  the resolution but we have found that the image quality
 was not adequate.  I have been experimenting with gdalwarp using the
 different resampling methods with varied results.  Is there any
 consensus on which resampling method provided with gdal provide the
 optimal results (from a viewing perspective) when downsampling imagery
 data?

 --
 Travis K.

 Toronto, Canada
 
 She knows there's no success like failure
 And that failure's no success at all.
 -Bob Dylan-
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] WCS that reads NetCDF files returns Image handling error. Attempt to operate on GDAL file with no bands

2009-02-27 Thread Roger André
Hi Norman,

Sorry for the direct email, but much of the relevant documentation
that I have found regarding this topic appears to have been written by
you.  I'm hoping you can take the time to share a bit more of your
wisdom regarding this.

I would like to setup a Mapserver WCS service that reads a single
netCDF file as the data source.  Later on I'd like to get fancy and
read multiple files as a tileindex, with multiple time slices in them,
but for now I am just trying to read a single file with a one-band
data layer in it.  I am using the example you posted on the Mapserver
website, http://mapserver.org/ogc/wcs_format.html, as well as an old
post from you -
http://lists.osgeo.org/pipermail/mapserver-users/2005-November/012153.html.
 The examples are great, but I'm having trouble adapting them to my
sample data.

I have downloaded a CF convention netCDF file from
http://www.unidata.ucar.edu/software/netcdf/examples/sresa1b_ncar_ccsm3_0_run1_21.nc,
which contains a SUBDATASET named tas.  This SUBDATASET contains
only a single band, which when queried by gdalinfo looks like this
(Note: I have omitted the Metadata for clarity.)
---
$ gdalinfo NETCDF:sresa1b_ncar_ccsm3_0_run1_21.nc:tas
Warning 1: Latitude grid not spaced evenly.
Seting projection for grid spacing is within 0.1 degrees threshold.

Driver: netCDF/Network Common Data Format
Files: none associated
Size is 256, 128
Coordinate System is `'
Origin = (-0.7031250,89.627952755905511)
Pixel Size = (1.4062500,-1.400436761811024)
Corner Coordinates:
Upper Left  (  -0.7031250,  89.6279528)
Lower Left  (  -0.7031250, -89.6279528)
Upper Right ( 359.297,  89.628)
Lower Right ( 359.297, -89.628)
Center  ( 179.2968750,   0.000)
Band 1 Block=256x1 Type=Float32, ColorInterp=Undefined
  NoData Value=1.0002004087734e+20
  Metadata:
    NETCDF_VARNAME=tas
    NETCDF_DIMENSION_time=730136
    NETCDF_time_units=days since -1-1
--

I have setup a mapfile to read this file/layer which looks like this:

--
MAP
NAME 'netcdf'

OUTPUTFORMAT
  NAME GEOTIFF_FLOAT
  DRIVER 'GDAL/GTiff'
  MIMETYPE 'image/tiff'
  IMAGEMODE FLOAT32
  EXTENSION 'tif'
END

LAYER
NAME tas
STATUS OFF
TYPE RASTER
DUMP TRUE
DATA sresa1b_ncar_ccsm3_0_run1_21.nc
METADATA
wcs_label Test netCDF Server
ows_extent '-0.7031250 -89.6279528 359.297 89.628' # -- 0 to 360?
wcs_resolution '1.4062500 -1.400436761811024'
ows_srs EPSG:4326 # -- Not sure about this
wcs_formats GEOTIFF_FLOAT
wcs_nativeformat netCDF
wcs_bandcount 1 # -- Not sure about this
wcs_rangeset_axes bands
wcs_rangeset_label Atmospheric Levels
wcs_rangeset_name tas # -- Not sure about this
END # end metadata
END # end layer

END # map


I took a stab at what the wcs and ows entries should look like in the
METADATA section, but I'm not at all sure I got them right.  For
example, the geographic extents of all the netCDF files I have seen so
far seem to use a 0 - 360 longitude range.  I'm not really sure how to
reconcile this with the ows_srs of EPSG:4326, of how to properly list
the extents.  I used what gdalinfo reports, thinking that since gdal
would be reading the file, the info should match.

With this mapfile, I am able to execute a DescribeCoverage request
using the following command:

---
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
SERVICE=WCS
VERSION=1.0.0
REQUEST=DescribeCoverage
COVERAGE=tas
---

I've attached the XML that is returned, it appears to be reasonable,
but whether it is correct or not, I'm not sure.  What is certain
though, is that when I try to make a GetCoverage request, I get back a
consistent error that says Attempt to operate on GDAL file with no
bands, layer=tas.  My GetCoverage request looks like this:

---
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
SERVICE=wcs
VERSION=1.0.0
REQUEST=GetCoverage
coverage=tas
CRS=EPSG:4326
BBOX=-0.703125,-89.6279528,359.297,89.628
WIDTH=600
HEIGHT=600
FORMAT=image/tiff
---

The error that is returned looks like this:

---
?xml version='1.0' encoding=ISO-8859-1 ?
ServiceExceptionReport version=1.2.0
xmlns=http://www.opengis.net/ogc;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xsi:schemaLocation=http://www.opengis.net/ogc
http://schemas.opengis.net/wcs/1.0.0/OGC-exception.xsd;
  ServiceExceptionmsGetGDALBandList(): Image handling error. Attempt
to operate on GDAL file with no bands, layer=tas.
  /ServiceException
/ServiceExceptionReport


And now I am stuck.  Since there are quite a few different parameters
that need to be set, I'm not 

[mapserver-users] Re: WCS that reads NetCDF files returns Image handling error. Attempt to operate on GDAL file with no bands

2009-02-27 Thread Roger André
Alright, found a promising lead in
http://trac.osgeo.org/mapserver/ticket/2462.  It appears that the DATA
parameter for the layer needs to specify more than just the filename
of the netcdf.  Using the syntax below returns a GeoTIFF.

DATA netCDF:/var/www/mapfiles/netCDF/sresa1b_ncar_ccsm3_0_run1_21.nc:tas

Now need to figure out how to work with the extents.
--

On Fri, Feb 27, 2009 at 11:40 AM, Roger André ran...@gmail.com wrote:
 Hi Norman,

 Sorry for the direct email, but much of the relevant documentation
 that I have found regarding this topic appears to have been written by
 you.  I'm hoping you can take the time to share a bit more of your
 wisdom regarding this.

 I would like to setup a Mapserver WCS service that reads a single
 netCDF file as the data source.  Later on I'd like to get fancy and
 read multiple files as a tileindex, with multiple time slices in them,
 but for now I am just trying to read a single file with a one-band
 data layer in it.  I am using the example you posted on the Mapserver
 website, http://mapserver.org/ogc/wcs_format.html, as well as an old
 post from you -
 http://lists.osgeo.org/pipermail/mapserver-users/2005-November/012153.html.
  The examples are great, but I'm having trouble adapting them to my
 sample data.

 I have downloaded a CF convention netCDF file from
 http://www.unidata.ucar.edu/software/netcdf/examples/sresa1b_ncar_ccsm3_0_run1_21.nc,
 which contains a SUBDATASET named tas.  This SUBDATASET contains
 only a single band, which when queried by gdalinfo looks like this
 (Note: I have omitted the Metadata for clarity.)
 ---
 $ gdalinfo NETCDF:sresa1b_ncar_ccsm3_0_run1_21.nc:tas
 Warning 1: Latitude grid not spaced evenly.
 Seting projection for grid spacing is within 0.1 degrees threshold.

 Driver: netCDF/Network Common Data Format
 Files: none associated
 Size is 256, 128
 Coordinate System is `'
 Origin = (-0.7031250,89.627952755905511)
 Pixel Size = (1.4062500,-1.400436761811024)
 Corner Coordinates:
 Upper Left  (  -0.7031250,  89.6279528)
 Lower Left  (  -0.7031250, -89.6279528)
 Upper Right ( 359.297,  89.628)
 Lower Right ( 359.297, -89.628)
 Center  ( 179.2968750,   0.000)
 Band 1 Block=256x1 Type=Float32, ColorInterp=Undefined
   NoData Value=1.0002004087734e+20
   Metadata:
     NETCDF_VARNAME=tas
     NETCDF_DIMENSION_time=730136
     NETCDF_time_units=days since -1-1
 --

 I have setup a mapfile to read this file/layer which looks like this:

 --
 MAP
 NAME 'netcdf'

 OUTPUTFORMAT
  NAME GEOTIFF_FLOAT
  DRIVER 'GDAL/GTiff'
  MIMETYPE 'image/tiff'
  IMAGEMODE FLOAT32
  EXTENSION 'tif'
 END

    LAYER
        NAME tas
        STATUS OFF
        TYPE RASTER
        DUMP TRUE
        DATA sresa1b_ncar_ccsm3_0_run1_21.nc
        METADATA
            wcs_label Test netCDF Server
            ows_extent '-0.7031250 -89.6279528 359.297 89.628' # -- 0 to 360?
            wcs_resolution '1.4062500 -1.400436761811024'
            ows_srs EPSG:4326 # -- Not sure about this
            wcs_formats GEOTIFF_FLOAT
            wcs_nativeformat netCDF
            wcs_bandcount 1 # -- Not sure about this
            wcs_rangeset_axes bands
            wcs_rangeset_label Atmospheric Levels
            wcs_rangeset_name tas # -- Not sure about this
        END # end metadata
    END # end layer

 END # map
 

 I took a stab at what the wcs and ows entries should look like in the
 METADATA section, but I'm not at all sure I got them right.  For
 example, the geographic extents of all the netCDF files I have seen so
 far seem to use a 0 - 360 longitude range.  I'm not really sure how to
 reconcile this with the ows_srs of EPSG:4326, of how to properly list
 the extents.  I used what gdalinfo reports, thinking that since gdal
 would be reading the file, the info should match.

 With this mapfile, I am able to execute a DescribeCoverage request
 using the following command:

 ---
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=WCS
 VERSION=1.0.0
 REQUEST=DescribeCoverage
 COVERAGE=tas
 ---

 I've attached the XML that is returned, it appears to be reasonable,
 but whether it is correct or not, I'm not sure.  What is certain
 though, is that when I try to make a GetCoverage request, I get back a
 consistent error that says Attempt to operate on GDAL file with no
 bands, layer=tas.  My GetCoverage request looks like this:

 ---
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/netCDF/netcdf.map
 SERVICE=wcs
 VERSION=1.0.0
 REQUEST=GetCoverage
 coverage=tas
 CRS=EPSG:4326
 BBOX=-0.703125,-89.6279528,359.297,89.628
 WIDTH=600
 HEIGHT=600
 FORMAT=image/tiff
 ---

 The error that is returned looks like this:

 ---
 ?xml version='1.0' encoding=ISO

[mapserver-users] wcs client support

2009-02-27 Thread Roger André
Hi All,

Does anyone know of any work being done to implement WCS client
functionality in Mapserver?  I have seen a passing reference to this
on the OGC Galeon page, http://www.ogcnetwork.net/node/113. It looked
like Texas AM was going to implement a test client, but I can't find
any additional info about this.

I'd like to make some maps using data stored on WCS servers, but I
can't seem to find any clients that can render the data directly.

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] wcs client support

2009-02-27 Thread Roger André
Hi Frank,

I didn't know about the gdal WCS driver.  I'll see if I can get
something working from the doc you've linked to.

Thanks,

Roger
--

On Fri, Feb 27, 2009 at 2:04 PM, Frank Warmerdam warmer...@pobox.com wrote:
 Roger André wrote:

 Hi All,

 Does anyone know of any work being done to implement WCS client
 functionality in Mapserver?  I have seen a passing reference to this
 on the OGC Galeon page, http://www.ogcnetwork.net/node/113. It looked
 like Texas AM was going to implement a test client, but I can't find
 any additional info about this.

 I'd like to make some maps using data stored on WCS servers, but I
 can't seem to find any clients that can render the data directly.

 Roger,

 GDAL already has a WCS driver so the normal approach to serving maps
 from WCS sources is to use MapServer and GDAL's WCS driver.  Within reason
 I can provide assistance trying this out.

  http://www.gdal.org/frmt_wcs.html

 Best regards,
 --
 ---+--
 I set the clouds in motion - turn up   | Frank Warmerdam,
 warmer...@pobox.com
 light and sound - activate the windows | http://pobox.com/~warmerdam
 and watch the world go round - Rush    | Geospatial Programmer for Rent


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] wcs client support

2009-02-27 Thread Roger André
Hi Frank,

Apologies if this is a dense question, but is it correct to assume the
following:

1) create an XML file similar to this one that points at valid WCS service:
WCS_GDAL
  ServiceURLhttp://maps.gdal.org/cgi-bin/mapserv_dem?/ServiceURL
  CoverageNamesrtmplus_raw/CoverageName
/WCS_GDAL

2. Create a Mapserver LAYER with TYPE raster, and where the DATA line
points to the above-mentioned XML file.

Is that it?  Do I need to specify in the LAYER something special for
Mapserver to use GDAL to query the WCS via the XML file? (whew, say
that 3x fast)

Thanks,

Roger
--

On Fri, Feb 27, 2009 at 2:38 PM, Roger André ran...@gmail.com wrote:
 Hi Frank,

 I didn't know about the gdal WCS driver.  I'll see if I can get
 something working from the doc you've linked to.

 Thanks,

 Roger
 --

 On Fri, Feb 27, 2009 at 2:04 PM, Frank Warmerdam warmer...@pobox.com wrote:
 Roger André wrote:

 Hi All,

 Does anyone know of any work being done to implement WCS client
 functionality in Mapserver?  I have seen a passing reference to this
 on the OGC Galeon page, http://www.ogcnetwork.net/node/113. It looked
 like Texas AM was going to implement a test client, but I can't find
 any additional info about this.

 I'd like to make some maps using data stored on WCS servers, but I
 can't seem to find any clients that can render the data directly.

 Roger,

 GDAL already has a WCS driver so the normal approach to serving maps
 from WCS sources is to use MapServer and GDAL's WCS driver.  Within reason
 I can provide assistance trying this out.

  http://www.gdal.org/frmt_wcs.html

 Best regards,
 --
 ---+--
 I set the clouds in motion - turn up   | Frank Warmerdam,
 warmer...@pobox.com
 light and sound - activate the windows | http://pobox.com/~warmerdam
 and watch the world go round - Rush    | Geospatial Programmer for Rent



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] wcs client support

2009-02-27 Thread Roger André
Unbelievable.  This is really incredible.  Works like a champ.

Thanks for your help.
--

On Fri, Feb 27, 2009 at 3:38 PM, Frank Warmerdam warmer...@pobox.com wrote:
 Roger André wrote:

 Hi Frank,

 Apologies if this is a dense question, but is it correct to assume the
 following:

 1) create an XML file similar to this one that points at valid WCS
 service:
 WCS_GDAL
  ServiceURLhttp://maps.gdal.org/cgi-bin/mapserv_dem?/ServiceURL
  CoverageNamesrtmplus_raw/CoverageName
 /WCS_GDAL

 2. Create a Mapserver LAYER with TYPE raster, and where the DATA line
 points to the above-mentioned XML file.



 Is that it?

 Yes

 Do I need to specify in the LAYER something special for

 Mapserver to use GDAL to query the WCS via the XML file? (whew, say
 that 3x fast)

 No, nothing special.  As far as MapServer knows this is just
 another raster file.  I will note that the XML file with the WCS
 definition needs to be writable as the first time it is accessed
 GDAL will fetch the WCS capabilities and add a bunch more detail in
 the XML file.  You might want to even trigger this in advance with
 gdalinfo to ensure things are working ok.

 Best regards,
 --
 ---+--
 I set the clouds in motion - turn up   | Frank Warmerdam,
 warmer...@pobox.com
 light and sound - activate the windows | http://pobox.com/~warmerdam
 and watch the world go round - Rush    | Geospatial Programmer for Rent


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Python mapscript: inline point feature How To

2009-02-24 Thread Roger André
Hi Everyone,

A little while ago, Brent Fraser sent me a mapfile snippet that could be
used to add a Title to a map using pixel coordinate space.  It looked like
this:

  LAYER
NAME title
STATUS DEFAULT
TRANSFORM FALSE
TYPE ANNOTATION

FEATURE
  POINTS 4 396 END
  TEXT 'This is a Great Map!'
END

CLASS
  LABEL
TYPE TRUETYPE
FONT arial
SIZE 8
ANTIALIAS
COLOR 255 255 255
POSITION UR
  END
END

  END

This works well, but I would like to override the TEXT value using mapscript
to create new labels that are based on the result of PostGIS queries.  I've
been picking apart various examples on the web, but can't seem to come up
with the magic sauce.  I can figure out how to grab the layer ByName, but
then I'm not quite sure what I need to do in order to access the feature and
override the TEXT.

Can someone give me a clue?

Thanks,

Roger
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Python mapscript: inline point feature How To

2009-02-24 Thread Roger André
Answered my own question using Sean Gillies AWESOME unit tests - again.
http://kentuckykarst.org/mapserver/mapscript/python/tests/cases/fonttest.py

  title_layer = mapobject.getLayerByName(title)
  point = mapscript.pointObj(500, 4)
  coords = mapscript.lineObj()
  coords.add(point)
  feature = mapscript.shapeObj(title_layer.type)
  feature.add(coords)
  feature.text = title_string
  title_layer.addFeature(feature)

I also had to comment out the FEATURE section of my mapfile, in order to
prevent having 2 entries in the resulting map.
--


On Tue, Feb 24, 2009 at 2:44 PM, Roger André ran...@gmail.com wrote:

 Hi Everyone,

 A little while ago, Brent Fraser sent me a mapfile snippet that could be
 used to add a Title to a map using pixel coordinate space.  It looked like
 this:

   LAYER
 NAME title
 STATUS DEFAULT
 TRANSFORM FALSE
 TYPE ANNOTATION

 FEATURE
   POINTS 4 396 END
   TEXT 'This is a Great Map!'
 END

 CLASS
   LABEL
 TYPE TRUETYPE
 FONT arial
 SIZE 8
 ANTIALIAS
 COLOR 255 255 255
 POSITION UR
   END
 END

   END

 This works well, but I would like to override the TEXT value using
 mapscript to create new labels that are based on the result of PostGIS
 queries.  I've been picking apart various examples on the web, but can't
 seem to come up with the magic sauce.  I can figure out how to grab the
 layer ByName, but then I'm not quite sure what I need to do in order to
 access the feature and override the TEXT.

 Can someone give me a clue?

 Thanks,

 Roger

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] GDAL image handling band error with NetCDF WCS layer

2009-02-18 Thread Roger André
Hi All,

- I am attempting to use a NetCDF file as a data source for a raster layer
in Mapserver.  According to a very useful email sent in November 2005 from
Norman Barker,
http://lists.osgeo.org/pipermail/mapserver-users/2005-November/012153.html,
and from Mapserver documentation at
http://www.mapserver.org/ogc/wcs_format.html#netcdf, it seems like this
should be possible using Mapserver's gdal driver to read the file.  However,
I am running into some problems when trying to implement his example.

- The NetCDF file which I am using is a CF Convention sample file which I
downloaded from
http://www.unidata.ucar.edu/software/netcdf/examples/tos_O1_2001-2002.nc.
This file contains information about sea-surface temperatures, and when
viewed by gdalinfo has the following characteristics:

$ gdalinfo tos_O1_2001-2002.nc
Driver: netCDF/Network Common Data Format
Files: tos_O1_2001-2002.nc
Size is 512, 512
Coordinate System is `'
Metadata:
  NC_GLOBAL#title=IPSL  model output prepared for IPCC Fourth Assessment
SRES A2 experiment
  NC_GLOBAL#institution=IPSL (Institut Pierre Simon Laplace, Paris, France)
  NC_GLOBAL#source=IPSL-CM4_v1 (2003) : atmosphere : LMDZ (IPSL-CM4_IPCC,
96x71x19) ; ocean ORCA2 (ipsl_cm4_v1_8, 2x2L31); sea ice LIM (ipsl_cm4_v
  NC_GLOBAL#contact=Sebastien Denvil, sebastien.den...@ipsl.jussieu.fr
  NC_GLOBAL#project_id=IPCC Fourth Assessment
  NC_GLOBAL#table_id=Table O1 (13 November 2004)
  NC_GLOBAL#experiment_id=SRES A2 experiment
  NC_GLOBAL#realization=1
  NC_GLOBAL#cmor_version=9.60e-01
  NC_GLOBAL#Conventions=CF-1.0
  NC_GLOBAL#history=/MM/JJ: data generated; /MM/JJ+1 data
transformed  At 16:37:23 on 01/11/2005, CMOR rewrote data to comply with CF
standards and IPCC Fourth Assessment requirements
  NC_GLOBAL#references=Dufresne et al, Journal of Climate, 2015, vol XX, p
136
  NC_GLOBAL#comment=Test drive
Subdatasets:
  SUBDATASET_1_NAME=NETCDF:tos_O1_2001-2002.nc:lon_bnds
  SUBDATASET_1_DESC=[180x2] lon_bnds (64-bit floating-point)
  SUBDATASET_2_NAME=NETCDF:tos_O1_2001-2002.nc:lat_bnds
  SUBDATASET_2_DESC=[170x2] lat_bnds (64-bit floating-point)
  SUBDATASET_3_NAME=NETCDF:tos_O1_2001-2002.nc:time_bnds
  SUBDATASET_3_DESC=[24x2] time_bnds (64-bit floating-point)
  SUBDATASET_4_NAME=NETCDF:tos_O1_2001-2002.nc:tos
  SUBDATASET_4_DESC=[24x170x180] sea_surface_temperature (32-bit
floating-point)
Corner Coordinates:
Upper Left  (0.0,0.0)
Lower Left  (0.0,  512.0)
Upper Right (  512.0,0.0)
Lower Right (  512.0,  512.0)
Center  (  256.0,  256.0)

- The SUBDATASET of interest is the tos one, and when queried by gdalinfo
it shows that it contains 24 bands, each of which varies by
NETCDF_DIMENSION_time that increments by 15.  When specifically queried by
gdalinfo, this SUBDATASET looks like this:

$ gdalinfo NETCDF:tos_O1_2001-2002.nc:tos
Driver: netCDF/Network Common Data Format
Files: none associated
Size is 180, 170
Coordinate System is `'
Origin = (0.000,90.000)
Pixel Size = (2.000,-1.000)
Metadata:
  NC_GLOBAL#title=IPSL  model output prepared for IPCC Fourth Assessment
SRES A2 experiment
  NC_GLOBAL#institution=IPSL (Institut Pierre Simon Laplace, Paris, France)
  NC_GLOBAL#source=IPSL-CM4_v1 (2003) : atmosphere : LMDZ (IPSL-CM4_IPCC,
96x71x19) ; ocean ORCA2 (ipsl_cm4_v1_8, 2x2L31); sea ice LIM (ipsl_cm4_v
  NC_GLOBAL#contact=Sebastien Denvil, sebastien.den...@ipsl.jussieu.fr
  NC_GLOBAL#project_id=IPCC Fourth Assessment
  NC_GLOBAL#table_id=Table O1 (13 November 2004)
  NC_GLOBAL#experiment_id=SRES A2 experiment
  NC_GLOBAL#realization=1
  NC_GLOBAL#cmor_version=9.60e-01
  NC_GLOBAL#Conventions=CF-1.0
  NC_GLOBAL#history=/MM/JJ: data generated; /MM/JJ+1 data
transformed  At 16:37:23 on 01/11/2005, CMOR rewrote data to comply with CF
standards and IPCC Fourth Assessment requirements
  NC_GLOBAL#references=Dufresne et al, Journal of Climate, 2015, vol XX, p
136
  NC_GLOBAL#comment=Test drive
  tos#standard_name=sea_surface_temperature
  tos#long_name=Sea Surface Temperature
  tos#units=K
  tos#cell_methods=time: mean (interval: 30 minutes)
  tos#_FillValue=1.00e+20
  tos#missing_value=1.00e+20
  tos#original_name=sosstsst
  tos#original_units=degC
  tos#history= At   16:37:23 on 01/11/2005: CMOR altered the data in the
following ways: added 2.73150E+02 to yield output units;  Cyclical dimension
was output starting at a different lon;
  lon#standard_name=longitude
  lon#long_name=longitude
  lon#units=degrees_east
  lon#axis=X
  lon#bounds=lon_bnds
  lon#original_units=degrees_east
  lat#standard_name=latitude
  lat#long_name=latitude
  lat#units=degrees_north
  lat#axis=Y
  lat#bounds=lat_bnds
  lat#original_units=degrees_north
  time#standard_name=time
  time#long_name=time
  time#units=days since 2001-1-1
  time#axis=T
  time#calendar=360_day
  time#bounds=time_bnds
  time#original_units=seconds since 2001-1-1
Corner Coordinates:
Upper Left  (   0.000,  90.000)
Lower Left  (   

[mapserver-users] Reading raster data source dynamically

2009-02-12 Thread Roger André
Hi All,

I'm wondering if there is some way I could feed Mapserver a raster data
source dynamically?  Like maybe constructing a GeoTIFF in memory from a
numerical array, and then passing that into mapscript along with the rest of
the layer info.  The goal here is to avoid having to create temporary image
files for each of the raster layers that I'm mapping.

Any idea here would be welcome.

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Reading raster data source dynamically

2009-02-12 Thread Roger André
Or maybe creating a GDAL In Memory Raster and then pointing to it as the
data source for the mapscript layer?
--

On Thu, Feb 12, 2009 at 3:46 PM, Roger André ran...@gmail.com wrote:

 Hi All,

 I'm wondering if there is some way I could feed Mapserver a raster data
 source dynamically?  Like maybe constructing a GeoTIFF in memory from a
 numerical array, and then passing that into mapscript along with the rest of
 the layer info.  The goal here is to avoid having to create temporary image
 files for each of the raster layers that I'm mapping.

 Any idea here would be welcome.

 Thanks,

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Python mapscript, cStringIO, and the AGG renderer

2009-02-01 Thread Roger André
Hi All,

I'm having problems using the AGG renderer with Python mapscript.  I believe
it may be due to the way in which I am writing the image into a
cStringIO.StringIO() object, but I'm not sure.  I do know that if I comment
out my OUTPUTFORMAT section of the mapfile, I get an image back in my
browser. I'm hoping I can fix this somehow with a FORMATOPTION.

- Below is the mapscript and Python CGI:
#! /usr/bin/python

import mapscript
import cStringIO

def DrawMap():
mapfile = /var/www/mapfiles/gis_layers/gis_layers.map
mapobject = mapscript.mapObj(mapfile)
mapimage = mapobject.draw()
f = cStringIO.StringIO()
mapimage.write(f)

print Content-type: image/png\n
f.seek(0)
print f.read()
print mapimage

if __name__ == __main__:
DrawMap()

- And here is the OUTPUTFORMAT section that's causing the problem:
OUTPUTFORMAT
  NAME 'AGG'
  DRIVER AGG/PNG
  IMAGEMODE RGB
END

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Python mapscript, cStringIO, and the AGG renderer

2009-02-01 Thread Roger André
- MapServer version 5.2.0

[image: The image http://localhost/cgi-bin/mapscript/dynamic_map.py; cannot
be displayed, because it contains errors.]- The image cannot be displayed,
because it contains errors.
-- 



On Sun, Feb 1, 2009 at 12:05 PM, thomas bonfort thomas.bonf...@gmail.comwrote:

  I'm having problems using the AGG renderer with Python mapscript.

 what version of mapserver, and exactly what problem?

 regards,
 thomas

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] google tiles

2009-01-19 Thread Roger André
Fascinating, thanks for sending the link!  Since you state that you only get
blank images when you try it out, perhaps it is a projection mis-match? It
appears that your mapfile extents are defined in meters, which would match
spherical mercator, but your layer is in EPSG 4326.  What if you make your
extents be in lat/lon instead?

Roger
--

On Mon, Jan 19, 2009 at 10:29 AM, Chad Clabaugh cclaba...@centwire.comwrote:

  Thanks for your reply Roger.  The spec for tilemode is at
 http://mapserver.org/output/tile_mode.html But I'll definitely look into
 TileCache as well.





 *From:* Roger André [mailto:ran...@gmail.com]
 *Sent:* Monday, January 19, 2009 12:03 PM
 *To:* Chad Clabaugh
 *Cc:* mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] google tiles



 Hi Chad,

 I wasn't aware that tile is a valid mode of operation for Mapserver.  I
 looked on http://mapserver.org/cgi/controls.html and didn't see it
 referenced there, but its entirely possible that it exists and that I've
 just missed it.  In any case, the way I'm familiar with generating google
 map tiles is via the use of Tilecache.  Tilecache works as in intermediary
 between Mapserver and your Google map. It make the appropriate request to
 Mapserver for a tile, and then returns the tile to your map.  I think this
 might be the solution you're looking for, http://tilecache.org/.

 Best of luck,

 Roger
 --

 On Mon, Jan 19, 2009 at 6:50 AM, Chad Clabaugh cclaba...@centwire.com
 wrote:

 Greetings,

 I have been trying to generate google tiles from shapefiles using
 mapserver.  I have been able to successfully generate maps by calling the
 url
 http://0.0.0.0/cgi-bin/mapserv?map=/srv/www/htdocs/mapserver/coverage.mapmode=map.
  but when I attempt to use the url
 http://172.18.154.186/cgi-bin/mapserv?map=/srv/www/htdocs/mapserver/coverage.mapmode=tiletile=4+6+4
 I receive only empty images, regardless of tile specified.



 Thanks for any help!



 MAP

   NAME COVERAGE

   STATUS ON

   SIZE 1400 900

   EXTENT 639000.00 4535300.00 689900.00 4582600.00

   UNITS METERS

   SHAPEPATH shapefiles

   IMAGECOLOR 220 220 220



   IMAGETYPE PNG



   PROJECTION

 init=epsg:4326

   END



   LAYER

 NAME CoverageMap

 TYPE POLYGON

 STATUS DEFAULT

 DATA notforchad



 CLASS

   STYLE

 OUTLINECOLOR 255 128 128

 COLOR 225 0 0

   END

 END



   END

 END



 Chad Clabaugh

 Technical Support, Engineering

 Office: 260.760.6398

 Mobile: 260.466.8861




 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Accessing a different type of raster data type

2009-01-13 Thread Roger André
Hi All,

I'm curious if you could give me an idea of the level of effort this would
take.  I have access to a data service at work that will render an array of
values in response to a bbox geographic query.  I'd like the ability to
create a Mapserver raster Layer that uses this service as a data source, so
that I can populate a web map using dynamically generated data, rather than
pre-rendering a raster set.  How hard would it be to write a new connector
that could read this data service?

Thanks in advance for any advice you can give me,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Accessing a different type of raster data type

2009-01-13 Thread Roger André
Frank, you rock.

Thanks for the links.

Roger
--

On Tue, Jan 13, 2009 at 1:17 PM, Frank Warmerdam warmer...@pobox.comwrote:

 Roger André wrote:

 Hi All,

 I'm curious if you could give me an idea of the level of effort this would
 take.  I have access to a data service at work that will render an array of
 values in response to a bbox geographic query.  I'd like the ability to
 create a Mapserver raster Layer that uses this service as a data source, so
 that I can populate a web map using dynamically generated data, rather than
 pre-rendering a raster set.  How hard would it be to write a new connector
 that could read this data service?

 Thanks in advance for any advice you can give me,


 Roger,

 It should be reasonable easy to add this as a new GDAL format driver,
 or alternatively as an extension of the existing WMS driver which
 has a minidriver mechanism to add new web service types beyond
 WMS.

 Some helpful resources:

 * The driver implementation tutorial:

  http://www.gdal.org/gdal_drivertut.html

 * The WMS driver code (see mini drivers for examples of new protocols):

  http://svn.osgeo.org/gdal/trunk/gdal/frmts/wms/

 Best regards,
 --

 ---+--
 I set the clouds in motion - turn up   | Frank Warmerdam,
 warmer...@pobox.com
 light and sound - activate the windows | 
 http://pobox.com/~warmerdamhttp://pobox.com/%7Ewarmerdam
 and watch the world go round - Rush| Geospatial Programmer for Rent


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Where is the raster classifier code in Mapserver?

2009-01-13 Thread Roger André
Very cool.  Looks like it is scheduled for inclusion in Release 5.4., and
even better, the code is still functional.  I'm playing around with it now,
and am easily applying a gradient to a single range of values, but have not
yet figured out how to apply different color gradients to different ranges.

Will keep working on it.

Thanks for the lead.
--



On Tue, Jan 13, 2009 at 2:02 PM, Frank Warmerdam warmer...@pobox.comwrote:

 Roger André wrote:

 This is probably a question for Frank W..  I'd like to re-write the raster
 classifier in Mapserver so that it can apply a linear color gradient using
 LUTs.  I've got code written already to do this with the Python API to GDAL,
 and would like to be able to do the same thing in Mapserver.  Can someone
 point me to the right C code?


 Roger,

 The core of the existing classification logic is msGetClass() in
 mapraster.c.
 Also if you search on classified in mapdrawgdal.c you will see most
 of the places it gets used.

 I believe that ramp based gradients should be written up as an RFC.  There
 was a previous effort which I think was partially implemented.  I would
 suggest you dig up information on it, before going too far.

  http://mapserver.org/development/rfc/ms-rfc-6.html

 Best regards,
 --

 ---+--
 I set the clouds in motion - turn up   | Frank Warmerdam,
 warmer...@pobox.com
 light and sound - activate the windows | 
 http://pobox.com/~warmerdamhttp://pobox.com/%7Ewarmerdam
 and watch the world go round - Rush| Geospatial Programmer for Rent


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: RESAMPLE types available as PROCESSING directives

2009-01-07 Thread Roger André
Wait... maybe they are not gdal-based.  Never mind.  That's a fair bit of
code to implement.
--

On Wed, Jan 7, 2009 at 4:18 PM, Roger André ran...@gmail.com wrote:

 Ok, I've kind of answered my own question.  mapresample.c only has the
 following 3 resampling options below, but is it possible to add BICUBIC into
 this?  It seems like these are gdal reasampling methods, so it should be
 possible.

 /*  */
 /*  Perform the resampling. */
 /*  */
 if( EQUAL(resampleMode,AVERAGE) )
 result =
 msAverageRasterResampler( srcImage, layer-offsite, image,
   anCMap, msApproxTransformer,
 pACBData,
   layer-debug );
 else if( EQUAL(resampleMode,BILINEAR) )
 result =
 msBilinearRasterResampler( srcImage, layer-offsite, image,
anCMap, msApproxTransformer,
 pACBData,
layer-debug );
 else
 result =
 msNearestRasterResampler( srcImage, layer-offsite, image,
   anCMap, msApproxTransformer,
 pACBData,
   layer-debug );



 On Wed, Jan 7, 2009 at 3:50 PM, Roger André ran...@gmail.com wrote:

 Hi All,

 I'm curious to know if the BICUBIC resampling option is available as a
 processing directive in Mapserver 5.2?  I see it mentioned in an RFC,
 http://mapserver.org/development/rfc/ms-rfc-4.html#rfc4, but not in the
 raster data documentation at
 http://mapserver.org/input/raster.html#special-processing-directives.

 I've tried using BICUBIC and it doesn't seem to do anything.

 Thanks,

 Roger
 --



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Need help selecting vector data source

2009-01-05 Thread Roger André
Hi Paul,

This this do what you needed?

Thanks,

Roger
--

On Sat, Jan 3, 2009 at 11:47 PM, Roger André ran...@gmail.com wrote:

 Hi Paul,

 This ought to get you started.  The florida.map is the project mapfile
 and looks for the coastline.map, lakes.map, and islands.map mapfiles
 for each of the separate layers.  You should just need to change the path in
 each of the DATA lines to point at your shapefiles. Attached is the image
 this generates, as well as the mapfiles.  You'll have to tweak the colors
 yourself.

 Roger
 --


 On Sat, Jan 3, 2009 at 8:47 PM, P.Romero romero...@hotmail.com wrote:

  Ok, Ive attached the image…


  --

 *From:* Roger André [mailto:ran...@gmail.com]
 *Sent:* 2009-01-03 10:28 PM
 *To:* P.Romero

 *Subject:* Re: [mapserver-users] Need help selecting vector data source



 Hi Paul,

 The image of what you want this to look like didn't come through to the
 list.  Can you send it to me directly?  I'll work up a mapfile that will
 look like it for you.

 Roger
 --

 On Sat, Jan 3, 2009 at 8:16 PM, P.Romero romero...@hotmail.com wrote:

 Roger,

 Thanks for the advice, I downloaded the 1.6 version.

 Another question: I cant seem to find a way to merge the two layers:
 land and lakes, since their each from a separate shapefile, and are on a
 separate layer. Is it even possible to merge the layers? Here's my map file:



 MAP

 NAME dd

 UNITS DD

 EXTENT -90 20 -60 35

 SIZE 600 600

 SHAPEPATH /data/apps/mapserver/shp

 IMAGECOLOR 130 180 200

 WEB

 IMAGEPATH /var/www/html/images/mapserver

 IMAGEURL /images/mapserver

 LOG /var/log/maplog

 END

 LAYER

 NAME gshhs_land

 TYPE POLYGON

 STATUS ON

 DATA gshhs_land.shp

 CLASS

 STYLE

 COLOR 240 240 230

 OUTLINECOLOR 240 240 230

 END

 END

 END

 END

 LAYER

 NAME gshhs_lake

 TYPE POLYGON

 STATUS ON

 DATA gshhs_lake.shp

 CLASS

 STYLE

 COLOR 130 180 200

 END

 END

 END

 END



 The first layer seems to simply overlap and cover the second layer.
 Im not sure how to set the transparency of a layer (I read through the
 documentation, but it wasn't very clear).

 Basically, I want land a beige color, and oceans (background) and bodies
 of water (polygons from the lakes shapefile) to be a blue color.



 What should I do? Do this require something drastic, like merging the land
  lakes shapefiles, or something like this?

 Please help,

 Thanks,

 P.Romero




  --

 *From:* Roger André [mailto:ran...@gmail.com]
 *Sent:* 2009-01-03 8:43 PM
 *To:* Pablo Romero
 *Cc:* mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] Need help selecting vector data source



 Version 1.6 of the gshhs shapefiles are polygon features.  You can find
 them at ftp://ftp.ihg.uni-duisburg.de/GIS/GISData/GSHHS/
 --

 On Sat, Jan 3, 2009 at 4:42 PM, Pablo Romero romero...@hotmail.com
 wrote:

 hello,
 I need help selecting a datasource to produce the following: a basic,
 high-resolution land map, showing ONLY coastlines and bodies of water.
 basically, Im trying to emulate a type of image tiling that I found on
 another site, which I believe is also being produced using mapserver, but Im
 unsure about which data source/shapefile is being used.

 Ive ATTACHED the image.
 You can see that image includes a high-resolution map of the florida
 coast, including interior bodies of water.

 Ive tried using the admin98.shp and world_vector_shorelines.shp in
 order to recreate these results, but these two shapefiles dont include
 interior bodies of water (lakes, ponds, etc.). Ive ALSO tried using the
 gshhs shapefiles (http://www.ngdc.noaa.gov/mgg/shorelines/gshhs.html),
 and these *seem* like they might work, but they are broken up into separate
 shapefiles for coastal outline, lakes, ponds, etc., and these shapefiles are
 IN LINES instead of POLYGONS/POLYLINES, so I cannot figure out how to fill
 the space between lines with a different color  in order to make the
 landmasses and interior bodies of water stand out.

 So, simply put, my question is: can someone please help me figure out /
 recommend which data source I should use in order to produce output similiar
 to the image Ive attached? just high-resolution coastal outline and interior
 bodies of water IN decimal degrees (WGS1984?), please help

 P.Romero


  --

 It's the same Hotmail(R). If by same you mean up to 70% faster. Get your
 account 
 now.http://windowslive.com/online/hotmail?ocid

Re: [mapserver-users] MapServer and Heatmap Point Layer

2009-01-04 Thread Roger André
Matt Perry wote a gdal-based tool that will read a shapefile and create a
heat-density raster from it.  You can find it at
http://perrygeo.googlecode.com/svn/trunk/gis-bin/point_density.py.  If you
already have a raster with these values, then you can use the info at
http://mapserver.org/input/raster.html#how-are-rasters-added-to-a-map-file(look
for the classifying rasters section).

Roger
--



On Sun, Jan 4, 2009 at 12:15 PM, Donald Kerr donald.k...@dkerr.co.ukwrote:

 I am assuming that someone has tackled the subject of heatmap overlays in
 MapServer. If anyone has any information they can give me or maybe point me
 in the right direction, it would be much appreciated. An alternative might
 be something for OpenLayers with a MapServer/KaMap behind it. Again, any
 info appreciated.

 Many thanks.

 Regards,

 Donald Kerr

 ___
 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] Need help selecting vector data source

2009-01-03 Thread Roger André
Version 1.6 of the gshhs shapefiles are polygon features.  You can find them
at ftp://ftp.ihg.uni-duisburg.de/GIS/GISData/GSHHS/
--


On Sat, Jan 3, 2009 at 4:42 PM, Pablo Romero romero...@hotmail.com wrote:

  hello,
 I need help selecting a datasource to produce the following: a basic,
 high-resolution land map, showing ONLY coastlines and bodies of water.
 basically, Im trying to emulate a type of image tiling that I found on
 another site, which I believe is also being produced using mapserver, but Im
 unsure about which data source/shapefile is being used.

 Ive ATTACHED the image.
 You can see that image includes a high-resolution map of the florida coast,
 including interior bodies of water.

 Ive tried using the admin98.shp and world_vector_shorelines.shp in
 order to recreate these results, but these two shapefiles dont include
 interior bodies of water (lakes, ponds, etc.). Ive ALSO tried using the
 gshhs shapefiles (http://www.ngdc.noaa.gov/mgg/shorelines/gshhs.html), and
 these *seem* like they might work, but they are broken up into separate
 shapefiles for coastal outline, lakes, ponds, etc., and these shapefiles are
 IN LINES instead of POLYGONS/POLYLINES, so I cannot figure out how to fill
 the space between lines with a different color  in order to make the
 landmasses and interior bodies of water stand out.

 So, simply put, my question is: can someone please help me figure out /
 recommend which data source I should use in order to produce output similiar
 to the image Ive attached? just high-resolution coastal outline and interior
 bodies of water IN decimal degrees (WGS1984?), please help

 P.Romero

 --
 It's the same Hotmail(R). If by same you mean up to 70% faster. Get your
 account 
 now.http://windowslive.com/online/hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_broad1_122008

 ___
 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: RE : [mapserver-users] How to make MapServer WMS super fast?

2008-12-12 Thread Roger André
I think serving pre-cached tiles with TileCache running under FastCGI should
improve your response times considerably.

Roger
--
PS - Give send an update if you try any of these.

On Fri, Dec 12, 2008 at 8:00 AM, Léveillé, James 
james.levei...@mtq.gouv.qc.ca wrote:

  Here is a message published by Alexandre Dubé a few weeks ago - helpfull




 Here's how to install and setup fastCGI with Apache 2.2.8 contained in

 the MS4W 2.2.7 version.

 1- MS4W 2.2.7 contains a MapServer compiled to support FastCGI so

 nothing needs to be done there.

 2- But, Apache 2.2.8 that comes with MS4W 2.2.7 doesn't include the

 mod_fcgi module. This module can be dowloaded at

 *http://www.apachelounge.com/download/*http://www.apachelounge.com/download/...
  Take the

 mod_fcgid-2.2a-w32.zip which will work with Apache 2.2.8.

 3- Copy mod_fcgid.so to your apache/modules folder

 4- Install the Visual C++ 2008 Redistributable Package (the binary is

 build with VC 2008). Download and install, if it isn't already done,

 from:

 *
 www.microsoft.com/downloads/details.aspx?FamilyID=9B2DA534-3E03-4391-8A4D-074B9F2BC1BFdisplaylang=en
 *

 5- Modify your /ms4w/Apache/conf/httpd.conf

 a) Add :

 LoadModule fcgid_module modules/mod_fcgid.so

 b) Add :

 ScriptAlias /cgi-bin/ /ms4w/Apache/cgi-bin/

 ScriptAlias /fcgi-bin/ /ms4w/Apache/cgi-bin/

 c) Remove :

 Directory /ms4w/Apache/cgi-bin

 AllowOverride All

 Options None

 Order allow,deny

 Allow from all

 /Directory

 d) Add :

 Location /cgi-bin

 Options None

 Order allow,deny

 Allow from all

 /Location

 e) Add :

 Location /fcgi-bin

 # The following line activates the fastCGI script to all files

 in location

 SetHandler fcgid-script

 Options None

 Order allow,deny

 Allow from all

 /Location

 f) Add :

 IfModule fcgid_module

 IPCCommTimeout 60

 IdleTimeout 60

 DefaultMinClassProcessCount 2

 DefaultMaxClassProcessCount 20

 DefaultInitEnv PROJ_LIB c:/ms4w/proj/nad/

 DefaultInitEnv PATH


 c:/ms4w/Apache/cgi-bin;c:/WINDOWS/system32;c:/WINDOWS;c:/WINDOWS/System32/Wbem;

 DefaultInitEnv windir c:/WINDOWS

 DefaultInitEnv SystemRoot c:/WINDOWS

 DefaultInitEnv SystemDrive c:

 DefaultInitEnv GDAL_DATA c:/ms4w/gdaldata

 DefaultInitEnv GDAL_DRIVER_PATH c:/ms4w/gdalplugins

 DefaultInitEnv TMP c:/ms4w/tmp

 DefaultInitEnv TEMP c:/ms4w/tmp

 /IfModule

 6- Restart Apache : /ms4w/apache-restart.bat

 7- In your mapfile, set a PROCESSING directive to tell FastCGI to cache

 the connections and layer information on all layers for which connection

 caching is desired - ie. all slow layers.

 a) Add :

 PROCESSING CLOSE_CONNECTION=DEFER

 8- Now you can load your map using either normal CGI or FastCGI :

 a) CGI :

 *http://host:port/cgi-bin/mapserv.exe*http://host:port/cgi-bin/mapserv.exe?...


 b) fastCGI :

 *http://host:port/fcgi-bin/mapserv.exe*http://host:port/fcgi-bin/mapserv.exe?...


 That way, your original cgi-bin folder wont be affected by fastCGI

 unless you use the modified url with fcti-bin which is the alias you

 added to your httpd.conf file at 5b).

 Special thanks to Jeff McKenna and Daniel Morissette who helped me a lot

 with this.







 __

 *JAMES LÉVEILLÉ
 *Service des systèmes de Mission
 Direction des technologies de l'information
 Ministère des Transports du Québec

 5833, boul. Pierre-Bertrand, 2ième étage
 Québec (Québec) G2K 1K7
 Téléphone:   (418) 380-2005 poste 227
 Télécopieur: (418) 644-6653
 james.levei...@mtq.gouv.qc.ca



  -Message d'origine-
 *De :* mapserver-users-boun...@lists.osgeo.org [mailto:
 mapserver-users-boun...@lists.osgeo.org] *De la part de* Rahkonen Jukka
 *Envoyé :* 12 décembre 2008 10:39
 *À :* Marcelo Oliveira; mapserver-users@lists.osgeo.org
 *Objet :* Re: [mapserver-users] How to make MapServer WMS super fast?

 Hi,

 Thanks, I will try Fast CGI.  Are there some simple enough document for a
 ms4w users about how to turn the system to use Fast CGI?

 -Jukka-

  --
 *Lähettäjä:* Marcelo Oliveira [mailto:molive...@geostats.com]
 *Lähetetty:* 12. joulukuuta 2008 17:05
 *Vastaanottaja:* Rahkonen Jukka; mapserver-users@lists.osgeo.org
 *Aihe:* RE: [mapserver-users] How to make MapServer WMS super fast?

  Try using Fast CGI, it should improve your latency problem you are
 seeing.  It is also possible that using other raster formats could help.



 Good luck! M



 --

 Marcelo Simas Oliveira

 GeoStats LP

 530 Means St., Ste. 310

 Atlanta, Georgia 30318

 (404) 588-1004

 www.geostats.com



 *From:* mapserver-users-boun...@lists.osgeo.org [mailto:
 mapserver-users-boun...@lists.osgeo.org] *On Behalf Of *Rahkonen Jukka
 *Sent:* Friday, December 12, 2008 10:01 AM
 *To:* mapserver-users@lists.osgeo.org
 *Subject:* [mapserver-users] How to make MapServer WMS super fast?



 Hi,



 Are there any effective tricks for making MapServer to Top-Fuel class?  We
 have now a typical ms4w installation on a rather good 

[mapserver-users] Graticule and Map Frame strategies

2008-12-11 Thread Roger André
Hi All,

I'm curious what options have been explored to create tick marks, graticules
and outside-of-map symbology?  I'm currently investigating the use of
Matplotlib as a compositer to draw on top of a Mapserver-generated image,
and while I think this will give nice looking results, the speed of the
process is quite slow, probably because Matplotlib deconstructs the
Mapserver image with PIL and works with it as a numpy array.

I'm interested in hearing about any other tools that allow for the same sort
of drawing on top of strategy, preferrably ones with API's.

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Graticule and Map Frame strategies

2008-12-11 Thread Roger André
Hi Bob and Brent,

That was a great thread to dig into, thanks for sending me the link.  I'm
guessing that Mapserver wasn't originally developed with the intent of
acting as an engine for cartographic quality, paper, map production.  The
fact that it's capable of generating images of such high quality that I'm
considering its use for exactly that purpose really says something about the
quality of the development effort that has gone into it.  Kudos to all who
have contributed to the project.  I really love it as a tool, and I enjoy
working with it.

I myself use (or am attempting to use) Mapserver for 2 completely disparate
tasks.  One use is to drive a web-map interface, and with that I have no
issues whatsoever.  The other is to create map graphics which are included
in printed reports.  Although the data shown is similar in both cases, the
paper use-case is definitely more difficult to implement and has it's own
unique requirements.  As Brent said in one of his posts, a map without a
graticule, scale bar, and projection statement, (with parameter values!) is
just a diagram.  I would add a legend to that list as well, and Mapserver
can generate all of those things relatively well.  However, as is true with
all projects, the 80/20 rule is biting at my heels here.

To give some background to the problem, the requirement I'm working from is
to generate graphics that look as good, or better, than those which are
currently being generated with GMT (Generic Mapping Tools).  For those of
you who haven't tried GMT, it is capable of some pretty fantastic looking,
print-quality maps.  However, its use in an automated system is somewhat
difficult, and it lacks some of the flexibility in data access, cartographic
styling, and labeling which Mapserver has.  It also lacks an API.  Although
I doubt we will ever fully replace GMT in the creation of one-off's, I think
there is a good case to be made for replacing it with another tool for
automated, and menu-driven map creation.  The problem is that GMT does it
all.  Without going into all of what GMT can do, here are a few of the
things that it does which I haven't been able to find an easy way to
implement with Mapserver.

1) Rendering of raster features based on the input of an array of
regulalry-spaced points with X,Y,Z values.
2) Raster symbolization using color gradients, as opposed to just discreet
colors.
3) Creation of color bars (legend) to show the values in a raster data set.
4) Graticule tick-marks on the edges of the map frame.
5) Inclusion of a map title.
6) Inclusion of text to describe the map.

So far, my solution seems to be similar in concept to what others appear to
be doing - I do these things outside of Mapserver.  Items 1 and 2 are taken
care of by the creation of a display-ready GeoTIFF with gdal.  3 - 6 are
still being worked on, but at the moment are being dealt with by loading the
Mapserver image into Matplotlib, then adding decoration.  Although this
works, it seems a bit klunky to do these with 3 separate tools, especially
given the nice job Mapserver already does with other things that are very
similar in nature.

Having said that, please don't flame me!  I'm finding workarounds to solve
the problems I'm having.  I just want to add my voice to those who have
already expressed an interest in extending some of the decoration
functionality in Mapserver.  And yes, I also know that other tools (such as
GRASS) can do this, but that's not the point. ;)

Thanks again to all of you who have worked to make Mapserver such a great
tool.

Roger
--

On Thu, Dec 11, 2008 at 11:06 AM, Bob Basques
bob.basq...@ci.stpaul.mn.uswrote:

 Brent,

 We basically came to the same conclusions, although I think there is
 also the potential for combining seamless overlay with the surround
 method as well.  I still keep looking inside of MapServer too, but just
 can't seem to come up with a flexible method of building anything.

 The surround method is on my list, but it's down a ways.  :c)

 bobb



  Brent Fraser bfra...@geoanalytic.com 12/11/08 1:00 PM 
 Roger,

  I asked a similar question last year
 (http://lists.osgeo.org/pipermail/discuss/2007-September/002349.html).

  Landon Blake and I (and others) came to the conclusion that the answer
 was to create a map surround library suitable for wrapping as a
 plug-in to various generic publishing/compositing applications (such as
 Inkscape, Scribus, ReportLab, etc) and possibly some desktop GIS apps
 (uDig, Quantum, gvSig, OpenJump, etc).

  While I still believe that's the ultimate answer, I find myself going
 back to Mapserver's mappdf.c (and mapgraticule.c, etc), and speculating
 on enhancements to give Mapserver the capability right out of the box.

 Brent Fraser
 GeoAnalytic Inc.


 Roger André wrote:
  Hi All,
 
  I'm curious what options have been explored to create tick marks,
  graticules and outside-of-map symbology?  I'm currently investigating
  the use of Matplotlib as a compositer to draw on top

[mapserver-users] Difference in appearance between mode=map and WMS

2008-12-08 Thread Roger André
Hi All,

I think I'm having an instance of cranial flatulation, but maybe not.
Hopefully you can set me straight.

I need to create an image with Mapserver using mapscript that I can then
georeference manually and use in another application.  It needs to look
exactly the same as the image I can already generate via a WMS call that
looks like this:

http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.map
SERVICE=WMS
version=%221.1.1%22
REQUEST=GetMap
LAYERS=imagery
STYLES=BBOX=-125,39,-108,54
WIDTH=600
HEIGHT=600
FORMAT=png
SRS=epsg:4326

I'm testing my mapscript parameters using a simple mode=map call to
Mapserver, and the results I'm getting so far don't match the appearance of
the WMS output at all.  My mapfile has the following extent and projection
info in it:

  PROJECTION
init=epsg:4326
  END

  EXTENT -125.0  39.0 -108.0  54.0
  SIZE 600 600

In addition to the mapfile projection specification, I am also specifying
the same projection info in each of my LAYERS as well.

Is it possible to do what I'm trying to accomplish here?

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Difference in appearance between mode=map and WMS

2008-12-08 Thread Roger André
Hi Julien,

That makes sense, but it doesn't work.  I modified my mapfile so that I now
generate a 20_deg x 20_deg tile that is 600_pixels x 600_pixels.  If I
georeference that image using the extents, I still get incorrect placement.
Maybe if I choose an output projection which always has square pixels, like
spherical mercator (?) this will work.  I'll give it a shot.

Is there any way to give a WMS request via mapscript and NOT go through CGI?

Roger
--



On Mon, Dec 8, 2008 at 12:25 PM, Julien-Samuel Lacroix 
[EMAIL PROTECTED] wrote:

 Hi,

 I guess would be that the WMS use non-square pixels. So if your BBOX x/y
  (rectangle in your case) doesn't match you WIDTH/HEIGHT ratio (square in
 your case) the map will appear stretched. MapServer will actually stretch
 the map to fit the extent in the WIDTH/HEIGHT.

 The mode=map don't do that. If your extent doesn't have the same ratio, it
 adds some degree in your extent to fit the size.

 Make sure your BBOX and EXTENT are a square in your requests and retry


 Julien

 Roger André wrote:

 Hi All,

 I think I'm having an instance of cranial flatulation, but maybe not.
  Hopefully you can set me straight.

 I need to create an image with Mapserver using mapscript that I can then
 georeference manually and use in another application.  It needs to look
 exactly the same as the image I can already generate via a WMS call that
 looks like this:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.map
 SERVICE=WMS
 version=%221.1.1%22
 REQUEST=GetMap
 LAYERS=imagery
 STYLES=BBOX=-125,39,-108,54
 WIDTH=600
 HEIGHT=600
 FORMAT=png
 SRS=epsg:4326

 I'm testing my mapscript parameters using a simple mode=map call to
 Mapserver, and the results I'm getting so far don't match the appearance of
 the WMS output at all.  My mapfile has the following extent and projection
 info in it:

  PROJECTION
init=epsg:4326
  END

  EXTENT -125.0  39.0 -108.0  54.0
  SIZE 600 600

 In addition to the mapfile projection specification, I am also specifying
 the same projection info in each of my LAYERS as well.

 Is it possible to do what I'm trying to accomplish here?

 Thanks,

 Roger
 --


 

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


 --
 Julien-Samuel Lacroix
 Mapgears
 http://www.mapgears.com/

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] AGG renderer and paletted RGBA PNG's

2008-12-08 Thread Roger André
Hi All,

I'm seeing a problem in some of my raster data which have graduated color
ramps in them.  When using the AGG renderer, the data appears to have
discreet colors (which is incorrect), whereas with the GD renderer, we get
correct color gradients.

The GD outputformat looks like this:

  OUTPUTFORMAT
   NAME 'png'
   DRIVER GD/PNG
   IMAGEMODE RGBA
   EXTENSION png
   FORMATOPTION TRANSPARENT=ON
   FORMATOPTION INTERLACE=OFF
   TRANSPARENT ON
  END #end outputformat


The AGG outputformat looks like this:

OUTPUTFORMAT
  NAME 'AGGA'
  DRIVER AGG/PNG
  IMAGEMODE RGBA
  EXTENSION png
  MIMETYPE image/png; mode=24bit
  FORMATOPTION TRANSPARENT=ON
  FORMATOPTION INTERLACE=OFF
END

In addition, the output image appears to have a color palette, instead of
being a  4-ch png.  Finally, the problem is present in WMS requests, but not
straight MODE=map requests.

My WMS request looks like this:
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.mapSERVICE=WMSversion=%221.1.1%22REQUEST=GetMapLAYERS=imagerySTYLES=BBOX=-125,39,-108,54WIDTH=600HEIGHT=600FORMAT=pngSRS=epsg:4326

Any ideas?
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Difference in appearance between mode=map andWMS

2008-12-08 Thread Roger André
Perfect, yes.  That should do exactly what I need.  I'd forgotten about
those OWSRequests.  Tilecache uses those in its MapServerLayer requests as
well.

Thanks very much Tom
--

On Mon, Dec 8, 2008 at 2:33 PM, Kralidis,Tom [Ontario] 
[EMAIL PROTECTED] wrote:


 Roger: you can use MapScript WxS
 http://mapserver.gis.umn.edu/docs/howto/wxs_mapscript as an approach to
 run a WMS request via mapscript.  Maybe that can work for you?

 ..Tom



 -Original Message-
 From: [EMAIL PROTECTED] on behalf of Roger André
 Sent: Mon 08-Dec-08 16:21
 To: Julien-Samuel Lacroix
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Difference in appearance between mode=map
 andWMS

 Hi Julien,

 That makes sense, but it doesn't work.  I modified my mapfile so that I now
 generate a 20_deg x 20_deg tile that is 600_pixels x 600_pixels.  If I
 georeference that image using the extents, I still get incorrect placement.
 Maybe if I choose an output projection which always has square pixels, like
 spherical mercator (?) this will work.  I'll give it a shot.

 Is there any way to give a WMS request via mapscript and NOT go through
 CGI?

 Roger
 --



 On Mon, Dec 8, 2008 at 12:25 PM, Julien-Samuel Lacroix 
 [EMAIL PROTECTED] wrote:

  Hi,
 
  I guess would be that the WMS use non-square pixels. So if your BBOX x/y
   (rectangle in your case) doesn't match you WIDTH/HEIGHT ratio (square in
  your case) the map will appear stretched. MapServer will actually stretch
  the map to fit the extent in the WIDTH/HEIGHT.
 
  The mode=map don't do that. If your extent doesn't have the same ratio,
 it
  adds some degree in your extent to fit the size.
 
  Make sure your BBOX and EXTENT are a square in your requests and retry
 
 
  Julien
 
  Roger André wrote:
 
  Hi All,
 
  I think I'm having an instance of cranial flatulation, but maybe not.
   Hopefully you can set me straight.
 
  I need to create an image with Mapserver using mapscript that I can then
  georeference manually and use in another application.  It needs to look
  exactly the same as the image I can already generate via a WMS call that
  looks like this:
 
  http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.map
  SERVICE=WMS
  version=%221.1.1%22
  REQUEST=GetMap
  LAYERS=imagery
  STYLES=BBOX=-125,39,-108,54
  WIDTH=600
  HEIGHT=600
  FORMAT=png
  SRS=epsg:4326
 
  I'm testing my mapscript parameters using a simple mode=map call to
  Mapserver, and the results I'm getting so far don't match the appearance
 of
  the WMS output at all.  My mapfile has the following extent and
 projection
  info in it:
 
   PROJECTION
 init=epsg:4326
   END
 
   EXTENT -125.0  39.0 -108.0  54.0
   SIZE 600 600
 
  In addition to the mapfile projection specification, I am also
 specifying
  the same projection info in each of my LAYERS as well.
 
  Is it possible to do what I'm trying to accomplish here?
 
  Thanks,
 
  Roger
  --
 
 
  
 
  ___
  mapserver-users mailing list
  mapserver-users@lists.osgeo.org
  http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
  --
  Julien-Samuel Lacroix
  Mapgears
  http://www.mapgears.com/
 


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: AGG renderer and paletted RGBA PNG's

2008-12-08 Thread Roger André
Looks like the WMS request needs some additional parameters:

FORMAT=image/png;%20mode=24bit

Can I add these into the mapfile instead?
--




On Mon, Dec 8, 2008 at 2:46 PM, Roger André [EMAIL PROTECTED] wrote:

 Hi All,

 I'm seeing a problem in some of my raster data which have graduated color
 ramps in them.  When using the AGG renderer, the data appears to have
 discreet colors (which is incorrect), whereas with the GD renderer, we get
 correct color gradients.

 The GD outputformat looks like this:

   OUTPUTFORMAT
NAME 'png'
DRIVER GD/PNG
IMAGEMODE RGBA
EXTENSION png
FORMATOPTION TRANSPARENT=ON
FORMATOPTION INTERLACE=OFF
TRANSPARENT ON
   END #end outputformat


 The AGG outputformat looks like this:

 OUTPUTFORMAT
   NAME 'AGGA'
   DRIVER AGG/PNG
   IMAGEMODE RGBA
   EXTENSION png
   MIMETYPE image/png; mode=24bit
   FORMATOPTION TRANSPARENT=ON
   FORMATOPTION INTERLACE=OFF
 END

 In addition, the output image appears to have a color palette, instead of
 being a  4-ch png.  Finally, the problem is present in WMS requests, but not
 straight MODE=map requests.

 My WMS request looks like this:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/hydro/hydro.mapSERVICE=WMSversion=%221.1.1%22REQUEST=GetMapLAYERS=imagerySTYLES=BBOX=-125,39,-108,54WIDTH=600HEIGHT=600FORMAT=pngSRS=epsg:4326

 Any ideas?

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Strategies for creating Google Map tiles...

2008-12-04 Thread Roger André
Hi John,

I've had good success with Option 1, but I'm not sure I understand all of
the conditions you've mentioned.  I assume that you intend to display these
tiles in a Google Maps mashup when you're done?  If so, using  TileCache's
tilecache_seed.py would allow you to pre-generate the tiles using Mapserver
initially, and then display them in the map - without ever calling on
Mapserver again.  The major advantage I see to this method is that Mapserver
can aggregate all of the separate layers and display them in a common
projection.

Good luck,

Roger
--

On Thu, Dec 4, 2008 at 7:07 AM, John Jameson [EMAIL PROTECTED] wrote:


 I need to make tiles compatible with Google maps out of this mess.  The
 outcome needs to be the typical pyramid of tiles where each detailed zoom
 level has 4x the number of tiles than the level above.

 Here are the things I've considered strategy-wise:

 1. Combine everything into a single map file and then let MapServer serve
 the tiles (through TileCache).  I can then go through the area of data I'm
 interested in and collect the tiles and save them.  The super advantage of
 this strategy is that I can test it by having it serve the tiles live.
 It'll be slower than having them pre-computed and that isn't ultimately
 acceptable because I'll need offline use of the tiles and won't have
 MapServer.  Still, it allows for great testing before the tile collection
 begins.  The disadvantage is that I fear I'll run out of space with
 hundreds
 of raster maps and another hundred shapefiles (each with 20-30 layers).  I
 fear I'd have to re-gen MapServer with all of the layers needed.  Back on
 the plus side, it seems like MapServer will quilt the maps together
 nicely.  This strategy has me scared about resource size and speed needed.


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: [gdal-dev] Can I change SOURCE_EXTRA setting at compile time?

2008-11-18 Thread Roger André
Hi Frank,

You're absolutely right.  Changing those values in mapresample.c to 10
removed the artifacts when using a WMS request.  They're still present when
the request is made via mapscript though.  I need to manually code a
mapscript example though, because right now I'm testing that via TileCache,
and I'm not 100% certain how the image is being requested.  Can you think of
a reason why WMS would be different from a straight read and reproject
through mapscript?

cc'ing TileCache list and mapserver lists as well
--

On Tue, Nov 18, 2008 at 5:58 PM, Frank Warmerdam [EMAIL PROTECTED]wrote:

 Roger André wrote:

 Hi Frank,

 I've theorized all sorts of reasons for what I'm seeing.  So far none of
 them are right.  Basically, if I take a really high-res epsg:4326 image, and
 serve it up through Mapserver in epsg:900913, there are instances where I
 get images back which are missing rows of pixels at the bottom of the image.
  If I reduce the resolution of the image the lines go away.  I haven't yet
 figured out at what resolution the problem starts to appear.

 I just tested the idea of changing the values in the warper code:
 First:
 nResWinSize += 100;
 Then:
 nResWinSize += 500;

 Then rebuilt gdal.   Didn't seem to make a difference.


 Roger,

 Are you sure the GDAL warper is being used? If the reprojection is being
 done by MapServer it will be using the MapServer warper.

 Try changing the +- 1.0 values to larger values in the following code in
 mapserver's mapresample.c:

 /*  */
 /*  Project desired extents out by 2 pixels, and then strip to  */
 /*  available data. */
 /*  */
memcpy( sOrigSrcExtent, sSrcExtent, sizeof(sSrcExtent) );

sSrcExtent.minx = floor(sSrcExtent.minx-1.0);
sSrcExtent.maxx = ceil (sSrcExtent.maxx+1.0);
sSrcExtent.miny = floor(sSrcExtent.miny-1.0);
sSrcExtent.maxy = ceil (sSrcExtent.maxy+1.0);


 See if that helps.  Currently there is no processing option that does
 what SOURCE_EXTRA does, though it might be worth adding one.


 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| Geospatial Programmer for Rent


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Ubuntu libpdf support for Mapserver

2008-11-15 Thread Roger André
Hi everyone,

I'm just about done building a fresh copy of Mapserver 5.2 on my Ubuntu 8.04
machine and have one final snag to overcome - PDF support.  I've specified
--with-pdf in my compile options, but when I look carefully, I see libpdf
not found or too old, and my resulting mapserv executable lacks PDF
support.  Problem is that there doesn't seem to be a libpdf, or pdflib
package for Ubuntu, so I'm not really sure what to do.

There are a couple other *pdf*.so files in /usr:
/usr/lib/tracker/extract-modules/libextract-pdf.so
/usr/lib/openoffice/program/libpdffilter680li.so
/usr/lib/ImageMagick-6.3.7/modules-Q16/coders/pdf.so
/usr/lib/evince/backends/libpdfdocument.so

Could I use one of those instead?

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Would like to flesh out Python mapscript page

2008-11-13 Thread Roger André
Hi,

I'd like to add some examples to the
http://mapserver.gis.umn.edu/docs/howto/mapscript_python page.
Unfortunately, when I try to register for an account at
mapserver.gis.umn.edu, I get an error saying No space left on device.

Could someone let me know if there is another way that I can register?

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Would like to flesh out Python mapscript page

2008-11-13 Thread Roger André
Thanks, but it now the registration service appears unable to contact either
my company's mail server, or GMail's.  Is it possible something is still
rotten in Denmark?
--

On Thu, Nov 13, 2008 at 1:44 PM, Howard Butler [EMAIL PROTECTED] wrote:


 On Nov 13, 2008, at 3:00 PM, Roger André wrote:

  Hi,

 I'd like to add some examples to the
 http://mapserver.gis.umn.edu/docs/howto/mapscript_python page.
  Unfortunately, when I try to register for an account at
 mapserver.gis.umn.edu, I get an error saying No space left on device.

 Could someone let me know if there is another way that I can register?


 Log overflow.  Fixed.  Thanks for the report.

 Howard
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Documentation for serving large raster images using tile cache.

2008-11-10 Thread Roger André
Hi Asif,

My apologies.  I saw your message Friday evening but forgot about it over
the weekend in the course of reinstalling my Linux OS.  If time is of the
essence, posting your question to the entire list should ensure a speedier
response.

Regarding your questions:

1) I am not aware of any applications that will act as viewers for Mapserver
operating in map mode.  They may exist, but I'm not familiar with them.  I
tend to use Mapserver in only one of two ways at the moment; in map mode
to generate static maps, in wms mode with a connection to it via
OpenLayers (or TileCache).

2) Regarding the path to your mapfile, I believe there are several solutions
that you can try if your goal is to shorten the URL string.  They are
well-explained here -
http://mapserver.gis.umn.edu/docs/howto/wms_server/#more-about-the-online-resource-url.
As far as why the 1st URL doesn't actually work, it's because the path
should be relative to the mapserv.exe location in cgi-bin, not to htdocs.
So try this instead:

-
http://localhost:9090/cgi-bin/mapserv.exe?map=../htdocs/mapdemo/itasca_demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.mapmode=map

Roger
--

On Mon, Nov 10, 2008 at 1:58 AM, Asif Memon [EMAIL PROTECTED] wrote:

  Hi All,



 I have couple of question, could you please take a look at it :



 1)  Do you know any Map Server Client that allows viewing the image
 service (created on the Minnesota Map Server) if I give the URL listed
 below:

 http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.mapmode=map
 



 2)  I am using Windows XP on my PC. When I give the URL in this format
 -
 http://localhost:9090/cgi-bin/mapserv.exe?map=/mapdemo/itasca_demo.mapmode=map;,
 it doesn't work. But if I give it in format -
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.mapmode=map,
 it works. The problem in giving the URL is this format is I have to put the
 complete path starting with C: drive and if I have to run it on the
 server, I cannot give it like that.



 Could you please help me with both the above issues? Thanks!



 Sincerely,

 Asif Memon





 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Tuesday, October 28, 2008 8:11 PM
 *To:* Asif Memon
 *Cc:* mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 I downloaded the demo.tif file that you sent earlier, and the
 itasca_demo.map from you rprevious email.  I changed the path in the DATA
 portion of the LAYER section to point to my filesystem,
 DATA /var/www/mapfiles/itasca/demo.tif

 and also changed the EXTENT to this:
   EXTENT  -0.9194182 -4.2013292 -0.9002422 -4.1870152

 This matches the extent of the file when you run gdalinfo against it (min_x
 min_y max_x Max_y).

 With these changes, I'm able to view the file with the following URL:

 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/itasca/itasca_demo.mapmode=map

 (Note, I'm running this in Linux, so paths and URLs are going to be
 slightly different than yours)

 Try changing your EXTENT entry to match mine, that might do the trick.
 --

  On Tue, Oct 28, 2008 at 3:45 PM, Asif Memon [EMAIL PROTECTED] wrote:

 Thanks Roger.



 I don't see any errors now, but no image appears in the browser(the browser
 is blank). I made minor changes to the map file that you sent me (about the
 paths, attached is the file).



 The URL that I am using in the browser is
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.mapmode=map



 Please correct me if anything is wrong in the URL or in the map file.



 Sincerely,

 Asif Memon





 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Tuesday, October 28, 2008 3:17 PM


 *To:* Asif Memon
 *Cc:* mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Ok, here's a new mapfile that you can try.  Change your request to point to
 this one, and see if you get an image back in your browser.

 Roger
 --

 On Tue, Oct 28, 2008 at 2:06 PM, Asif Memon [EMAIL PROTECTED] wrote:

 I believe one of the END was missing at the end of the file, I have added
 that. This resolves the earlier error and generated a new one - msDrawMap():
 Image handling error. Unable to initialize image. msPrepareImage(): General
 error message. Image dimensions not specified. msCalculateScale(): General
 error message. Invalid image extent, minx=-1.00, miny=-1.00,
 maxx=-1.00, maxy=-1.00. mapserv(): Web application error. No way

Re: [mapserver-users] Just starting out...

2008-11-10 Thread Roger André
Hi Tucker,

My experience using the techniques that Frank's described below (burn away
areas of non-interest using gdal_rasterize, then layer separate raster
layers in Mapserver) has been very good.  The one additional piece that I
have used is TileCache, so that I can generate PNG tiles for display in
Google Maps.  Of especially great value to me has been Mapserver's ability
to display data sets together which often differ in their projections.

One thing I would advise you to do first is to display 2 different data sets
that overlap, in 2 different projections, in a simple mapfile.  Then check
that the reprojection is working properly and that features line up.

Sounds like a neat project,

Roger
--


On Mon, Nov 10, 2008 at 10:50 AM, Frank Warmerdam [EMAIL PROTECTED]wrote:

 tuckeratwork wrote:

What information do you have now defining the regions for the
cutouts?  Are
you expecting to need to manually define polygons for these by
digitizing?
  First, wow - I'm getting answers from the source!  I'm sorry to bother
 you with such trivial questions.


 Tucker,

 The questions are not at all trivial, though possibly hard to give
 solid answers for.

  Yes, I expect to write a quick digitizing program to define the boundaries
 and cutouts.  There's some other meta data I need to collect too.  The
 borders aren't in the header like the BSB/KAP files.
  I'll definitely check out the gdal_rasterize utility - that's the exact
 kind of advice I was looking for.  I'm a developer and don't mind writing
 custom code if needed with gdal, etc.


 The utility is available as part of GDAL and is documented at:

  http://www.gdal.org/gdal_rasterize.html

 Note the -i flag to invert the sense of what is inside or outside.

  How about the quilting aspects of it all?  Will I get the type of tile
 results that GeoGarage got?  I'm not really sure how they did what they did
 - perhaps they used MapServer too...


 MapServer should be able to quilt images fairly well if you can burn away
 all the stuff you don't want to show, and then order them as you want them
 layered.  If the images are not all in the same coordinate system you may
 need to use multiple LAYER's for them otherwise you can just dump them into
 a tileindex (ie. shapefile) with some care to ordering.

 When burning away uninteresting parts of the images make sure you burn them
 out to a particular value that can be used as the OFFSITE value in your
 LAYER definition - assuming you don't go the alpha transparency route which
 is somewhat involved.

 What you want to do should be achievable but may be somewhat challenging.
 I'm not sure that it is critical to do it through mapserver.  You could
 likely achieve something similar by creating a suitable mosaic image, and
 gdalwarp'ing the individual maps into that in a suitable order (after
 appropriate masking).

 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| Geospatial Programmer for Rent

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] mapserver on Centos?

2008-11-09 Thread Roger André
Hi Dave,

I've had good luck using the version of Mapserver that comes with FWTools on
a CentOS 5.1 machine.  http://fwtools.maptools.org/

Roger
--

On Sat, Nov 8, 2008 at 1:45 PM, Dave Stevens [EMAIL PROTECTED] wrote:

 Hi,

 I have a little server using a 32 bit Intel cpu configured with Centos 5.2
 and
 Virtualmin GPL. It has been doing a good job for me as a web and mail
 server
 with a light load and I am interested in trying Mapserver on it.

 On my Fedora box mapserver is in the repo (F7). Does anyone have
 experience,
 references or tips about implementing mapserver on the Centos box?

 Thanks very much,

 Dave


 --
 Canada must refuse to be entangled in any more wars fought to make the
 world
 safe for capitalism.

 -- The Regina Manifesto, 1933
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Status of Postscript support in MapServer

2008-11-05 Thread Roger André
Hi Everyone,

I'm considering the use of MapServer in an application that generates small
maps that are included in printed documents.  Currently these maps are
generated by GMT as .eps files, a format which makes then very easy to
insert into the report.  I would like to know how people feel about the
current state of PDF support provided by MapServer, and whether anyone is
using it in a similar fashion.

I found a document on the MapServer site titled, PDF Output, which was
last updated in 2006, and which contains several caveats regarding
unsupported features, ie symbol-filled polygons, legends and scalebars.
Are any of these now supported in PDF output?

Thanks in advance for all comments and observations,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Matching .TFW file with EXTENT parameter?

2008-11-03 Thread Roger André
Hi Kresh,

The parameters in a .tfw file are explained here:
http://www.kralidis.ca/gis/worldfile.htm

One caveat to be aware of is that the pixel coordinates are for the center
of the pixel, not the UL corner.  So if you have an image with the UL corner
at (x,y), you need to use the following in your worldfile

Pixel_X_size
0
0
Pixel_Y_size (usually a negative number when using North-up data)
UL_x + (Pixel_X_size / 2)
UL_y + (Pixel_Y_size /2)

Roger
--

On Sun, Nov 2, 2008 at 11:19 PM, [EMAIL PROTECTED] 
[EMAIL PROTECTED] wrote:

 I have a map file with following MapExtent parameter:
  EXTENT 106.335006 -6.896956 107.315811 -5.983994

 Recently, I got a TIFF file without coordinates. I plan to use the TIFF
 file with my map. Thus, I'm supposed to create a .TFW file using text
 editor, am I correct?

 Problem is: I'm not sure what parameter to be put in the .TFW file. Here is
 the parameters I put in my TFW file so far:
  1.000
  0.000
  0.000
 -1.000
106.335006
 -5.983994

 And I failed to show the raster on my map.

 Please note that I am merely guessing. It seems that the fifth and the
 sixth like of the TFW should be the leftmost and rightmost number of my
 EXTENT parameter, respectively, but I have no idea what the first four lines
 are for.

 Based on EXTENT parameter above, what the correct .TFW values should be?
 Many thanks,

 -Kresh





 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: [FWTools] Can someone help test a potential bug for me?

2008-10-28 Thread Roger André
Hi Dane,

Thanks very much for the testing.  Sounds like maybe there is a problem
then.

So far, the only workaround that I have found which seems to work well is
one that is somewhat akin to fixing the missing scanlines in Landsat data.
I create a very low resolution version of the data and serve it underneath
the high-res layer.  It fills in the missing row of pixels without being
noticeable, and looks pretty good.  Not sure if it will work with all data
sets though, and it's at best a bandaid fix.
--


On Mon, Oct 27, 2008 at 4:58 PM, Dane Springmeyer [EMAIL PROTECTED]wrote:

 Roger,
 Yes, I can replicate the 'edge' effect you describe in Mapnik as well, by
 either viewing a TileCache Mapnik layer in OL or specifically requesting of
 mapnik (using nik2img) the BBOX that tilecache requests.

 The lines (actually missing pixel rows it seems) appear on the bottom edge
 of tile where the raster data is unrendered but not where vector data is
 effectively rendered.

 These two bbox's trigger a one-pixel red line(where the raster file is not
 rendered) at the bottom of the image:

 1) -20037508.34,10018754.17,-10018754.17,20037508.34
 2) -20037508.34,0.0,0.0,20037508.34

 ...when requested as 256x256 tiles, while requesting a 255,256 tile will
 clip off the missing pixel row.


 Sample image attached (not the upper red band is truly lacking data while
 the single pixel row on the bottom is the un-rendered data)

 Dane


 On Oct 27, 2008, at 11:58 AM, Roger André wrote:

 Hi Dane,

 A sample image will be too large to upload - it's just under 300 MB, but
 I've attached a mapfile.  I can send a .tfw for anyone who isn't able to add
 georeferencing to the image after they have created it.

 I would be interested in knowing from you whether a WMS request of the same
 nature, but made to Mapnik, will yield the same results.  And I have already
 posted the same question to the GeoServer list as well.

 Thanks,

 Roger
 --

 On Mon, Oct 27, 2008 at 10:54 AM, Dane Springmeyer [EMAIL PROTECTED]wrote:

 Roger,
 Uploading a test case with a sample image and sample mapfile prepackaged
 would be really useful to speed testing and keep consistent.

 Dane



 On Oct 27, 2008, at 9:40 AM, Roger André wrote:

 Hi,

 I'd like to ask for some help from a couple people running MapServer.  I
 would like to know if others are able to replicate some strange behavior I
 have noticed lately, and what versions of MapServer they are using.  Below
 are the steps needed, they don't take very long.

 Step 1.  Create a large rectangular image of Size 14400 x 7200.

 Step 2.  Assign georeferencing to the image:
 gdal_translate -a_ullr -180 90 180 -90 -a_srs EPSG:4326 big_black.tif
 wgs84_big_black.tif

 Step 3. Load this image into a MapServer layer and set a contrasting
 IMAGECOLOR in the mapfile (red works well).

 Step 4. Make sure you have a spherical mercator projection defined in your
 epsg file.
 900913 +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0
 +y_0=0 +k=1.0 +units=m [EMAIL PROTECTED] +no_defs 

 Step 5. Make a WMS request for a tile that replicates one that TileCache
 makes:
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/test/test.map
 layers=imagery
 srs=EPSG%3A900913
 version=1.1.1
 bbox=-20037508.34%2C-20037508.34%2C-10018754.1704%2C-10018754.1704
 service=WMS
 width=256
 styles=
 format=image%2Fpng
 request=GetMap
 height=256

 Step 6. Look at your resulting tile. Is it full of data from top to
 bottom, or is there a band of IMAGECOLOR at the bottom?

 Step 7.  Let me know your results.

 Thanks very much!

 Roger
 --

 ___
 FWTools mailing list
 [EMAIL PROTECTED]
 http://lists.maptools.org/mailman/listinfo/fwtools
 http://fwtools.maptools.org/



 bug.map



raster_edge_bug.png___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] RE: Documentation for serving large raster images using tile cache.

2008-10-28 Thread Roger André
Hi Asif,

Are you able to view a map when you go to 
http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.mapmode=map;
?  Also, can you send a copy of your mapfile, and of your tilecache.cfg
files?

Roger
--

On Tue, Oct 28, 2008 at 11:15 AM, Asif Memon [EMAIL PROTECTED] wrote:

  Hi Roger,



 I followed the instructions on the documentation and setup the map server
 and demo, when I try to execute the index.html, I get this error - 
 msLoadMap():
 Unable to access file. (http://localhost:9090/mapdemo/itasca.map)



 Do you know what could be it?



 Sincerely,

 Asif Memon



 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Monday, October 20, 2008 1:38 PM
 *To:* Gregor Mosheh
 *Cc:* Asif Memon; mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Best thing to do is take a look at these 2 docs first:
 - http://mapserver.gis.umn.edu/docs/howto/raster_data
 - http://tilecache.org/readme.html

 Once you have the ability to see your raster in MapServer via a mode=map
 request, then you will have to decide how you wish to view your data
 afterwards.  There are different things to do in TileCache depending on
 whether you wish to view the data in OpenLayers, or over Google Maps/MS VE.
 --


  On Mon, Oct 20, 2008 at 12:01 PM, Gregor Mosheh [EMAIL PROTECTED]
 wrote:

 Asif Memon wrote:

 Could someone please point me to the documentation for serving large (2GB
 to 3GB) raster images using tile cache. I want to use Minnesota Map Server
 and GDAL to achieve this.



 You'll want to ask the TileCache list about that, likely. Once you have
 MapServer actually serving up the imagery, get your client using MapServer
 or WMS (I like OpenLayers, myself). Then install TileCache and change the OL
 app to use TC's URL instead of MapServer's. Easy.

 But you may want to install OpenLayers and get it working with MapServer
 first, then hit up the OL and TC mailing lists.

 --
 Gregor Mosheh / Greg AllensworthBS, A+, Network+, Security+, Server+
 System Administrator, Lead Programmer
 HostGIS development  hosting services, http://www.HostGIS.com/

 Remember that no one cares if you can back up,
  only if you can restore. - AMANDA
 ___
 mapserver-users mailing list
 mapserver-users@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] RE: Documentation for serving large raster images using tile cache.

2008-10-28 Thread Roger André
Hi Asif,

Ok, here's a new mapfile that you can try.  Change your request to point to
this one, and see if you get an image back in your browser.

Roger
--

On Tue, Oct 28, 2008 at 2:06 PM, Asif Memon [EMAIL PROTECTED] wrote:

  I believe one of the END was missing at the end of the file, I have
 added that. This resolves the earlier error and generated a new one - 
 msDrawMap():
 Image handling error. Unable to initialize image. msPrepareImage(): General
 error message. Image dimensions not specified. msCalculateScale(): General
 error message. Invalid image extent, minx=-1.00, miny=-1.00,
 maxx=-1.00, maxy=-1.00. mapserv(): Web application error. No way to
 generate map extent.



 Any help is much appreciated?



 Sincerely,

 Asif Memon



 *From:* Asif Memon
 *Sent:* Tuesday, October 28, 2008 1:48 PM
 *To:* 'Roger André'
 *Cc:* 'mapserver-users@lists.osgeo.org'
 *Subject:* RE: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 No, TileCache didn't come with that. I am trying to view any image right
 now to see an example of serving an image into Mapserver.



 I changed the path of the WMS URL(
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Cdemo.mapmode=map)
 and the error I am getting now is - msLoadMap(): Premature End-of-File.



 I ran the GDAL tile cache command on a .tif image to create the shape files
 using (gdaltindex doq_index.shp doq/*.tif). Also, I made some changes in the
 map file. Attached is the most updated map file along with the shape files.



 Could you please take a look at it.



 Sincerely,

 Asif Memon



 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Tuesday, October 28, 2008 1:22 PM
 *To:* Asif Memon
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Sorry I assumed that the index.html file was the one that came with
 TileCache.  Is that not correct?
 --

 On Tue, Oct 28, 2008 at 1:02 PM, Asif Memon [EMAIL PROTECTED] wrote:

 Thanks for your reply.



 Attached is the map file. I do not have the any tilecache.cfg file. From
 the error(msLoadMap(): Unable to access file. (/path/to/demo.map)), it
 appears the map file is not accessible.



 Sincerely,

 Asif Memon





 *From:* Roger André [mailto:[EMAIL PROTECTED]

 *Sent:* Tuesday, October 28, 2008 12:53 PM
 *To:* Asif Memon

 *Cc:* mapserver-users@lists.osgeo.org


 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Are you able to view a map when you go to 
 http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.mapmode=map;
 ?  Also, can you send a copy of your mapfile, and of your tilecache.cfg
 files?

 Roger
 --

 On Tue, Oct 28, 2008 at 11:15 AM, Asif Memon [EMAIL PROTECTED] wrote:

 Hi Roger,



 I followed the instructions on the documentation and setup the map server
 and demo, when I try to execute the index.html, I get this error - 
 msLoadMap():
 Unable to access file. (http://localhost:9090/mapdemo/itasca.map)



 Do you know what could be it?



 Sincerely,

 Asif Memon



 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Monday, October 20, 2008 1:38 PM
 *To:* Gregor Mosheh
 *Cc:* Asif Memon; mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Best thing to do is take a look at these 2 docs first:
 - http://mapserver.gis.umn.edu/docs/howto/raster_data
 - http://tilecache.org/readme.html

 Once you have the ability to see your raster in MapServer via a mode=map
 request, then you will have to decide how you wish to view your data
 afterwards.  There are different things to do in TileCache depending on
 whether you wish to view the data in OpenLayers, or over Google Maps/MS VE.
 --

 On Mon, Oct 20, 2008 at 12:01 PM, Gregor Mosheh [EMAIL PROTECTED]
 wrote:

 Asif Memon wrote:

 Could someone please point me to the documentation for serving large (2GB
 to 3GB) raster images using tile cache. I want to use Minnesota Map Server
 and GDAL to achieve this.



 You'll want to ask the TileCache list about that, likely. Once you have
 MapServer actually serving up the imagery, get your client using MapServer
 or WMS (I like OpenLayers, myself). Then install TileCache and change the OL
 app to use TC's URL instead of MapServer's. Easy.

 But you may want to install OpenLayers and get it working with MapServer
 first, then hit up the OL and TC mailing lists.

 --
 Gregor Mosheh / Greg AllensworthBS, A+, Network+, Security+, Server+
 System Administrator, Lead Programmer
 HostGIS development  hosting services, http://www.HostGIS.com/

 Remember that no one cares if you can back up,
  only if you can restore. - AMANDA

Re: [mapserver-users] RE: Documentation for serving large raster images using tile cache.

2008-10-28 Thread Roger André
Hi Asif,

I downloaded the demo.tif file that you sent earlier, and the
itasca_demo.map from you rprevious email.  I changed the path in the DATA
portion of the LAYER section to point to my filesystem,
DATA /var/www/mapfiles/itasca/demo.tif

and also changed the EXTENT to this:
  EXTENT  -0.9194182 -4.2013292 -0.9002422 -4.1870152

This matches the extent of the file when you run gdalinfo against it (min_x
min_y max_x Max_y).

With these changes, I'm able to view the file with the following URL:
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/itasca/itasca_demo.mapmode=map

(Note, I'm running this in Linux, so paths and URLs are going to be slightly
different than yours)

Try changing your EXTENT entry to match mine, that might do the trick.
--



On Tue, Oct 28, 2008 at 3:45 PM, Asif Memon [EMAIL PROTECTED] wrote:

  Thanks Roger.



 I don't see any errors now, but no image appears in the browser(the browser
 is blank). I made minor changes to the map file that you sent me (about the
 paths, attached is the file).



 The URL that I am using in the browser is
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\itasca_demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Citasca_demo.mapmode=map



 Please correct me if anything is wrong in the URL or in the map file.



 Sincerely,

 Asif Memon





 *From:* Roger André [mailto:[EMAIL PROTECTED]
 *Sent:* Tuesday, October 28, 2008 3:17 PM

 *To:* Asif Memon
 *Cc:* mapserver-users@lists.osgeo.org
 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Ok, here's a new mapfile that you can try.  Change your request to point to
 this one, and see if you get an image back in your browser.

 Roger
 --

 On Tue, Oct 28, 2008 at 2:06 PM, Asif Memon [EMAIL PROTECTED] wrote:

 I believe one of the END was missing at the end of the file, I have added
 that. This resolves the earlier error and generated a new one - msDrawMap():
 Image handling error. Unable to initialize image. msPrepareImage(): General
 error message. Image dimensions not specified. msCalculateScale(): General
 error message. Invalid image extent, minx=-1.00, miny=-1.00,
 maxx=-1.00, maxy=-1.00. mapserv(): Web application error. No way to
 generate map extent.



 Any help is much appreciated?



 Sincerely,

 Asif Memon



 *From:* Asif Memon
 *Sent:* Tuesday, October 28, 2008 1:48 PM
 *To:* 'Roger André'


 *Cc:* 'mapserver-users@lists.osgeo.org'

 *Subject:* RE: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 No, TileCache didn't come with that. I am trying to view any image right
 now to see an example of serving an image into Mapserver.



 I changed the path of the WMS URL(
 http://localhost:9090/cgi-bin/mapserv.exe?map=C:\Asif\work\devtools\MMS\ms4w\Apache\htdocs\mapdemo\demo.mapmode=maphttp://localhost:9090/cgi-bin/mapserv.exe?map=C:%5CAsif%5Cwork%5Cdevtools%5CMMS%5Cms4w%5CApache%5Chtdocs%5Cmapdemo%5Cdemo.mapmode=map)
 and the error I am getting now is - msLoadMap(): Premature End-of-File.



 I ran the GDAL tile cache command on a .tif image to create the shape files
 using (gdaltindex doq_index.shp doq/*.tif). Also, I made some changes in the
 map file. Attached is the most updated map file along with the shape files.



 Could you please take a look at it.



 Sincerely,

 Asif Memon



 *From:* Roger André [mailto:[EMAIL PROTECTED]

 *Sent:* Tuesday, October 28, 2008 1:22 PM
 *To:* Asif Memon

 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Sorry I assumed that the index.html file was the one that came with
 TileCache.  Is that not correct?
 --

 On Tue, Oct 28, 2008 at 1:02 PM, Asif Memon [EMAIL PROTECTED] wrote:

 Thanks for your reply.



 Attached is the map file. I do not have the any tilecache.cfg file. From
 the error(msLoadMap(): Unable to access file. (/path/to/demo.map)), it
 appears the map file is not accessible.



 Sincerely,

 Asif Memon





 *From:* Roger André [mailto:[EMAIL PROTECTED]

 *Sent:* Tuesday, October 28, 2008 12:53 PM
 *To:* Asif Memon

 *Cc:* mapserver-users@lists.osgeo.org


 *Subject:* Re: [mapserver-users] RE: Documentation for serving large
 raster images using tile cache.



 Hi Asif,

 Are you able to view a map when you go to 
 http://localhost:9090/cgi-bin/mapserv.exe?map=/path/to/itasca.mapmode=map;
 ?  Also, can you send a copy of your mapfile, and of your tilecache.cfg
 files?

 Roger
 --

 On Tue, Oct 28, 2008 at 11:15 AM, Asif Memon [EMAIL PROTECTED] wrote:

 Hi Roger,



 I followed the instructions on the documentation and setup the map server
 and demo, when I try to execute the index.html, I get this error - 
 msLoadMap():
 Unable to access file. (http://localhost:9090/mapdemo/itasca.map)



 Do you know what could

Re: [mapserver-users] projection = geographer's pain

2008-10-27 Thread Roger André
Hi Monier,

My understanding of how this works is as follows.

Assuming your data is in epsg:4326, and you wish to display it in epsg:3785:

1) Your LAYER needs to reflect epsg:4326.
PROJECTION
  init=epsg:4326
END

2) Your layer also needs to have a wms_srs parameter in the METADATA section
to allow for the layer to be requested in epsg:3785, ie
METADATA
  wms_srs EPSG:4326 EPSG:3785
  wms_namecounties
  wms_server_version  1.1.1
  wms_format  image/png
  wms_onlineresource  
http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/states/states.map;
END

3) Your request to Mapserver needs to define the extents of the image you
want , *in the units of the projection.  *So a valid request for the layer
above would be:

http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/states/state.maphttp://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/test/test.map
layers=counties
srs=EPSG%3A3785
version=1.1.1
bbox=-20037508.34%2C-20037508.34%2C-10018754.1704%2C-10018754.1704
service=WMS
width=256
styles=
format=image%2Fpng
request=GetMap
height=25

Hope that helps,

Roger
--

Monier Clement wrote:

 Hi,

 There is bigger than tiny difference in extents in epsg:4326 and in
 epsg:3785.  The latter is using meters as an unit.
 I had a try with Finland polygon and here are the results:

 D:\TEMPogrinfo -summary Finland_WGS84.shp Finland_WGS84
 Feature Count: 1
 Extent: (19.648331, 59.804989) - (31.587299, 70.079422)

 D:\TEMPogr2ogr -f ESRI Shapefile -s_srs epsg:4326 -t_srs epsg:900913
 Finland_
 Spherical.shp Finland_WGS84.shp

 D:\TEMPogrinfo -summary Finland_Spherical.shp Finland_Spherical
 Feature Count: 1
 Extent: (2187242.167179, 8356448.200347) - (3516282.078834,
 11094615.004724)

 -Jukka-


  Hi,
 
  I got the map extent from shpinfo.
  Beside, I know that there should only be a tiny difference
  between coordinates in latlon-wgs84 (data proj) and web
  spherical mercator (map proj).
 
  You'll find the whole test-case files as attachement.
 
  Here's the command line to get the map :
  C:\ms4w\tools\mapserv\shp2img -m
  C:\ms4w\apps\gmap\htdocs\test.map -o test.png -l layer1 -i agga
 
  Thanks
 
  Clément
 
 
  -Message d'origine-
  De : Rahkonen Jukka [mailto:[EMAIL PROTECTED]
  Envoyé : lundi 27 octobre 2008 12:46
  À : Monier Clement; mapserver-users@lists.osgeo.org Objet :
  VS: [mapserver-users] projection = geographer's pain
 
  Hi,
 
  Have you double-checked that your map extent correspods with
  the map projection?
  Or if you could send your whole mapfile I am pretty sure that
  you will get a final answer to your problem.
 
  -Jukka Rahkonen-
 
   -Alkuperäinen viesti-
   Lähettäjä: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED] Puolesta Monier
   Clement
   Lähetetty: 27. lokakuuta 2008 13:39
   Vastaanottaja: 'Pietro Giannini'; mapserver-users@lists.osgeo.org
   Aihe: RE: [mapserver-users] projection = geographer's pain
  
  
   Thanks for your answers Roger  Pietro.
  
   I've followed your advice by trying these 4 test-cases :
  
   1)
   Map proj set to :   init=epsg:3785 (web spherical Mercator,
   manually added
   into espg file)
   Layer proj set to : init=epsg:4326 (latlon wgs84, proj
  system of my
   shapefiles)
  
   = got a blank map
  
   2)
   Map projection set to : init=epsg:4326
   Layer projection set to : init=epsg:4326
  
   = got a map
  
   3)
   Map projection set to : init=epsg:3785
   Layer projection set to : init=epsg:3785
  
   = got the same map as 2)
  
   4)
   Map projection set to : init=epsg:4326
   Layer projection set to : init=epsg:3785
  
   = got a blank map
  
   I've also tried with another well-known existing epsg proj-system
   (instead of the manually-added 3785 code), but got the same results.
   I've made other attempts by replacing init=3785 by full
  description
   proj-string like +proj=longlat +ellps=WGS84
   +datum=WGS84 +no_defs  no_defs
   or +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0
   +x_0=0.0 +y_0=0
   +k=1.0 +units=m [EMAIL PROTECTED]  no_defs
   But it didn't change anything...
  
   It seems that :
   - a map is drawn only if the map's and layer's proj-systems are the
   same.
   - the output projection is always overridden by the
  shapefile system,
   no re-projection is done anyway.
  
   Let me know if you have any further leads to solve this issue.
  
   Thanks for your help
  
   Clément
  
   -Message d'origine-
   De : [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED] De la part
  de Pietro
   Giannini Envoyé : vendredi 24 octobre 2008 21:40 À
   : mapserver-users@lists.osgeo.org Objet : Re:
   [mapserver-users] projection = geographer's pain
  
   I can confirm that projection is often a pain!
  
   However, the problem may be in the projection of the layer.
  
   The PROJECTION section in a layer declare the projection of
  the data
   source of this layer, while the PROJECTION on the map level is the
   projection wich you 

Re: [mapserver-users] Can someone help test a potential bug for me?

2008-10-27 Thread Roger André
Kristian,

Thanks very much for your help, and for listing your test parameters.

Roger
--

On Mon, Oct 27, 2008 at 10:01 AM, Kristian Thy [EMAIL PROTECTED] wrote:

 On Mon, Oct 27, Roger André wrote:
  Step 6. Look at your resulting tile. Is it full of data from top to
 bottom,
  or is there a band of IMAGECOLOR at the bottom?

 Band of red at the bottom.

 Parameters:
  * MS 5.2.0 (Win32)
  * The GDAL packaged with FWTools 2.1.0
  * TIFF created in Gimp and saved with no compression
  * Mapfile used:

 MAP
NAME Test
DEBUG OFF
EXTENT -180 -90 180 90
SIZE 1000 500
UNITS DD

WEB
LOG caches.log
IMAGEPATH /K/Programs/ms4w/tmp/ms_tmp/
IMAGEURL /ms_tmp/
METADATA
wms_title  Test
wms_onlineresource 
 http://localhost:81/cgi-bin/mapserv.exe?map=/K/Programs/ms4w/apps/caches/test.map;
 
wms_srsEPSG:4326 EPSG:900913
END #metadata
END #web

PROJECTION
init=epsg:4326
END #projection

IMAGECOLOR 255 0 0

LAYER
NAME 'TEST'
TYPE RASTER
DATA 'wgs84_big_black.tif'
STATUS ON
PROJECTION
'init=epsg:4326'
END #projection
METADATA
wms_title TEST
END #metadata
END #layer
 END #map

 \\kristian
 --
 ... et nemo ex vobis interrogat me: »Quo vadis?«
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: [FWTools] Can someone help test a potential bug for me?

2008-10-27 Thread Roger André
Hi Dane,

A sample image will be too large to upload - it's just under 300 MB, but
I've attached a mapfile.  I can send a .tfw for anyone who isn't able to add
georeferencing to the image after they have created it.

I would be interested in knowing from you whether a WMS request of the same
nature, but made to Mapnik, will yield the same results.  And I have already
posted the same question to the GeoServer list as well.

Thanks,

Roger
--

On Mon, Oct 27, 2008 at 10:54 AM, Dane Springmeyer [EMAIL PROTECTED]wrote:

 Roger,
 Uploading a test case with a sample image and sample mapfile prepackaged
 would be really useful to speed testing and keep consistent.

 Dane



 On Oct 27, 2008, at 9:40 AM, Roger André wrote:

 Hi,

 I'd like to ask for some help from a couple people running MapServer.  I
 would like to know if others are able to replicate some strange behavior I
 have noticed lately, and what versions of MapServer they are using.  Below
 are the steps needed, they don't take very long.

 Step 1.  Create a large rectangular image of Size 14400 x 7200.

 Step 2.  Assign georeferencing to the image:
 gdal_translate -a_ullr -180 90 180 -90 -a_srs EPSG:4326 big_black.tif
 wgs84_big_black.tif

 Step 3. Load this image into a MapServer layer and set a contrasting
 IMAGECOLOR in the mapfile (red works well).

 Step 4. Make sure you have a spherical mercator projection defined in your
 epsg file.
 900913 +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0
 +y_0=0 +k=1.0 +units=m [EMAIL PROTECTED] +no_defs 

 Step 5. Make a WMS request for a tile that replicates one that TileCache
 makes:
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/test/test.map
 layers=imagery
 srs=EPSG%3A900913
 version=1.1.1
 bbox=-20037508.34%2C-20037508.34%2C-10018754.1704%2C-10018754.1704
 service=WMS
 width=256
 styles=
 format=image%2Fpng
 request=GetMap
 height=256

 Step 6. Look at your resulting tile. Is it full of data from top to bottom,
 or is there a band of IMAGECOLOR at the bottom?

 Step 7.  Let me know your results.

 Thanks very much!

 Roger
 --

 ___
 FWTools mailing list
 [EMAIL PROTECTED]
 http://lists.maptools.org/mailman/listinfo/fwtools
 http://fwtools.maptools.org/





bug.map
Description: Binary data
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] projection = geographer's pain

2008-10-24 Thread Roger André
Hi Clement,

Looking at the info you provided, I think the problem is here in your
MAPFILE




 PROJECTION

init=epsg:3785 # is this correct ?

 END

I believe this should be set to init=epsg:4326 in order to define the
projection of the shapefile.  Then when the request is made to display the
data in epsg:3785, the system will know how to calculate the reprojection.

Best wishes,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Is OUTLINEWIDTH implemented for labels?

2008-10-24 Thread Roger André
Hi,

Just a quick question about whether this option has been added?  I'm trying
to use it in a map, and although i's use doesn't seem to cause MapServer to
choke, it also doesn't seem to change the size of the halo around the label
text.  Here is how I'm using it:

LABEL
  TYPE truetype
  FONT arial
  SIZE 30
  COLOR 0 0 0
  OUTLINECOLOR 255 255 255
  OUTLINEWIDTH 50
  POSITION ur
END

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Missing row of pixels in MapServer generated tiles

2008-10-20 Thread Roger André
Nope, that's not it.  Had the correct params in that entry after all:

900913 +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0
+y_0=0 +k=1.0 +units=m [EMAIL PROTECTED] +no_defs

This matches documentation at
http://spatialreference.org/ref/user/google-projection/

Reprojected my data file with gdalwarp to epsg 900913, then updated the
mapfile to reflect that input layer is in that projection and tested.  Got
rid of the missing rixel rows at the bottom of tiles, but now the image only
extends between 80 to -80 latitude, and there is a weird, scalloped seam at
the international dateline.  So something is still not right, but it would
appear that it's projection related.
--


On 10/19/08, Roger André [EMAIL PROTECTED] wrote:

 One thing I did notice is that my EPSG file definition for Spherical
 Mercator is missing a parameter, [EMAIL PROTECTED].  I'll test tomorrow to
 see if adding it to the definition removes the problem.
 --


 On Sat, Oct 18, 2008 at 7:25 PM, Roger André [EMAIL PROTECTED] wrote:

 This is probably more of a TileCache question, than a MapServer one, but I
 figure one of you may have had the same issue in the past.  I'm using
 MapServer to feed TileCache a fairly large GeoTiff with global extents,
 which I'm then displaying in Google Maps as a tile layer.  This has worked
 well in the past, but now I'm encountering a weird problem.  Some of my
 tiles are being rendered by MapServer with a row of pixels missing on the
 bottom of the image.  So for example, in Zoom Level 2, all of the 0.png
 tiles will be 256 x 256 pixels, but row 256 will not contain data from my
 global image, but instead will be set entirely to whatever background color
 I have set in my Mapfile. The problem appears in multiple, but not all, Zoom
 levels, and at different geographic locations, but always at the bottom row
 of a tile.

 The source image doesn't have the lines in then, so I have to believe that
 the dead row is an artifact of the rendering process.  My seed image is in
 lat/lon WGS84, and the tiles are being requested in EPSG:900913.  The
 reprojection seems to be working correctly, insofar as image lineup with
 Google Maps seems to indicate.  If I take the seed image and create a very
 reduced resolution version of it, then run it through TileCache, I don't get
 any lines.  So it seems like the lines *might* be a result of downsampling,
 but since they're not present at the bottom of every image, I'm not
 convinced that's the problem.

 Oh, and I'm using the GD driver.

 Any ideas?

 Roger
 --



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] RE: Documentation for serving large raster images using tile cache.

2008-10-20 Thread Roger André
Hi Asif,

Best thing to do is take a look at these 2 docs first:
- http://mapserver.gis.umn.edu/docs/howto/raster_data
- http://tilecache.org/readme.html

Once you have the ability to see your raster in MapServer via a mode=map
request, then you will have to decide how you wish to view your data
afterwards.  There are different things to do in TileCache depending on
whether you wish to view the data in OpenLayers, or over Google Maps/MS VE.
--



On Mon, Oct 20, 2008 at 12:01 PM, Gregor Mosheh [EMAIL PROTECTED] wrote:

 Asif Memon wrote:

 Could someone please point me to the documentation for serving large (2GB
 to 3GB) raster images using tile cache. I want to use Minnesota Map Server
 and GDAL to achieve this.


 You'll want to ask the TileCache list about that, likely. Once you have
 MapServer actually serving up the imagery, get your client using MapServer
 or WMS (I like OpenLayers, myself). Then install TileCache and change the OL
 app to use TC's URL instead of MapServer's. Easy.

 But you may want to install OpenLayers and get it working with MapServer
 first, then hit up the OL and TC mailing lists.

 --
 Gregor Mosheh / Greg AllensworthBS, A+, Network+, Security+, Server+
 System Administrator, Lead Programmer
 HostGIS development  hosting services, http://www.HostGIS.com/

 Remember that no one cares if you can back up,
  only if you can restore. - AMANDA
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Missing row of pixels in MapServer generated tiles

2008-10-19 Thread Roger André
One thing I did notice is that my EPSG file definition for Spherical
Mercator is missing a parameter, [EMAIL PROTECTED].  I'll test tomorrow to
see if adding it to the definition removes the problem.
--


On Sat, Oct 18, 2008 at 7:25 PM, Roger André [EMAIL PROTECTED] wrote:

 This is probably more of a TileCache question, than a MapServer one, but I
 figure one of you may have had the same issue in the past.  I'm using
 MapServer to feed TileCache a fairly large GeoTiff with global extents,
 which I'm then displaying in Google Maps as a tile layer.  This has worked
 well in the past, but now I'm encountering a weird problem.  Some of my
 tiles are being rendered by MapServer with a row of pixels missing on the
 bottom of the image.  So for example, in Zoom Level 2, all of the 0.png
 tiles will be 256 x 256 pixels, but row 256 will not contain data from my
 global image, but instead will be set entirely to whatever background color
 I have set in my Mapfile. The problem appears in multiple, but not all, Zoom
 levels, and at different geographic locations, but always at the bottom row
 of a tile.

 The source image doesn't have the lines in then, so I have to believe that
 the dead row is an artifact of the rendering process.  My seed image is in
 lat/lon WGS84, and the tiles are being requested in EPSG:900913.  The
 reprojection seems to be working correctly, insofar as image lineup with
 Google Maps seems to indicate.  If I take the seed image and create a very
 reduced resolution version of it, then run it through TileCache, I don't get
 any lines.  So it seems like the lines *might* be a result of downsampling,
 but since they're not present at the bottom of every image, I'm not
 convinced that's the problem.

 Oh, and I'm using the GD driver.

 Any ideas?

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Missing row of pixels in MapServer generated tiles

2008-10-18 Thread Roger André
This is probably more of a TileCache question, than a MapServer one, but I
figure one of you may have had the same issue in the past.  I'm using
MapServer to feed TileCache a fairly large GeoTiff with global extents,
which I'm then displaying in Google Maps as a tile layer.  This has worked
well in the past, but now I'm encountering a weird problem.  Some of my
tiles are being rendered by MapServer with a row of pixels missing on the
bottom of the image.  So for example, in Zoom Level 2, all of the 0.png
tiles will be 256 x 256 pixels, but row 256 will not contain data from my
global image, but instead will be set entirely to whatever background color
I have set in my Mapfile. The problem appears in multiple, but not all, Zoom
levels, and at different geographic locations, but always at the bottom row
of a tile.

The source image doesn't have the lines in then, so I have to believe that
the dead row is an artifact of the rendering process.  My seed image is in
lat/lon WGS84, and the tiles are being requested in EPSG:900913.  The
reprojection seems to be working correctly, insofar as image lineup with
Google Maps seems to indicate.  If I take the seed image and create a very
reduced resolution version of it, then run it through TileCache, I don't get
any lines.  So it seems like the lines *might* be a result of downsampling,
but since they're not present at the bottom of every image, I'm not
convinced that's the problem.

Oh, and I'm using the GD driver.

Any ideas?

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Drawing a line

2008-10-15 Thread Roger André
You can add a new LAYER with a FEATURE that has the 2 points specified in
it, like this:

  LAYER
NAME 'line'
STATUS DEFAULT
TYPE LINE
FEATURE
  POINTS  -67.012 -16.952
-67.012 -17.450

  END
END
CLASS
  STYLE
COLOR 255 0 0
WIDTH 2
  END
END # class
  END # layer

##


On Wed, Oct 15, 2008 at 3:42 AM, ramya srinivasan [EMAIL PROTECTED]wrote:

 Hi, How to draw a line on the map between two points given by the user?
 What all should be included in the mapfile for this line layer.

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Output size for printed map sized like 7.5 minute quad?

2008-10-11 Thread Roger André
Hi,

I've got a quick question about how to determine the size in pixels an image
should be in order to achieve a specific DPI when it is printed.  I'd like
to print something that's roughly about the size of a USGS 7.5 minute quad
sheet - which is generally 22 x 27 in size, and with 300 DPI in print
quality.  Is there an easy way for me to calculate how big an image I should
generate to achieve this?

Thanks,

Roger
--
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Output size for printed map sized like 7.5 minute quad?

2008-10-11 Thread Roger André
Hmm, well if I'm not being more of an idiot than I already think I am, I
think the answer is 6600 x 8100.  That sound right, just inches * DPI =
pixels?
--



On Sat, Oct 11, 2008 at 7:33 PM, Roger André [EMAIL PROTECTED] wrote:

 Hi,

 I've got a quick question about how to determine the size in pixels an
 image should be in order to achieve a specific DPI when it is printed.  I'd
 like to print something that's roughly about the size of a USGS 7.5 minute
 quad sheet - which is generally 22 x 27 in size, and with 300 DPI in print
 quality.  Is there an easy way for me to calculate how big an image I should
 generate to achieve this?

 Thanks,

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Creating legend

2008-10-07 Thread Roger André
Also, you might want to consider making a separate GetLegendGraphic WMS
request and putting the legend in a separate DIV element in your web page.

Just an idea.
--

On Tue, Oct 7, 2008 at 8:22 AM, Steve Lime [EMAIL PROTECTED]wrote:

 Visit:

  http://www.openlayers.org/dev/examples/example-list.html

 and search for untiled. There's a WMS Untiled example you can view the
 source of. The singleTile option goes in the options object as opposed the
 params object. Params get passed to the WMS service, options are handled
 by OL.

 Steve

  Subha Ramakrishnan [EMAIL PROTECTED] 10/07/08 9:58 AM 
 Hi Steve,
 It would be great if you can give me an example or tell me where it is
 usually set in OL.
 Thanks for your help.

 Subha

 Steve Lime wrote:
  There's nothing you have to do on the MapServer side. Looks like your OL
 config is wrong
  though. I think 'singleTile' is set in the wrong configuration object,
 perhaps others are in
  the wrong place too.
 
  Steve
 
 
  Subha Ramakrishnan [EMAIL PROTECTED] 10/07/08 1:30 AM 
 
  Hi,
 
  I am using mapserver 5.0.2 with openlayers.
  I've a problem while creating a legend for a map from mapserver.When i
  try to overlay the image from the mapserver on openlayers' base map, the
  images are rendered in tiles, and every tile has a legend and is limited
  by the size of the tile. So, i see lots of legends on the map and only
  half of them are visible as it is restricted by the tile size.
 
  This is my request to mapserver from openlayers
 
  var mapfile = layer_tablename+'.map';
  twms1 = new OpenLayers.Layer.WMS(
  layer_tablename,http://localhost/cgi-bin/mapserv?;,
  { map: mapfile,
 transparent: 'true', layers:layer_tablename,
 format: 'image/png',
 projection:EPSG:4326,reproject:false,
 units: m,
 singleTile: true
  },{numZoomLevels : MaxZoomLevel});
  map.addLayer(twms1);
 
  I am using the option of singleTile. Is there any setting to be done in
  the map file or mapserver for it render a single tile/single legend per
  image?
 
  Thank you.
 
  Regards,
  Subha
 
  ___
  mapserver-users mailing list
  mapserver-users@lists.osgeo.org
  http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
 


 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Creation of continuous color ramp legends [SEC=UNCLASSIFIED]

2008-09-26 Thread Roger André
Hi Antti,

Sounds like they probably looked very good.  However I was hoping to find a
means of generating them automagically.  I found some interesting
information regarding the Imagemagick gradient tool last night, but was not
able to pass in more than 2 colors at a time.  I'll have to see if it's
possible to do so, or whether I can create multiple, small images of the
gradients between color pairs, and then assemble them into a longer image
that represents the entire range.

Thanks,

Roger
--

On Thu, Sep 25, 2008 at 8:58 PM, Roppola, Antti - BRS 
[EMAIL PROTECTED] wrote:

  I used GIMP to create visually pleasing colour ramps and somehow (it was
 a while ago) exported/embedded them in TIFF files as colour maps (I think).
 The legend was colour chips for key breakpoints in the gradients I defined
 and to hold the legend I created a bogus layer in the same group as the
 TIFF.

 Sorry if this is vague or incorrect, it was a few years ago now...

 Antti

  --
 *From:* [EMAIL PROTECTED] [mailto:
 [EMAIL PROTECTED] *On Behalf Of *Roger André
 *Sent:* Friday, 26 September 2008 1:28 PM
 *To:* mapserver-users@lists.osgeo.org
 *Subject:* [mapserver-users] Creation of continuous color ramp legends

  I'm interested in hearing how people have gone about creating legend
 graphics for continuous data sets.  Say for hypsometric tinting.

 Thanks!

 Roger
 --



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[mapserver-users] Re: Transparency via WMS request?

2008-09-24 Thread Roger André
Thanks to some help from a fellow GIS developer, I think I've narrowed the
problem down to the OUTPUTFORMAT section of my mapfile.  Changing from the
AGG to GD driver seemed to take care of the problem.  Will need to do some
additional futzing to see if I can get it working with AGG.
--



On Wed, Sep 24, 2008 at 1:38 PM, Roger André [EMAIL PROTECTED] wrote:

 Ok, this is driving me bonkers.  I have a raster image with nodata values
 set to be transparent.  When I make requests to this layer in mode=map, it
 works beautifully, and the nodata values are transparent.

 -
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/temp/temp.mapmode=map

 However, when I try to view the same data via a WMS request, the nodata
 values are displayed in black.

 - http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/temp/temp.map
 SERVICE=WMS
 version=%221.1.122
 REQUEST=GetMap
 LAYERS=imagery
 STYLES=
 BBOX=-180,-90,180,90
 WIDTH=600
 HEIGHT=500
 FORMAT=png
 SRS=epsg:4326

 I have tried doing a couple of things to fix this, none of which has
 worked:
 - added wms_transparent TRUE to METADATA section of LAYER
 - added TRANSPARENT=TRUE to the end of the WMS request
 - made sure that in OUTPUTFORMAT I have all of these:
   OUTPUTFORMAT
NAME png
DRIVER AGG/PNG
MIMETYPE image/png
IMAGEMODE RGBA
EXTENSION png
FORMATOPTION TRANSPARENT=ON
FORMATOPTION INTERLACE=OFF
TRANSPARENT ON
   END #end outputformat

 Please, can anyone tell me what I'm missing?

 Thanks,

 Roger
 --

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Re: Transparency via WMS request?

2008-09-24 Thread Roger André
Sorry, but I can't test that.  I don't have pdf support compiled into this
version of Mapserver.

I did get transparency to work using the AGG driver by altering my
OUTPUTFORMAT to look like this:
  OUTPUTFORMAT
   NAME 'AGGA'
   DRIVER AGG/PNG
   IMAGEMODE RGBA
   EXTENSION png
   FORMATOPTION TRANSPARENT=ON
   FORMATOPTION INTERLACE=OFF
   TRANSPARENT ON
  END #end outputformat

Unfortunately, it seemed to have decreased the quality of the rendering.
I've switched back to using the GD driver, and that seems to give good
quality and correct transparency.
  OUTPUTFORMAT
   NAME 'png'
   DRIVER GD/PNG
   IMAGEMODE RGBA
   EXTENSION png
   FORMATOPTION TRANSPARENT=ON
   FORMATOPTION INTERLACE=OFF
   TRANSPARENT ON
  END #end outputformat

---

On Wed, Sep 24, 2008 at 3:39 PM, Robert Sanson [EMAIL PROTECTED]wrote:

  Is it possible to get layer transparency when outputformat=PDF?

 Thanks,

 Robert Sanson

  Roger André [EMAIL PROTECTED] 25/09/2008 10:36 a.m. 
 Thanks to some help from a fellow GIS developer, I think I've narrowed the
 problem down to the OUTPUTFORMAT section of my mapfile.  Changing from the
 AGG to GD driver seemed to take care of the problem.  Will need to do some
 additional futzing to see if I can get it working with AGG.
 --



 On Wed, Sep 24, 2008 at 1:38 PM, Roger André [EMAIL PROTECTED] wrote:

 Ok, this is driving me bonkers.  I have a raster image with nodata values
 set to be transparent.  When I make requests to this layer in mode=map, it
 works beautifully, and the nodata values are transparent.

 -
 http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/temp/temp.mapmode=map

 However, when I try to view the same data via a WMS request, the nodata
 values are displayed in black.

 - http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/temp/temp.map
 SERVICE=WMS
 version=1.1.122

 REQUEST=GetMap
 LAYERS=imagery
 STYLES=
 BBOX=-180,-90,180,90
 WIDTH=600
 HEIGHT=500
 FORMAT=png
 SRS=epsg:4326

 I have tried doing a couple of things to fix this, none of which has
 worked:
 - added wms_transparent TRUE to METADATA section of LAYER
 - added TRANSPARENT=TRUE to the end of the WMS request
 - made sure that in OUTPUTFORMAT I have all of these:
   OUTPUTFORMAT
NAME png
DRIVER AGG/PNG
MIMETYPE image/png
IMAGEMODE RGBA
EXTENSION png
FORMATOPTION TRANSPARENT=ON
FORMATOPTION INTERLACE=OFF
TRANSPARENT ON
   END #end outputformat

 Please, can anyone tell me what I'm missing?

 Thanks,

 Roger
 --




 Click here https://www.mailcontrol.com/sr/wQw0zmjPoHdJTZGyOCrrhg== to
 report this email as spam.



 --

 The contents of this email are confidential to AsureQuality. If you have 
 received this communication in error please notify the sender immediately and 
 delete the message and any attachments. The opinions expressed in this email 
 are not necessarily those of AsureQuality. This message has been scanned for 
 known viruses before delivery. AsureQuality supports the Unsolicited 
 Electronic Messages Act 2007. If you do not wish to receive similar 
 communications in future, please notify the sender of this message.
 --

 This message has been scanned for malware by SurfControl plc.
 www.surfcontrol.com

 ___
 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