Let's say somePic.jpg does not fit the ratio of 300x100, I would expect it to be centered within the slot allocated to it, but with the this command its left aligned.
Code: Select all
convert -size 300x250 -quality 80.0 xc:black \( -gravity Center 'somePic.jpg' -resize 300x100 -repage 0x0+0+110 \) -flatten 'newPic.jpg'
Code: Select all
convert "somePic.jpg" -resize 144x82 -size 144x82 xc:#343434 +swap -gravity center -composite "newPic.jpg"