-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Closed
Labels
BugAny unexpected behavior, until confirmed feature.Any unexpected behavior, until confirmed feature.
Description
What did you do?
Open a 16-bit grayscale png and access its mode flag.
What did you expect to happen?
im.mode == 'I;16'
What actually happened?
im.mode == 'I'
What are your OS, Python and Pillow versions?
- OS: Ubuntu 18.04.2 LTS (Linux 4.15.0-47)
- Python: 3.6.7
- Pillow: 6.0.0
import numpy as np
from PIL import Image
ar = np.ones((32, 32), dtype=np.uint16)
im = Image.fromarray(ar)
im.save('foo.png')
im = Image.open('foo.png')
assert im.mode == 'I;16'> file foo.png
foo.png: PNG image data, 32 x 32, 16-bit grayscale, non-interlacedabusque, wang2bo2, wwarriner, xtofl, johnthagen and 4 more
Metadata
Metadata
Assignees
Labels
BugAny unexpected behavior, until confirmed feature.Any unexpected behavior, until confirmed feature.
Type
Projects
Status
Closed