mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 01:46:18 +03:00
Merge pull request #7555 from radarhere/pdf_palette
Correct PDF palette size when saving
This commit is contained in:
commit
b431e2c140
|
@ -96,7 +96,7 @@ def _write_image(im, filename, existing_pdf, image_refs):
|
||||||
dict_obj["ColorSpace"] = [
|
dict_obj["ColorSpace"] = [
|
||||||
PdfParser.PdfName("Indexed"),
|
PdfParser.PdfName("Indexed"),
|
||||||
PdfParser.PdfName("DeviceRGB"),
|
PdfParser.PdfName("DeviceRGB"),
|
||||||
255,
|
len(palette) // 3 - 1,
|
||||||
PdfParser.PdfBinary(palette),
|
PdfParser.PdfBinary(palette),
|
||||||
]
|
]
|
||||||
procset = "ImageI" # indexed color
|
procset = "ImageI" # indexed color
|
||||||
|
|
Loading…
Reference in New Issue
Block a user