Page 1 of 1

Problem converting JPG

Posted: 2013-05-21T08:18:13-07:00
by hexmode
I'm running into a weird error with this image: http://php.med.unsw.edu.au/cellbiology/ ... ing_03.jpg

Running display shows the image. Identify doesn't show anything weird, but convert refuses to convert anything:

$ convert --version
Version: ImageMagick 6.7.7-10 2012-11-06 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2012 ImageMagick Studio LLC
Features: OpenMP

$ convert -scale 50x50 Nuclear_reprogramming_03.jpg
convert.im6: no images defined `Nuclear_reprogramming_03.jpg' @ error/convert.c/ConvertImageCommand/3044.

(The version I'm using is from http://packages.debian.org/wheezy/imagemagick, so I can report this there if it is a problem that has been fixed already.)

Re: Problem converting JPG

Posted: 2013-05-21T08:20:50-07:00
by hexmode
Original user with the problem is here: https://www.mediawiki.org/wiki/Thread:P ... 2_problems

Re: Problem converting JPG

Posted: 2013-05-21T09:38:18-07:00
by glennrp
You need to specify the destination file for convert, e.g,,

Code: Select all

convert -scale 50x50 Nuclear_reprogramming_03.jpg Nuclear_reprogramming_03_converted.jpg

Re: Problem converting JPG

Posted: 2013-05-21T09:41:37-07:00
by snibgo

Code: Select all

$ convert -scale 50x50 Nuclear_reprogramming_03.jpg
"convert" needs an output filename.

Re: Problem converting JPG

Posted: 2013-05-21T10:30:33-07:00
by fmw42
correct IM 6 syntax is

convert input -scale WxH output

It is not a good idea to do the scale before your input image

Re: Problem converting JPG

Posted: 2013-05-21T10:47:01-07:00
by glennrp
It is not a good idea to do the scale before your input image
Agreed. I should have suggested

Code: Select all

convert  Nuclear_reprogramming_03.jpg -scale 50x50 Nuclear_reprogramming_03_scaled.jpg

Re: Problem converting JPG

Posted: 2013-05-28T20:54:12-07:00
by anthony
IMv7 will complain that scale has no image