mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-03-23 19:44:13 +03:00
Set SMaskInData to 1 for PDFs with alpha
This commit is contained in:
parent
95257dff87
commit
bc11b2d6a9
|
@ -164,6 +164,7 @@ def _save(im, fp, filename, save_all=False):
|
||||||
# params = f"<< /Predictor 15 /Columns {width-2} >>"
|
# params = f"<< /Predictor 15 /Columns {width-2} >>"
|
||||||
colorspace = PdfParser.PdfName("DeviceGray")
|
colorspace = PdfParser.PdfName("DeviceGray")
|
||||||
procset = "ImageB" # grayscale
|
procset = "ImageB" # grayscale
|
||||||
|
dict_obj["SMaskInData"] = 1
|
||||||
elif im.mode == "P":
|
elif im.mode == "P":
|
||||||
filter = "ASCIIHexDecode"
|
filter = "ASCIIHexDecode"
|
||||||
palette = im.getpalette()
|
palette = im.getpalette()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user