mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Docs refresh
This commit is contained in:
@@ -24,7 +24,10 @@
|
||||
Rotate the output image by either an explicit angle
|
||||
or auto-orient based on the EXIF `Orientation` tag.
|
||||
|
||||
Use this method without angle to determine the angle from EXIF data.
|
||||
If an angle is provided, it is converted to a valid 90/180/270deg rotation.
|
||||
For example, `-450` will produce a 270deg rotation.
|
||||
|
||||
If no angle is provided, it is determined from the EXIF data.
|
||||
Mirroring is supported and may infer the use of a flip operation.
|
||||
|
||||
The use of `rotate` implies the removal of the EXIF `Orientation` tag, if any.
|
||||
@@ -34,7 +37,7 @@ for example `rotate(x).extract(y)` will produce a different result to `extract(y
|
||||
|
||||
**Parameters**
|
||||
|
||||
- `angle` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** 0, 90, 180 or 270. (optional, default `auto`)
|
||||
- `angle` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)** angle of rotation, must be a multiple of 90. (optional, default `auto`)
|
||||
|
||||
**Examples**
|
||||
|
||||
|
||||
@@ -49,6 +49,14 @@ Requires libvips v8.5.5.
|
||||
[#783](https://github.com/lovell/sharp/pull/783)
|
||||
[@YvesBos](https://github.com/YvesBos)
|
||||
|
||||
* Add support for rotation using any multiple of +/-90 degrees.
|
||||
[#791](https://github.com/lovell/sharp/pull/791)
|
||||
[@ncoden](https://github.com/ncoden)
|
||||
|
||||
* Add "jpg" alias to toFormat as shortened form of "jpeg".
|
||||
[#814](https://github.com/lovell/sharp/pull/814)
|
||||
[@jingsam](https://github.com/jingsam)
|
||||
|
||||
### v0.17 - "*quill*"
|
||||
|
||||
Requires libvips v8.4.2.
|
||||
|
||||
Reference in New Issue
Block a user