Open michaelrsweet opened 3 years ago
@michaelrsweet @tillkamppeter new PR opened : #349
Commit 7190a0bc2ba9e9bd771dba9499a78a6845aae17e solves:
Please review the above in detail.
Commit e24d9e3357f470f0cc5f6242b4d90057bbbdf3bf marks this as done
Commit 317300f166f8fe61105cb94619dc649bb415e59f marks this as done
In order to support multi-function devices and standalone scanners, PAPPL should provide APIs, interfaces, and objects for scanning, with the goal of providing IPP Scan and/or eSCL protocol endpoints (eSCL is used for AirPrint and Mopria, IPP Scan is a published but otherwise unused standard that has the needed semantics/data elements) that can be linked to a printer object and/or used separately.
Specific sub-tasks:
pappl_scanner_t
object based onpappl_printer_t
(adapted to the needs of scanning - 90% duplication here)pappl_job_t
object to support print or scan jobs (add a pointer topappl_scanner_t
)pappl_sc_driver_data_t
structure based onpappl_pr_driver_data_t
, with corresponding callback functions using thepappl_sc_
prefix. For the purposes of PAPPL scanning, do not support vendor options.pappl_sc_options_t
structure based onpappl_pr_options_t
. For the purposes of PAPPL scanning, do not support vendor options.scanner.h
header with public API andscanner-private.h
header with private API using appropriately-named header guard macros. These can be patterned after the corresponding printer headers.scanner.c
file that provides the scanner object constructor and destructor.scanner-accessors.c
file that provides the scanner object accessor (get/set) functions, patterned onprinter-accessors.c
scanner-driver.c
file that provides the scan driver interfaces and attributes, patterned onprinter-driver.c
.scanner-webif.c
file that provides scan-specific web pages.job-scan.c
file that provides scan job processing functions.papplPrinterSetScanner
API to set the scanner associated with a printerpapplSystemSetScannerDrivers
API to set the list of scanner drivers, callback, etc.pappl_sc_autoadd_cb_t
,pappl_sc_create_cb_t
,pappl_sc_driver_cb_t
, andpappl_scanner_cb_t
callbacks tosystem.h
.Need to think about how to auto-associate scanners in printers.