Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added "transparency" argument to EpsImagePlugin load() #5620

Merged
merged 4 commits into from Aug 6, 2021

Conversation

radarhere
Copy link
Member

@radarhere radarhere commented Jul 18, 2021

Resolves #5619

At the moment, EpsImagePlugin can load images at different scales like so

with Image.open(FILE1) as image1_scale2:
image1_scale2.load(scale=2)

This PR adds another argument, "transparency",

with Image.open(FILE1) as image12: 
     image1.load(transparency=True)

to switch from "ppmraw"

"-sDEVICE=ppmraw", # ppm driver

to "pngalpha", generating an RGBA image with a transparent background, instead of an RGB image with a white background.

Copy link
Member

@hugovk hugovk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's also add this to release notes.

@hugovk hugovk added the automerge Automatically merge PRs that are ready label Aug 6, 2021
@mergify mergify bot merged commit 43785a3 into python-pillow:master Aug 6, 2021
@radarhere radarhere deleted the eps branch August 6, 2021 23:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Automatically merge PRs that are ready Enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

EPS files are loaded without transparency
2 participants