Image Processing Toolbox User's Guide |
Compute new values of A
based on lookup table LUT
Note
uintlut is an obsolete version of intlut and may be removed in a future version of the toolbox.
|
Syntax
Purpose
B = uintlut(A,LUT)
creates an array B
containing new values of A
based on the lookup table LUT
. For example, if A
is a vector whose kth element is equal to alpha
, then B(k)
is equal to the LUT
value corresponding to alpha
, that is, LUT(alpha+1)
.
Class Support
A
must be uint8
or uint16
. If A
is uint8, then LUT
must be a uint8
vector with 256 elements. If A
is uint16
, then LUT
must be a uint16
vector with 65536 elements. B
has the same size and class as A
.
Example
A = uint8([1 2 3 4; 5 6 7 8;9 10 11 12]); LUT = repmat(uint8([0 150 200 255]),1,64); B = uintlut(A,LUT); imshow(A), figure, imshow(B);
See Also
uint8 | warp |
© 1994-2005 The MathWorks, Inc.