update module name, update readme
This commit is contained in:
parent
13b012ff73
commit
62b7ee3151
@ -21,7 +21,7 @@ Options:
|
|||||||
|
|
||||||
Library
|
Library
|
||||||
-------
|
-------
|
||||||
Documentation available at hackage
|
[Documentation available at hackage](https://hackage.haskell.org/package/picedit-0.1.0.0/docs/Data-Picture.html)
|
||||||
|
|
||||||
```haskell
|
```haskell
|
||||||
import Picture
|
import Picture
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
module Main where
|
module Main where
|
||||||
import Picture
|
import Data.Picture
|
||||||
import System.Environment
|
import System.Environment
|
||||||
|
|
||||||
data Options = Options { file :: FilePath
|
data Options = Options { file :: FilePath
|
||||||
@ -27,7 +27,6 @@ module Main where
|
|||||||
main :: IO ()
|
main :: IO ()
|
||||||
main = do
|
main = do
|
||||||
args <- getArgs
|
args <- getArgs
|
||||||
print args
|
|
||||||
|
|
||||||
if null args
|
if null args
|
||||||
then do
|
then do
|
||||||
|
@ -2,12 +2,12 @@ name: picedit
|
|||||||
version: 0.1.0.0
|
version: 0.1.0.0
|
||||||
synopsis: simple image manipulation functions
|
synopsis: simple image manipulation functions
|
||||||
description: Simple set of functions for image manipulation: contrast, brightnesss, rotation, etc.
|
description: Simple set of functions for image manipulation: contrast, brightnesss, rotation, etc.
|
||||||
homepage: https://github.com/mdibaiee/image-editor-hs#readme
|
homepage: https://github.com/mdibaiee/picedit#readme
|
||||||
license: GPL-3
|
license: GPL-3
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Author name here
|
author: Mahdi Dibaiee
|
||||||
maintainer: example@example.com
|
maintainer: mdibaiee@aol.com
|
||||||
copyright: 2016 Author name here
|
copyright: 2016 Mahdi Dibaiee
|
||||||
category: Image, Picture, Matrix
|
category: Image, Picture, Matrix
|
||||||
build-type: Simple
|
build-type: Simple
|
||||||
-- extra-source-files:
|
-- extra-source-files:
|
||||||
@ -15,14 +15,14 @@ cabal-version: >=1.10
|
|||||||
|
|
||||||
library
|
library
|
||||||
hs-source-dirs: src
|
hs-source-dirs: src
|
||||||
exposed-modules: Picture
|
exposed-modules: Data.Picture
|
||||||
build-depends: base >= 4.7 && < 5,
|
build-depends: base >= 4.7 && < 5,
|
||||||
JuicyPixels >= 3.2.8 && < 3.3,
|
JuicyPixels >= 3.2.8 && < 3.3,
|
||||||
hmatrix >= 0.17.0.2 && < 0.18,
|
hmatrix >= 0.17.0.2 && < 0.18,
|
||||||
vector >= 0.11.0.0 && < 0.12
|
vector >= 0.11.0.0 && < 0.12
|
||||||
default-language: Haskell2010
|
default-language: Haskell2010
|
||||||
|
|
||||||
executable image-editor-hs-exe
|
executable picedit
|
||||||
hs-source-dirs: app
|
hs-source-dirs: app
|
||||||
main-is: Main.hs
|
main-is: Main.hs
|
||||||
ghc-options: -threaded -rtsopts -with-rtsopts=-N
|
ghc-options: -threaded -rtsopts -with-rtsopts=-N
|
||||||
|
@ -2,18 +2,27 @@
|
|||||||
{-# LANGUAGE FlexibleContexts #-}
|
{-# LANGUAGE FlexibleContexts #-}
|
||||||
{-# LANGUAGE TypeFamilies #-}
|
{-# LANGUAGE TypeFamilies #-}
|
||||||
|
|
||||||
module Picture ( grayscale
|
{-|
|
||||||
, readPicture
|
Module : Picture
|
||||||
, fromImage
|
Description : manipulation functions
|
||||||
, toImage
|
Copyright : (c) Mahdi Dibaiee, 2016
|
||||||
, writePicturePng
|
License : GPL-3
|
||||||
, fade
|
Maintainer : mdibaiee@aol.com
|
||||||
, rotate
|
Stability : experimental
|
||||||
, contrast
|
Portability : POSIX
|
||||||
, brightness
|
-}
|
||||||
, gamma
|
module Data.Picture ( grayscale
|
||||||
, invert
|
, readPicture
|
||||||
)
|
, fromImage
|
||||||
|
, toImage
|
||||||
|
, writePicturePng
|
||||||
|
, fade
|
||||||
|
, rotate
|
||||||
|
, contrast
|
||||||
|
, brightness
|
||||||
|
, gamma
|
||||||
|
, invert
|
||||||
|
)
|
||||||
where
|
where
|
||||||
|
|
||||||
import Codec.Picture
|
import Codec.Picture
|
||||||
@ -21,10 +30,7 @@ module Picture ( grayscale
|
|||||||
import qualified Data.Vector.Storable as V
|
import qualified Data.Vector.Storable as V
|
||||||
import System.IO
|
import System.IO
|
||||||
import Data.Maybe
|
import Data.Maybe
|
||||||
import Debug.Trace
|
|
||||||
|
|
||||||
-- RGBA
|
|
||||||
|
|
||||||
-- | 'Picture' type is just a triple of color channel matrices: (R, G, B)
|
-- | 'Picture' type is just a triple of color channel matrices: (R, G, B)
|
||||||
type Picture = (Matrix Double, Matrix Double, Matrix Double)
|
type Picture = (Matrix Double, Matrix Double, Matrix Double)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user