Proper handling of the EXIF cases.

Kudos to
https://www.daveperrett.com/articles/2012/07/28/exif-orientation-handling-is-a-ghetto/

Signed-off-by: Yoan Blanc <yoan@dosimple.ch>
This commit is contained in:
Yoan Blanc 2017-08-24 18:46:06 -04:00
parent 833af3b49a
commit b752fe8ea6
No known key found for this signature in database
GPG key ID: 6058CF4574298812
34 changed files with 62 additions and 2 deletions

View file

@ -518,7 +518,7 @@ func calculateRotationAndFlip(image *C.VipsImage, angle Angle) (Angle, bool) {
break // flip 1
case 7:
flip = true
rotate = D90
rotate = D270
break // flip 6
case 4:
flip = true
@ -526,7 +526,7 @@ func calculateRotationAndFlip(image *C.VipsImage, angle Angle) (Angle, bool) {
break // flip 3
case 5:
flip = true
rotate = D270
rotate = D90
break // flip 8
}