mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 18:06:18 +03:00
Use f-string
Co-authored-by: Aarni Koskela <akx@iki.fi>
This commit is contained in:
parent
f1fef09d4a
commit
30eb41475d
|
@ -154,9 +154,7 @@ class DdsImageFile(ImageFile.ImageFile):
|
|||
self._mode = "RGB"
|
||||
mask_count = 3
|
||||
|
||||
masks = struct.unpack(
|
||||
"<" + str(mask_count) + "I", header.read(mask_count * 4)
|
||||
)
|
||||
masks = struct.unpack(f"<{mask_count}I", header.read(mask_count * 4))
|
||||
self.tile = [("dds_rgb", (0, 0) + self.size, 0, (bitcount, masks))]
|
||||
elif pfflags & DDPF_PALETTEINDEXED8:
|
||||
self._mode = "P"
|
||||
|
|
Loading…
Reference in New Issue
Block a user