[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: how to detect if a jpeg file is progressive or not

Olafur Jens Sigurdsson wrote:

> Imagemagick does the trick for you.
> To see if your files are interlaced or not you can use identify
> -verbose filename.jpg and search for the Interlace line and if it says
> None then it isnt a progressive jpeg and if it says Plane it is.

That was really great help. Thank a ton. The problem of identifying an
image as progressive or not is solved.

> To convert from basic to progressive use convert infile.jpg -interlace
> Plane outfile.jpg

The problem left is to convert all my current jpegs into progressive
ones. jpegtran did the job (the following is one long command):
$> for f in *.jpg; do echo "$f"; mv "$f" tmp.jpg; jpegtran  -progressive
tmp.jpg  > "$f"; rm -f tmp.jpg; done

(I am sure there is a way to use the stdout and stdin in this procedure
instead of tmp.jpg, but I didn't check)


Reply to: