Re: [mapserver-users] Re: Raster Data from PostGIS
Gustavo1376 wrote: > I mean, i > think that a PostGis with 500GB storage capacity should be able to store > much more images than a flat file system with same capacity. Unfortunate database can not do such a magic. Database tables are also stored into files, and I do not believe that they are especially well compressed. Probably your images would take more disk space in the database than as image files. -Jukka Rahkonen-___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
RE: [mapserver-users] Re: Raster Data from PostGIS
Florencia, Since you are using this strategy for vector layers, I think that it could work for rasters. You would use gdaltindex or something else to create a polygon data set that represented the 'footprints' of your raster files. http://mapserver.org/optimization/tileindex.html One of the attribute columns in a tile index is the path to the location of each individual raster file. The raster files are stored in the file system, not in the database. The database just stores the paths to the images. I don't know if you can create a tileindex directly in PostGIS, but you could import the output shapefile. I am guessing that you would then create a related table in PostGIS that stored records containing the allowed tileid and username combinations. For the tileindex, you would use pretty much the same query that you use for your vector layers. David. -Original Message- From: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of florencia.bujan Sent: Monday, November 29, 2010 10:39 AM To: mapserver-users@lists.osgeo.org Subject: [mapserver-users] Re: Raster Data from PostGIS David, Exactly. I done this with a dynamic parameter, like this: DATA "the_geom from (SELECT l.* from lotes l, campos c WHERE c.id=l.idcampo AND l.idcampo=%param%) as lotes using unique gid using SRID=-1" but I want to do that with raster layer. Perhaps another solution is in the passage of parameters. Thanks! Florencia from Uruguay -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Raster-Data-from-PostGIS-tp5784362p5785003.html Sent from the Mapserver - User mailing list archive at Nabble.com. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
RE: [mapserver-users] Re: Raster Data from PostGIS
If I remember correctly, you can use a PostGIS data set as a tileindex. Perhaps it would be possible to have a PostGIS polygon layer that serves as the tileindex with a where clause that only includes the footprint polygons for the rasters that a particular user should be able to see. Has anyone done this? David. -Original Message- From: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of florencia.bujan Sent: Monday, November 29, 2010 10:12 AM To: mapserver-users@lists.osgeo.org Subject: [mapserver-users] Re: Raster Data from PostGIS Stephen, Carlos Thanks for your response again. My problem is that the group of rasters not always the same (dinamic). For example, rasters show according to the user logged (some users can see some rasters but no all), everything depends on the user. With the other types of layers (polygon, line, point, etc) I can do that using the param (%param%) on the data layer. Then, I will investigate the TILEINDEX in the LAYER and the solution with GROUP (but should be dynamic). If anyone finds an example please let me know. Thank you very much for your cooperation! and sorry for my poor english Florencia from Uruguay -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Raster-Data-from-PostGIS-tp5784362p5784894.html Sent from the Mapserver - User mailing list archive at Nabble.com. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Re: Raster Data from PostGIS
On 11/29/2010 10:50 AM, florencia.bujan wrote: Hi Carlos, Thanks for your response. Ok, but I want to show only one layer with some rasters (more than one). I can save tif files into my system (directory into my hard disc instead of PostGIS), but I am thinking about can show a layer with more than one tif raster. Any ideas? Thanks a lot! Florencia from Uruguay Florencia, If you have a lot of tiff files on the disk, there are two ways to work with them if you want them to appear as a single layer: 1. create a tileindex for rasters use gdaltindex command then in mapserver reference this with the TILEINDEX in the LAYER 2. create a vrt file the includes all your rasters with gdalbuildvrt This you can reference in the DATA "myvrtfile.vrt" -Steve W ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Re: Raster Data from PostGIS
Hi Florencia, You just can show a layer per LAYER section at a time. However, you can use the GROUP label within each LAYER section of each raster you want to show, to turn on/off all those layers. Solo puedes mostrar una capa por cada sección LAYER a la vez. Sin embargo, puedes hacer uso de la etiqueta GROUP dentro de cada sección LAYER a cada uno de los archivos raster que quieras mostrar para encenderlos o apagarlos en grupo. IC Carlos Ruiz From: florencia.bujan To: mapserver-users@lists.osgeo.org Sent: Mon, November 29, 2010 9:50:35 AM Subject: [mapserver-users] Re: Raster Data from PostGIS Hi Carlos, Thanks for your response. Ok, but I want to show only one layer with some rasters (more than one). I can save tif files into my system (directory into my hard disc instead of PostGIS), but I am thinking about can show a layer with more than one tif raster. Any ideas? Thanks a lot! Florencia from Uruguay -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Raster-Data-from-PostGIS-tp5784362p5784801.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