/* sane - Scanner Access Now Easy. Copyright (C) 1997 David Mosberger-Tang and Andreas Beck This file is part of the SANE package.
This file is in the public domain. You may use and modify it as you see fit, as long as this copyright message is included and that there is an indication as to what modifications have been made (if any).
SANE is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
This file declares SANE application interface. See the SANE
standard for a detailed explanation of the interface. */ #ifndef sane_h #define sane_h
typedefenum
{
SANE_STATUS_GOOD = 0, /* everything A-OK */
SANE_STATUS_UNSUPPORTED, /* operation is not supported */
SANE_STATUS_CANCELLED, /* operation was cancelled */
SANE_STATUS_DEVICE_BUSY, /* device is busy; try again later */
SANE_STATUS_INVAL, /* data is invalid (includes no dev at open) */
SANE_STATUS_EOF, /* no more data available (end-of-file) */
SANE_STATUS_JAMMED, /* document feeder jammed */
SANE_STATUS_NO_DOCS, /* document feeder out of documents */
SANE_STATUS_COVER_OPEN, /* scanner cover is open */
SANE_STATUS_IO_ERROR, /* error during device I/O */
SANE_STATUS_NO_MEM, /* out of memory */
SANE_STATUS_ACCESS_DENIED /* access to resource has been denied */
}
SANE_Status;
typedefenum
{
SANE_UNIT_NONE = 0, /* the value is unit-less (e.g., # of scans) */
SANE_UNIT_PIXEL, /* value is number of pixels */
SANE_UNIT_BIT, /* value is number of bits */
SANE_UNIT_MM, /* value is millimeters */
SANE_UNIT_DPI, /* value is resolution in dots/inch */
SANE_UNIT_PERCENT, /* value is a percentage */
SANE_UNIT_MICROSECOND /* value is micro seconds */
}
SANE_Unit;
typedefstruct
{
SANE_String_Const name; /* unique device name */
SANE_String_Const vendor; /* device vendor string */
SANE_String_Const model; /* device model name */
SANE_String_Const type; /* device type (e.g., "flatbed scanner") */
}
SANE_Device;
typedefstruct
{
SANE_Word min; /* minimum (element) value */
SANE_Word max; /* maximum (element) value */
SANE_Word quant; /* quantization value (0 if none) */
}
SANE_Range;
typedefstruct
{
SANE_String_Const name; /* name of this option (command-line name) */
SANE_String_Const title; /* title of this option (single-line) */
SANE_String_Const desc; /* description of this option (multi-line) */
SANE_Value_Type type; /* how are values interpreted? */
SANE_Unit unit; /* what is the (physical) unit? */
SANE_Int size;
SANE_Int cap; /* capabilities */
SANE_Constraint_Type constraint_type; union
{ const SANE_String_Const *string_list; /* NULL-terminated list */ const SANE_Word *word_list; /* first element is list-length */ const SANE_Range *range;
}
constraint;
}
SANE_Option_Descriptor;
typedefenum
{
SANE_FRAME_GRAY, /* band covering human visual range */
SANE_FRAME_RGB, /* pixel-interleaved red/green/blue bands */
SANE_FRAME_RED, /* red band only */
SANE_FRAME_GREEN, /* green band only */
SANE_FRAME_BLUE /* blue band only */
}
SANE_Frame;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.