mirror of
https://github.com/lovell/sharp.git
synced 2025-12-18 23:05:04 +01:00
Use bounding box of alpha+non-alpha for trim op #2166
This commit is contained in:
@@ -430,7 +430,8 @@ function extract (options) {
|
||||
|
||||
/**
|
||||
* Trim "boring" pixels from all edges that contain values similar to the top-left pixel.
|
||||
* Images consisting entirely of a single colour will calculate "boring" using the alpha channel, if any.
|
||||
*
|
||||
* Images with an alpha channel will use the combined bounding box of alpha and non-alpha channels.
|
||||
*
|
||||
* The `info` response Object, obtained from callback of `.toFile()` or `.toBuffer()`,
|
||||
* will contain `trimOffsetLeft` and `trimOffsetTop` properties.
|
||||
|
||||
Reference in New Issue
Block a user