Coder Social home page Coder Social logo

conversimg's Introduction

Logo

Conversimg

An open-source image converter and resizer

Build Status License: LGPL v3 made-with-java built-with-gradle windows mac linux release

 

1 - Description

Conversimg is an open-source command interpreter program whose purpose is to allow the user to convert and resize images locally without having to resort to external services on the Internet.

2 - Supported formats

Conversimg works with the most standardized image formats. The supported formats are the following:

Version 1.0:

  • BMP (Windows bitmap).
  • JPG (Joint Photographic Experts Group).
  • GIF (Graphic Interchange Format).
  • PNG (Portable Network Graphics).

Version 2.0:

Able conversion from image to pdf and viceversa

  • From BMP, JPG, GIF, PNG to PDF
  • From PDF to jpg bmp BMP gif GIF WBMP iff IFF png PNG JPEG wbmp jpeg

More formats will be added in later versions.

3 - Source code

The application has been developed in a gradle project (version 5.6.2) in java programming language. The application has three files written in java to model the converter, the resizer and the main control module. The files are documented to make them as easy to understand as possible.

4 - How to compile

In order to compile and make use of the application you must install a gradle version on your computer. The following describes how to compile and execute the project.

  • To be able to compile the project:
gradle assemble
  • To be able to execute the unitary tests:
gradle test
  • To be able to execute the above two commands in one
gradle build

If you want to generate an executable for your system you must modify the file gradle.build and indicate the corresponding command to be able to achieve it. However, in the release a runnable jar file is provided to be executed in your personal computer.

5 - Compatibility

The application runs on the following operating systems:

  • Windows (all versions).
  • Linux (all distributions).
  • Mac.

The only requirement is to have gradle installed.

6 - Continuous integration

The application has been built, as well as its future versions using continuous integration. Travis has been used for this. The set of tasks you have to execute are in the file .travis.yml. Apart from compiling the project, a set of unit tests in java have been provided to prove that image format validation, conversion and resizing work well. In order to test the resizing and conversion of images, a folder has been provided, called Images, where four images are found in the four possible formats for now.

7 - How to execute?

Commands to run the program are shown below:

  • To convert an image to another format:
java -jar Conversimg.jar <-c> <input_image> <output_image> 

  • To resize an image:
java -jar Conversimg.jar <-r> <input_image> <output_image> <percent>
  • To convert from image to pdf
java -jar Conversimg.jar <-ip> <input_image> <output_pdf>
  • To convert from pdf to image
java -jar Conversimg.jar <-pi> <input_pdf> <out_put>

8 - Release

The relsease provided has a runnable jar file that contains all referenced dependencies and libraries. So with that file only the program runs correctly on any system where java is installed.

9 - Images of different scenaries of execution

Below are example images that show some execution scenearies of the program realised both in native windowds 10 and in a virtual machine with Debian 10.

  • The following image shows how the programm works when the order for convert an image is written correctly:

correct conversion windows

correct conversion linux

 

  • The following image shows how the programm works when the order for resize an image is written correctly:

correct resize windows

correct resize linux

 

  • The following image shows how the programm works when the order for convert an image with a not supported format:

not supported format windows

not supported format linux

 

  • The following image shows how the programm works when the order is not correct:

Incorrect flag windows

Incorrect flag linux

 

  • The following image shows how the programm works when an image is resized but the output format is changed:

bad output format changed windows

bad output format changed linux

conversimg's People

Contributors

zgzinfinity avatar

Watchers

 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.