[Image-SIG] Result of testing convert
Edward C. Jones
edcjones@erols.com
Wed, 25 Dec 2002 11:00:09 -0500
Conversions to mode "1" are often buggy because of problems with the
internal representation of mode "1". The expression
Image.new("1", (1,1), 255).getpixel((0,0))
returns 255. I use Gentoo Linux 1.3 on a PC with gcc 2.95.3.
mode "1", value 0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "1", value 1 to mode
"1" 1
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
--------------------------------
mode "L", value 0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "L", value 255 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
--------------------------------
mode "RGB", value (0, 0, 0) to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (255, 255, 255, 0)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "RGB", value (255, 255, 255) to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
--------------------------------
mode "RGBA", value (0, 0, 0, 0) to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 0)
"RGBX" (0, 0, 0, 255)
"CMYK" (255, 255, 255, 0)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "RGBA", value (255, 255, 255, 255) to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
--------------------------------
mode "RGBX", value (0, 0, 0, 0) to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 0)
"CMYK" (255, 255, 255, 0)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "RGBX", value (255, 255, 255, 255) to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
--------------------------------
mode "CMYK", value (0, 0, 0, 0) to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 255
"F" 255.0
mode "CMYK", value (255, 255, 255, 255) to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (255, 255, 255, 255)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
--------------------------------
mode "YCbCr", value (0, 0, 0, 0) to mode
"1" 0
"L" 0
"RGB" (0, 135, 0)
"RGBA" (0, 135, 0, 255)
"RGBX" (0, 135, 0, 255)
"CMYK" (255, 120, 255, 0)
"YCbCr" (0, 0, 0)
"I" 79
"F" 79.2450027466
mode "YCbCr", value (255, 255, 255, 255) to mode
"1" 255
"L" 255
"RGB" (255, 120, 255)
"RGBA" (255, 120, 255, 255)
"RGBX" (255, 120, 255, 255)
"CMYK" (0, 135, 0, 0)
"YCbCr" (255, 255, 255)
"I" 175
"F" 175.755004883
--------------------------------
mode "I", value -1024 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -1024
"F" -1024.0
mode "I", value -64 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -64
"F" -64.0
mode "I", value 0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "I", value 64 to mode
"1" 0
"L" 64
"RGB" (64, 64, 64)
"RGBA" (64, 64, 64, 255)
"RGBX" (64, 64, 64, 255)
"CMYK" (0, 0, 0, 191)
"YCbCr" (64, 128, 128)
"I" 64
"F" 64.0
mode "I", value 1024 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 1024
"F" 1024.0
--------------------------------
mode "F", value -1e+15 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -2147483648
"F" -9.99999986991e+14
mode "F", value -100000.0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -100000
"F" -100000.0
mode "F", value -1024.0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -1024
"F" -1024.0
mode "F", value -64.0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" -64
"F" -64.0
mode "F", value 0.0 to mode
"1" 0
"L" 0
"RGB" (0, 0, 0)
"RGBA" (0, 0, 0, 255)
"RGBX" (0, 0, 0, 255)
"CMYK" (0, 0, 0, 255)
"YCbCr" (0, 128, 128)
"I" 0
"F" 0.0
mode "F", value 64.0 to mode
"1" 0
"L" 64
"RGB" (64, 64, 64)
"RGBA" (64, 64, 64, 255)
"RGBX" (64, 64, 64, 255)
"CMYK" (0, 0, 0, 191)
"YCbCr" (64, 128, 128)
"I" 64
"F" 64.0
mode "F", value 1024.0 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 1024
"F" 1024.0
mode "F", value 100000.0 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 100000
"F" 100000.0
mode "F", value 1073741824.0 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" 1073741824
"F" 1073741824.0
mode "F", value 8589934592.0 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" -2147483648
"F" 8589934592.0
mode "F", value 1e+15 to mode
"1" 255
"L" 255
"RGB" (255, 255, 255)
"RGBA" (255, 255, 255, 255)
"RGBX" (255, 255, 255, 255)
"CMYK" (0, 0, 0, 0)
"YCbCr" (255, 128, 128)
"I" -2147483648
"F" 9.99999986991e+14