Skip to content

skazsi/ProfilePictureMaker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Profile Picture Maker

A small utility tool and Java library for making circle shaped transparent profile pictures out of any rectangular pictures. Can be used as a Java command line tool as well as a Java library.

The pictures are cropped to square at first using center alignment. Then resized to the desired size, cropped to a circle, and finally decorated with a small border. The following samples represent the applied changes.

Original Result with 100px size configuration
Lena Lena
Mona Lisa Lena

Command Line Usage

For using the command line tool Java 11 or higher JVM is required. It supports the following parameters:

  • -dir ../any/valid/directory that specifies a directory for looking for images. Defaults to the current directory.
  • -imageSize 200 that specifies the desired profile picture size assuming 200 pixels. Defaults to 150 pixels.

The command line tool looks for any jpg, jpeg, gif and png files in the specified directory and saves the created profile pictures with a profile filename suffix and png type.

Example execution assuming Lenna.png and Mona-lisa.jpg in the /some/dir directory will create the respective Lenna_profile.png and Mona-lis_profile.png files in the same directory.

> java -jar ProfilePictureMaker-0.0.1-SNAPSHOT.jar -dir /some/dir -imageSize 200
Using parameters:
        directory: /some/dir
        imageSize: 200
Processing image of Lenna.png
Processing image of Mona-lisa.jpg

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages