libgdiplus icon indicating copy to clipboard operation
libgdiplus copied to clipboard

Fix ISSUE #706 The color of CMYK pixel format pictures is incorrect.

Open e8-ShiWei opened this issue 3 years ago • 2 comments

Values of b and r are incorrect. Red is assigned to b, and blue is assigned to r.

Swap the positions of b and r. Fix to:

r = (255 - k) * (255 - c) / 255;
g = (255 - k) * (255 - m) / 255;
b = (255 - k) * (255 - y) / 255;

Example, red: C = 0% M = 100% Y = 100% K = 0%

=>

R = 255 * 255 / 255 = 255 G = 255 * 0 / 255 = 0 B = 255 * 0 / 255 = 0

e8-ShiWei avatar May 31 '21 23:05 e8-ShiWei

Hi, any update? When will we get a release version containing this modification? If it takes a long time to release a new version, we may need to compile this library ourselves. Thanks.

e8-ShiWei avatar Jun 10 '21 22:06 e8-ShiWei

Usually the release cadence of this library is quite slow. @akoeplinger, can you look at this PR / approve it?

filipnavara avatar Jun 11 '21 05:06 filipnavara