Retinex.C File Reference

#include "Image/Retinex.H"
#include "Image/Image.H"
#include "Image/ImageSet.H"
#include "Image/MathOps.H"
#include "Image/PyramidOps.H"
#include "Image/Range.H"
#include "Image/ShapeOps.H"
#include "Util/Assert.H"
#include "Util/log.H"
#include "Util/safecopy.H"
#include <vector>
Include dependency graph for Retinex.C:

Go to the source code of this file.

Functions

template<class T >
static Image< T > retinexCompareNeighbors (const Image< T > &src, const Image< T > &radiance, const Point2D< int > shift, const T maxi, const Rectangle &bbox)
size_t retinexDepth (const Dims &dims)
 Get the recommended pyramid depth for the given input dims.
template<class T >
Image< T > intXYWithPad (const Image< T > &src, const bool padx, const bool pady)
template<class T >
ImageSet< T > buildPyrRetinexLog (const Image< T > &L, const size_t depth, const int niter, const Rectangle &outrect)
 Build a retinex pyramid of the given depth using niter iterations.
template ImageSet< float > buildPyrRetinexLog (const Image< float > &, size_t, int, const Rectangle &)

Detailed Description

Retinex color-correction algorithm

Definition in file Retinex.C.


Function Documentation

template<class T >
ImageSet<T> buildPyrRetinexLog ( const Image< T > &  L,
const size_t  depth,
const int  niter,
const Rectangle outrect 
) [inline]

Build a retinex pyramid of the given depth using niter iterations.

The input is expected to be in log scale, and the output will also be in log scale.

This implementation is based on "McCann99" algorithm described in

Brian Funt, Florian Ciurea, and John McCann "Retinex in Matlab," Proceedings of the IS&T/SID Eighth Color Imaging Conference: Color Science, Systems and Applications, 2000, pp 112-121

The paper and matlab code are published here:

http://www.cs.sfu.ca/~colour/publications/IST-2000/ http://www.cs.sfu.ca/~colour/publications/IST-2000/retinex_mccann99.m

Definition at line 167 of file Retinex.C.

References ASSERT, Rectangle::bottomO(), buildPyrLocalAvg2x2(), Image< T >::clear(), Image< T >::getBounds(), Image< T >::getDims(), Image< T >::getHeight(), Rectangle::getOverlap(), Image< T >::getWidth(), height, intXY(), Rectangle::left(), Range< T >::max(), NO_INIT, rangeOf(), Rectangle::rightO(), Rectangle::tlbrO(), and Rectangle::top().

Referenced by buildPyrRetinexLog().

size_t retinexDepth ( const Dims dims  ) 

Get the recommended pyramid depth for the given input dims.

Definition at line 115 of file Retinex.C.

References Dims::h(), and Dims::w().

Generated on Sun May 8 08:42:42 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3