| TerraLib 4.1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Examples

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes
TePDILevelRemap Class Reference
General purpose algorithms.

This is the base class for level remapping algorithms. More...

`#include <TePDILevelRemap.hpp>`

Inheritance diagram for TePDILevelRemap:

List of all members.

## Public Types

typedef TeSharedPtr < TePDILevelRemap > | pointer
typedef const TeSharedPtr < TePDILevelRemap > | const_pointer

## Public Member Functions

virtual | ~TePDILevelRemap ()
| Default Destructor.

## Protected Types

typedef double(* | remap_func_3_ptr_type )(double, double, double)
| A level remap function pointer ( 3 arguments ).
typedef double(* | remap_func_4_ptr_type )(double, double, double, double)
| A level remap function pointer ( 4 arguments ).

## Protected Member Functions

| TePDILevelRemap ()
| Default Constructor.
virtual void | ResetState (const TePDIParameters &params)
| Reset the internal state to the initial state.
bool | RemapLevels (TePDITypes::TePDIRasterPtrType &inRaster, remap_func_3_ptr_type remapp_func, int in_channel, int out_channel, double gain, double offset, bool normalize_output, TePDITypes::TePDIRasterPtrType &outRaster)
| Do level remapping from one raster to another.
bool | RemapLevels (TePDITypes::TePDIRasterPtrType &inRaster1, TePDITypes::TePDIRasterPtrType &inRaster2, remap_func_4_ptr_type remapp_func, int in_channel1, int in_channel2, int out_channel, double gain, double offset, bool normalize_output, TePDITypes::TePDIRasterPtrType &outRaster)
| Do level remapping from two input rasters to another.
void | BuildHistograms (TePDITypes::TePDIRasterPtrType &inRaster, unsigned int histo_levels, std::vector< int > &channels, bool force=false)
| Build level ordered histograms from the required raster channels.
TePDIHistogram::pointer | GetHistRef (TePDITypes::TePDIRasterPtrType &inRaster, unsigned int band)
| Returns the histogram reference stored inside the histogram cache.

## Protected Attributes

std::map< std::pair< TeRaster *, unsigned int > , TePDIHistogram::pointer > | histo_cache_
| A cache of level ordered histograms to avoid rebuilding histograms all the times.

## Detailed Description

This is the base class for level remapping algorithms.

Author:
  Emiliano F. Castejon <castejon@dpi.inpe.br>

## Member Typedef Documentation

typedef const TeSharedPtr< TePDILevelRemap > TePDILevelRemap::const_pointer

Type definition for a const algorithm instance pointer.

Reimplemented from TePDIAlgorithm.

typedef TeSharedPtr< TePDILevelRemap > TePDILevelRemap::pointer

Type definition for an algorithm instance pointer.

Reimplemented from TePDIAlgorithm.

typedef double(* TePDILevelRemap::remap_func_3_ptr_type)(double, double, double)`[protected]`

A level remap function pointer ( 3 arguments ).

Parameters:

  double | Level to be remapped.
  double | Gain.
  double | Offset.

Returns:
  The remapped level.

typedef double(* TePDILevelRemap::remap_func_4_ptr_type)(double, double, double, double)`[protected]`

A level remap function pointer ( 4 arguments ).

Parameters:

  double | Input Level 1 ( from image 1 ) to be remapped.
  double | Input Level 2 ( from image 2 ) to be remapped.
  double | Gain.
  double | Offset.

Returns:
  The remapped level.

## Constructor & Destructor Documentation

TePDILevelRemap::~TePDILevelRemap | ( |  | ) | `[virtual]`

Default Destructor.

TePDILevelRemap::TePDILevelRemap | ( |  | ) | `[protected]`

Default Constructor.

## Member Function Documentation

void TePDILevelRemap::BuildHistograms | ( | TePDITypes::TePDIRasterPtrType & | inRaster,
|  | unsigned int | histo_levels,
|  | std::vector< int > & | channels,
|  | bool | force = `false`
| ) |  | `[protected]`

Build level ordered histograms from the required raster channels.

Note:
  The result histograms will remain inside the protected object histo_cache_

Parameters:

  inRaster | The input Raster.
  histo_levels | Number of histogram interpolated levels.
  channels | Channels to use for histogram generation.
  force | Force histogram regeneratin even if already in cache.

TePDIHistogram::pointer TePDILevelRemap::GetHistRef | ( | TePDITypes::TePDIRasterPtrType & | inRaster,
|  | unsigned int | band
| ) |  | `[protected]`

Returns the histogram reference stored inside the histogram cache.

Note:
  The result histograms will remain inside the protected object histo_cache_

Parameters:

  inRaster | The input Raster.
  band | Band number.

Returns:
  The histogram reference.

bool TePDILevelRemap::RemapLevels | ( | TePDITypes::TePDIRasterPtrType & | inRaster,
|  | remap_func_3_ptr_type | remapp_func,
|  | int | in_channel,
|  | int | out_channel,
|  | double | gain,
|  | double | offset,
|  | bool | normalize_output,
|  | TePDITypes::TePDIRasterPtrType & | outRaster
| ) |  | `[protected]`

Do level remapping from one raster to another.

Parameters:

  inRaster | The input Raster.
  outRaster | The Output Raster.
  remapp_func | The level remapping function pointer.
  in_channel | in_raster channel to remap.
  out_channel | out_raster channel to write on.
  gain | Level Gain.
  offset | Level Offset.
  normalize_output | Do output normalization following the output raster channel allowed values range.

Returns:
  true if ok, false on errors.

bool TePDILevelRemap::RemapLevels | ( | TePDITypes::TePDIRasterPtrType & | inRaster1,
|  | TePDITypes::TePDIRasterPtrType & | inRaster2,
|  | remap_func_4_ptr_type | remapp_func,
|  | int | in_channel1,
|  | int | in_channel2,
|  | int | out_channel,
|  | double | gain,
|  | double | offset,
|  | bool | normalize_output,
|  | TePDITypes::TePDIRasterPtrType & | outRaster
| ) |  | `[protected]`

Do level remapping from two input rasters to another.

Parameters:

  inRaster1 | The input Raster 1.
  inRaster2 | The input Raster 2.
  outRaster | The Output Raster.
  remapp_func | The level remapping function pointer.
  in_channel1 | in_raster1 channel to remap.
  in_channel2 | in_raster2 channel to remap.
  out_channel | out_raster channel to write on.
  gain | Level Gain.
  offset | Level Offset.
  normalize_output | Do output normalization following the output raster channel allowed values range

Returns:
  true if ok, false on errors.

void TePDILevelRemap::ResetState | ( | const TePDIParameters & | params | ) | `[protected, virtual]`

Reset the internal state to the initial state.

Parameters:

  params | The new parameters referente at initial state.

Implements TePDIAlgorithm.

## Member Data Documentation

std::map< std::pair< TeRaster*, unsigned int >, TePDIHistogram::pointer > TePDILevelRemap::histo_cache_`[protected]`

A cache of level ordered histograms to avoid rebuilding histograms all the times.

Parameters:

  TeRaster | A raster naked pointer reference.
  unsigned | int Raster band.
  TePDIHistogram::pointer | A Histogram shared pointer reference.

The documentation for this class was generated from the following files:

- E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/image_processing/TePDILevelRemap.hpp
- E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/image_processing/TePDILevelRemap.cpp

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines