All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Functions.h File Reference

Raster Processing functions. More...

#include "Config.h"
#include "Matrix.h"
#include "Macros.h"
#include "../dataaccess/datasource/DataSource.h"
#include "../raster/Raster.h"
#include "../raster/RasterFactory.h"
#include "../raster/Grid.h"
#include "../raster/BandProperty.h"
#include "../raster/Utils.h"
#include <memory>
#include <map>
#include <vector>
#include <string>
#include <limits>
#include <boost/numeric/ublas/matrix.hpp>

Go to the source code of this file.

Namespaces

 te
 URI C++ Library.
 
 te::rp
 Namespace for Raster Processing module of TerraLib.
 
 te::rst
 Namespace for the Raster module of TerraLib.
 

Functions

void te::rp::Convert2DoublesVector (void *inputVector, const int inputVectorDataType, unsigned int inputVectorSize, double *outputVector)
 Convert vector elements. More...
 
void te::rp::ConvertDoublesVector (double *inputVector, unsigned int inputVectorSize, const int outputVectorDataType, void *outputVector)
 Convert a doubles vector. More...
 
bool te::rp::ConvertIHS2RGB (const te::rst::Raster &inputIHSRaster, const unsigned int intensityBandIdx, const unsigned int hueBandIdx, const unsigned int saturationBandIdx, const double rgbRangeMin, const double rgbRangeMax, te::rst::Raster &outputRGBRaster)
 IHS to RGB conversion. More...
 
bool te::rp::ConvertRGB2IHS (const te::rst::Raster &inputRGBRaster, const unsigned int redBandIdx, const unsigned int greenBandIdx, const unsigned int blueBandIdx, const double rgbRangeMin, const double rgbRangeMax, te::rst::Raster &outputIHSRaster)
 RGB to IHS conversion. More...
 
bool TERPEXPORT te::rp::Copy2DiskRaster (const te::rst::Raster &inputRaster, const std::string &fileName)
 Create a new raster into a GDAL datasource. More...
 
bool te::rp::CreateNewGdalRaster (const te::rst::Grid &rasterGrid, std::vector< te::rst::BandProperty * > bandsProperties, const std::string &fileName, RasterHandler &outRasterHandler)
 Create a new raster into a GDAL datasource. More...
 
bool te::rp::CreateNewMemRaster (const te::rst::Grid &rasterGrid, std::vector< te::rst::BandProperty * > bandsProperties, RasterHandler &outRasterHandler)
 Create a new raster into a new memory datasource. More...
 
bool te::rp::CreateNewRaster (const te::rst::Grid &rasterGrid, const std::vector< te::rst::BandProperty * > &bandsProperties, const std::string &outDataSetName, const std::string &dataSourceType, RasterHandler &outRasterHandler)
 Create a new raster into the givem data source. More...
 
bool te::rp::CreateNewRaster (const te::rst::Grid &rasterGrid, const std::vector< te::rst::BandProperty * > &bandsProperties, const std::string &outDataSetName, te::da::DataSource &outDataSource, RasterHandler &outRasterHandler)
 Create a new raster into the givem data source. More...
 
template<typename MatrixElementT >
bool te::rp::CreateRasterFileFromMatrix (const te::rp::Matrix< MatrixElementT > &matrix, const bool normalize, const std::string &fileName)
 Create a tiff file from a matrix. More...
 
bool te::rp::DirectPrincipalComponents (const te::rst::Raster &inputRaster, const std::vector< unsigned int > &inputRasterBands, boost::numeric::ublas::matrix< double > &pcaMatrix, te::rst::Raster &pcaRaster, const unsigned int maxThreads)
 Generate all principal components from the given input raster. More...
 
std::vector< std::string > te::rp::GetBandNames ()
 Returns a vector os with band's names. More...
 
bool te::rp::GetCovarianceValue (const te::rst::Band &band1, const te::rst::Band &band2, const unsigned int maxThreads, double const *const mean1ValuePtr, double const *const mean2ValuePtr, double &covarianceValue)
 Get the covariance of band pixel values. More...
 
void TERPEXPORT te::rp::GetDataTypeRange (const int dataType, double &min, double &max)
 Returns the real data type range (all values that can be represented by the given data type). More...
 
std::pair< double, double > te::rp::GetDigitalNumberBandInfo (std::string bandName)
 Returns the maximun and minimum digital numbers of a given sensor/band. More...
 
double te::rp::GetDigitalNumberBandMax (std::string bandName)
 Returns the maximum digital number of a given sensor/band. More...
 
bool te::rp::GetMeanValue (const te::rst::Band &band, const unsigned int maxThreads, double &meanValue)
 Get the mean of band pixel values. More...
 
std::vector< te::gm::Point * > te::rp::GetRandomPointsInRaster (const te::rst::Raster &inputRaster, unsigned int numberOfPoints=1000)
 Creates a vector of random positions (points) inside the raster. More...
 
std::pair< double, double > te::rp::GetSpectralBandInfo (std::string bandName)
 Returns the maximun and minimum reflectance values of a given sensor/band. More...
 
double te::rp::GetSpectralBandMax (std::string bandName)
 Returns the maximum reflectance value of a given sensor/band. More...
 
double te::rp::GetSpectralBandMin (std::string bandName)
 Returns the minimum reflectance value of a given sensor/band. More...
 
bool te::rp::GetStdDevValue (const te::rst::Band &band, const unsigned int maxThreads, double const *const meanValuePtr, double &stdDevValue)
 Get the standard deviation of band pixel values. More...
 
bool te::rp::InversePrincipalComponents (const te::rst::Raster &pcaRaster, const boost::numeric::ublas::matrix< double > &pcaMatrix, te::rst::Raster &outputRaster, const unsigned int maxThreads)
 Regenerate the original raster from its principal components. More...
 
bool te::rp::NormalizeRaster (te::rst::Raster &inputRaster, double nmin=0.0, double nmax=255.0)
 Normalizes one raster in a given interval. More...
 
bool te::rp::RemapValues (const te::rst::Raster &inputRaster, const std::vector< unsigned int > &inputRasterBands, const boost::numeric::ublas::matrix< double > &remapMatrix, te::rst::Raster &outputRaster, const unsigned int maxThreads)
 Remap pixel values using a remap function matrix. More...
 

Detailed Description

Raster Processing functions.

Definition in file Functions.h.