yes
This commit is contained in:
parent
8f7f1c89ed
commit
c4930a5629
@ -14,7 +14,7 @@ loadImage :: String -- ^ Path to the file
|
|||||||
-> IO DynamicImage
|
-> IO DynamicImage
|
||||||
loadImage input = either error id <$> readImage input
|
loadImage input = either error id <$> readImage input
|
||||||
|
|
||||||
mainProcess :: (String,Float,Float, String, String) -> IO ()
|
mainProcess :: (String,String,String, String, String) -> IO ()
|
||||||
mainProcess (polarity,primaryScaleDark,primaryScaleLight, input, output) = do
|
mainProcess (polarity,primaryScaleDark,primaryScaleLight, input, output) = do
|
||||||
putStrLn $ "Processing " ++ input
|
putStrLn $ "Processing " ++ input
|
||||||
|
|
||||||
@ -28,7 +28,7 @@ mainProcess (polarity,primaryScaleDark,primaryScaleLight, input, output) = do
|
|||||||
writeFile output $ encode outputTable
|
writeFile output $ encode outputTable
|
||||||
putStrLn $ "Saved to " ++ output
|
putStrLn $ "Saved to " ++ output
|
||||||
|
|
||||||
parseArguments :: [String] -> Either String (String, Float,Float,String, String)
|
parseArguments :: [String] -> Either String (String, String,String,String, String)
|
||||||
parseArguments [polarity, primaryScaleDark, primaryScaleLight,input, output] = Right (polarity,primaryScaleDark, primaryScaleLight, input, output)
|
parseArguments [polarity, primaryScaleDark, primaryScaleLight,input, output] = Right (polarity,primaryScaleDark, primaryScaleLight, input, output)
|
||||||
parseArguments [_, _,_,_] = Left "Please specify an output file"
|
parseArguments [_, _,_,_] = Left "Please specify an output file"
|
||||||
parseArguments [_, _,_] = Left "Please specify an image"
|
parseArguments [_, _,_] = Left "Please specify an image"
|
||||||
|
Loading…
Reference in New Issue
Block a user