[postgis-users] raster output
Paragon Corporation
lr at pcorp.us
Tue Dec 20 15:13:26 PST 2011
Stephen,
There are couple of ways to view raster data.
1) QGIS has a plug-in for viewing raster which as I recall is on 1.7. QGIS
users can probably fill you in on the details of that.
2) UMN Mapserver can also load PostGIS raster detailed here:
http://www.postgis.org/documentation/manual-svn/RT_FAQ.html#id3031186
To be honest I haven't tried Mapserver in a couple of months with raster, so
haven't confirmed all the changes we've done haven't broken it or if the
syntax has changed.
3) You can use gdal_translate (compiled with PostgreSQL support) to output a
postgis raster query.
4) And my favorite which is the one I use for documenting the PostGIS user
docs like for example this picture is to output it to a file or memory
stream using your favorite language
http://www.postgis.org/documentation/manual-svn/RT_ST_Rescale.html
An example of the ad hoc tool I built is here
http://www.bostongis.com/blog/index.php?/archives/174-Minimalist-Web-based-A
SP.NET-PostGIS-2.0-Spatial-GeometryRaster-Viewer.html (code is downloadable
and free to use if you want ot play with it)
It's a pretty short script that utilizes the raster output functions to
output the query results to a browser response stream
http://www.postgis.org/documentation/manual-svn/RT_reference.html#Raster_Out
puts
The approach is ideal if you need tight integration with your own custom
app. It will work just as well with any language or report write capable of
consuming file streams or a memory stream of a file e.g (Java using plain
vanilall JDBC driver, .NET both desktop and web, PHP, Perl etc.)
Thanks,
Regina
http://www.postgis.us
-----Original Message-----
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of Stephen
Crawford
Sent: Tuesday, December 20, 2011 1:47 PM
To: PostGIS Users Discussion
Subject: [postgis-users] raster output
Raster newbie question: How do I create an image from raster data I have in
a postGIS raster db? For example I have some rainfall data
(inches) and would like to make a classified map, perhaps 5 classes.
Thanks,
Steve
--
Stephen Crawford
Center for Environmental Informatics
The Pennsylvania State University
_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users
More information about the postgis-users
mailing list