Kozea / CairoSVG

Convert your vector images
https://courtbouillon.org/cairosvg
GNU Lesser General Public License v3.0
754 stars 149 forks source link

Wrong svg to png conversion after latest update #391

Open faisalakhlaq opened 1 year ago

faisalakhlaq commented 1 year ago

In the latest updates when an SVG is converted to png the output does not come as expected (the colors are lost). I believe its because of the change in the cairosvg/image.py file where a check is added to convert "CMYK" to "RGB".

82        if image.mode == "CMYK":
83            image = image.convert("RGB")

Can I ask what is this doing. Maybe there is a problem while converting CMYK to RGB. Sorry I am not providing the files but I found the error after updating and then rolled back to the previous version.

liZe commented 1 year ago

Hi!

Could you please provide a CMYK image that would help us to reproduce the problem?