Skip to Content.
Sympa Menu

baslinux - [BL] double sided printing script

baslinux AT lists.ibiblio.org

Subject: Baslinux mailing list

List archive

Chronological Thread  
  • From: sindi keesan <keesan AT sdf.lonestar.org>
  • To: baslinux AT lists.ibiblio.org
  • Subject: [BL] double sided printing script
  • Date: Wed, 22 Mar 2006 01:48:06 +0000 (UTC)

I have a pdf file made by scanning a document (Bach Partita for keyboard No. 5 which I hope eventually to record as midi using Rosegarden) that I can convert with netpbm or gs (pdfimages or similar) to 20 sequentially numbered pbm files (black and white bit-mapped) which I can print one at a time with
ljtopbm filename.pbm > /dev/lp0
(plus a switch for resolution since the default is 150 dpi).

I want to print the even numbered files and then turn over the stack and print the odd numbered files starting from the highest number, for instance print 0, 2, 4, 6, 8.....20 and then turn over and print 19 17 15.......1 so I can use a three-ring binder and flip pages and see two pages at one time. (Otherwise I could print the first 10 pages then turn over and print the last 10).

I could split it up into two parts:

ljtopbm filename.pbm > filename.lj; cat filename.lj > /dev/lp0

for i in *; do ljtopbm $i.pbm > $i.lj; done ?????

But then how do I add 2 to a filename ending in 2 digits and cat the result to the printer?

Would there be a print buffer problem if I sent 20 pages to the printer at once? Gs is so slow to convert that it is the bottleneck, not the printer.

All suggestions welcome, even if they require gs or xpdf to print.

I should read about how to write scripts.

Sindi




Archive powered by MHonArc 2.6.24.

Top of Page