te::attributefill Namespace Reference

Classes

class  RasterToVector
 
class  RasterToVectorDialog
 
class  VectorToRaster
 
class  VectorToRasterDialog
 
class  VectorToVectorDialog
 
class  VectorToVectorMemory
 
class  VectorToVectorOp
 

Enumerations

enum  OperationType {
  VALUE, MIN_VALUE, MAX_VALUE, MEAN,
  SUM, COUNT, COUNT_DISTINCT, VALID_COUNT,
  STANDARD_DEVIATION, VARIANCE, SKEWNESS, KURTOSIS,
  AMPLITUDE, MEDIAN, VAR_COEFF, MODE,
  HIGHEST_OCCURRENCE, HIGHEST_INTERSECTION, PERCENT_CLASS, MIN_DISTANCE,
  MIN_DISTANCE_CENTROID, PRESENCE, WEIGHTED, WEIGHTED_SUM,
  PERCENT_EACH_CLASS, PERCENT_TOTAL_AREA
}
 Define grouping operations type. More...
 

Functions

TEATTRIBUTEFILLEXPORT std::pair< uint32_t, uint32_t > GeoToGrid (const te::gm::Coord2D &coord, const rst::Grid &grid)
 Convert the coordinate to the grid col/row postion of the pixel . More...
 
TEATTRIBUTEFILLEXPORT void GetMinMaxLineAndColumn (const te::rst::Raster &raster, const te::gm::Polygon &polygon, uint32_t &minimumRow, uint32_t &minimumColumn, uint32_t &maximumRow, uint32_t &maximumColumn)
 Gets the minimum and maximum row and column values of the raster based on polygon. More...
 
TEATTRIBUTEFILLEXPORT std::string GetOperationFullName (const int &e)
 Gets the full name of the operation as string. More...
 
TEATTRIBUTEFILLEXPORT void GetPercentOfEachClassByArea (const te::rst::Raster &raster, const unsigned int &band, const gm::Polygon &polygon, const uint32_t &minimumRow, const uint32_t &minimumColumn, const uint32_t &maximumRow, const uint32_t &maximumColumn, std::map< double, double > &percentOfEachClassByArea)
 Gets the pixel percentage for a specific band that intersects the polygon. More...
 
TEATTRIBUTEFILLEXPORT void GetValuesFromBand (const te::rst::Raster &raster, const unsigned int &band, const gm::Polygon &polygon, const uint32_t &minimumRow, const uint32_t &minimumColumn, const uint32_t &maximumRow, const uint32_t &maximumColumn, std::map< double, int > &values)
 Gets the pixel values for a specific band that intersects the polygon. More...
 

Enumeration Type Documentation

Define grouping operations type.

Enum that defines the operation type(Insert, Delete ...).

Enumerator
VALUE 
MIN_VALUE 
MAX_VALUE 
MEAN 
SUM 
COUNT 
COUNT_DISTINCT 
VALID_COUNT 
STANDARD_DEVIATION 
VARIANCE 
SKEWNESS 
KURTOSIS 
AMPLITUDE 
MEDIAN 
VAR_COEFF 
MODE 
HIGHEST_OCCURRENCE 
HIGHEST_INTERSECTION 
PERCENT_CLASS 
MIN_DISTANCE 
MIN_DISTANCE_CENTROID 
PRESENCE 
WEIGHTED 
WEIGHTED_SUM 
PERCENT_EACH_CLASS 
PERCENT_TOTAL_AREA 

Definition at line 39 of file Enums.h.

Function Documentation

TEATTRIBUTEFILLEXPORT std::pair<uint32_t, uint32_t> te::attributefill::GeoToGrid ( const te::gm::Coord2D coord,
const rst::Grid grid 
)

Convert the coordinate to the grid col/row postion of the pixel .

If the coordinate is outside the grid extent the function will return std::numeric_limits<uint32_t>::max for col and/or row the is outside. The other value is valid.

Returns
Pair of <col, row> of the pixel at the coord.
TEATTRIBUTEFILLEXPORT void te::attributefill::GetMinMaxLineAndColumn ( const te::rst::Raster raster,
const te::gm::Polygon polygon,
uint32_t &  minimumRow,
uint32_t &  minimumColumn,
uint32_t &  maximumRow,
uint32_t &  maximumColumn 
)

Gets the minimum and maximum row and column values of the raster based on polygon.

Parameters
rasterThe raster.
polygonThe polygon.
minimumRowMinimum value for row
minimumColumnMinimum value for column
maximumRowMaximum value for row
maximumColumnMaximum value for column
Returns
Fills the minimum and maximum values.
TEATTRIBUTEFILLEXPORT std::string te::attributefill::GetOperationFullName ( const int &  e)

Gets the full name of the operation as string.

Parameters
eThe enumerator.
Returns
The full name for the operation.
TEATTRIBUTEFILLEXPORT void te::attributefill::GetPercentOfEachClassByArea ( const te::rst::Raster raster,
const unsigned int &  band,
const gm::Polygon polygon,
const uint32_t &  minimumRow,
const uint32_t &  minimumColumn,
const uint32_t &  maximumRow,
const uint32_t &  maximumColumn,
std::map< double, double > &  percentOfEachClassByArea 
)

Gets the pixel percentage for a specific band that intersects the polygon.

The computation is based on the intersection of the pixel resolution and the polygon.

Parameters
rasterThe raster.
bandThe band.
polygonThe polygon.
minimumRowMinimum value for row
minimumColumnMinimum value for column
maximumRowMaximum value for row
maximumColumnMaximum value for column
percentOfEachClassByAreaA map<key, value> where the key will be filled with the pixel and the value with the percentage of occurence.
Returns
A map<key, value> of values that the key is the pixel and the value is the percentage of occurrence.
TEATTRIBUTEFILLEXPORT void te::attributefill::GetValuesFromBand ( const te::rst::Raster raster,
const unsigned int &  band,
const gm::Polygon polygon,
const uint32_t &  minimumRow,
const uint32_t &  minimumColumn,
const uint32_t &  maximumRow,
const uint32_t &  maximumColumn,
std::map< double, int > &  values 
)

Gets the pixel values for a specific band that intersects the polygon.

The computation is based on the intersection of the pixel resolution and the polygon.

Parameters
rasterThe raster.
bandThe band.
polygonThe polygon.
minimumRowMinimum value for row
minimumColumnMinimum value for column
maximumRowMaximum value for row
maximumColumnMaximum value for column
valuesA map<key, value> where the key will be filled with the pixel and the value with the number of occurrence.
Returns
A map<key, value> of values that the key is the pixel and the value is the number of occurrence.