Chapter 7. Raster functions

 

This chapter covers

  • Constructor functions
  • Output functions
  • Raster band and pixel accessors and setters
  • Georeferencing functions
  • Reclassing functions
  • Polygonizing functions

The raster type is different in makeup from the geometry type covered in chapter 6. Geometries model an object as a set of linear equations, whereas rasters model an object as a tapestry of cells. In PostGIS, you’ll find the two types working together, leveraging each other’s strengths. For example, you can output a geometry in a raster file format such as PNG. You can also clip raster images with vector boundaries. We’ll touch on raster processing in this chapter, but we’ll leave the more thorough treatment for chapter 12, where we’ll demonstrate advanced raster-processing functions, such as raster aggregate functions, map algebra functions, and set-returning functions.

The PostGIS raster type only supports pixels, which are 2D cells on an X-Y grid. It can’t yet support voxels, which are pixels with more than two dimensions, but you can compensate by storing higher dimensional data as a band or using multiple rasters with the same coverage area. For example, if you have a raster with elevations and measurements, you can add two more bands: one to hold the Z value, and one to hold the M value.

As always, for the full breadth of raster functions, refer to the official documentation, “PostGIS raster functions reference”: http://postgis.net/docs/RT_reference.html.

7.1. Raster terminology

 
 

7.2. Raster constructors

 

7.3. Raster output functions

 
 
 

7.4. Raster accessors and setters

 
 

7.5. Georeferencing functions

 

7.6. Reclassing functions

 
 
 
 

7.7. Polygonizing functions

 
 
 

7.8. Summary

 
 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest