mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Ensure create has correct bit depth and colourspace #3139
This commit is contained in:
@@ -289,6 +289,20 @@ Produce the "negative" of the image.
|
||||
|
||||
* `options.alpha` **[Boolean][6]** Whether or not to negate any alpha channel (optional, default `true`)
|
||||
|
||||
### Examples
|
||||
|
||||
```javascript
|
||||
const output = await sharp(input)
|
||||
.negate()
|
||||
.toBuffer();
|
||||
```
|
||||
|
||||
```javascript
|
||||
const output = await sharp(input)
|
||||
.negate({ alpha: false })
|
||||
.toBuffer();
|
||||
```
|
||||
|
||||
Returns **Sharp**
|
||||
|
||||
## normalise
|
||||
|
||||
@@ -4,6 +4,11 @@
|
||||
|
||||
Requires libvips v8.12.2
|
||||
|
||||
### v0.30.4 - TBD
|
||||
|
||||
* Ensure `create` input image has correct bit depth and colour space.
|
||||
[#3139](https://github.com/lovell/sharp/issues/3139)
|
||||
|
||||
### v0.30.3 - 14th March 2022
|
||||
|
||||
* Allow `sharpen` options to be provided more consistently as an Object.
|
||||
|
||||
Reference in New Issue
Block a user