A command to add a transparent area to a non-square image to make it square and centered
convert infile -background transparent -gravity center -extent '1024x1024' outfile
referenced: https://stackoverflow.com/questions/11833599/add-lines-of-transparent-pixels-to-image-using-command-line