Coder Social home page Coder Social logo

ajaxxishere / median-image-filter-in-c Goto Github PK

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

This is an image filter program that reads hsdec files and applies a median image filter over them!

Makefile 1.41% Python 28.01% C 70.58%
c embedded-c image-processing ppm-image python3

median-image-filter-in-c's Introduction

F28HS Coursework 1

H00458396: HSDEC MEDIAN NORM

Image Processing Coursework

This project implements a basic image processing technique in C, includes median filter (apply_MEDIAN) and normalization (apply_NORM).

Overview

  • Median Filter (apply_MEDIAN): Smoothens the image by replacing each pixel's value with the median of its neighbors in 1x1 matrix (top, bottom, left, right,).
  • Normalization (apply_NORM): Rescales pixel values to the range of 0-255 for better visualization and consistency.

Prerequisits

  1. Using any linux machine (WSL/ Virtual Machine also works)
  2. Root access to the program by the computer (this can be done with 'chmod -x ./process' for example)
  3. Any image file in '.hsdec' format in the same folder as the program (i've included 2 example images and their output ppm image in the folder).

Usage

  1. Compile the code using the already included makefile. eg. run - 'make'
  2. Run the code using './process INPUTFILENAME OUTPUTFILENAME'. eg. run './process portrait.hsdec newPortrait.hsdec' 3.Convert the output file from '.hsdec' to '.ppm' using the already included 'hsconvert.py' file. eg. run './hsconvert -f PPM newPortrait.hsdec viewPortrait.ppm'
  3. View the output image using any compatible image viewer in your machine.

Dependencies

  • Standard C libraries (no external dependencies)

median-image-filter-in-c's People

Contributors

ajaxxishere avatar

Watchers

 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.