Skip to content
This repository has been archived by the owner on Aug 27, 2021. It is now read-only.

Commit

Permalink
Merge pull request #15 from team-lab/debug/rotation
Browse files Browse the repository at this point in the history
回転処理のコードをオリジナルコードに戻す
  • Loading branch information
mogisu authored Dec 3, 2019
2 parents c417a30 + 497c4b2 commit 25fccdc
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions resizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -578,29 +578,29 @@ func calculateRotationAndFlip(image *C.VipsImage, angle Angle) (Angle, bool) {

switch vipsExifOrientation(image) {
case 6:
rotate = D270
rotate = D90
break
case 3:
rotate = D180
break
case 8:
rotate = D90
rotate = D270
break
case 2:
flip = true
rotate = D180
break // flip 3
break // flip 1
case 7:
flip = true
rotate = D90
break // flip 8
rotate = D270
break // flip 6
case 4:
flip = true
break // flip 1
rotate = D180
break // flip 3
case 5:
flip = true
rotate = D270
break // flip 6
rotate = D90
break // flip 8
}

return rotate, flip
Expand Down

0 comments on commit 25fccdc

Please sign in to comment.