mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-09-24 13:07:00 +03:00
rotate() will use "angle % 360"
This commit is contained in:
parent
05a6010311
commit
c6915f717f
|
@ -35,5 +35,5 @@ def test_rotated(orientation: int) -> None:
|
|||
|
||||
with Image.open("Tests/images/hopper.pcd") as expected:
|
||||
assert_image_equal(
|
||||
im, expected.rotate(90 if orientation == 1 else -90, expand=True)
|
||||
im, expected.rotate(90 if orientation == 1 else 270, expand=True)
|
||||
)
|
||||
|
|
|
@ -43,7 +43,7 @@ class PcdImageFile(ImageFile.ImageFile):
|
|||
if orientation == 1:
|
||||
self.tile_post_rotate = 90
|
||||
elif orientation == 3:
|
||||
self.tile_post_rotate = -90
|
||||
self.tile_post_rotate = 270
|
||||
|
||||
self._mode = "RGB"
|
||||
self._size = (512, 768) if orientation in (1, 3) else (768, 512)
|
||||
|
|
Loading…
Reference in New Issue
Block a user