A singleton for keeping raster summaries (most statistics). It stores an internal map of raster references and their respective summaries. More...
#include <RasterSummaryManager.h>
  
 Public Member Functions | |
| void | add (const Raster *raster, RasterSummary *summary) | 
| Adds a new entry in the summary manager.  More... | |
| const RasterSummary * | find (const Raster *raster) const | 
| It searches for a raster summary.  More... | |
| const RasterSummary * | get (const Raster *raster, const SummaryTypes st) | 
| It searches for a raster summary. If not found it creates the summary and returns it.  More... | |
| void | remove (const Raster *raster) | 
| Removes the summary from the specified raster.  More... | |
| ~RasterSummaryManager () | |
| Destructor.  More... | |
Static Public Member Functions | |
| static RasterSummaryManager & | getInstance () | 
| It returns a reference to the singleton instance.  More... | |
Protected Member Functions | |
| RasterSummaryManager () | |
| Constructor.  More... | |
Private Attributes | |
| boost::ptr_map< const Raster  *, RasterSummary >  | m_rasterSummaries | 
| A map of rasters and their respective summaries.  More... | |
Friends | |
| class | te::common::Singleton< RasterSummaryManager > | 
A singleton for keeping raster summaries (most statistics). It stores an internal map of raster references and their respective summaries.
Definition at line 56 of file RasterSummaryManager.h.
| te::rst::RasterSummaryManager::~RasterSummaryManager | ( | ) | 
Destructor.
Definition at line 133 of file RasterSummaryManager.cpp.
      
  | 
  protected | 
Constructor.
Definition at line 137 of file RasterSummaryManager.cpp.
| void te::rst::RasterSummaryManager::add | ( | const Raster * | raster, | 
| RasterSummary * | summary | ||
| ) | 
Adds a new entry in the summary manager.
| raster | The raster to be added. | 
| summary | The raster summary of the respective raster. The manager will take its ownership. | 
Definition at line 35 of file RasterSummaryManager.cpp.
References m_rasterSummaries.
| const te::rst::RasterSummary * te::rst::RasterSummaryManager::find | ( | const Raster * | raster | ) | const | 
It searches for a raster summary.
| raster | The raster to be found. | 
Definition at line 43 of file RasterSummaryManager.cpp.
| const te::rst::RasterSummary * te::rst::RasterSummaryManager::get | ( | const Raster * | raster, | 
| const SummaryTypes | st | ||
| ) | 
It searches for a raster summary. If not found it creates the summary and returns it.
| raster | The raster to be found. | 
| types | The desired types of summary to be calculated (min, max, ...). | 
Definition at line 56 of file RasterSummaryManager.cpp.
References te::rst::Raster::getBand(), te::rst::Band::getHistogramI(), te::rst::Band::getHistogramR(), te::rst::Band::getMaxValue(), te::rst::Band::getMeanValue(), te::rst::Band::getMinValue(), te::rst::Raster::getNumberOfBands(), te::rst::Band::getStdValue(), te::rst::BandSummary::m_histogramI, te::rst::BandSummary::m_histogramR, te::rst::BandSummary::m_maxVal, te::rst::BandSummary::m_meanVal, te::rst::BandSummary::m_minVal, te::rst::BandSummary::m_stdVal, te::rst::SUMMARY_I_HISTOGRAM, te::rst::SUMMARY_MAX, te::rst::SUMMARY_MEAN, te::rst::SUMMARY_MIN, te::rst::SUMMARY_R_HISTOGRAM, and te::rst::SUMMARY_STD.
      
  | 
  staticinherited | 
It returns a reference to the singleton instance.
Referenced by te::map::DrawRaster(), te::rp::Contrast::execHistogramEqualizationContrast(), te::rp::Contrast::execSetMeanAndStdContrast(), te::qt::widgets::HistogramDataWidget::HistogramDataWidget(), te::qt::widgets::ReadPixelTool::mouseReleaseEvent(), te::qt::widgets::ColorMapWidget::onBandSelected(), and te::qt::widgets::HistogramDataWidget::onPropertyComboBoxIndexChanged().
| void te::rst::RasterSummaryManager::remove | ( | const Raster * | raster | ) | 
Removes the summary from the specified raster.
| raster | The raster to remove the summary. | 
Definition at line 51 of file RasterSummaryManager.cpp.
      
  | 
  friend | 
Definition at line 58 of file RasterSummaryManager.h.
      
  | 
  private | 
A map of rasters and their respective summaries.
Definition at line 109 of file RasterSummaryManager.h.
Referenced by add().