Problem encountered during resizing.

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
helloworld
Posts: 69
Joined: 2013-05-22T09:42:33-07:00
Authentication code: 6789

Problem encountered during resizing.

Post by helloworld »

Hello,

I am trying to resize a image with the following command,

convert /tmp/PP_qfl7QW -verbose -strip -resize 200x200 -quality 99 -density 72x72 -units pixelsperinch /tmp/PP_bNI5iq

and its giving me a error like below,

convert: no decode delegate for this image format `/tmp/PP_qfl7QW' @ error/constitute.c/ReadImage/555.

I am not sure what does this mean? Am i missing any delegates?

Version which i installed on my machine is,

Version: ImageMagick 6.8.8-2 Q16 x86_64 2014-01-24 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2014 ImageMagick Studio LLC
Features: DPC OpenMP
Delegates: bzlib djvu fftw fontconfig freetype jbig jng jpeg lcms lqr lzma openexr pangocairo png tiff x xml zlib
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Problem encountered during resizing.

Post by snibgo »

This means it can't figure out what type of image is in the file "/tmp/PP_qfl7QW". What type of image is it? Can you see it in an image viewer? What happens with:

Code: Select all

identify /tmp/PP_qfl7QW
snibgo's IM pages: im.snibgo.com
helloworld
Posts: 69
Joined: 2013-05-22T09:42:33-07:00
Authentication code: 6789

Re: Problem encountered during resizing.

Post by helloworld »

when i do, identify /tmp/PP_qfl7QW,
It says identify: no decode delegate for this image format `/tmp/PP_qfl7QW' @ error/constitute.c/ReadImage/555.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Problem encountered during resizing.

Post by fmw42 »

I don't think it is a good idea to try to work with unlabeled tmp images from IM or anywhere else in your /tmp directory. If you need to work with it, first copy it out of the tmp directory and add its actual suffix as user snibgo has indicated. In any case, for IM, it is likely in MIFF format.
helloworld
Posts: 69
Joined: 2013-05-22T09:42:33-07:00
Authentication code: 6789

Re: Problem encountered during resizing.

Post by helloworld »

What we are doing is,

When ever a person uploads a original image, we are storing that image in tmp folder as PP_cbgdt56ty and we are converting that tmp file to different dimensions..
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Problem encountered during resizing.

Post by fmw42 »

I would not store it in /tmp, but in some special directory for your use. Other tools may leave files there. Eventually you may need to purge /tmp. Furthermore, it clogs up the directory with your working files and provides less room for IM and other functions to work.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Problem encountered during resizing.

Post by snibgo »

So you don't know if it is a corrupt image or something malicious. As IM doesn't recognise it as an image, I suggest you treat it as junk.
snibgo's IM pages: im.snibgo.com
Post Reply