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

Using ResizeToFill and ResizeToFit changes colors of JPEG #564

Open
rbosch opened this issue Jul 5, 2023 · 2 comments
Open

Using ResizeToFill and ResizeToFit changes colors of JPEG #564

rbosch opened this issue Jul 5, 2023 · 2 comments

Comments

@rbosch
Copy link

rbosch commented Jul 5, 2023

Great package!

I hope someone can help. Doing some very basic resizing. But for some JPG files there are color difference between the original and the resized image when using ResizeToFill and ResizeToFit.

test = ImageSpecField(
        source="filename",
        processors=[ResizeToFill(1024, 768)],
        format="JPEG",
        options={"quality": 100},
)

Is there any option I'm missing that would fix this?

Thx!

@vstoykov
Copy link
Collaborator

The resizing processors don't have information about changing colors. Only if you use ResizeToFit or ResizeCanvas you can pass color but this is for the background.

Can you give us a sample of original image and the resized image with changed colors to see what you mean?

@vstoykov
Copy link
Collaborator

@rbosch is the problem resolved. Can we close the issue?

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