Skip to content

Commit c6915f7

Browse files
committed
rotate() will use "angle % 360"
1 parent 05a6010 commit c6915f7

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Tests/test_file_pcd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@ def test_rotated(orientation: int) -> None:
3535

3636
with Image.open("Tests/images/hopper.pcd") as expected:
3737
assert_image_equal(
38-
im, expected.rotate(90 if orientation == 1 else -90, expand=True)
38+
im, expected.rotate(90 if orientation == 1 else 270, expand=True)
3939
)

src/PIL/PcdImagePlugin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def _open(self) -> None:
4343
if orientation == 1:
4444
self.tile_post_rotate = 90
4545
elif orientation == 3:
46-
self.tile_post_rotate = -90
46+
self.tile_post_rotate = 270
4747

4848
self._mode = "RGB"
4949
self._size = (512, 768) if orientation in (1, 3) else (768, 512)

0 commit comments

Comments
 (0)