Files
blozi-etag/tools/scripts/image2hex.py
2022-06-26 01:54:00 +08:00

11 lines
327 B
Python

from PIL.Image import Dither # noqa
from tools.utils import image2hex, load_test_image
if __name__ == '__main__':
# print(image2hex(load_test_image('test-01.bmp')))
print(image2hex(load_test_image('mao.bmp'), dither=Dither.FLOYDSTEINBERG))
print(image2hex(load_test_image('car-sign.png'), dither=Dither.NONE))