Scanning quality & formats |
Xsane, Sane, Scanimage |
Adding text with Convert |
Convert and Ps2pdf |
Merging pdf files
1 Scanning quality & formats - PDF or PS
1.1 recommended settings
- 150dpi bw - if no comments need being inserted (such as the source or name of the document scanned) or for on-screen use only
- 300dpi for text or 600dpi for photos - colour (you can easily resample 600 or 300 to 150dpi & 'convert' using 'monochrome' for smaller files)
1.2 recommended formats
- either save directly as pdf if no further editing required
- or save as ps, carry out required editing and then convert ps to pdf
2 Scanning alternatives - XSANE / SANE / SCANIMAGE
- use a GUI [graphical user interface] with Xsane (or The Gimp with 'sane' plugin) if you need to select precisely the margins
- use a command line from the terminal (eg. xterm)
sane > page.ps
scanimage --formatted-device-list=plustek:libusb:001:003 scanimage -p --mode Gray --resolution 150 --brightness 20 \ --speed -l 2 -t 2 -x 178 -y 262 -B > pg01.pnm
scanimage --formatted-device-list=plustek:libusb:001:003 scanimage --batch-start=pg00 --batch-count=1 --batch-increment=1 \ --batch-prompt -p --mode Gray --resolution 150 \ --brightness 20 --speed -l 2 -t 2 -x 178 -y 262
3 Adding text with CONVERT (minimum 300dpi)
3.1 position comment at the top of the page
- example 1
convert -pointsize 16 -draw "text 150,13 'Title of the book - Company \ - User group" -fill black page01.ps page01.pdf
convert -font Bookman-DemiItalic -pointsize 16 -draw "text 120,13 'Title \ of the book - Company - User group" -fill black page01.ps page01.pdf
3.2 or position comment at the bottom of the page
- example 1
convert -pointsize 10 -draw "text 150,738 'Title of the book - Company \ - User group" -fill black page01.ps page01.pdf
convert -font Bookman-DemiItalic -pointsize 16 -draw "text 120,732 'Title \ of the book - Company - User group" -fill black page01.ps page01.pdf convert -pointsize 10 -draw "text 150,738 'Title of the book - Company \ - User group" -fill black page01.ps page01.pdf
4 Adding text with CONVERT and PS2PDF
(original is below 300dpi)
- avoid using function 'convert' to both insert a comment & produce a pdf in one go if the document was scanned with less than 300dpi
- first, if you scanned directly into pdf you need to generate a ps file
pdf2ps page01.pdf
convert -font Bookman-DemiItalic -pointsize 10 -draw "text 120,13 'Title \ of the book - Company - User group" -fill red page01.ps page01_with_title.ps
ps2pdf page01_with_title.ps
page01_with_title.pdf
5 Merging scanned files into a single, multi-page pdf file
- put all the required pdf files into a new temporary directory (to avoid including unnecessary files during the join process)
- rename pdf files in the right order if relevant (eg: page00.pdf, page01.pdf. page02.pdf, etc)
- run the following command
pdfjoin *.pdf
page02-joined.pdf