alexpevzner / sane-airscan

Scanner Access Now Easy - universal driver for eSCL (Apple AirScan) and WSD
Other
289 stars 44 forks source link

Merge scan-intent parameter support into the main branch #353

Closed alexpevzner closed 1 week ago

alexpevzner commented 1 week ago

Both eSCL and WSD contains a very similar parameter, called Intent in the eSCL and ContentType in the WSD, which hints the scanner on the purpose of the scan request, letting scanner to choose optimal scan parameters.

Intent is documented in the Mopria eSCL Scan Specification, chapter 5 (https://mopria.org/mopria-escl-specification).

ContentType is documented by Microsoft here (https://learn.microsoft.com/en-us/windows-hardware/drivers/image/contenttypevalue) and here (https://learn.microsoft.com/en-us/windows-hardware/drivers/image/contenttype).

This patch (mostly contributed by @alvinhochun and polished by me), brings the uniform, protocol-independent access to this parameter into the set of scanner options, supported by sane-airscan