Skip to content

Commit

Permalink
Merge pull request #114 from makermelissa/master
Browse files Browse the repository at this point in the history
Update examples to work with Pillow 10.0.0
  • Loading branch information
makermelissa authored Jul 5, 2023
2 parents 3a313a3 + 0603368 commit 94b0a9a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/rgb_display_pillow_animated_gif.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ def preload(self):
frame_object.image = ImageOps.pad( # pylint: disable=no-member
image.convert("RGB"),
(self._width, self._height),
method=Image.Resampling.NEAREST,
method=Image.NEAREST,
color=(0, 0, 0),
centering=(0.5, 0.5),
)
Expand Down
2 changes: 1 addition & 1 deletion examples/rgb_display_pillow_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
else:
scaled_width = width
scaled_height = image.height * width // image.width
image = image.resize((scaled_width, scaled_height), Image.Resampling.BICUBIC)
image = image.resize((scaled_width, scaled_height), Image.BICUBIC)

# Crop and center the image
x = scaled_width // 2 - width // 2
Expand Down

0 comments on commit 94b0a9a

Please sign in to comment.