Page 1 of 1

Joining MANY images into a single PDF.

Posted: 2009-09-22T06:06:15-07:00
by RQuadling
Hi.

I've got 264 images which I want to bind into a single PDF file.

I can do this at the command line for a few images ...

Code: Select all

convert img1.tif img2.tif img3.tif big.pdf
and that works fine.

But the actual filenames are ...

Code: Select all

\\BV-CLUSTER-FILE\BANDVULCFAXESRECEIVED\2009\01\22\2009-01-22__09-45__Page-0153__11SAEAJ0.tif
\\BV-CLUSTER-FILE\BANDVULCFAXESRECEIVED\2009\01\22\2009-01-22__09-45__Page-0154__12161ASD.tif
\\BV-CLUSTER-FILE\BANDVULCFAXESRECEIVED\2009\05\29\2009-05-29__09-27__Page-0156__12IXGJHM.tif
So I get a line WAY too long for processing.

I see from

Code: Select all

convert -h
that I can use - as the input.

So, I thought

Code: Select all

convert -write big.pdf -
and then simply paste the filenames to the console.

But nope. I get an error ...

Code: Select all

[Z:\] >convert - z:\big.pdf
convert: no decode delegate for this image format `C:/DOCUME~1/RichardQ/LOCALS~1/Temp/magick-w0Ejp0Ju' @ constitute.c/ReadImage/503.
convert: missing an image filename `z:\big.pdf' @ convert.c/ConvertImageCommand/2772.

[Z:\] >convert - -write z:\big.pdf
convert: no decode delegate for this image format `C:/DOCUME~1/RichardQ/LOCALS~1/Temp/magick-9b-KUPZQ' @ constitute.c/ReadImage/503.
convert: option requires an argument `-write' @ convert.c/ConvertImageCommand/2752.

[Z:\] >convert -write z:\big.pdf -
convert: missing an image filename `-' @ convert.c/ConvertImageCommand/2772.

[Z:\] >convert -write z:\big.pdf
convert: option requires an argument `-write' @ convert.c/ConvertImageCommand/2752.

[Z:\] >convert -write z:\big.pdf
convert: option requires an argument `-write' @ convert.c/ConvertImageCommand/2752.

[Z:\] >convert -write z:\big.pdf --
convert: missing an image filename `--' @ convert.c/ConvertImageCommand/2772.

[Z:\] >convert -write z:\big.pdf -
convert: missing an image filename `-' @ convert.c/ConvertImageCommand/2772.

[Z:\] >convert -- -write z:\big.pdf
convert: unable to open image `-write': No such file or directory @ blob.c/OpenBlob/2476.
convert: missing an image filename `z:\big.pdf' @ convert.c/ConvertImageCommand/2772.

[Z:\] >convert -write z:\big.pdf -adjoin -
convert: missing an image filename `-' @ convert.c/ConvertImageCommand/2772.
What am missing please?

Regards,

Richard Quadling.

Re: Joining MANY images into a single PDF.

Posted: 2009-09-22T09:16:47-07:00
by fmw42
You will likely need to write a script to add them one at a time (or a few at a time).

For example:

convert rose: rose.pdf
convert rose: rose.pdf rose.pdf
convert rose: rose.pdf rose.pdf

identify rose.pdf
identify rose.pdf
rose.pdf[0] PDF 70x46 70x46+0+0 16-bit Bilevel DirectClass 1.39kb
rose.pdf[1] PDF 70x46 70x46+0+0 16-bit Bilevel DirectClass 1.39kb
rose.pdf[2] PDF 70x46 70x46+0+0 16-bit Bilevel DirectClass 1.39kb

Re: Joining MANY images into a single PDF.

Posted: 2009-09-28T02:44:26-07:00
by RQuadling
Thank you.