Herror ::lut_trans (
    Hobject Image,
    Hobject *ImageResult,
    const HTuple &Lut
)
HImage HImage::LutTrans (
    const HTuple &Lut
) const
HImageArray HImageArray::LutTrans (
    const HTuple &Lut
) const

Transform an image with a gray-value look-up-table

::lut_trans transforms an image Image by using a gray value look-up-table Lut. This table acts as a transformation function.


Parameters

Image (input_object)
(multichannel-)image(-array) -> Hobject: HImage(Array) ( byte )
Image whose gray values are to be transformed.

ImageResult (output_object)
(multichannel-)image(-array) -> Hobject * : HImage(Array) ( byte )
Transformed image.

Lut (input_control)
integer-array -> HTuple.long
Table containing the transformation.


Example
/* To get the inverse of an image: */
Htuple  lut;
read_image(&Image,"wald1");
creat_tuple(&lut,256);
for (i=0; i<256; i++)
  set_i(lut,255-i,i);
T_lut_trans(Image,&Invers,lut);

Result

The operator ::lut_trans returns the value H_MSG_TRUE if the parameters are correct. Otherwise an exception is raised.


Module

Image filters



Copyright © 1996-2002 MVTec Software GmbH