Classes
contrib/tbl/vipl/vipl_threshold.h File Reference

set pixel to given value if above/below certain threshold More...

#include <vipl/filter/vipl_filter_2d.h>

Go to the source code of this file.

Classes

class  vipl_threshold< ImgIn, ImgOut, DataIn, DataOut, PixelItr >
 set pixel to given value if above/below certain threshold. More...

Detailed Description

set pixel to given value if above/below certain threshold

This image processing class is implemented using the vipl filters, which means that it can be used with any image class (IUE or not, TargetJr or not, vil or vil1 or not) of any pixel data type.

This class actually implements two threshold operations, namely the `classical' single threshold mapping where pixel values not larger than T are mapped to L, values larger than T to H; and the `clipping' operation where only pixel values below T are mapped to L, the others left unchanged.

For the first version, the constructor must be given three parameters: T, L and H. For the second version, two parameters: T and L. In the second situation, there clearly must be an implicit conversion from DataIn to DataOut. Note that this is not necessary in the first situation, because all output pixels will be either L or H.

Note that the input image data type must support "operator<=()"; thus thresholding of colour images makes no sense (unless you define a sensible "<=" for RGB triples).

Author:
Peter Vanroose, K.U.Leuven (ESAT/PSI)
Date:
15 November 1997.
   Modifications:
     Terry Boult - Dec. 1997 - made various mods for newgen and IUE consistency
     Peter Vanroose, Aug.2000 - adapted to vxl
   

Definition in file vipl_threshold.h.