-
Notifications
You must be signed in to change notification settings - Fork 42
Open
Description
Hi,
first I like your script. Very well done!
I have in my project
img {
image-orientation: from-image;
}
With this enabled images are wrongly scaled when the image needs to be rotated because of the orientation. As I did not find a quick solution to read the exif information I did it quick and dirty change in row 213.
if (Math.round(img.naturalHeight/img.naturalWidth * 100) == Math.round(img.width/img.height * 100)) {
that.imgHeight = img.naturalWidth || img.width;
that.imgWidth = img.naturalHeight || img.height;
}
else {
that.imgWidth = img.naturalWidth || img.width;
that.imgHeight = img.naturalHeight || img.height;
}
And it works (at least in my cases) Would be great if you have a cleaner solution.
Thanks again.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels