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

Color Changed When Resize #129

Open
vinh84 opened this issue Mar 9, 2017 · 5 comments
Open

Color Changed When Resize #129

vinh84 opened this issue Mar 9, 2017 · 5 comments

Comments

@vinh84
Copy link

vinh84 commented Mar 9, 2017

I don't know why :(

Upload image in Github, Gmail have the same issue
Resize on Imagesharp have the same issue

But when i try resize using net452, use system.drawing, image color is good, not changed, it is oke

ResizeOptions opt = new ResizeOptions();
opt.Mode = ResizeMode.Max;
opt.Size = size.Size;
image.Resize(opt).Save(outStream);

Original

image

GitHub

bug_612

bug_612.zip

Sori if my eng is not good

@JimBobSquarePants
Copy link
Member

I'm sorry I do not understand. What is wrong with the image?

@vinh84
Copy link
Author

vinh84 commented Mar 9, 2017

original image in bug_612.zip]
your resize resized.zip

(i compress in zip because when i upload to github, image changed, them same your issue)

img_5436

@JimBobSquarePants
Copy link
Member

Hmmm.... The image has an odd ICC profile embedded within it. If it's not just ImageSharp causing the issue then I'm inclined to say it'll be unsupported on most libraries. That said we have no ICC profile embedding at all. It's on my TODO list.

See #74

@JimBobSquarePants
Copy link
Member

JimBobSquarePants commented Oct 6, 2017

@vinhhrv

We now have ICC preservation within our codebase but the output will still be incorrect as there is a conversion from CMYK to RGB taking place within the decoding process. (This is the same as libjpeg)

We do have a work-in-progress PR in place which will allow us to use the embedded ICC profile to perform a more accurate color conversion. #273

Once that's in we should be able to replicate the Windows decoder which is the only one that performs the conversion correctly.

@vinh84
Copy link
Author

vinh84 commented Oct 6, 2017

@JimBobSquarePants
Thanks

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

No branches or pull requests

2 participants