| [mmlimits] [Up] [mmdatatype] | Image Information and Manipulation |
Implemented in Python.
| TYPE | String One of the strings 'uint8', 'uint16' or 'int32', specifying the image type Default:
|
| max | the maximum level value of type TYPE |
def mmmaxleveltype(TYPE='uint8'):
max = 0
if TYPE == 'uint8' : max=255
elif TYPE == 'binary' : max=1
elif TYPE == 'uint16' : max=65535
elif TYPE == 'int32' : max=2147483647
else:
assert 0, 'does not support this data type:'+TYPE
return max
| [mmlimits] [Up] [mmdatatype] | |
| Copyright (c) 2003, Roberto A. Lotufo, UNICAMP-University of Campinas; Rubens C. Machado, CenPRA-Renato Archer Research Center. |