Giter Site home page Giter Site logo

devmichalek / depict-it Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 1.2 MB

Depict-It contains combination of the most basic and the most popular image processing algorithms.

License: MIT License

C 97.35% Lex 0.45% Yacc 1.27% Batchfile 0.93%
image-processing depict-it bison flex

depict-it's Introduction

umbrella

Depict-It - List of Commands

-average - grays the image by averaging RGB channels of the image.
-blur <matrix size> - blurs the image with given matrix size (Gaussian Blur Algorithm).
-brighten <level> - brightens the image with positive values (max 255) or dims it with negative values (min -255).
-contrast <level> - makes image more contrast (positive values up to 255) or smears it (negative values down to -255).
-decompose <min/max> - decomposes the image by taking the smallest/greatest channel of each pixel.
-desaturate - desaturates the image, converts RGB channel into HSL channels each divided by two.
-diffuse <n> - reduces to the n to the power of 3 colors with Floyd-Steinberg Error Diffusion.
-gamma <ratio> - produces gamma correction on image with given level.
-grayshade <number of shades> - grays the image determined by number of shades.
-invert - inverts RGB channels of the image.
-luminance <r> <g> <b> - luminances the image, takes each ratio separetaly for each channel.
-pixelate <chunk size> - cuts image into smaller chunks defined by chunk size.
-reduce <n> - reduces image colors to the n to the power of 3 colors.
-singechannel <r/g/b> - grays the image by chosen RGB channel.
-solarise <threshold> <below/above> - solarises the image above/below to the given threshold.

Depict-It - Syntax & Examples:

<executable name> <input.png> <commands> <output.png> - notice that output.png is optional but other arguments are required for program to run correctly without errors.
image.png -blur 8 -luminance 0.2 0.5 0.3 - image.png will be blurred with Gaussian Kernel 8x8 then luminanced.
in.png -decompose max -solarise 128 below out.png - in.png will be decomposed with max function then solarised (each pixel below 128) then out.png will be produced.
picture.png -gamma 1.25 - picture.png will be converted with gamma conversion algorithm with ratio 1.25.

List of Used Articles

Francis G. Loch Article
Wikipedia Article
Tanner Helland Article
What-When-How Article
Stack Overflow Gaussian Blur Question
Stack Overflow Gaussian Kernel Question

Download (Windows)

Download for Windows 32-bit
Download for Windows 64-bit

Depict-It - Buiding on Linux

# Generate parser & lexer
bison -b Generated/parser -d "Bison Flex/parser.y"
flex -o Generated/lexer.c "Bison Flex/lexer.l"
# Generate objects
gcc -I "Header Files" -c Generated/parser.tab.c Generated/lexer.c
gcc -I "Header Files" -c "Source Files/lodepng.c" "Source Files/image.c" "Source Files/process.c" "Source Files/semantic.c" "Source Files/main.c"
# Create executable
gcc parser.tab.o lexer.o lodepng.o image.o process.o semantic.o main.o -lm -o Depict-It
# Run executable
./Depict-It

depict-it's People

Contributors

devmichalek avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.