Dithering
- Reduce the number of colors used in an image
- Decrease the size of image file
- Use a limited colors to show the image on a device
Three type of input:
Matrix
Such as:
| 2x2 Matrix |
4x4 Martix |
0 2
3 1 |
0 8 2 10
12 4 14 6
3 11 1 9
15 7 13 5 |
Level
Lower level will use lesser color to represent the image
Higher level will use more color to represent the image
- L1 ~21 = remap image pixels in 0..255 into 0..1 range (256/2)
- L2 ~22 = remap image pixels in 0..255 into 0..3 range (256/4)
- L3 ~23 = remap image pixels in 0..255 into 0..7 range (256/8)
- L4 ~24 = remap image pixels in 0..255 into 0..15 range (256/16)
- L5 ~25 = remap image pixels in 0..255 into 0..31 range (256/32)
- L6 ~26 = remap image pixels in 0..255 into 0..63 range (256/64)
- L7 ~27 = remap image pixels in 0..255 into 0..127 range (256/128)
- L8 ~28 = remap image pixels in 0..255 into 0..255 range (256/256)
Color Dither
Yes = color image
-Calculate each pixel for the image and process dithering
No = grey image
-Change the image to grey image then process dithering