| TerraLib 4.1

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

- File List
- File Members

E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/image_processing/TePDIContrast.hpp
Go to the documentation of this file.

    00001 /*
    00002 TerraLib - a library for developing GIS applications.
    00003 Copyright  2001, 2002, 2003 INPE and Tecgraf/PUC-Rio.
    00004
    00005 This code is part of the TerraLib library.
    00006 This library is free software; you can redistribute it and/or
    00007 modify it under the terms of the GNU Lesser General Public
    00008 License as published by the Free Software Foundation; either
    00009 version 2.1 of the License, or (at your option) any later version.
    00010
    00011 You should have received a copy of the GNU Lesser General Public
    00012 License along with this library.
    00013
    00014 The authors reassure the license terms regarding the warranties.
    00015 They specifically disclaim any warranties, including, but not limited to,
    00016 the implied warranties of merchantability and fitness for a particular
    00017 purpose. The library provided hereunder is on an "as is" basis, and the
    00018 authors have no obligation to provide maintenance, support, updates,
    00019 enhancements, or modifications.
    00020 In no event shall INPE be held liable to any party
    00021 for direct, indirect, special, incidental, or consequential damages arising
    00022 out of the use of this library and its documentation.
    00023 */
    00024
    00025 #ifndef TEPDICONTRAST_HPP
    00026   #define TEPDICONTRAST_HPP
    00027
    00028   #include "TePDIAlgorithm.hpp"
    00029   #include "TePDIRgbPalette.hpp"
    00030   #include "TePDITypes.hpp"
    00031   #include "../kernel/TeSharedPtr.h"
    00032   #include "TePDIHistogram.hpp"
    00033
    00131   class PDI_DLL TePDIContrast : public TePDIAlgorithm {
    00132     public :
    00133
    00137       enum TePDIContrastType{
    00140         TePDIContrastMinMax = 1,
    00142         TePDIContrastLinear = 2,
    00144         TePDIContrastSquareRoot = 3,
    00146         TePDIContrastSquare = 4,
    00148         TePDIContrastLog = 5,
    00150         TePDIContrastNegative = 6,
    00152         TePDIContrastHistEqualizer = 7,
    00155         TePDIContrastSimpleSlicer = 8,
    00157         TePDIContrastStat = 9
    00158       };
    00159
    00164       TePDIContrast();
    00165
    00169       ~TePDIContrast();
    00170
    00180       bool CheckParameters( const TePDIParameters& parameters ) const;
    00181
    00182     protected :
    00183
    00187       TePDIHistogram::pointer histo_ptr_;
    00188
    00194       bool RunImplementation();
    00195
    00201       void ResetState( const TePDIParameters& params );
    00202
    00211       TePDITypes::TePDILutType GetMinMaxLut(
    00212         double channel_min_level, double channel_max_level,
    00213         TePDITypes::TePDILutType& base_lut );
    00214
    00225       TePDITypes::TePDILutType GetLinearLut(
    00226         TePDITypes::TePDILutType& base_lut,
    00227         double min, double max,
    00228         double channel_min_level, double channel_max_level );
    00229
    00240       TePDITypes::TePDILutType GetSquareRootLut(
    00241         TePDITypes::TePDILutType& base_lut,
    00242         double min, double max,
    00243         double channel_min_level, double channel_max_level );
    00244
    00255       TePDITypes::TePDILutType GetSquareLut(
    00256         TePDITypes::TePDILutType& base_lut,
    00257         double min, double max,
    00258         double channel_min_level, double channel_max_level );
    00259
    00270       TePDITypes::TePDILutType GetLogLut(
    00271         TePDITypes::TePDILutType& base_lut,
    00272         double min, double max,
    00273         double channel_min_level, double channel_max_level );
    00274
    00285       TePDITypes::TePDILutType GetNegativeLut(
    00286         TePDITypes::TePDILutType& base_lut,
    00287         double min, double max,
    00288         double channel_min_level, double channel_max_level );
    00289
    00298       TePDITypes::TePDILutType GetHistEqualizerLut(
    00299         TePDIHistogram::pointer hist,
    00300         double channel_min_level, double channel_max_level );
    00301
    00311       void GetSimpleSlicerLut(
    00312         TePDIHistogram::pointer hist,
    00313         TePDIRgbPalette::pointer in_palette,
    00314         double min,
    00315         double max,
    00316         TePDITypes::TePDILutType& out_lut );
    00317
    00328       void GetStatLut( TePDIHistogram::pointer hist, double target_mean,
    00329         double target_variance, double channel_min_level,
    00330         double channel_max_level, TePDITypes::TePDILutType& out_lut );
    00331
    00348       bool RemapLevels(
    00349         TePDITypes::TePDIRasterPtrType& inRaster,
    00350         TePDITypes::TePDILutType& lut,
    00351         int in_channel,
    00352         int out_channel,
    00353         TePDITypes::TePDIRasterPtrType& outRaster,
    00354         bool use_dummy, double dummy_value,
    00355         bool fixed_step_lut );
    00356
    00374       bool FullRangeLutRemapLevels(
    00375         TePDITypes::TePDIRasterPtrType& inRaster,
    00376         TePDITypes::TePDILutType& lut,
    00377         int in_channel,
    00378         int out_channel,
    00379         TePDITypes::TePDIRasterPtrType& outRaster,
    00380         bool use_dummy, double dummy_value );
    00381
    00391       bool getHistogram( TePDIHistogram::pointer& hist, bool useDummy,
    00392         double dummyValue );
    00393
    00409       bool getBaseLut( TePDITypes::TePDILutType& lut, bool& hist_based_lut,
    00410         bool useDummy, double dummyValue );
    00411   };
    00412
    00417 #endif //TEPDICONTRAST_HPP

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines