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

Background of transparent png always black when exporting #562

Open
fabb opened this issue Jul 9, 2021 · 4 comments
Open

Background of transparent png always black when exporting #562

fabb opened this issue Jul 9, 2021 · 4 comments

Comments

@fabb
Copy link

fabb commented Jul 9, 2021

When loading a png file with transparency and exporting it as jpg, the transparent areas turn black. It would be nice if the color could be selected (for my use case I would need white).

CC905213-55C2-4029-8D0B-8366534968A1

@targos
Copy link
Member

targos commented Jul 9, 2021

See #485 (comment) for a workaround.

@fabb
Copy link
Author

fabb commented Jul 9, 2021

Hm, couldn‘t that be a problem when i don‘t know if i load a jpg or a png?

I would suggest to add an option to color the canvas area before loading the image into the canvas.

@targos
Copy link
Member

targos commented Jul 9, 2021

couldn‘t that be a problem when i don‘t know if i load a jpg or a png?

Maybe you can put it behind a if(image.alpha) ?

I would suggest to add an option to color the canvas area before loading the image into the canvas.

This is not an easy option to add, because we don't create the array that holds the data. It comes directly from the decoder libraries.

@fabb
Copy link
Author

fabb commented Jul 9, 2021

Maybe you can put it behind a if(image.alpha) ?

thanks, I‘ll try that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants