eLynx SDK
v3.3.0 C++ image processing API reference |
00001 //============================================================================ 00002 // IImageMiscProcessing.h Image.Component package 00003 //============================================================================ 00004 // Usage : interface for misceallenous image processing 00005 // 00006 //---------------------------------------------------------------------------- 00007 // Copyright (C) 2007 by eLynx project 00008 // 00009 // This library is free software; you can redistribute it and/or 00010 // modify it under the terms of the GNU Library General Public 00011 // License as published by the Free Software Foundation; either 00012 // version 2 of the License, or (at your option) any later version. 00013 // 00014 // This library is distributed in the hope that it will be useful, 00015 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00017 // See the GNU Library General Public License for more details. 00018 //---------------------------------------------------------------------------- 00019 #ifndef __IImageMiscProcessing_h__ 00020 #define __IImageMiscProcessing_h__ 00021 00022 #include <boost/shared_ptr.hpp> 00023 00024 #include <elx/core/ProgressNotifier.h> 00025 #include <elx/math/Geometry.h> 00026 #include <elx/image/ImageLib.h> 00027 #include <elx/image/ImageImpl.h> 00028 00029 namespace eLynx { 00030 namespace Image { 00031 00032 // Forward declaration 00033 class AbstractImage; 00034 00036 enum EGradientMethod 00037 { 00038 GM_Linear, 00039 GM_Quadratic 00040 }; 00041 00043 enum EColorEmphasis 00044 { 00045 CE_R = 0x0, CE_G = 0x1, CE_B = 0x2, CE_L = 0x3, // for description do not use 00046 CE_RGB = CE_R + (CE_G<<2) + (CE_B<<4), 00047 CE_BGR = CE_B + (CE_G<<2) + (CE_R<<4), 00048 CE_GGG = CE_G + (CE_G<<2) + (CE_G<<4), 00049 CE_LLL = CE_L + (CE_L<<2) + (CE_L<<4), 00050 CE_BRR = CE_B + (CE_R<<2) + (CE_B<<4), 00051 CE_BBR = CE_B + (CE_B<<2) + (CE_R<<4), 00052 CE_Default = CE_RGB 00053 }; 00054 00056 enum EChannelSubstitution 00057 { 00058 CSM_Lab, // Substituting the b&w for the L channel in a Lab color image. 00059 CSM_LRGB, // Blending the b&w luminance layer in a RGB color image. 00060 CSM_HLS, // Substituting the luminance channel in HSL color. 00061 CSM_HSB // Substituting the brightness channel in HSB color. 00062 }; 00063 00067 ExportedByImage const char * elxToString(EGradientMethod iMethod); 00068 00072 00073 class ExportedByImage IImageMiscProcessing 00074 { 00075 public: 00076 virtual ~IImageMiscProcessing(); 00077 00089 virtual bool ApplyRotationalGradient(AbstractImage& ioImage, 00090 uint32 iXc, uint32 iYc, 00091 double iRadialShift, double iRotationalShift, bool ibInterpolation, 00092 uint32 iChannelMask, ProgressNotifier& iNotifier) const = 0; 00093 00104 virtual bool RemoveGradient(AbstractImage& ioImage, 00105 AbstractImage& oBackground, 00106 const Math::Point2iList& iPoints, EGradientMethod iMethod, 00107 uint32 iChannelMask, ProgressNotifier& iNotifier) const = 0; 00108 00109 virtual bool Debloom(AbstractImage& ioImage, 00110 uint32 iChannelMask, ProgressNotifier& iNotifier) const = 0; 00111 00112 virtual bool ApplyDigitalDevelopment(AbstractImage& ioImage, 00113 double iBackground, double iCrossOver, double iScale, 00114 double iVariance, EColorEmphasis iEmphasis, 00115 uint32 iChannelMask, ProgressNotifier& iNotifier) const = 0; 00116 /* 00128 virtual boost::shared_ptr<AbstractImage> ApplyChannelSubstitution( 00129 const AbstractImage& iHighResGrayImage, 00130 const AbstractImage& iLowResColorImage, 00131 EChannelSubstitution iSubstitution, 00132 double iBlendScalar, 00133 ProgressNotifier& iNotifier) const = 0; 00134 */ 00135 }; 00136 00137 } // namespace Image 00138 } // namespace eLynx 00139 00140 #endif // __IImageMiscProcessing_h__