mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-11 16:35:47 +01:00
Implements Jimp exitRotate() new method (jimp 0.2.28) to sove incoherent rotations when scaling images.
This commit is contained in:
@@ -37,6 +37,10 @@ image.resizeImage = function (data, callback) {
|
||||
var y = 0;
|
||||
var crop;
|
||||
|
||||
if (image._exif && image._exif.tags && image._exif.tags.Orientation) {
|
||||
image.exifRotate();
|
||||
}
|
||||
|
||||
if (origRatio !== desiredRatio) {
|
||||
if (desiredRatio > origRatio) {
|
||||
desiredRatio = 1 / desiredRatio;
|
||||
|
||||
Reference in New Issue
Block a user