GithubHelp home page GithubHelp logo

willie84 / imageprocessing Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 1.03 MB

Image processing -Creation of Image cointainer and using iterator to processes it

License: MIT License

C++ 99.66% Makefile 0.34%

imageprocessing's Introduction

This project focused on creating an image cointaner and a specialised Image iterator. The project also focuses on the concept of overloading operators such as ("=","%","+","-","*").

The files that are extensively used are as follows: Image.h which is the header file of the image. This file cointains also the iterator class. Image.cpp which is the file that cointains the image operations and specifications. Array.h is a class that cointains the filtering data in an N*N float array The catch.cpp file is used to enable the unit testing of the methods and classes.

The makeFile is used for automating the process of testing the program. After compiling the programs;
an executable called Imageops(Image operations) is produced.

The images that are supported here are of type .pgm which are grayscale images with a max of 255 pixels.

To invoke/Test the code; follow the following procedures.

  1. To add two images; ./Imageops -a Image1 Image2 Addresult.pgm //Result is saved in addresult.pgm file.

  2. To substract two images; ./Imageops -s Image1 Image2 subresult.pgm //Result is saved in subresult.pgm file.

  3. To INVERT one images; ./Imageops -i Image1 invertresult.pgm //Result is saved in invertresult.pgm file.

  4. To mask one image with another; ./Imageops -l Image1 MaskImage mask_result.pgm //Result is saved in mask_result.pgm file.

  5. To threshold one image with an integer; ./Imageops -t Image1 int f threshold_result.pgm //Result is saved in threshold_result.pgm file.

  6. To threshold filter image with a filter; ./Imageops -f Image1 filter filter_result.pgm //Result is saved in filter_result.pgm file.

To simplify the above processes: Just run the following commands

  1. make invert //to invert 2.make add //to add 3.make subtract //to subtract 4.make threshold //to threshold 5.make mask //to mask 6.make filter //to filter

These operations have been supported by overloading the operators(+,-,*,%,/,!)

for the testcases just run the Test executable.

run make test which calls the ./Testexec

The Test.cpp class is used to unit test the code. Run it to see if the code passes all the tests.

imageprocessing's People

Contributors

willie84 avatar

Watchers

James Cloos 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.