Skip to content

afreemanio/mosaicMaker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mosaicMaker: Photographic Mosaic Command Line Tool

Contributors Forks Stargazers Issues MIT License LinkedIn

Report Bug · Request Feature

Photographic Mosaic Command Line Tool

Content

About The Project

This is a Python project created for my Winter 2021 Semester at the King's University, my final project for CMPT450: Image Processing.

It creates photomosaic images from all images in the "inputImages" folder, based on tiling the specified input on the command line, and saves everything to the outputImages folder.

Next steps are to make it look fancier by adding more pretty command line stuff like help (error codes), proper argument parsing, etc.

Thank you!

With a special thanks to Dr. Michael Janzen.


Photographic mosaics (Photomosaics) are pictures that have been divided into tiled sections, with each tile being replaced with another image that resembles the colour of the tile it replaces. The effect has each pixel in the original image replaced by another distinct image – so at low magnification, the original image appears as normal, but when magnified, one can see that the original picture is made up of many smaller images.

Refer to https://en.wikipedia.org/wiki/Photographic_mosaic for more information on Photographic Mosaics.

Built With

Features

  • Creation of Photomosaics of specified height and width.
  • Automatically uses the best photos from the provided source directory (/tileImages/).
  • Automatically adjusts the brightness to ensure accuracy to the source image.
  • Works with most common image filetypes! If its supported in Pillow, it's supported here!
  • Simple and easy to install and run!

Installation

  1. Download the repository files (project) directly from the download section or clone this project by entering the following command:

    git clone https://github.com/afreemanio/mosaicMaker.git
    
  2. Navigate to the repository using your terminal of choice

  3. Add source photos to the tileImages folder that will be the tiles (small pictures) in your Photographic Mosaic

  4. Add source files to the sourceImages folder that will be the main (bigger) photo in your Photographic Mosaic

  5. With Python3 installed, navigate to /src/, run the following command to install the required dependencies:

    pip3 install -r requirements.txt
    
  6. Then run the program using this format:

    python main.py [image from sourceImages + .ext] [output width] [output height] [number of tiles in x direction] [number of tiles in y direction]

For example:

python main.py samuel.jpg 1000 1000 100 100

To run the program specifying ../sourceImages/samuel.jpg as the base image, 1000x1000 as the width/height of your final Photomosiac, with 100(w)x100(h)=10000 tiles in total.

Contributing

Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/CoolNewFeature)
  3. Commit your Changes (git commit -m 'Add some CoolNewFeature')
  4. Push to the Branch (git push origin feature/CoolNewFeature)
  5. Open a Pull Request

Contact

Andrew Freeman - @afreemanio - [email protected]

Project Link: https://github.com/afreemanio/mosaicMaker

License

Copyright (c) 2021 Andrew Freeman

Distributed under and usage provided for under the MIT License. See LICENSE for the full details.

Releases

No releases published

Packages

No packages published

Languages