aboutsummaryrefslogtreecommitdiff
path: root/compiler/src
diff options
context:
space:
mode:
authorOzoneGrif2020-02-02 04:44:46 +0100
committerGitHub2020-02-02 04:44:46 +0100
commit56901340cb510ee9012bb4a122b95831258e9789 (patch)
tree8edfa4089ab2cd3b2375ce8aa8fd758cfc2beb1d /compiler/src
parentdd022bfc7325f2375d84abf14e94ee909eed20b0 (diff)
parente954915fd5b6c035dbd784f8b8d9c5c0943d76ac (diff)
downloadldgallery-56901340cb510ee9012bb4a122b95831258e9789.tar.gz
Merge pull request #73 from pacien/feature-image-rotation
compiler: auto orient processed images
Diffstat (limited to 'compiler/src')
-rw-r--r--compiler/src/Processors.hs6
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/src/Processors.hs b/compiler/src/Processors.hs
index f2ade63..df7e632 100644
--- a/compiler/src/Processors.hs
+++ b/compiler/src/Processors.hs
@@ -86,7 +86,11 @@ resizePictureUpTo maxResolution inputPath outputPath =
86 maxSize Resolution{width, height} = show width ++ "x" ++ show height ++ ">" 86 maxSize Resolution{width, height} = show width ++ "x" ++ show height ++ ">"
87 87
88 resize :: FileName -> FileName -> IO () 88 resize :: FileName -> FileName -> IO ()
89 resize input output = callProcess "magick" [input, "-resize", maxSize maxResolution, output] 89 resize input output = callProcess "magick"
90 [ input
91 , "-auto-orient"
92 , "-resize", maxSize maxResolution
93 , output ]
90 94
91 95
92type Cache = FileProcessor -> FileProcessor 96type Cache = FileProcessor -> FileProcessor