-
-
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
.flip() doesn't work after .composite() #4288
Comments
Hello, you'll need to split this into two pipelines, one to composite and a second to flip. This is alluded to in the docs (but perhaps could be made clearer to include flip/flop): https://sharp.pixelplumbing.com/api-composite
|
Ah, yeah thanks, no problem, I was already doing so but figured this wasn't expected.
Yeah I think so, I did look but it didn't click for me that flip/flop was included. Just so I can have a better mental model, what is the reason for these operations being order dependent? What class of operations should I expect to be broken by having a I'd be happy to send a pull against the docs once I have a good understanding of how this works/is supposed to work. |
Possible bug
System Info
System:
OS: Windows 10 10.0.19044
CPU: (12) x64 Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz
Memory: 13.38 GB / 31.95 GB
Binaries:
Node: 22.11.0 - C:\Program Files\nodejs\node.EXE
npm: 10.9.0 - C:\Program Files\nodejs\npm.CMD
npmPackages:
sharp: ^0.33.5 => 0.33.5
What are the steps to reproduce?
What is the expected behaviour?
The expectation here is that we get a transparent PNG with it's lower left quarter containing a white square, instead I get a non-flipped PNG with the upper left quarter containing a white square.
I see that in the documentation it's noted that
This operation does not work correctly with multi-page images.
but I don't think that's what's happening here?The text was updated successfully, but these errors were encountered: