> > - a separate process is forked which reads data from the
> > scanner and delivers the data to the parent process.
> > Unlike several other backends, which also fork a reader
> > process and transfer the data to parent process through
> > a pipe, the Sharp backend uses shared memory for this
> > purpose.
>
> May I ask why?
Firstly, because I did not get a sufficiently fast reader
process using a pipe - at least for the Sharp JX-250.
This scanner is a relatively fast scanner (the data
transfer for an A4 gray scale scan with 400 dpi needs
less than 10 seconds), but has obviously only a very small
internal buffer. In order to avoid carriage stops, the
reader process must issue a read command to the scanner as
soon as possible after processing the data from the
previous read command. Writing the scan data into a pipe
needs, at least on a P166 under Linux, enough time to
cause some carriage stops.
Secondly, with shared memory it is easy to use a larger
buffer. This can avoid some carriage stops if the frontend
is temporarily too slow to read the scan data as fast as it
is delivered by the backend.
Abel
-- Source code, list archive, and docs: http://www.mostang.com/sane/ To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com