Added by jgarnett, last edited by Adrian Custer on Sep 15, 2008  (view change) show comment

Labels:

Enter labels to add to this page:
Wait Image 
Looking for a label? Just start typing.

The coverage module of the main library provides a way to build and use highly structured grids of numeric values such as imagery data, for instance GeoTIFF format files, or multi-dimensional matrix data, like that found in NetCDF format files.

The Coverage module in GeoTools

Within GeoTools, the coverage module exists below the main module and therefore a GeoTools GridCoverage is not a feature. (Actually, there is currently a trivial dependence on main but that will likely disappear in the future.)

Because GeoTools 'Coverage' objects are not 'Feature' objects, 'Coverage' objects do not conform to the 'Coverage' object from the ISO 19123 standard specification. GeoTools 'Coverage' objects emerged from an earlier specification published by the OpenGeospatial Consortium (OGC) called "Grid Coverage Services Implementation" (OGC 01-004). However, both the GeoAPI interfaces and the GeoTools code are slowly migrating to follow the ISO standard. It is expected that some day the GeoTools library will have real ISO coverages at which time GridCoverage instances may then become true ISO 'Coverage' objects.


You are here
<< >>

Current status, fall 2008

The coverage module, while readily usable and very powerful, does not yet provide the programmer with a trivial tool to access data directly from the common formats. As of September 2008, programmers who use the GeoTools library still need to write their own code to create the GridCoverage2D objects.

The standard way to access an external data source to create GeoTools GridCoverage instances currently requires creating several classes:

  • A javax.imageio.ImageReader class to access the data source and providing the methods to create:
    • a java.awt.image.RenderedImage
    • a javax.imageio.metadata.IIOMetadata instance defining both
      • the meaning of the numeric values in the RenderedImage and
      • the georeferencing parameters to geolocate the image
  • A builder of the GridCoverage2D which uses the above information to create an instance.

The first part of this section on the 'Coverage' module explains the concepts behind this work and the steps required to create a GridCoverage2D instance. It should eventually be possible to reduce the work currently required of programmers wishing to use this part of the library; today, this work is still required because there is no existing, standard way to define all the different kinds of metadata which may be required to build grid coverages.

Design based on Java image handling

The design of the coverage modules follows closely the design of image handling in Java. Java provides three major subsystems in their Java media API's which are used and extended in GeoTools.

Java provides the Image I/O system to access files with image content. This provides code to access many standard image formats.

Java also has the Java Advanced Imaging (JAI) system which provides a powerful approach for performing operations on images. Not only does JAI provide efficient code for performing lots of operations, but it creates a system through which a user can create chains of operations which can be applied repeatedly to an image or applied to a whole slew of images.

Finally, Java provides the JAI Image I/O system which combines the two other systems by treating image access as one of the JAI operations allowing for differed access and enabling the treatment of file access as a standard step in an operation chain. The module also provides access to additional file formats.

When combined, these subsystems provide immense power to the GeoTools coverage module but this dependency does require that programmers who wish to use and extend the module must learn to use these other Java modules. Programmers must also learn some complex mathematical ideas, at a minimum they should fully understand Affine Transforms, in order to work effectively with the coverage module. Affines are explained in all decent computer graphics textbooks and on many web sites.