Problems with -format
Posted: 2012-03-15T06:45:11-07:00
Hey everyone,
I am trying to get the image witdth and heigth of an image!
I have googled a lot and found this page: http://www.imagemagick.org/script/identify.php
Identify has an option -format that can give me the height and width of an image. Unfortunately this does not work for me.. Am I doing something wrong?
$ identify -format "%[fx:w/72] by %[fx:h/72] inches" document.png
8.5 x 11 inches
I have a testfile called 000.png and I use this command:
identify -format "%[fx:w/72] by %[fx:h/72] inches" 000.png
My Output is this: w/72] by h/72] inches
My goal is to use this dimensions as variables for later opertations, thats why I need to save them into variables.
Somehow I don't get the dimensions. Does someone know what I am doing wrong? I have installed this imagemagick version: ImageMagick-6.7.6-0-Q16-windows-x64-static.exe
I hope someone can help me!
Thanks in advance,
Andreas
I am trying to get the image witdth and heigth of an image!
I have googled a lot and found this page: http://www.imagemagick.org/script/identify.php
Identify has an option -format that can give me the height and width of an image. Unfortunately this does not work for me.. Am I doing something wrong?
$ identify -format "%[fx:w/72] by %[fx:h/72] inches" document.png
8.5 x 11 inches
I have a testfile called 000.png and I use this command:
identify -format "%[fx:w/72] by %[fx:h/72] inches" 000.png
My Output is this: w/72] by h/72] inches
My goal is to use this dimensions as variables for later opertations, thats why I need to save them into variables.
Somehow I don't get the dimensions. Does someone know what I am doing wrong? I have installed this imagemagick version: ImageMagick-6.7.6-0-Q16-windows-x64-static.exe
I hope someone can help me!
Thanks in advance,
Andreas