-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
CMYK roundtrip via pipelineColourspace should not convert to sRGB internally #3620
Comments
Thanks for reporting, commit b763801 fixes this and adds a unit test that would previously have failed. It looks like the "This feature is experimental..." warning for https://sharp.pixelplumbing.com/api-colour#pipelinecolourspace |
Hello, 1- Can I use modulate function on a cmyk image without converting to srgb? |
|
v0.32.1 now available with these fixes. |
I have checked resize and modulate it works perfectly fine! thanks for your amazing work ! |
I have listened to you and checked the icc package. I started working on a pr on this package following this issue : lovell/icc#2 |
Possible bug
With the code I provided in this repo https://github.com/Aminelahlou/sharpCmykTest we can see that color conversion happens even if I stated that pipelinecolorspace is cmyk and to colorspace is cmyk.
when I launch my script (as described below and in the git repo I made, I should get an image full of C:100 M:0 Y:0 K:0 values (same values than input image)
But here is the current behaviour:
When I launch
node test-sharp.js
I get a new image with values of C: 66 M: 18 Y:0 K:1maybe I don't understand the docs but it seems sharp is doing a conversion here (either CMYK => (s)RGB => CMYK or CMYK=> CMYK) maybe there is also something I didn't understand in the docs but i have searched in issue 218 and did not found any answer.
Is this a possible bug in a feature of sharp, unrelated to installation?
npm install sharp
completes without error.node -e "require('sharp')"
completes without error.If you cannot confirm both of these, please open an installation issue instead.
Are you using the latest version of sharp?
sharp
as reported bynpm view sharp dist-tags.latest
.npm view sharp dist-tags.latest
gives me 0.32 and in package-lock:If you cannot confirm this, please upgrade to the latest version and try again before opening an issue.
If you are using another package which depends on a version of
sharp
that is not the latest, please open an issue against that package instead.What is the output of running
npx envinfo --binaries --system --npmPackages=sharp --npmGlobalPackages=sharp
?What are the steps to reproduce?
Code:
"./input/test-sharp-input.tif" contains a tiff image without any profile and full of CMYK pixel with Cyan value of 100 (other values are 0)
I have made a public repository at https://github.com/Aminelahlou/sharpCmykTest
What is the expected behaviour?
I should not make any color conversion wether SRGB=> CMYK CMYK=> CMYK or CMYK => SRGB.
and when I launch
npm i
and thennode test-sharp.js
I should get a new image in the output folder with exact same value which are Cyan:100 M:0 Y:0 K:0Please provide a minimal, standalone code sample, without other dependencies, that demonstrates this problem
https://github.com/Aminelahlou/sharpCmykTest
Please provide sample image(s) that help explain this problem
sample image is in the github repo in the
input
folder and is calledtest-sharp-input.tif
The text was updated successfully, but these errors were encountered: