Skip to content

This is a simple project made for educational purposes to practice multithreaded programming.This console application allows you to increase and decrease the size of the original image(s).

Mark1708/multithreaded-image-resizer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

multithreaded-image-resizer

Java

This is a simple project made for educational purposes to practice multithreaded programming.

Table of contents

General info

This console application allows you to increase and decrease the size of the original image(s)

Resizing algorithms:

  • resize by nearest neighbor algorithm
  • resize by imgscalr
  • resize by Graphics2D with RenderingHints

To run the application, you must run the riser.jar which I added to the assets folder or run the mvn package command (the jar will be in the target folder)

Technologies

  • Java - version 11

Code Examples

About using

➜ java -jar resizer.jar -h
    Usage: <main class> [options]
      Options:
        --dst, -d
          Path to destination directory 
          Default: (by default image(s) will be saved in src directory)
        --mode, -m
          Mode of resizing image:
              1 - resize by nearest neighbor algorithm; 
              2 - resize by imgscalr; 
              3 - resize by Graphics2D with RenderingHints
          Default: 3
        --size, -S
          New image size (by default the image will be resized to size 300px)
          Default: 300
      * --src, -s
          Path to source image/directory

Resize all images in src folder to 400px and write to dst folder

➜ java -jar resizer.jar -s /path/src -d /path/dst -S 400 -m 3
    Duration: 19677
    Count of objects: 501

Resize image to 1920px

➜ java -jar resizer.jar -s /path/image.jpg -S 1920 -m 2
    Duration: 6273
    Count of objects: 1

Result

Before After
before after
3648  x  5472 1920  x  2880

Features

  • Multithreading
  • Nearest Neighbor Algorithm
  • imgscalr
  • Graphics2D
  • JCommander

Status

Project is: finished

Inspiration

The project was created for educational purposes

Contact

Created by Gurianov Mark - feel free to contact me!

+7(962)024-50-04 | mark1708.work@gmail.com | github

Readme Card

About

This is a simple project made for educational purposes to practice multithreaded programming.This console application allows you to increase and decrease the size of the original image(s).

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages