mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 01:46:18 +03:00
self.mode = "BGRA" wasn't correct and captured by #affa059
This commit is contained in:
parent
919f38e3d9
commit
3fbc9eb229
Binary file not shown.
Before Width: | Height: | Size: 1.6 KiB |
Binary file not shown.
Before Width: | Height: | Size: 270 B |
|
@ -22,7 +22,8 @@ def test_load_blp2_dxt1a():
|
|||
|
||||
def test_load_blp1():
|
||||
with Image.open("Tests/images/blp/war3mapMap.blp") as im:
|
||||
im.convert("RGB")
|
||||
png = im.copy()
|
||||
png.save(fp="Tests/images/blp/war3mapMap.png")
|
||||
assert_image_equal_tofile(im, "Tests/images/blp/war3mapMap.png")
|
||||
|
||||
|
||||
|
|
|
@ -245,7 +245,7 @@ class BlpImageFile(ImageFile.ImageFile):
|
|||
|
||||
if self.magic == b"BLP1":
|
||||
decoder = "BLP1"
|
||||
self.mode = "BGRA"
|
||||
self.mode = "RGBA"
|
||||
elif self.magic == b"BLP2":
|
||||
decoder = "BLP2"
|
||||
self.mode = "RGBA" if self._blp_alpha_depth else "RGB"
|
||||
|
|
Loading…
Reference in New Issue
Block a user