[Top] [Up] [Prev] [Next] [Up] [Basic Concepts] [Demonstrations] [Functions] SDC Morphology Toolbox V1.1 15Jan02

mmgray - Convert a binary image into a gray-scale image.


Synopsis
y = mmgray( f, TYPE, k1 )
Input
f: Binary image (logical uint8).
TYPE: String. 'uint8' or 'uint16'. Default: "uint8".
k1: Non-negative integer. Default: Maximum pixel value allowed.
Output
y: Gray-scale (uint8 or uint16) image.
Description
mmgray converts a binary image into a gray-scale image of a specified data type. The value k1 is assigned to the 1 pixels of f, while the 0 pixels keep their value.
Examples
a=uint8([0 1 0 1]);
b=mmbinary(a)

b =
     0     1     0     1
c=mmgray(b)

c =
     0   255     0   255
d=mmgray(b,'uint8',100)

d =
     0   100     0   100
Equation

equation

See Also
mmbinary - Convert a gray-scale image into a binary image.
mmfreedom - Control automatic data type conversion.
mmis - Verify if a relationship among images is true or false.
mmthreshad - Threshold (adaptive).

[Top] [Up] [Prev] [Next] [Up] [Basic Concepts] [Demonstrations] [Functions] Valid XHTML 1.0!
Copyright (c) 1998-2002 by SDC Information Systems