Background

In early 2007, efforts were made to reintroduce some basic contrast enhancement and begin refactoring the largely monolithic QgsRasterLayer class. Efforts to modify the core raster functionality began in earnest with creation of the RasterTransparencyBranch. In June of 2007 an IRC meeting was held to discuss some potential future directions for how the core raster functionality should work, the outline for this discussion as captured on the RasterRefactorRfc page.

There are numerous directions that raster development can go and a great number of features that are desired (e.g., chained filters, integration with OSSIM). Discussions throughout 2007 largely ended with a general consensus of keeping the number of dependencies to a minimum and to focus on a smaller set of functionality that would be rock solid for the upcoming release of version 1.0.

This page is largely going to focus on the needs for getting the core raster functionality ready for version 1.0. A section at the end will be provided for large scale changes and functionality that would be desired in a future major release (i.e., version 2.0)

Branches Related To Raster Development

  • gdalogr-capi-branch [no longer active]
  • RasterTransparencyBranch [no longer active]

ToDo List

General

  • Switch from GDAL C++ API back to the C API due to Windows platform limitations (./)
  • Performance improvements
  • Improve self checking in all QgsRasterLayer methods and classes
    • Segfault protection at the start of each method - is the raster band valid (need mostly superceded by C API which does this checking)
    • Verify all internal variables are initialized properly and in the proper order
    • Is the method appropriate for the data type - e.g., raster band stats should not be generated for wms
  • Remove all QT3 support
  • Migrate to using GDALGetRasterStatistics() and let GDAL keep it in an .aux.xml file, consider allowing approximate stats. (FrankW willing to take this task)
  • Display palleted images as single band with color map rather than faux three band

GUI

  • Neaten up raster properties UI (in progress)
  • Fix current transparency slider (./)
  • Update histogram tab
  • Hide Custom Color map until needed rather than just disabling
  • Verify GUI features properly enabled/disabled depending on image type and display method

Python Specific

  • Make identify method in QgsRasterLayer python friendly or create an alternative method/wrapper

Refactoring

  • Create independent histogram class
    • Implement more dynamic and informative browsing of histogram table
    • Allow min max values to be set from histogram

Transparency Class

  • Fully implement getting transparency level from another band in the current layer
  • Fully implement getting transparency level from another band in a different layer
  • Add ability to use simple logical expressions in place of absolute pixel values

Shader Class

  • More user-defined color pallet/lookup options
  • Ability to save custom ramp

Wish List & Looking Toward Version 2

The list below is intended to provide a set of features and future direction that are beyond what is deemed necessary and possible for getting a stable raster core ready for version 1.0. Please contribute your ideas (be as descriptive as possible).

  • Evaluate integration with OSSIM - initial testing should be done as plugins
  • Windowed access to raster data for filtering and analysis
  • Chained filters