Page 1 of 1

Operating system, Imagemagick version pdf final size & dpi

Posted: 2013-11-18T11:41:34-07:00
by janezstefanec
Dear forum users, please help me to improve my script speed, get the paper white and chars black ready for use in e-books.

My current script is:

convert $i.jpg -matte -background none -virtual-pixel background
-distort Perspective "0,0 0,0 1998,0 1990,0 2003,1335 1998,1335 35,1325 0,1325" -trim -rotate -90 -quality 10 -sharpen 0x1.0 $i.pdf

I use the code to convert photos taken with two Canon 400D cameras on my book scanner robot at a speed of 2 scans per second (7200 scans per hour)

original photo from a camera exp. 1/80:
http://www.bookscanner.si/Anthony/capture000597.jpg
original photo from a camera exp. 1/60:
http://www.bookscanner.si/Anthony/capture000605.jpg
img size: 3189 x 2126 300 dpi

1/80 converted to a pdf: http://www.bookscanner.si/Anthony/3.pdf
1/60 converted to a pdf: http://www.bookscanner.si/Anthony/19.pdf

As you can see I have a couple of other problems:
some of the text shows through the page of the book.
There are some compression artefacts the pdf.

Should the photos be resized for the e-book pdf format before conversion?
Can I combine the perspective distort and rotate in a different distort command to improve the speed?

Thank you.

Re: Operating system, Imagemagick version pdf final size & d

Posted: 2013-11-18T12:55:17-07:00
by fmw42
You may be seeing jpg compression artifacts in your output. Have tried scanning either directly to pdf or to png or tiff to avoid the jpg compression issues?

Re: Operating system, Imagemagick version pdf final size & d

Posted: 2013-11-18T13:05:16-07:00
by Bonzo
The OP is using a canon dslr and the formats are either jpg or RAW.

Looking at the specifications for that camera " Continuous: 3.0 fps up to 27 JPEG / 10 RAW frames ". I would guess at the speed he is working RAW would fill the buffer after 10 photos.

Re: Operating system, Imagemagick version pdf final size & d

Posted: 2013-11-18T13:13:58-07:00
by snibgo
If you don't like the compression artefacts, don't use such a low quality number.