This script takes an image as input and converts it into a square by adding equal padding to its shorter dimension. It utilizes ImageMagick for image processing.
./make_square.sh [input_image] [output_image]
- ImageMagick
./make_square.sh input.jpg output.jpg
This will take input.jpg
, add necessary padding to make it square, and save the result as output.jpg
.