Get dimensions to insert text when image box dimensions are known
Posted: 2018-08-27T02:27:08-07:00
Hello friends,
We are working on adding some text dynamically in the image. Our designers will allocate a box inside each image and give us the dimensions, location of the box as shown in the image below. I tried to add text, but the X and Y axis required are very different from the ones provided by our design team. How can I add text in an image with dimensions and location based upon Pixels. Image height and width is known in pixels. Thank you.
Command used :
We are working on adding some text dynamically in the image. Our designers will allocate a box inside each image and give us the dimensions, location of the box as shown in the image below. I tried to add text, but the X and Y axis required are very different from the ones provided by our design team. How can I add text in an image with dimensions and location based upon Pixels. Image height and width is known in pixels. Thank you.
Command used :
Code: Select all
convert output.png -gravity West -pointsize 30 -annotate +120+225 'my crazy cat' output.jpg