Giter Site home page Giter Site logo

puremintsoftware / proportional-image-resizer Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 35 KB

Resizes a folder of images to a new user determined size, whilst keeping the proportions of the original images. It outputs the resized images to a new "Resized" folder inside the original image folder.

License: MIT License

Python 100.00%

proportional-image-resizer's Introduction

Proportional Image Resizer
by Pure Mint Software

Resizes images in a folder (and its subfolders) to a new user determined size, whilst keeping the proportions of the original images. It outputs the resized images to a new "Resized" folder inside the source folder. Any files which don't require resizing will be copied to the "Resized" folder so that every image is replicated in "Resized".

Example

You have a folder called "Cat Memes", and the images are a mix of sizes and proportions (portrait, landscape, square). You want to resize them (whether up or down) so that their longest sides all become 1000 pixels, whilst maintaining their original proportionality.

2000 x 1000 (Landscape Image) will become 1000 x 500 ... Scaled Down.
300 x 400 (Portrait Image) will become 1000 x 750 ... Scaled Up.
1583 x 1583 (Square Image) will become 1000 x 1000 ... Scaled Down.
500 x 1000 (Portrait Image) will remain 500 x 1000 ... No Scaling Required.

Required Libraries

It just requires Pillow, because OS and Tkinter should already be installed in any Python installation.
Open "CMD" from the Windows Start Menu, type the line below into the Windows Terminal, and press enter.

pip install pillow tk

Running The Script

Open "CMD" from the Windows Start Menu. Navigate to the folder where you have downloaded the script using the "CD" command, and then type the line below into the Windows Terminal, and press enter.

python pir.pyw

proportional-image-resizer's People

Contributors

puremintsoftware avatar

Stargazers

 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.