DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

scanimage(1)


scanimage -- scans an image

Synopsis

scanimage [-d|--device-name dev] [-h|--help] [-L|--list-devices] [-T|--test] [-v|--verbose] [-V|--version] [device-specific-options]

Description

scanimage 1 is a command-line interface to control image acquisition devices such as flatbed scanners or cameras. The device is controlled via command-line options. After command-line processing, scanimage normally proceeds to acquire an image. The image data is written to standard output in one of the PNM (portable aNyMaP) formats (PBM for black and white images, PGM for grayscale images, and PPM for color images). scanimage accesses image acquisition devices through the SANE (Scanner Access Now Easy) interface and can support any device for which there exists a SANE backend.

Options


-d or --device-name
must be followed by a SANE device-name. A (partial) list of available devices can be obtained with the --list-devices option. If no device-name is specified explicitly, scanimage will attempt to open the first available device.

-h or --help
requests help information. The information is printed on standard output and in this case, no attempt will be made to acquire an image.

-L or --list-devices
requests a (partial) list of devices that are available. The list is not complete since some devices may be available, but are not listed in any of the configuration files (which are typically stored in directory /usr/local/etc/sane.d). This is particularly the case when accessing scanners through the network. If a device is not listed in a configuration file, the only way to access it is by its full device name.

-T or --test
requests that scanimage perform a few simple sanity tests to make sure the backend works as defined by the SANE API (in particular the sane_read function is exercised by this test).

-v or --verbose
increases the verbosity of the operation of scanimage. The option may be specified repeatedly, each time increasing the verbosity level.

Much of the power of scanimage comes from the fact that it can control any SANE backend. Thus, the exact set of command-line options depends on the capabilities of the selected device. To see the options for a device named dev, invoke scanimage using:

scanimage --help --device-name dev

The documentation for the device-specific options printed by --help is best explained with a few examples:


--brightness -100..100% [0]
Controls the brightness of the acquired image.

The option --brightness expects an option value in the range from -100 to 100 percent. The value in square brackets indicates that the current option value is 0 percent.


--default-enhancements
Set default values for enhancement controls.

The option --default-enhancements has no option value. It should be thought of as having an immediate effect at the point of the command line at which it appears. For example, since this option resets the --brightness option, the option-pair --brightness 50 --default-enhancements would have no effect and the options would be set to defaults.


--mode Lineart|Gray|Color [Gray]
Selects the scan mode (Line Art, gray or color).

The option --mode accepts an argument that must be one of the strings ``Lineart'', ``Gray'', or ``Color''. The value in the square bracket indicates that the option is currently set to ``Gray''. For convenience, it is legal to abbreviate the string values as long as they remain unique. It is case-insensitive. For example, option setting --mode col is identical to --mode Color.


--custom-gamma[=(yes|no)] [inactive]
Determines whether a built-in or a custom gamma-table should be used.

The option --custom-gamma expects either a ``no'' option value, or a ``yes'' option value. The value in square-brackets indicates that the option is not currently active. Attempting to set the option would result in an error message. The set of available options typically depends on the settings of other options. For example, the --custom-gamma table might be active only when a grayscale or color scan mode has been requested.

Note that the --help option is processed only after all other options have been processed. This makes it possible to see the option settings for a particular mode by specifying the appropriate mode-options along with the --help option. For example, the command line:

scanimage --help --mode color

would print the option settings that are in effect when the color-mode is selected.


--gamma-table 0..255,...
Gamma-correction table. In color mode this option equally affects the red, green, and blue channels simultaneously (it is an intensity gamma table).

The option --gamma-table expects zero or more values in the range 0 to 255. For example, a legal value for this option would be ``3,4,5,6,7,8,9,10,11,12''. Since it is cumbersome to specify long vectors in this form, the same can be expressed by the abbreviated form ``[0]3-[9]12''. This means that the first vector element is set to 0, the 9-th element is set to 12 and the values in between are interpolated linearly. It is possible to specify multiple such linear segments. For example, ``[0]3-[2]3-[6]7,[7]10-[9]6'' is equivalent to ``3,3,3,4,5,6,7,10,8,6''.


--filename string [/tmp/input.ppm]
The filename of the image to be loaded.

The option takes an arbitrary string value (which happens to be a filename). The value in brackets shows that the option is currently set to the filename /tmp/input.ppm.

Files


/usr/local/etc/sane.d
This directory holds the various configuration files.

References

sane-abaton(5), sane-agfafocus(5), sane-apple(5), saned(1), sane-dc25(5), sane-dll(5), sane-dmc(5), sane-epson(5), sane-hp(5), sane-microtek(5), sane-microtek2(5), sane-mustek(5), sane-net(5), sane-pnm(5), sane-pint(5), sane-umax(5) xsane(1), xscanimage(1)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004