Yeah, it is unfortunate that ImageMagick uses those chars since they have 
other meanings on the cmd line.

just escape it ( \> ) and that should work ( works on a linux box )

morgan

At 07:53 PM 4/18/2001, you wrote:
>morgan,
>     this is starting to work! the 175x175 does resize it to a width of 175
>while retaining the aspect ratio.
>
>     however.... when i tried using the less than sign, the windows nt
>command prompt is treating it as saving the output to a file:
>
>c:\progra~1\imagem~1\mogrify.exe -geometry 175x175> picture.jpeg
>
>imagemagick replies with : missing image file name. this is because the >
>sign is telling windows to save the output to a file.
>i tried putting a 1 after the > sign and it made a blank file with filename
>of '1'.
>
>how can i get around this? i couldnt figure out how to use -identify, it was
>not in the docs
>
>Thanks so much!
>
>- Noah
>
>----- Original Message -----
>From: "Morgan Curley" <[EMAIL PROTECTED]>
>Newsgroups: php.general
>Sent: Wednesday, April 18, 2001 5:55 PM
>Subject: Re: [PHP] how to scale down image using ImageMagick?
>
>
>according to the docs use
>-geometry 175x175> picture.jpeg
>
>man mogrify:
>   -geometry <width>x<height>{+-}<x offset>{+-}<y offset>{%}{!}{<}{>}
>                preferred width and height of the image.  See X(1) for
>details about the geometry specification.
>
>                By default, the width and height are maximum values.  That
>is, the image is expanded or contracted to
>                fit the width and height value while maintaining the aspect
>ratio of the image.  Append an exclamation
>                point to the geometry to force the image size to exactly the
>size you specify.  For example, if you
>                specify 640x480! the image width is set to 640 pixels and
>height to 480.  If only one factor is speci­
>                fied, both the width and height assume the value.
>
>                To specify a percentage width or height instead, append
>%.  The image size is multiplied by the width
>                and height percentages to obtain the final image
>dimensions.  To increase the size of an image, use a
>                value greater than 100 (e.g. 125%).  To decrease an image's
>size, use a percentage less than 100.
>
>                Use > to change the dimensions of the image only if its size
>exceeds the geometry specification.  <
>                resizes the image only if its dimensions is less than the
>geometry specification.  For example, if you
>                specify 640x480> and the image size is 512x512, the image
>size does not change.  However, if the image
>                is 1024x1024, it is resized to 640x480.
>
>it looks like mogrify bases its resizing on the first value that is diff
>than the one supplied i.e. if your image is 200x50 it will scale it to
>175x? but if it is 50x200 it will scale it to ?x175
>
>if it is important you not resize based on height use identify to get the
>geometry first.
>
>morgan
>
>
>At 04:27 PM 4/18/2001, Noah Spitzer-Williams wrote:
> >I have a bunch of pictures all in ranging filesizes and dimensions. I want
> >to resize the ones that over 175 pixels wide to a 175 pixel wide picture
> >however i want the height to scale down (ie. i dont want a really thin
> >picture, i just want it to be what it would be if it were resized). i have
> >this but i cant figure out how to just scale down the width:
> >
> >c:\progra~1\imagem~1\mogrify.exe -geometry 175x30! picture.jpeg
> >
> >the '!' forces those sizes to be used but obvoiusly i dont want the height
> >to be 30. i want it to be whatever it should be so the picture doesnt look
> >flattened.
> >
> >Thanks! - Noah
> >
> >
> >
> >--
> >PHP General Mailing List (http://www.php.net/)
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to