convert -get attribute myvariable
Posted: 2007-10-13T07:58:39-07:00
Is there a mechanism to read (get) and re-use image attributes in the "convert" pipeline?
i.e. hypothetically:
convert \(srcImage.tif -get height\) \(virtualRuler.tif -crop x%[height]+0+0\) +append srcPlusRuler.tif
I would like to take the attributes of a template image and apply them to another image.
For example: take a ruler image, appropriately scale it, and place it next to the calibrated content of a geophysical image. In this case the calibrating attributes of the 2nd are used to appropriately scale and set the attributes of the 1st before appending the two together.
Understood that this can be accomplished:
* Under *nix'ish shells using back-quoted identify commands
* Or via one of the ImageMagick language APIs (Perl, PHP, C/C++)
but am looking for a cleaner command-line solution under Windows, if such exists.
i.e. hypothetically:
convert \(srcImage.tif -get height\) \(virtualRuler.tif -crop x%[height]+0+0\) +append srcPlusRuler.tif
I would like to take the attributes of a template image and apply them to another image.
For example: take a ruler image, appropriately scale it, and place it next to the calibrated content of a geophysical image. In this case the calibrating attributes of the 2nd are used to appropriately scale and set the attributes of the 1st before appending the two together.
Understood that this can be accomplished:
* Under *nix'ish shells using back-quoted identify commands
* Or via one of the ImageMagick language APIs (Perl, PHP, C/C++)
but am looking for a cleaner command-line solution under Windows, if such exists.