next up previous contents index
次へ: Option Descriptor Type 上へ: Data Types 戻る: Status Type   目次   索引

Device Descriptor Type

Each SANE device is represented by a structure of type SANE_Device. The C declaration of this type is given below.

typedef struct
  {
    SANE_String_Const name;
    SANE_String_Const vendor;
    SANE_String_Const model;
    SANE_String_Const type;
  }
SANE_Device;
The structure provides the unique name of the scanner in member name. It is this unique name that should be passed in a call to sane_open(). The format of this name is completely up to the backend. The only constraints are that the name is unique among all devices supported by the backend and that the name is a legal SANE text string. To simplify presentation of unique names, their length should not be excessive. It is recommended that backends keep unique names below 32 characters in length. However, applications must be able to cope with arbitrary length unique names.

The remaining members in the device structure provide additional information on the device corresponding to the unique name. Specifically, members vendor, model, and type are single-line strings that give information on the vendor (manufacturer), model, and the type of the device. For consistency's sake, the following strings should be used when appropriate (the lists will be expanded as need arises):


表 4.2: Predefined Device Information Strings
Vendor Strings
AGFA Microtek
Abaton Minolta
Acer Mustek
Apple NEC
Artec Nikon
Avision Plustek
CANON Polaroid
Connectix Ricoh
Epson Sharp
Fujitsu Siemens
Hewlett-Packard Tamarack
IBM UMAX
Kodak Noname
Logitech  
Type Strings
film scanner
flatbed scanner
frame grabber
handheld scanner
multi-function peripheral
sheetfed scanner
still camera
video camera
virtual device


Note that vendor string Noname can be used for virtual devices that have no physical vendor associated. Also, there are no predefined model name strings since those are vendor specific and therefore completely under control of the respective backends.


next up previous contents index
次へ: Option Descriptor Type 上へ: Data Types 戻る: Status Type   目次   索引
MATSUBAYASHI 'Shaolin' Kohji 平成14年10月29日